1 //===- PPCSchedule.td - PowerPC Scheduling Definitions -----*- tablegen -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 //===----------------------------------------------------------------------===//
11 // Functional units across PowerPC chips sets
13 def BPU : FuncUnit; // Branch unit
14 def SLU : FuncUnit; // Store/load unit
15 def SRU : FuncUnit; // special register unit
16 def IU1 : FuncUnit; // integer unit 1 (simple)
17 def IU2 : FuncUnit; // integer unit 2 (complex)
18 def IU3 : FuncUnit; // integer unit 3 (7450 simple)
19 def IU4 : FuncUnit; // integer unit 4 (7450 simple)
20 def FPU1 : FuncUnit; // floating point unit 1
21 def FPU2 : FuncUnit; // floating point unit 2
22 def VPU : FuncUnit; // vector permutation unit
23 def VIU1 : FuncUnit; // vector integer unit 1 (simple)
24 def VIU2 : FuncUnit; // vector integer unit 2 (complex)
25 def VFPU : FuncUnit; // vector floating point unit
28 //===----------------------------------------------------------------------===//
29 // Instruction Itinerary classes used for PowerPC
31 def IntGeneral : InstrItinClass;
32 def IntCompare : InstrItinClass;
33 def IntDivD : InstrItinClass;
34 def IntDivW : InstrItinClass;
35 def IntMFFS : InstrItinClass;
36 def IntMFVSCR : InstrItinClass;
37 def IntMTFSB0 : InstrItinClass;
38 def IntMTSRD : InstrItinClass;
39 def IntMulHD : InstrItinClass;
40 def IntMulHW : InstrItinClass;
41 def IntMulHWU : InstrItinClass;
42 def IntMulLI : InstrItinClass;
43 def IntRFID : InstrItinClass;
44 def IntRotateD : InstrItinClass;
45 def IntRotate : InstrItinClass;
46 def IntShift : InstrItinClass;
47 def IntTrapD : InstrItinClass;
48 def IntTrapW : InstrItinClass;
49 def BrB : InstrItinClass;
50 def BrCR : InstrItinClass;
51 def BrMCR : InstrItinClass;
52 def BrMCRX : InstrItinClass;
53 def LdStDCBA : InstrItinClass;
54 def LdStDCBF : InstrItinClass;
55 def LdStDCBI : InstrItinClass;
56 def LdStGeneral : InstrItinClass;
57 def LdStDSS : InstrItinClass;
58 def LdStICBI : InstrItinClass;
59 def LdStUX : InstrItinClass;
60 def LdStLD : InstrItinClass;
61 def LdStLDARX : InstrItinClass;
62 def LdStLFD : InstrItinClass;
63 def LdStLFDU : InstrItinClass;
64 def LdStLHA : InstrItinClass;
65 def LdStLMW : InstrItinClass;
66 def LdStLVecX : InstrItinClass;
67 def LdStLWA : InstrItinClass;
68 def LdStLWARX : InstrItinClass;
69 def LdStSLBIA : InstrItinClass;
70 def LdStSLBIE : InstrItinClass;
71 def LdStSTD : InstrItinClass;
72 def LdStSTDCX : InstrItinClass;
73 def LdStSTVEBX : InstrItinClass;
74 def LdStSTWCX : InstrItinClass;
75 def LdStSync : InstrItinClass;
76 def SprISYNC : InstrItinClass;
77 def SprMFSR : InstrItinClass;
78 def SprMTMSR : InstrItinClass;
79 def SprMTSR : InstrItinClass;
80 def SprTLBSYNC : InstrItinClass;
81 def SprMFCR : InstrItinClass;
82 def SprMFMSR : InstrItinClass;
83 def SprMFSPR : InstrItinClass;
84 def SprMFTB : InstrItinClass;
85 def SprMTSPR : InstrItinClass;
86 def SprMTSRIN : InstrItinClass;
87 def SprRFI : InstrItinClass;
88 def SprSC : InstrItinClass;
89 def FPGeneral : InstrItinClass;
90 def FPCompare : InstrItinClass;
91 def FPDivD : InstrItinClass;
92 def FPDivS : InstrItinClass;
93 def FPFused : InstrItinClass;
94 def FPRes : InstrItinClass;
95 def FPSqrt : InstrItinClass;
96 def VecGeneral : InstrItinClass;
97 def VecFP : InstrItinClass;
98 def VecFPCompare : InstrItinClass;
99 def VecComplex : InstrItinClass;
100 def VecPerm : InstrItinClass;
101 def VecFPRound : InstrItinClass;
102 def VecVSL : InstrItinClass;
103 def VecVSR : InstrItinClass;
105 //===----------------------------------------------------------------------===//
106 // Processor instruction itineraries.
108 include "PPCScheduleG3.td"
109 include "PPCScheduleG4.td"
110 include "PPCScheduleG4Plus.td"
111 include "PPCScheduleG5.td"
113 //===----------------------------------------------------------------------===//
114 // Instruction to itinerary class map - When add new opcodes to the supported
115 // set, refer to the following table to determine which itinerary class the
118 // opcode itinerary class
119 // ====== ===============
156 // dcbtst LdStGeneral
331 // sthbrx LdStGeneral
344 // stwbrx LdStGeneral
360 // tlbsync SprTLBSYNC
363 // vaddcuw VecGeneral
365 // vaddsbs VecGeneral
366 // vaddshs VecGeneral
367 // vaddsws VecGeneral
368 // vaddubm VecGeneral
369 // vaddubs VecGeneral
370 // vadduhm VecGeneral
371 // vadduhs VecGeneral
372 // vadduwm VecGeneral
373 // vadduws VecGeneral
384 // vcmpbfp VecFPCompare
385 // vcmpeqfp VecFPCompare
386 // vcmpequb VecGeneral
387 // vcmpequh VecGeneral
388 // vcmpequw VecGeneral
389 // vcmpgefp VecFPCompare
390 // vcmpgtfp VecFPCompare
391 // vcmpgtsb VecGeneral
392 // vcmpgtsh VecGeneral
393 // vcmpgtsw VecGeneral
394 // vcmpgtub VecGeneral
395 // vcmpgtuh VecGeneral
396 // vcmpgtuw VecGeneral
402 // vmaxfp VecFPCompare
409 // vmhaddshs VecComplex
410 // vmhraddshs VecComplex
411 // vminfp VecFPCompare
418 // vmladduhm VecComplex
426 // vmsummbm VecComplex
427 // vmsumshm VecComplex
428 // vmsumshs VecComplex
429 // vmsumubm VecComplex
430 // vmsumuhm VecComplex
431 // vmsumuhs VecComplex
432 // vmulesb VecComplex
433 // vmulesh VecComplex
434 // vmuleub VecComplex
435 // vmuleuh VecComplex
436 // vmulosb VecComplex
437 // vmulosh VecComplex
438 // vmuloub VecComplex
439 // vmulouh VecComplex
482 // vsubcuw VecGeneral
484 // vsubsbs VecGeneral
485 // vsubshs VecGeneral
486 // vsubsws VecGeneral
487 // vsububm VecGeneral
488 // vsububs VecGeneral
489 // vsubuhm VecGeneral
490 // vsubuhs VecGeneral
491 // vsubuwm VecGeneral
492 // vsubuws VecGeneral
493 // vsum2sws VecComplex
494 // vsum4sbs VecComplex
495 // vsum4shs VecComplex
496 // vsum4ubs VecComplex
497 // vsumsws VecComplex