10b57cec5SDimitry Andric//===-- X86Schedule.td - X86 Scheduling Definitions --------*- tablegen -*-===// 20b57cec5SDimitry Andric// 30b57cec5SDimitry Andric// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 40b57cec5SDimitry Andric// See https://llvm.org/LICENSE.txt for license information. 50b57cec5SDimitry Andric// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 60b57cec5SDimitry Andric// 70b57cec5SDimitry Andric//===----------------------------------------------------------------------===// 80b57cec5SDimitry Andric 90b57cec5SDimitry Andric//===----------------------------------------------------------------------===// 100b57cec5SDimitry Andric// InstrSchedModel annotations for out-of-order CPUs. 110b57cec5SDimitry Andric 120b57cec5SDimitry Andric// Instructions with folded loads need to read the memory operand immediately, 130b57cec5SDimitry Andric// but other register operands don't have to be read until the load is ready. 140b57cec5SDimitry Andric// These operands are marked with ReadAfterLd. 150b57cec5SDimitry Andricdef ReadAfterLd : SchedRead; 160b57cec5SDimitry Andricdef ReadAfterVecLd : SchedRead; 170b57cec5SDimitry Andricdef ReadAfterVecXLd : SchedRead; 180b57cec5SDimitry Andricdef ReadAfterVecYLd : SchedRead; 190b57cec5SDimitry Andric 200b57cec5SDimitry Andric// Instructions that move data between general purpose registers and vector 210b57cec5SDimitry Andric// registers may be subject to extra latency due to data bypass delays. 220b57cec5SDimitry Andric// This SchedRead describes a bypass delay caused by data being moved from the 230b57cec5SDimitry Andric// integer unit to the floating point unit. 240b57cec5SDimitry Andricdef ReadInt2Fpu : SchedRead; 250b57cec5SDimitry Andric 260b57cec5SDimitry Andric// Instructions with both a load and a store folded are modeled as a folded 270b57cec5SDimitry Andric// load + WriteRMW. 280b57cec5SDimitry Andricdef WriteRMW : SchedWrite; 290b57cec5SDimitry Andric 300b57cec5SDimitry Andric// Helper to set SchedWrite ExePorts/Latency/ResourceCycles/NumMicroOps. 310b57cec5SDimitry Andricmulticlass X86WriteRes<SchedWrite SchedRW, 320b57cec5SDimitry Andric list<ProcResourceKind> ExePorts, 330b57cec5SDimitry Andric int Lat, list<int> Res, int UOps> { 340b57cec5SDimitry Andric def : WriteRes<SchedRW, ExePorts> { 350b57cec5SDimitry Andric let Latency = Lat; 360b57cec5SDimitry Andric let ResourceCycles = Res; 370b57cec5SDimitry Andric let NumMicroOps = UOps; 380b57cec5SDimitry Andric } 390b57cec5SDimitry Andric} 400b57cec5SDimitry Andric 410b57cec5SDimitry Andric// Most instructions can fold loads, so almost every SchedWrite comes in two 420b57cec5SDimitry Andric// variants: With and without a folded load. 430b57cec5SDimitry Andric// An X86FoldableSchedWrite holds a reference to the corresponding SchedWrite 440b57cec5SDimitry Andric// with a folded load. 450b57cec5SDimitry Andricclass X86FoldableSchedWrite : SchedWrite { 460b57cec5SDimitry Andric // The SchedWrite to use when a load is folded into the instruction. 470b57cec5SDimitry Andric SchedWrite Folded; 480b57cec5SDimitry Andric // The SchedRead to tag register operands than don't need to be ready 490b57cec5SDimitry Andric // until the folded load has completed. 500b57cec5SDimitry Andric SchedRead ReadAfterFold; 510b57cec5SDimitry Andric} 520b57cec5SDimitry Andric 530b57cec5SDimitry Andric// Multiclass that produces a linked pair of SchedWrites. 540b57cec5SDimitry Andricmulticlass X86SchedWritePair<SchedRead ReadAfter = ReadAfterLd> { 550b57cec5SDimitry Andric // Register-Memory operation. 560b57cec5SDimitry Andric def Ld : SchedWrite; 570b57cec5SDimitry Andric // Register-Register operation. 580b57cec5SDimitry Andric def NAME : X86FoldableSchedWrite { 590b57cec5SDimitry Andric let Folded = !cast<SchedWrite>(NAME#"Ld"); 600b57cec5SDimitry Andric let ReadAfterFold = ReadAfter; 610b57cec5SDimitry Andric } 620b57cec5SDimitry Andric} 630b57cec5SDimitry Andric 640b57cec5SDimitry Andric// Helpers to mark SchedWrites as unsupported. 650b57cec5SDimitry Andricmulticlass X86WriteResUnsupported<SchedWrite SchedRW> { 660b57cec5SDimitry Andric let Unsupported = 1 in { 670b57cec5SDimitry Andric def : WriteRes<SchedRW, []>; 680b57cec5SDimitry Andric } 690b57cec5SDimitry Andric} 700b57cec5SDimitry Andricmulticlass X86WriteResPairUnsupported<X86FoldableSchedWrite SchedRW> { 710b57cec5SDimitry Andric let Unsupported = 1 in { 720b57cec5SDimitry Andric def : WriteRes<SchedRW, []>; 730b57cec5SDimitry Andric def : WriteRes<SchedRW.Folded, []>; 740b57cec5SDimitry Andric } 750b57cec5SDimitry Andric} 760b57cec5SDimitry Andric 770b57cec5SDimitry Andric// Multiclass that wraps X86FoldableSchedWrite for each vector width. 780b57cec5SDimitry Andricclass X86SchedWriteWidths<X86FoldableSchedWrite sScl, 790b57cec5SDimitry Andric X86FoldableSchedWrite s128, 800b57cec5SDimitry Andric X86FoldableSchedWrite s256, 810b57cec5SDimitry Andric X86FoldableSchedWrite s512> { 820b57cec5SDimitry Andric X86FoldableSchedWrite Scl = sScl; // Scalar float/double operations. 830b57cec5SDimitry Andric X86FoldableSchedWrite MMX = sScl; // MMX operations. 840b57cec5SDimitry Andric X86FoldableSchedWrite XMM = s128; // XMM operations. 850b57cec5SDimitry Andric X86FoldableSchedWrite YMM = s256; // YMM operations. 860b57cec5SDimitry Andric X86FoldableSchedWrite ZMM = s512; // ZMM operations. 870b57cec5SDimitry Andric} 880b57cec5SDimitry Andric 890b57cec5SDimitry Andric// Multiclass that wraps X86SchedWriteWidths for each fp vector type. 900b57cec5SDimitry Andricclass X86SchedWriteSizes<X86SchedWriteWidths sPS, 910b57cec5SDimitry Andric X86SchedWriteWidths sPD> { 920b57cec5SDimitry Andric X86SchedWriteWidths PS = sPS; 930b57cec5SDimitry Andric X86SchedWriteWidths PD = sPD; 940b57cec5SDimitry Andric} 950b57cec5SDimitry Andric 960b57cec5SDimitry Andric// Multiclass that wraps move/load/store triple for a vector width. 970b57cec5SDimitry Andricclass X86SchedWriteMoveLS<SchedWrite MoveRR, 980b57cec5SDimitry Andric SchedWrite LoadRM, 990b57cec5SDimitry Andric SchedWrite StoreMR> { 1000b57cec5SDimitry Andric SchedWrite RR = MoveRR; 1010b57cec5SDimitry Andric SchedWrite RM = LoadRM; 1020b57cec5SDimitry Andric SchedWrite MR = StoreMR; 1030b57cec5SDimitry Andric} 1040b57cec5SDimitry Andric 1058bcb0991SDimitry Andric// Multiclass that wraps masked load/store writes for a vector width. 1068bcb0991SDimitry Andricclass X86SchedWriteMaskMove<SchedWrite LoadRM, SchedWrite StoreMR> { 1078bcb0991SDimitry Andric SchedWrite RM = LoadRM; 1088bcb0991SDimitry Andric SchedWrite MR = StoreMR; 1098bcb0991SDimitry Andric} 1108bcb0991SDimitry Andric 1110b57cec5SDimitry Andric// Multiclass that wraps X86SchedWriteMoveLS for each vector width. 1120b57cec5SDimitry Andricclass X86SchedWriteMoveLSWidths<X86SchedWriteMoveLS sScl, 1130b57cec5SDimitry Andric X86SchedWriteMoveLS s128, 1140b57cec5SDimitry Andric X86SchedWriteMoveLS s256, 1150b57cec5SDimitry Andric X86SchedWriteMoveLS s512> { 1160b57cec5SDimitry Andric X86SchedWriteMoveLS Scl = sScl; // Scalar float/double operations. 1170b57cec5SDimitry Andric X86SchedWriteMoveLS MMX = sScl; // MMX operations. 1180b57cec5SDimitry Andric X86SchedWriteMoveLS XMM = s128; // XMM operations. 1190b57cec5SDimitry Andric X86SchedWriteMoveLS YMM = s256; // YMM operations. 1200b57cec5SDimitry Andric X86SchedWriteMoveLS ZMM = s512; // ZMM operations. 1210b57cec5SDimitry Andric} 1220b57cec5SDimitry Andric 1230b57cec5SDimitry Andric// Loads, stores, and moves, not folded with other operations. 1240b57cec5SDimitry Andricdef WriteLoad : SchedWrite; 1250b57cec5SDimitry Andricdef WriteStore : SchedWrite; 1260b57cec5SDimitry Andricdef WriteStoreNT : SchedWrite; 1270b57cec5SDimitry Andricdef WriteMove : SchedWrite; 1280b57cec5SDimitry Andricdef WriteCopy : WriteSequence<[WriteLoad, WriteStore]>; // mem->mem copy 1290b57cec5SDimitry Andric 1300b57cec5SDimitry Andric// Arithmetic. 1310b57cec5SDimitry Andricdefm WriteALU : X86SchedWritePair; // Simple integer ALU op. 1320b57cec5SDimitry Andricdefm WriteADC : X86SchedWritePair; // Integer ALU + flags op. 1330b57cec5SDimitry Andricdef WriteALURMW : WriteSequence<[WriteALULd, WriteRMW]>; 1340b57cec5SDimitry Andricdef WriteADCRMW : WriteSequence<[WriteADCLd, WriteRMW]>; 1350b57cec5SDimitry Andricdef WriteLEA : SchedWrite; // LEA instructions can't fold loads. 1360b57cec5SDimitry Andric 1370b57cec5SDimitry Andric// Integer multiplication 1380b57cec5SDimitry Andricdefm WriteIMul8 : X86SchedWritePair; // Integer 8-bit multiplication. 1390b57cec5SDimitry Andricdefm WriteIMul16 : X86SchedWritePair; // Integer 16-bit multiplication. 1400b57cec5SDimitry Andricdefm WriteIMul16Imm : X86SchedWritePair; // Integer 16-bit multiplication by immediate. 1410b57cec5SDimitry Andricdefm WriteIMul16Reg : X86SchedWritePair; // Integer 16-bit multiplication by register. 1420b57cec5SDimitry Andricdefm WriteIMul32 : X86SchedWritePair; // Integer 32-bit multiplication. 1430b57cec5SDimitry Andricdefm WriteIMul32Imm : X86SchedWritePair; // Integer 32-bit multiplication by immediate. 1440b57cec5SDimitry Andricdefm WriteIMul32Reg : X86SchedWritePair; // Integer 32-bit multiplication by register. 1450b57cec5SDimitry Andricdefm WriteIMul64 : X86SchedWritePair; // Integer 64-bit multiplication. 1460b57cec5SDimitry Andricdefm WriteIMul64Imm : X86SchedWritePair; // Integer 64-bit multiplication by immediate. 1470b57cec5SDimitry Andricdefm WriteIMul64Reg : X86SchedWritePair; // Integer 64-bit multiplication by register. 1480b57cec5SDimitry Andricdef WriteIMulH : SchedWrite; // Integer multiplication, high part. 1490b57cec5SDimitry Andric 1500b57cec5SDimitry Andricdef WriteBSWAP32 : SchedWrite; // Byte Order (Endianness) 32-bit Swap. 1510b57cec5SDimitry Andricdef WriteBSWAP64 : SchedWrite; // Byte Order (Endianness) 64-bit Swap. 1520b57cec5SDimitry Andricdefm WriteCMPXCHG : X86SchedWritePair; // Compare and set, compare and swap. 1530b57cec5SDimitry Andricdef WriteCMPXCHGRMW : SchedWrite; // Compare and set, compare and swap. 1540b57cec5SDimitry Andricdef WriteXCHG : SchedWrite; // Compare+Exchange - TODO RMW support. 1550b57cec5SDimitry Andric 1560b57cec5SDimitry Andric// Integer division. 1570b57cec5SDimitry Andricdefm WriteDiv8 : X86SchedWritePair; 1580b57cec5SDimitry Andricdefm WriteDiv16 : X86SchedWritePair; 1590b57cec5SDimitry Andricdefm WriteDiv32 : X86SchedWritePair; 1600b57cec5SDimitry Andricdefm WriteDiv64 : X86SchedWritePair; 1610b57cec5SDimitry Andricdefm WriteIDiv8 : X86SchedWritePair; 1620b57cec5SDimitry Andricdefm WriteIDiv16 : X86SchedWritePair; 1630b57cec5SDimitry Andricdefm WriteIDiv32 : X86SchedWritePair; 1640b57cec5SDimitry Andricdefm WriteIDiv64 : X86SchedWritePair; 1650b57cec5SDimitry Andric 1660b57cec5SDimitry Andricdefm WriteBSF : X86SchedWritePair; // Bit scan forward. 1670b57cec5SDimitry Andricdefm WriteBSR : X86SchedWritePair; // Bit scan reverse. 1680b57cec5SDimitry Andricdefm WritePOPCNT : X86SchedWritePair; // Bit population count. 1690b57cec5SDimitry Andricdefm WriteLZCNT : X86SchedWritePair; // Leading zero count. 1700b57cec5SDimitry Andricdefm WriteTZCNT : X86SchedWritePair; // Trailing zero count. 1710b57cec5SDimitry Andricdefm WriteCMOV : X86SchedWritePair; // Conditional move. 1720b57cec5SDimitry Andricdef WriteFCMOV : SchedWrite; // X87 conditional move. 1730b57cec5SDimitry Andricdef WriteSETCC : SchedWrite; // Set register based on condition code. 1740b57cec5SDimitry Andricdef WriteSETCCStore : SchedWrite; 1750b57cec5SDimitry Andricdef WriteLAHFSAHF : SchedWrite; // Load/Store flags in AH. 1760b57cec5SDimitry Andric 1770b57cec5SDimitry Andricdef WriteBitTest : SchedWrite; // Bit Test 1780b57cec5SDimitry Andricdef WriteBitTestImmLd : SchedWrite; 1790b57cec5SDimitry Andricdef WriteBitTestRegLd : SchedWrite; 1800b57cec5SDimitry Andric 1810b57cec5SDimitry Andricdef WriteBitTestSet : SchedWrite; // Bit Test + Set 1820b57cec5SDimitry Andricdef WriteBitTestSetImmLd : SchedWrite; 1830b57cec5SDimitry Andricdef WriteBitTestSetRegLd : SchedWrite; 1840b57cec5SDimitry Andricdef WriteBitTestSetImmRMW : WriteSequence<[WriteBitTestSetImmLd, WriteRMW]>; 1850b57cec5SDimitry Andricdef WriteBitTestSetRegRMW : WriteSequence<[WriteBitTestSetRegLd, WriteRMW]>; 1860b57cec5SDimitry Andric 1870b57cec5SDimitry Andric// Integer shifts and rotates. 1880b57cec5SDimitry Andricdefm WriteShift : X86SchedWritePair; 1890b57cec5SDimitry Andricdefm WriteShiftCL : X86SchedWritePair; 1900b57cec5SDimitry Andricdefm WriteRotate : X86SchedWritePair; 1910b57cec5SDimitry Andricdefm WriteRotateCL : X86SchedWritePair; 1920b57cec5SDimitry Andric 1930b57cec5SDimitry Andric// Double shift instructions. 1940b57cec5SDimitry Andricdef WriteSHDrri : SchedWrite; 1950b57cec5SDimitry Andricdef WriteSHDrrcl : SchedWrite; 1960b57cec5SDimitry Andricdef WriteSHDmri : SchedWrite; 1970b57cec5SDimitry Andricdef WriteSHDmrcl : SchedWrite; 1980b57cec5SDimitry Andric 1990b57cec5SDimitry Andric// BMI1 BEXTR/BLS, BMI2 BZHI 2000b57cec5SDimitry Andricdefm WriteBEXTR : X86SchedWritePair; 2010b57cec5SDimitry Andricdefm WriteBLS : X86SchedWritePair; 2020b57cec5SDimitry Andricdefm WriteBZHI : X86SchedWritePair; 2030b57cec5SDimitry Andric 2040b57cec5SDimitry Andric// Idioms that clear a register, like xorps %xmm0, %xmm0. 2050b57cec5SDimitry Andric// These can often bypass execution ports completely. 2060b57cec5SDimitry Andricdef WriteZero : SchedWrite; 2070b57cec5SDimitry Andric 2080b57cec5SDimitry Andric// Branches don't produce values, so they have no latency, but they still 2090b57cec5SDimitry Andric// consume resources. Indirect branches can fold loads. 2100b57cec5SDimitry Andricdefm WriteJump : X86SchedWritePair; 2110b57cec5SDimitry Andric 2120b57cec5SDimitry Andric// Floating point. This covers both scalar and vector operations. 2130b57cec5SDimitry Andricdef WriteFLD0 : SchedWrite; 2140b57cec5SDimitry Andricdef WriteFLD1 : SchedWrite; 2150b57cec5SDimitry Andricdef WriteFLDC : SchedWrite; 2160b57cec5SDimitry Andricdef WriteFLoad : SchedWrite; 2170b57cec5SDimitry Andricdef WriteFLoadX : SchedWrite; 2180b57cec5SDimitry Andricdef WriteFLoadY : SchedWrite; 2190b57cec5SDimitry Andricdef WriteFMaskedLoad : SchedWrite; 2200b57cec5SDimitry Andricdef WriteFMaskedLoadY : SchedWrite; 2210b57cec5SDimitry Andricdef WriteFStore : SchedWrite; 2220b57cec5SDimitry Andricdef WriteFStoreX : SchedWrite; 2230b57cec5SDimitry Andricdef WriteFStoreY : SchedWrite; 2240b57cec5SDimitry Andricdef WriteFStoreNT : SchedWrite; 2250b57cec5SDimitry Andricdef WriteFStoreNTX : SchedWrite; 2260b57cec5SDimitry Andricdef WriteFStoreNTY : SchedWrite; 2278bcb0991SDimitry Andric 2288bcb0991SDimitry Andricdef WriteFMaskedStore32 : SchedWrite; 2298bcb0991SDimitry Andricdef WriteFMaskedStore64 : SchedWrite; 2308bcb0991SDimitry Andricdef WriteFMaskedStore32Y : SchedWrite; 2318bcb0991SDimitry Andricdef WriteFMaskedStore64Y : SchedWrite; 2328bcb0991SDimitry Andric 2330b57cec5SDimitry Andricdef WriteFMove : SchedWrite; 2340b57cec5SDimitry Andricdef WriteFMoveX : SchedWrite; 2350b57cec5SDimitry Andricdef WriteFMoveY : SchedWrite; 2360b57cec5SDimitry Andric 2370b57cec5SDimitry Andricdefm WriteFAdd : X86SchedWritePair<ReadAfterVecLd>; // Floating point add/sub. 2380b57cec5SDimitry Andricdefm WriteFAddX : X86SchedWritePair<ReadAfterVecXLd>; // Floating point add/sub (XMM). 2390b57cec5SDimitry Andricdefm WriteFAddY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point add/sub (YMM). 2400b57cec5SDimitry Andricdefm WriteFAddZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point add/sub (ZMM). 2410b57cec5SDimitry Andricdefm WriteFAdd64 : X86SchedWritePair<ReadAfterVecLd>; // Floating point double add/sub. 2420b57cec5SDimitry Andricdefm WriteFAdd64X : X86SchedWritePair<ReadAfterVecXLd>; // Floating point double add/sub (XMM). 2430b57cec5SDimitry Andricdefm WriteFAdd64Y : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double add/sub (YMM). 2440b57cec5SDimitry Andricdefm WriteFAdd64Z : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double add/sub (ZMM). 2450b57cec5SDimitry Andricdefm WriteFCmp : X86SchedWritePair<ReadAfterVecLd>; // Floating point compare. 2460b57cec5SDimitry Andricdefm WriteFCmpX : X86SchedWritePair<ReadAfterVecXLd>; // Floating point compare (XMM). 2470b57cec5SDimitry Andricdefm WriteFCmpY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point compare (YMM). 2480b57cec5SDimitry Andricdefm WriteFCmpZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point compare (ZMM). 2490b57cec5SDimitry Andricdefm WriteFCmp64 : X86SchedWritePair<ReadAfterVecLd>; // Floating point double compare. 2500b57cec5SDimitry Andricdefm WriteFCmp64X : X86SchedWritePair<ReadAfterVecXLd>; // Floating point double compare (XMM). 2510b57cec5SDimitry Andricdefm WriteFCmp64Y : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double compare (YMM). 2520b57cec5SDimitry Andricdefm WriteFCmp64Z : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double compare (ZMM). 253*5ffd83dbSDimitry Andricdefm WriteFCom : X86SchedWritePair<ReadAfterVecLd>; // Floating point compare to flags (X87). 254*5ffd83dbSDimitry Andricdefm WriteFComX : X86SchedWritePair<ReadAfterVecLd>; // Floating point compare to flags (SSE). 2550b57cec5SDimitry Andricdefm WriteFMul : X86SchedWritePair<ReadAfterVecLd>; // Floating point multiplication. 2560b57cec5SDimitry Andricdefm WriteFMulX : X86SchedWritePair<ReadAfterVecXLd>; // Floating point multiplication (XMM). 2570b57cec5SDimitry Andricdefm WriteFMulY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point multiplication (YMM). 2580b57cec5SDimitry Andricdefm WriteFMulZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point multiplication (YMM). 2590b57cec5SDimitry Andricdefm WriteFMul64 : X86SchedWritePair<ReadAfterVecLd>; // Floating point double multiplication. 2600b57cec5SDimitry Andricdefm WriteFMul64X : X86SchedWritePair<ReadAfterVecXLd>; // Floating point double multiplication (XMM). 2610b57cec5SDimitry Andricdefm WriteFMul64Y : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double multiplication (YMM). 2620b57cec5SDimitry Andricdefm WriteFMul64Z : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double multiplication (ZMM). 2630b57cec5SDimitry Andricdefm WriteFDiv : X86SchedWritePair<ReadAfterVecLd>; // Floating point division. 2640b57cec5SDimitry Andricdefm WriteFDivX : X86SchedWritePair<ReadAfterVecXLd>; // Floating point division (XMM). 2650b57cec5SDimitry Andricdefm WriteFDivY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point division (YMM). 2660b57cec5SDimitry Andricdefm WriteFDivZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point division (ZMM). 2670b57cec5SDimitry Andricdefm WriteFDiv64 : X86SchedWritePair<ReadAfterVecLd>; // Floating point double division. 2680b57cec5SDimitry Andricdefm WriteFDiv64X : X86SchedWritePair<ReadAfterVecXLd>; // Floating point double division (XMM). 2690b57cec5SDimitry Andricdefm WriteFDiv64Y : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double division (YMM). 2700b57cec5SDimitry Andricdefm WriteFDiv64Z : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double division (ZMM). 2710b57cec5SDimitry Andricdefm WriteFSqrt : X86SchedWritePair<ReadAfterVecLd>; // Floating point square root. 2720b57cec5SDimitry Andricdefm WriteFSqrtX : X86SchedWritePair<ReadAfterVecXLd>; // Floating point square root (XMM). 2730b57cec5SDimitry Andricdefm WriteFSqrtY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point square root (YMM). 2740b57cec5SDimitry Andricdefm WriteFSqrtZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point square root (ZMM). 2750b57cec5SDimitry Andricdefm WriteFSqrt64 : X86SchedWritePair<ReadAfterVecLd>; // Floating point double square root. 2760b57cec5SDimitry Andricdefm WriteFSqrt64X : X86SchedWritePair<ReadAfterVecXLd>; // Floating point double square root (XMM). 2770b57cec5SDimitry Andricdefm WriteFSqrt64Y : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double square root (YMM). 2780b57cec5SDimitry Andricdefm WriteFSqrt64Z : X86SchedWritePair<ReadAfterVecYLd>; // Floating point double square root (ZMM). 2790b57cec5SDimitry Andricdefm WriteFSqrt80 : X86SchedWritePair<ReadAfterVecLd>; // Floating point long double square root. 2800b57cec5SDimitry Andricdefm WriteFRcp : X86SchedWritePair<ReadAfterVecLd>; // Floating point reciprocal estimate. 2810b57cec5SDimitry Andricdefm WriteFRcpX : X86SchedWritePair<ReadAfterVecXLd>; // Floating point reciprocal estimate (XMM). 2820b57cec5SDimitry Andricdefm WriteFRcpY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point reciprocal estimate (YMM). 2830b57cec5SDimitry Andricdefm WriteFRcpZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point reciprocal estimate (ZMM). 2840b57cec5SDimitry Andricdefm WriteFRsqrt : X86SchedWritePair<ReadAfterVecLd>; // Floating point reciprocal square root estimate. 2850b57cec5SDimitry Andricdefm WriteFRsqrtX: X86SchedWritePair<ReadAfterVecXLd>; // Floating point reciprocal square root estimate (XMM). 2860b57cec5SDimitry Andricdefm WriteFRsqrtY: X86SchedWritePair<ReadAfterVecYLd>; // Floating point reciprocal square root estimate (YMM). 2870b57cec5SDimitry Andricdefm WriteFRsqrtZ: X86SchedWritePair<ReadAfterVecYLd>; // Floating point reciprocal square root estimate (ZMM). 2880b57cec5SDimitry Andricdefm WriteFMA : X86SchedWritePair<ReadAfterVecLd>; // Fused Multiply Add. 2890b57cec5SDimitry Andricdefm WriteFMAX : X86SchedWritePair<ReadAfterVecXLd>; // Fused Multiply Add (XMM). 2900b57cec5SDimitry Andricdefm WriteFMAY : X86SchedWritePair<ReadAfterVecYLd>; // Fused Multiply Add (YMM). 2910b57cec5SDimitry Andricdefm WriteFMAZ : X86SchedWritePair<ReadAfterVecYLd>; // Fused Multiply Add (ZMM). 2920b57cec5SDimitry Andricdefm WriteDPPD : X86SchedWritePair<ReadAfterVecXLd>; // Floating point double dot product. 2930b57cec5SDimitry Andricdefm WriteDPPS : X86SchedWritePair<ReadAfterVecXLd>; // Floating point single dot product. 2940b57cec5SDimitry Andricdefm WriteDPPSY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point single dot product (YMM). 2950b57cec5SDimitry Andricdefm WriteDPPSZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point single dot product (ZMM). 2960b57cec5SDimitry Andricdefm WriteFSign : X86SchedWritePair<ReadAfterVecLd>; // Floating point fabs/fchs. 2970b57cec5SDimitry Andricdefm WriteFRnd : X86SchedWritePair<ReadAfterVecXLd>; // Floating point rounding. 2980b57cec5SDimitry Andricdefm WriteFRndY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point rounding (YMM). 2990b57cec5SDimitry Andricdefm WriteFRndZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point rounding (ZMM). 3000b57cec5SDimitry Andricdefm WriteFLogic : X86SchedWritePair<ReadAfterVecXLd>; // Floating point and/or/xor logicals. 3010b57cec5SDimitry Andricdefm WriteFLogicY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point and/or/xor logicals (YMM). 3020b57cec5SDimitry Andricdefm WriteFLogicZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point and/or/xor logicals (ZMM). 3030b57cec5SDimitry Andricdefm WriteFTest : X86SchedWritePair<ReadAfterVecXLd>; // Floating point TEST instructions. 3040b57cec5SDimitry Andricdefm WriteFTestY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point TEST instructions (YMM). 3050b57cec5SDimitry Andricdefm WriteFTestZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point TEST instructions (ZMM). 3060b57cec5SDimitry Andricdefm WriteFShuffle : X86SchedWritePair<ReadAfterVecXLd>; // Floating point vector shuffles. 3070b57cec5SDimitry Andricdefm WriteFShuffleY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point vector shuffles (YMM). 3080b57cec5SDimitry Andricdefm WriteFShuffleZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point vector shuffles (ZMM). 3090b57cec5SDimitry Andricdefm WriteFVarShuffle : X86SchedWritePair<ReadAfterVecXLd>; // Floating point vector variable shuffles. 3100b57cec5SDimitry Andricdefm WriteFVarShuffleY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point vector variable shuffles (YMM). 3110b57cec5SDimitry Andricdefm WriteFVarShuffleZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point vector variable shuffles (ZMM). 3120b57cec5SDimitry Andricdefm WriteFBlend : X86SchedWritePair<ReadAfterVecXLd>; // Floating point vector blends. 3130b57cec5SDimitry Andricdefm WriteFBlendY : X86SchedWritePair<ReadAfterVecYLd>; // Floating point vector blends (YMM). 3140b57cec5SDimitry Andricdefm WriteFBlendZ : X86SchedWritePair<ReadAfterVecYLd>; // Floating point vector blends (ZMM). 3150b57cec5SDimitry Andricdefm WriteFVarBlend : X86SchedWritePair<ReadAfterVecXLd>; // Fp vector variable blends. 3160b57cec5SDimitry Andricdefm WriteFVarBlendY : X86SchedWritePair<ReadAfterVecYLd>; // Fp vector variable blends (YMM). 3170b57cec5SDimitry Andricdefm WriteFVarBlendZ : X86SchedWritePair<ReadAfterVecYLd>; // Fp vector variable blends (YMZMM). 3180b57cec5SDimitry Andric 3190b57cec5SDimitry Andric// FMA Scheduling helper class. 3200b57cec5SDimitry Andricclass FMASC { X86FoldableSchedWrite Sched = WriteFAdd; } 3210b57cec5SDimitry Andric 3220b57cec5SDimitry Andric// Horizontal Add/Sub (float and integer) 3230b57cec5SDimitry Andricdefm WriteFHAdd : X86SchedWritePair<ReadAfterVecXLd>; 3240b57cec5SDimitry Andricdefm WriteFHAddY : X86SchedWritePair<ReadAfterVecYLd>; 3250b57cec5SDimitry Andricdefm WriteFHAddZ : X86SchedWritePair<ReadAfterVecYLd>; 3260b57cec5SDimitry Andricdefm WritePHAdd : X86SchedWritePair<ReadAfterVecLd>; 3270b57cec5SDimitry Andricdefm WritePHAddX : X86SchedWritePair<ReadAfterVecXLd>; 3280b57cec5SDimitry Andricdefm WritePHAddY : X86SchedWritePair<ReadAfterVecYLd>; 3290b57cec5SDimitry Andricdefm WritePHAddZ : X86SchedWritePair<ReadAfterVecYLd>; 3300b57cec5SDimitry Andric 3310b57cec5SDimitry Andric// Vector integer operations. 3320b57cec5SDimitry Andricdef WriteVecLoad : SchedWrite; 3330b57cec5SDimitry Andricdef WriteVecLoadX : SchedWrite; 3340b57cec5SDimitry Andricdef WriteVecLoadY : SchedWrite; 3350b57cec5SDimitry Andricdef WriteVecLoadNT : SchedWrite; 3360b57cec5SDimitry Andricdef WriteVecLoadNTY : SchedWrite; 3370b57cec5SDimitry Andricdef WriteVecMaskedLoad : SchedWrite; 3380b57cec5SDimitry Andricdef WriteVecMaskedLoadY : SchedWrite; 3390b57cec5SDimitry Andricdef WriteVecStore : SchedWrite; 3400b57cec5SDimitry Andricdef WriteVecStoreX : SchedWrite; 3410b57cec5SDimitry Andricdef WriteVecStoreY : SchedWrite; 3420b57cec5SDimitry Andricdef WriteVecStoreNT : SchedWrite; 3430b57cec5SDimitry Andricdef WriteVecStoreNTY : SchedWrite; 344*5ffd83dbSDimitry Andricdef WriteVecMaskedStore32 : SchedWrite; 345*5ffd83dbSDimitry Andricdef WriteVecMaskedStore64 : SchedWrite; 346*5ffd83dbSDimitry Andricdef WriteVecMaskedStore32Y : SchedWrite; 347*5ffd83dbSDimitry Andricdef WriteVecMaskedStore64Y : SchedWrite; 3480b57cec5SDimitry Andricdef WriteVecMove : SchedWrite; 3490b57cec5SDimitry Andricdef WriteVecMoveX : SchedWrite; 3500b57cec5SDimitry Andricdef WriteVecMoveY : SchedWrite; 3510b57cec5SDimitry Andricdef WriteVecMoveToGpr : SchedWrite; 3520b57cec5SDimitry Andricdef WriteVecMoveFromGpr : SchedWrite; 3530b57cec5SDimitry Andric 3540b57cec5SDimitry Andricdefm WriteVecALU : X86SchedWritePair<ReadAfterVecLd>; // Vector integer ALU op, no logicals. 3550b57cec5SDimitry Andricdefm WriteVecALUX : X86SchedWritePair<ReadAfterVecXLd>; // Vector integer ALU op, no logicals (XMM). 3560b57cec5SDimitry Andricdefm WriteVecALUY : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer ALU op, no logicals (YMM). 3570b57cec5SDimitry Andricdefm WriteVecALUZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer ALU op, no logicals (ZMM). 3580b57cec5SDimitry Andricdefm WriteVecLogic : X86SchedWritePair<ReadAfterVecLd>; // Vector integer and/or/xor logicals. 3590b57cec5SDimitry Andricdefm WriteVecLogicX : X86SchedWritePair<ReadAfterVecXLd>; // Vector integer and/or/xor logicals (XMM). 3600b57cec5SDimitry Andricdefm WriteVecLogicY : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer and/or/xor logicals (YMM). 3610b57cec5SDimitry Andricdefm WriteVecLogicZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer and/or/xor logicals (ZMM). 3620b57cec5SDimitry Andricdefm WriteVecTest : X86SchedWritePair<ReadAfterVecXLd>; // Vector integer TEST instructions. 3630b57cec5SDimitry Andricdefm WriteVecTestY : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer TEST instructions (YMM). 3640b57cec5SDimitry Andricdefm WriteVecTestZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer TEST instructions (ZMM). 3650b57cec5SDimitry Andricdefm WriteVecShift : X86SchedWritePair<ReadAfterVecLd>; // Vector integer shifts (default). 3660b57cec5SDimitry Andricdefm WriteVecShiftX : X86SchedWritePair<ReadAfterVecXLd>; // Vector integer shifts (XMM). 3670b57cec5SDimitry Andricdefm WriteVecShiftY : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer shifts (YMM). 3680b57cec5SDimitry Andricdefm WriteVecShiftZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer shifts (ZMM). 3690b57cec5SDimitry Andricdefm WriteVecShiftImm : X86SchedWritePair<ReadAfterVecLd>; // Vector integer immediate shifts (default). 3700b57cec5SDimitry Andricdefm WriteVecShiftImmX: X86SchedWritePair<ReadAfterVecXLd>; // Vector integer immediate shifts (XMM). 3710b57cec5SDimitry Andricdefm WriteVecShiftImmY: X86SchedWritePair<ReadAfterVecYLd>; // Vector integer immediate shifts (YMM). 3720b57cec5SDimitry Andricdefm WriteVecShiftImmZ: X86SchedWritePair<ReadAfterVecYLd>; // Vector integer immediate shifts (ZMM). 3730b57cec5SDimitry Andricdefm WriteVecIMul : X86SchedWritePair<ReadAfterVecLd>; // Vector integer multiply (default). 3740b57cec5SDimitry Andricdefm WriteVecIMulX : X86SchedWritePair<ReadAfterVecXLd>; // Vector integer multiply (XMM). 3750b57cec5SDimitry Andricdefm WriteVecIMulY : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer multiply (YMM). 3760b57cec5SDimitry Andricdefm WriteVecIMulZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector integer multiply (ZMM). 3770b57cec5SDimitry Andricdefm WritePMULLD : X86SchedWritePair<ReadAfterVecXLd>; // Vector PMULLD. 3780b57cec5SDimitry Andricdefm WritePMULLDY : X86SchedWritePair<ReadAfterVecYLd>; // Vector PMULLD (YMM). 3790b57cec5SDimitry Andricdefm WritePMULLDZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector PMULLD (ZMM). 3800b57cec5SDimitry Andricdefm WriteShuffle : X86SchedWritePair<ReadAfterVecLd>; // Vector shuffles. 3810b57cec5SDimitry Andricdefm WriteShuffleX : X86SchedWritePair<ReadAfterVecXLd>; // Vector shuffles (XMM). 3820b57cec5SDimitry Andricdefm WriteShuffleY : X86SchedWritePair<ReadAfterVecYLd>; // Vector shuffles (YMM). 3830b57cec5SDimitry Andricdefm WriteShuffleZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector shuffles (ZMM). 3840b57cec5SDimitry Andricdefm WriteVarShuffle : X86SchedWritePair<ReadAfterVecLd>; // Vector variable shuffles. 3850b57cec5SDimitry Andricdefm WriteVarShuffleX : X86SchedWritePair<ReadAfterVecXLd>; // Vector variable shuffles (XMM). 3860b57cec5SDimitry Andricdefm WriteVarShuffleY : X86SchedWritePair<ReadAfterVecYLd>; // Vector variable shuffles (YMM). 3870b57cec5SDimitry Andricdefm WriteVarShuffleZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector variable shuffles (ZMM). 3880b57cec5SDimitry Andricdefm WriteBlend : X86SchedWritePair<ReadAfterVecXLd>; // Vector blends. 3890b57cec5SDimitry Andricdefm WriteBlendY : X86SchedWritePair<ReadAfterVecYLd>; // Vector blends (YMM). 3900b57cec5SDimitry Andricdefm WriteBlendZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector blends (ZMM). 3910b57cec5SDimitry Andricdefm WriteVarBlend : X86SchedWritePair<ReadAfterVecXLd>; // Vector variable blends. 3920b57cec5SDimitry Andricdefm WriteVarBlendY : X86SchedWritePair<ReadAfterVecYLd>; // Vector variable blends (YMM). 3930b57cec5SDimitry Andricdefm WriteVarBlendZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector variable blends (ZMM). 3940b57cec5SDimitry Andricdefm WritePSADBW : X86SchedWritePair<ReadAfterVecLd>; // Vector PSADBW. 3950b57cec5SDimitry Andricdefm WritePSADBWX : X86SchedWritePair<ReadAfterVecXLd>; // Vector PSADBW (XMM). 3960b57cec5SDimitry Andricdefm WritePSADBWY : X86SchedWritePair<ReadAfterVecYLd>; // Vector PSADBW (YMM). 3970b57cec5SDimitry Andricdefm WritePSADBWZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector PSADBW (ZMM). 3980b57cec5SDimitry Andricdefm WriteMPSAD : X86SchedWritePair<ReadAfterVecXLd>; // Vector MPSAD. 3990b57cec5SDimitry Andricdefm WriteMPSADY : X86SchedWritePair<ReadAfterVecYLd>; // Vector MPSAD (YMM). 4000b57cec5SDimitry Andricdefm WriteMPSADZ : X86SchedWritePair<ReadAfterVecYLd>; // Vector MPSAD (ZMM). 4010b57cec5SDimitry Andricdefm WritePHMINPOS : X86SchedWritePair<ReadAfterVecXLd>; // Vector PHMINPOS. 4020b57cec5SDimitry Andric 4030b57cec5SDimitry Andric// Vector insert/extract operations. 4040b57cec5SDimitry Andricdefm WriteVecInsert : X86SchedWritePair; // Insert gpr to vector element. 4050b57cec5SDimitry Andricdef WriteVecExtract : SchedWrite; // Extract vector element to gpr. 4060b57cec5SDimitry Andricdef WriteVecExtractSt : SchedWrite; // Extract vector element and store. 4070b57cec5SDimitry Andric 4080b57cec5SDimitry Andric// MOVMSK operations. 4090b57cec5SDimitry Andricdef WriteFMOVMSK : SchedWrite; 4100b57cec5SDimitry Andricdef WriteVecMOVMSK : SchedWrite; 4110b57cec5SDimitry Andricdef WriteVecMOVMSKY : SchedWrite; 4120b57cec5SDimitry Andricdef WriteMMXMOVMSK : SchedWrite; 4130b57cec5SDimitry Andric 4140b57cec5SDimitry Andric// Conversion between integer and float. 4150b57cec5SDimitry Andricdefm WriteCvtSD2I : X86SchedWritePair<ReadAfterVecLd>; // Double -> Integer. 4160b57cec5SDimitry Andricdefm WriteCvtPD2I : X86SchedWritePair<ReadAfterVecXLd>; // Double -> Integer (XMM). 4170b57cec5SDimitry Andricdefm WriteCvtPD2IY : X86SchedWritePair<ReadAfterVecYLd>; // Double -> Integer (YMM). 4180b57cec5SDimitry Andricdefm WriteCvtPD2IZ : X86SchedWritePair<ReadAfterVecYLd>; // Double -> Integer (ZMM). 4190b57cec5SDimitry Andric 4200b57cec5SDimitry Andricdefm WriteCvtSS2I : X86SchedWritePair<ReadAfterVecLd>; // Float -> Integer. 4210b57cec5SDimitry Andricdefm WriteCvtPS2I : X86SchedWritePair<ReadAfterVecXLd>; // Float -> Integer (XMM). 4220b57cec5SDimitry Andricdefm WriteCvtPS2IY : X86SchedWritePair<ReadAfterVecYLd>; // Float -> Integer (YMM). 4230b57cec5SDimitry Andricdefm WriteCvtPS2IZ : X86SchedWritePair<ReadAfterVecYLd>; // Float -> Integer (ZMM). 4240b57cec5SDimitry Andric 4250b57cec5SDimitry Andricdefm WriteCvtI2SD : X86SchedWritePair<ReadAfterVecLd>; // Integer -> Double. 4260b57cec5SDimitry Andricdefm WriteCvtI2PD : X86SchedWritePair<ReadAfterVecXLd>; // Integer -> Double (XMM). 4270b57cec5SDimitry Andricdefm WriteCvtI2PDY : X86SchedWritePair<ReadAfterVecYLd>; // Integer -> Double (YMM). 4280b57cec5SDimitry Andricdefm WriteCvtI2PDZ : X86SchedWritePair<ReadAfterVecYLd>; // Integer -> Double (ZMM). 4290b57cec5SDimitry Andric 4300b57cec5SDimitry Andricdefm WriteCvtI2SS : X86SchedWritePair<ReadAfterVecLd>; // Integer -> Float. 4310b57cec5SDimitry Andricdefm WriteCvtI2PS : X86SchedWritePair<ReadAfterVecXLd>; // Integer -> Float (XMM). 4320b57cec5SDimitry Andricdefm WriteCvtI2PSY : X86SchedWritePair<ReadAfterVecYLd>; // Integer -> Float (YMM). 4330b57cec5SDimitry Andricdefm WriteCvtI2PSZ : X86SchedWritePair<ReadAfterVecYLd>; // Integer -> Float (ZMM). 4340b57cec5SDimitry Andric 4350b57cec5SDimitry Andricdefm WriteCvtSS2SD : X86SchedWritePair<ReadAfterVecLd>; // Float -> Double size conversion. 4360b57cec5SDimitry Andricdefm WriteCvtPS2PD : X86SchedWritePair<ReadAfterVecXLd>; // Float -> Double size conversion (XMM). 4370b57cec5SDimitry Andricdefm WriteCvtPS2PDY : X86SchedWritePair<ReadAfterVecYLd>; // Float -> Double size conversion (YMM). 4380b57cec5SDimitry Andricdefm WriteCvtPS2PDZ : X86SchedWritePair<ReadAfterVecYLd>; // Float -> Double size conversion (ZMM). 4390b57cec5SDimitry Andric 4400b57cec5SDimitry Andricdefm WriteCvtSD2SS : X86SchedWritePair<ReadAfterVecLd>; // Double -> Float size conversion. 4410b57cec5SDimitry Andricdefm WriteCvtPD2PS : X86SchedWritePair<ReadAfterVecXLd>; // Double -> Float size conversion (XMM). 4420b57cec5SDimitry Andricdefm WriteCvtPD2PSY : X86SchedWritePair<ReadAfterVecYLd>; // Double -> Float size conversion (YMM). 4430b57cec5SDimitry Andricdefm WriteCvtPD2PSZ : X86SchedWritePair<ReadAfterVecYLd>; // Double -> Float size conversion (ZMM). 4440b57cec5SDimitry Andric 4450b57cec5SDimitry Andricdefm WriteCvtPH2PS : X86SchedWritePair<ReadAfterVecXLd>; // Half -> Float size conversion. 4460b57cec5SDimitry Andricdefm WriteCvtPH2PSY : X86SchedWritePair<ReadAfterVecYLd>; // Half -> Float size conversion (YMM). 4470b57cec5SDimitry Andricdefm WriteCvtPH2PSZ : X86SchedWritePair<ReadAfterVecYLd>; // Half -> Float size conversion (ZMM). 4480b57cec5SDimitry Andric 4490b57cec5SDimitry Andricdef WriteCvtPS2PH : SchedWrite; // // Float -> Half size conversion. 4500b57cec5SDimitry Andricdef WriteCvtPS2PHY : SchedWrite; // // Float -> Half size conversion (YMM). 4510b57cec5SDimitry Andricdef WriteCvtPS2PHZ : SchedWrite; // // Float -> Half size conversion (ZMM). 4520b57cec5SDimitry Andricdef WriteCvtPS2PHSt : SchedWrite; // // Float -> Half + store size conversion. 4530b57cec5SDimitry Andricdef WriteCvtPS2PHYSt : SchedWrite; // // Float -> Half + store size conversion (YMM). 4540b57cec5SDimitry Andricdef WriteCvtPS2PHZSt : SchedWrite; // // Float -> Half + store size conversion (ZMM). 4550b57cec5SDimitry Andric 4560b57cec5SDimitry Andric// CRC32 instruction. 4570b57cec5SDimitry Andricdefm WriteCRC32 : X86SchedWritePair<ReadAfterLd>; 4580b57cec5SDimitry Andric 4590b57cec5SDimitry Andric// Strings instructions. 4600b57cec5SDimitry Andric// Packed Compare Implicit Length Strings, Return Mask 4610b57cec5SDimitry Andricdefm WritePCmpIStrM : X86SchedWritePair<ReadAfterVecXLd>; 4620b57cec5SDimitry Andric// Packed Compare Explicit Length Strings, Return Mask 4630b57cec5SDimitry Andricdefm WritePCmpEStrM : X86SchedWritePair<ReadAfterVecXLd>; 4640b57cec5SDimitry Andric// Packed Compare Implicit Length Strings, Return Index 4650b57cec5SDimitry Andricdefm WritePCmpIStrI : X86SchedWritePair<ReadAfterVecXLd>; 4660b57cec5SDimitry Andric// Packed Compare Explicit Length Strings, Return Index 4670b57cec5SDimitry Andricdefm WritePCmpEStrI : X86SchedWritePair<ReadAfterVecXLd>; 4680b57cec5SDimitry Andric 4690b57cec5SDimitry Andric// AES instructions. 4700b57cec5SDimitry Andricdefm WriteAESDecEnc : X86SchedWritePair<ReadAfterVecXLd>; // Decryption, encryption. 4710b57cec5SDimitry Andricdefm WriteAESIMC : X86SchedWritePair<ReadAfterVecXLd>; // InvMixColumn. 4720b57cec5SDimitry Andricdefm WriteAESKeyGen : X86SchedWritePair<ReadAfterVecXLd>; // Key Generation. 4730b57cec5SDimitry Andric 4740b57cec5SDimitry Andric// Carry-less multiplication instructions. 4750b57cec5SDimitry Andricdefm WriteCLMul : X86SchedWritePair<ReadAfterVecXLd>; 4760b57cec5SDimitry Andric 4770b57cec5SDimitry Andric// EMMS/FEMMS 4780b57cec5SDimitry Andricdef WriteEMMS : SchedWrite; 4790b57cec5SDimitry Andric 4800b57cec5SDimitry Andric// Load/store MXCSR 4810b57cec5SDimitry Andricdef WriteLDMXCSR : SchedWrite; 4820b57cec5SDimitry Andricdef WriteSTMXCSR : SchedWrite; 4830b57cec5SDimitry Andric 4840b57cec5SDimitry Andric// Catch-all for expensive system instructions. 4850b57cec5SDimitry Andricdef WriteSystem : SchedWrite; 4860b57cec5SDimitry Andric 4870b57cec5SDimitry Andric// AVX2. 4880b57cec5SDimitry Andricdefm WriteFShuffle256 : X86SchedWritePair<ReadAfterVecYLd>; // Fp 256-bit width vector shuffles. 4890b57cec5SDimitry Andricdefm WriteFVarShuffle256 : X86SchedWritePair<ReadAfterVecYLd>; // Fp 256-bit width variable shuffles. 4900b57cec5SDimitry Andricdefm WriteShuffle256 : X86SchedWritePair<ReadAfterVecYLd>; // 256-bit width vector shuffles. 4910b57cec5SDimitry Andricdefm WriteVarShuffle256 : X86SchedWritePair<ReadAfterVecYLd>; // 256-bit width vector variable shuffles. 4920b57cec5SDimitry Andricdefm WriteVarVecShift : X86SchedWritePair<ReadAfterVecXLd>; // Variable vector shifts. 4930b57cec5SDimitry Andricdefm WriteVarVecShiftY : X86SchedWritePair<ReadAfterVecYLd>; // Variable vector shifts (YMM). 4940b57cec5SDimitry Andricdefm WriteVarVecShiftZ : X86SchedWritePair<ReadAfterVecYLd>; // Variable vector shifts (ZMM). 4950b57cec5SDimitry Andric 4960b57cec5SDimitry Andric// Old microcoded instructions that nobody use. 4970b57cec5SDimitry Andricdef WriteMicrocoded : SchedWrite; 4980b57cec5SDimitry Andric 4990b57cec5SDimitry Andric// Fence instructions. 5000b57cec5SDimitry Andricdef WriteFence : SchedWrite; 5010b57cec5SDimitry Andric 5020b57cec5SDimitry Andric// Nop, not very useful expect it provides a model for nops! 5030b57cec5SDimitry Andricdef WriteNop : SchedWrite; 5040b57cec5SDimitry Andric 5050b57cec5SDimitry Andric// Move/Load/Store wrappers. 5060b57cec5SDimitry Andricdef WriteFMoveLS 5070b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteFMove, WriteFLoad, WriteFStore>; 5080b57cec5SDimitry Andricdef WriteFMoveLSX 5090b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteFMoveX, WriteFLoadX, WriteFStoreX>; 5100b57cec5SDimitry Andricdef WriteFMoveLSY 5110b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteFMoveY, WriteFLoadY, WriteFStoreY>; 5120b57cec5SDimitry Andricdef SchedWriteFMoveLS 5130b57cec5SDimitry Andric : X86SchedWriteMoveLSWidths<WriteFMoveLS, WriteFMoveLSX, 5140b57cec5SDimitry Andric WriteFMoveLSY, WriteFMoveLSY>; 5150b57cec5SDimitry Andric 5160b57cec5SDimitry Andricdef WriteFMoveLSNT 5170b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteFMove, WriteFLoad, WriteFStoreNT>; 5180b57cec5SDimitry Andricdef WriteFMoveLSNTX 5190b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteFMove, WriteFLoad, WriteFStoreNTX>; 5200b57cec5SDimitry Andricdef WriteFMoveLSNTY 5210b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteFMoveY, WriteFLoadY, WriteFStoreNTY>; 5220b57cec5SDimitry Andricdef SchedWriteFMoveLSNT 5230b57cec5SDimitry Andric : X86SchedWriteMoveLSWidths<WriteFMoveLSNT, WriteFMoveLSNTX, 5240b57cec5SDimitry Andric WriteFMoveLSNTY, WriteFMoveLSNTY>; 5250b57cec5SDimitry Andric 5260b57cec5SDimitry Andricdef WriteVecMoveLS 5270b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteVecMove, WriteVecLoad, WriteVecStore>; 5280b57cec5SDimitry Andricdef WriteVecMoveLSX 5290b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteVecMoveX, WriteVecLoadX, WriteVecStoreX>; 5300b57cec5SDimitry Andricdef WriteVecMoveLSY 5310b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteVecMoveY, WriteVecLoadY, WriteVecStoreY>; 5320b57cec5SDimitry Andricdef SchedWriteVecMoveLS 5330b57cec5SDimitry Andric : X86SchedWriteMoveLSWidths<WriteVecMoveLS, WriteVecMoveLSX, 5340b57cec5SDimitry Andric WriteVecMoveLSY, WriteVecMoveLSY>; 5350b57cec5SDimitry Andric 5360b57cec5SDimitry Andricdef WriteVecMoveLSNT 5370b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteVecMove, WriteVecLoadNT, WriteVecStoreNT>; 5380b57cec5SDimitry Andricdef WriteVecMoveLSNTX 5390b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteVecMoveX, WriteVecLoadNT, WriteVecStoreNT>; 5400b57cec5SDimitry Andricdef WriteVecMoveLSNTY 5410b57cec5SDimitry Andric : X86SchedWriteMoveLS<WriteVecMoveY, WriteVecLoadNTY, WriteVecStoreNTY>; 5420b57cec5SDimitry Andricdef SchedWriteVecMoveLSNT 5430b57cec5SDimitry Andric : X86SchedWriteMoveLSWidths<WriteVecMoveLSNT, WriteVecMoveLSNTX, 5440b57cec5SDimitry Andric WriteVecMoveLSNTY, WriteVecMoveLSNTY>; 5450b57cec5SDimitry Andric 5468bcb0991SDimitry Andric// Conditional SIMD Packed Loads and Stores wrappers. 5478bcb0991SDimitry Andricdef WriteFMaskMove32 5488bcb0991SDimitry Andric : X86SchedWriteMaskMove<WriteFMaskedLoad, WriteFMaskedStore32>; 5498bcb0991SDimitry Andricdef WriteFMaskMove64 5508bcb0991SDimitry Andric : X86SchedWriteMaskMove<WriteFMaskedLoad, WriteFMaskedStore64>; 5518bcb0991SDimitry Andricdef WriteFMaskMove32Y 5528bcb0991SDimitry Andric : X86SchedWriteMaskMove<WriteFMaskedLoadY, WriteFMaskedStore32Y>; 5538bcb0991SDimitry Andricdef WriteFMaskMove64Y 5548bcb0991SDimitry Andric : X86SchedWriteMaskMove<WriteFMaskedLoadY, WriteFMaskedStore64Y>; 555*5ffd83dbSDimitry Andricdef WriteVecMaskMove32 556*5ffd83dbSDimitry Andric : X86SchedWriteMaskMove<WriteVecMaskedLoad, WriteVecMaskedStore32>; 557*5ffd83dbSDimitry Andricdef WriteVecMaskMove64 558*5ffd83dbSDimitry Andric : X86SchedWriteMaskMove<WriteVecMaskedLoad, WriteVecMaskedStore64>; 559*5ffd83dbSDimitry Andricdef WriteVecMaskMove32Y 560*5ffd83dbSDimitry Andric : X86SchedWriteMaskMove<WriteVecMaskedLoadY, WriteVecMaskedStore32Y>; 561*5ffd83dbSDimitry Andricdef WriteVecMaskMove64Y 562*5ffd83dbSDimitry Andric : X86SchedWriteMaskMove<WriteVecMaskedLoadY, WriteVecMaskedStore64Y>; 5638bcb0991SDimitry Andric 5640b57cec5SDimitry Andric// Vector width wrappers. 5650b57cec5SDimitry Andricdef SchedWriteFAdd 5660b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFAdd, WriteFAddX, WriteFAddY, WriteFAddZ>; 5670b57cec5SDimitry Andricdef SchedWriteFAdd64 5680b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFAdd64, WriteFAdd64X, WriteFAdd64Y, WriteFAdd64Z>; 5690b57cec5SDimitry Andricdef SchedWriteFHAdd 5700b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFHAdd, WriteFHAdd, WriteFHAddY, WriteFHAddZ>; 5710b57cec5SDimitry Andricdef SchedWriteFCmp 5720b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFCmp, WriteFCmpX, WriteFCmpY, WriteFCmpZ>; 5730b57cec5SDimitry Andricdef SchedWriteFCmp64 5740b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFCmp64, WriteFCmp64X, WriteFCmp64Y, WriteFCmp64Z>; 5750b57cec5SDimitry Andricdef SchedWriteFMul 5760b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFMul, WriteFMulX, WriteFMulY, WriteFMulZ>; 5770b57cec5SDimitry Andricdef SchedWriteFMul64 5780b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFMul64, WriteFMul64X, WriteFMul64Y, WriteFMul64Z>; 5790b57cec5SDimitry Andricdef SchedWriteFMA 5800b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFMA, WriteFMAX, WriteFMAY, WriteFMAZ>; 5810b57cec5SDimitry Andricdef SchedWriteDPPD 5820b57cec5SDimitry Andric : X86SchedWriteWidths<WriteDPPD, WriteDPPD, WriteDPPD, WriteDPPD>; 5830b57cec5SDimitry Andricdef SchedWriteDPPS 5840b57cec5SDimitry Andric : X86SchedWriteWidths<WriteDPPS, WriteDPPS, WriteDPPSY, WriteDPPSZ>; 5850b57cec5SDimitry Andricdef SchedWriteFDiv 5860b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFDiv, WriteFDivX, WriteFDivY, WriteFDivZ>; 5870b57cec5SDimitry Andricdef SchedWriteFDiv64 5880b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFDiv64, WriteFDiv64X, WriteFDiv64Y, WriteFDiv64Z>; 5890b57cec5SDimitry Andricdef SchedWriteFSqrt 5900b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFSqrt, WriteFSqrtX, 5910b57cec5SDimitry Andric WriteFSqrtY, WriteFSqrtZ>; 5920b57cec5SDimitry Andricdef SchedWriteFSqrt64 5930b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFSqrt64, WriteFSqrt64X, 5940b57cec5SDimitry Andric WriteFSqrt64Y, WriteFSqrt64Z>; 5950b57cec5SDimitry Andricdef SchedWriteFRcp 5960b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFRcp, WriteFRcpX, WriteFRcpY, WriteFRcpZ>; 5970b57cec5SDimitry Andricdef SchedWriteFRsqrt 5980b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFRsqrt, WriteFRsqrtX, WriteFRsqrtY, WriteFRsqrtZ>; 5990b57cec5SDimitry Andricdef SchedWriteFRnd 6000b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFRnd, WriteFRnd, WriteFRndY, WriteFRndZ>; 6010b57cec5SDimitry Andricdef SchedWriteFLogic 6020b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFLogic, WriteFLogic, WriteFLogicY, WriteFLogicZ>; 6030b57cec5SDimitry Andricdef SchedWriteFTest 6040b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFTest, WriteFTest, WriteFTestY, WriteFTestZ>; 6050b57cec5SDimitry Andric 6060b57cec5SDimitry Andricdef SchedWriteFShuffle 6070b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFShuffle, WriteFShuffle, 6080b57cec5SDimitry Andric WriteFShuffleY, WriteFShuffleZ>; 6090b57cec5SDimitry Andricdef SchedWriteFVarShuffle 6100b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFVarShuffle, WriteFVarShuffle, 6110b57cec5SDimitry Andric WriteFVarShuffleY, WriteFVarShuffleZ>; 6120b57cec5SDimitry Andricdef SchedWriteFBlend 6130b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFBlend, WriteFBlend, WriteFBlendY, WriteFBlendZ>; 6140b57cec5SDimitry Andricdef SchedWriteFVarBlend 6150b57cec5SDimitry Andric : X86SchedWriteWidths<WriteFVarBlend, WriteFVarBlend, 6160b57cec5SDimitry Andric WriteFVarBlendY, WriteFVarBlendZ>; 6170b57cec5SDimitry Andric 6180b57cec5SDimitry Andricdef SchedWriteCvtDQ2PD 6190b57cec5SDimitry Andric : X86SchedWriteWidths<WriteCvtI2SD, WriteCvtI2PD, 6200b57cec5SDimitry Andric WriteCvtI2PDY, WriteCvtI2PDZ>; 6210b57cec5SDimitry Andricdef SchedWriteCvtDQ2PS 6220b57cec5SDimitry Andric : X86SchedWriteWidths<WriteCvtI2SS, WriteCvtI2PS, 6230b57cec5SDimitry Andric WriteCvtI2PSY, WriteCvtI2PSZ>; 6240b57cec5SDimitry Andricdef SchedWriteCvtPD2DQ 6250b57cec5SDimitry Andric : X86SchedWriteWidths<WriteCvtSD2I, WriteCvtPD2I, 6260b57cec5SDimitry Andric WriteCvtPD2IY, WriteCvtPD2IZ>; 6270b57cec5SDimitry Andricdef SchedWriteCvtPS2DQ 6280b57cec5SDimitry Andric : X86SchedWriteWidths<WriteCvtSS2I, WriteCvtPS2I, 6290b57cec5SDimitry Andric WriteCvtPS2IY, WriteCvtPS2IZ>; 6300b57cec5SDimitry Andricdef SchedWriteCvtPS2PD 6310b57cec5SDimitry Andric : X86SchedWriteWidths<WriteCvtSS2SD, WriteCvtPS2PD, 6320b57cec5SDimitry Andric WriteCvtPS2PDY, WriteCvtPS2PDZ>; 6330b57cec5SDimitry Andricdef SchedWriteCvtPD2PS 6340b57cec5SDimitry Andric : X86SchedWriteWidths<WriteCvtSD2SS, WriteCvtPD2PS, 6350b57cec5SDimitry Andric WriteCvtPD2PSY, WriteCvtPD2PSZ>; 6360b57cec5SDimitry Andric 6370b57cec5SDimitry Andricdef SchedWriteVecALU 6380b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVecALU, WriteVecALUX, WriteVecALUY, WriteVecALUZ>; 6390b57cec5SDimitry Andricdef SchedWritePHAdd 6400b57cec5SDimitry Andric : X86SchedWriteWidths<WritePHAdd, WritePHAddX, WritePHAddY, WritePHAddZ>; 6410b57cec5SDimitry Andricdef SchedWriteVecLogic 6420b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVecLogic, WriteVecLogicX, 6430b57cec5SDimitry Andric WriteVecLogicY, WriteVecLogicZ>; 6440b57cec5SDimitry Andricdef SchedWriteVecTest 6450b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVecTest, WriteVecTest, 6460b57cec5SDimitry Andric WriteVecTestY, WriteVecTestZ>; 6470b57cec5SDimitry Andricdef SchedWriteVecShift 6480b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVecShift, WriteVecShiftX, 6490b57cec5SDimitry Andric WriteVecShiftY, WriteVecShiftZ>; 6500b57cec5SDimitry Andricdef SchedWriteVecShiftImm 6510b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVecShiftImm, WriteVecShiftImmX, 6520b57cec5SDimitry Andric WriteVecShiftImmY, WriteVecShiftImmZ>; 6530b57cec5SDimitry Andricdef SchedWriteVarVecShift 6540b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVarVecShift, WriteVarVecShift, 6550b57cec5SDimitry Andric WriteVarVecShiftY, WriteVarVecShiftZ>; 6560b57cec5SDimitry Andricdef SchedWriteVecIMul 6570b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVecIMul, WriteVecIMulX, 6580b57cec5SDimitry Andric WriteVecIMulY, WriteVecIMulZ>; 6590b57cec5SDimitry Andricdef SchedWritePMULLD 6600b57cec5SDimitry Andric : X86SchedWriteWidths<WritePMULLD, WritePMULLD, 6610b57cec5SDimitry Andric WritePMULLDY, WritePMULLDZ>; 6620b57cec5SDimitry Andricdef SchedWriteMPSAD 6630b57cec5SDimitry Andric : X86SchedWriteWidths<WriteMPSAD, WriteMPSAD, 6640b57cec5SDimitry Andric WriteMPSADY, WriteMPSADZ>; 6650b57cec5SDimitry Andricdef SchedWritePSADBW 6660b57cec5SDimitry Andric : X86SchedWriteWidths<WritePSADBW, WritePSADBWX, 6670b57cec5SDimitry Andric WritePSADBWY, WritePSADBWZ>; 6680b57cec5SDimitry Andric 6690b57cec5SDimitry Andricdef SchedWriteShuffle 6700b57cec5SDimitry Andric : X86SchedWriteWidths<WriteShuffle, WriteShuffleX, 6710b57cec5SDimitry Andric WriteShuffleY, WriteShuffleZ>; 6720b57cec5SDimitry Andricdef SchedWriteVarShuffle 6730b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVarShuffle, WriteVarShuffleX, 6740b57cec5SDimitry Andric WriteVarShuffleY, WriteVarShuffleZ>; 6750b57cec5SDimitry Andricdef SchedWriteBlend 6760b57cec5SDimitry Andric : X86SchedWriteWidths<WriteBlend, WriteBlend, WriteBlendY, WriteBlendZ>; 6770b57cec5SDimitry Andricdef SchedWriteVarBlend 6780b57cec5SDimitry Andric : X86SchedWriteWidths<WriteVarBlend, WriteVarBlend, 6790b57cec5SDimitry Andric WriteVarBlendY, WriteVarBlendZ>; 6800b57cec5SDimitry Andric 6810b57cec5SDimitry Andric// Vector size wrappers. 6820b57cec5SDimitry Andricdef SchedWriteFAddSizes 6830b57cec5SDimitry Andric : X86SchedWriteSizes<SchedWriteFAdd, SchedWriteFAdd64>; 6840b57cec5SDimitry Andricdef SchedWriteFCmpSizes 6850b57cec5SDimitry Andric : X86SchedWriteSizes<SchedWriteFCmp, SchedWriteFCmp64>; 6860b57cec5SDimitry Andricdef SchedWriteFMulSizes 6870b57cec5SDimitry Andric : X86SchedWriteSizes<SchedWriteFMul, SchedWriteFMul64>; 6880b57cec5SDimitry Andricdef SchedWriteFDivSizes 6890b57cec5SDimitry Andric : X86SchedWriteSizes<SchedWriteFDiv, SchedWriteFDiv64>; 6900b57cec5SDimitry Andricdef SchedWriteFSqrtSizes 6910b57cec5SDimitry Andric : X86SchedWriteSizes<SchedWriteFSqrt, SchedWriteFSqrt64>; 6920b57cec5SDimitry Andricdef SchedWriteFLogicSizes 6930b57cec5SDimitry Andric : X86SchedWriteSizes<SchedWriteFLogic, SchedWriteFLogic>; 6940b57cec5SDimitry Andricdef SchedWriteFShuffleSizes 6950b57cec5SDimitry Andric : X86SchedWriteSizes<SchedWriteFShuffle, SchedWriteFShuffle>; 6960b57cec5SDimitry Andric 6970b57cec5SDimitry Andric//===----------------------------------------------------------------------===// 6980b57cec5SDimitry Andric// Generic Processor Scheduler Models. 6990b57cec5SDimitry Andric 7000b57cec5SDimitry Andric// IssueWidth is analogous to the number of decode units. Core and its 7010b57cec5SDimitry Andric// descendents, including Nehalem and SandyBridge have 4 decoders. 7020b57cec5SDimitry Andric// Resources beyond the decoder operate on micro-ops and are bufferred 7030b57cec5SDimitry Andric// so adjacent micro-ops don't directly compete. 7040b57cec5SDimitry Andric// 7050b57cec5SDimitry Andric// MicroOpBufferSize > 1 indicates that RAW dependencies can be 7060b57cec5SDimitry Andric// decoded in the same cycle. The value 32 is a reasonably arbitrary 7070b57cec5SDimitry Andric// number of in-flight instructions. 7080b57cec5SDimitry Andric// 7090b57cec5SDimitry Andric// HighLatency=10 is optimistic. X86InstrInfo::isHighLatencyDef 7100b57cec5SDimitry Andric// indicates high latency opcodes. Alternatively, InstrItinData 7110b57cec5SDimitry Andric// entries may be included here to define specific operand 7120b57cec5SDimitry Andric// latencies. Since these latencies are not used for pipeline hazards, 7130b57cec5SDimitry Andric// they do not need to be exact. 7140b57cec5SDimitry Andric// 7150b57cec5SDimitry Andric// The GenericX86Model contains no instruction schedules 7160b57cec5SDimitry Andric// and disables PostRAScheduler. 7170b57cec5SDimitry Andricclass GenericX86Model : SchedMachineModel { 7180b57cec5SDimitry Andric let IssueWidth = 4; 7190b57cec5SDimitry Andric let MicroOpBufferSize = 32; 7200b57cec5SDimitry Andric let LoadLatency = 4; 7210b57cec5SDimitry Andric let HighLatency = 10; 7220b57cec5SDimitry Andric let PostRAScheduler = 0; 7230b57cec5SDimitry Andric let CompleteModel = 0; 7240b57cec5SDimitry Andric} 7250b57cec5SDimitry Andric 7260b57cec5SDimitry Andricdef GenericModel : GenericX86Model; 7270b57cec5SDimitry Andric 7280b57cec5SDimitry Andric// Define a model with the PostRAScheduler enabled. 7290b57cec5SDimitry Andricdef GenericPostRAModel : GenericX86Model { 7300b57cec5SDimitry Andric let PostRAScheduler = 1; 7310b57cec5SDimitry Andric} 732