1 //=- SystemZScheduleZEC12.td - SystemZ Scheduling Definitions --*- tblgen -*-=//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
9 // This file defines the machine model for ZEC12 to support instruction
10 // scheduling and other instruction cost heuristics.
12 // Pseudos expanded right after isel do not need to be modelled here.
14 //===----------------------------------------------------------------------===//
16 def ZEC12Model : SchedMachineModel {
18 let UnsupportedFeatures = Arch10UnsupportedFeatures.List;
21 let MicroOpBufferSize = 40; // Issue queues
22 let LoadLatency = 1; // Optimistic load latency.
24 let PostRAScheduler = 1;
26 // Extra cycles for a mispredicted branch.
27 let MispredictPenalty = 16;
30 let SchedModel = ZEC12Model in {
31 // These definitions need the SchedModel value. They could be put in a
32 // subtarget common include file, but it seems the include system in Tablegen
33 // currently (2016) rejects multiple includes of same file.
35 // Decoder grouping rules
36 let NumMicroOps = 1 in {
37 def : WriteRes<NormalGr, []>;
38 def : WriteRes<BeginGroup, []> { let BeginGroup = 1; }
39 def : WriteRes<EndGroup, []> { let EndGroup = 1; }
41 def : WriteRes<GroupAlone, []> {
46 def : WriteRes<GroupAlone2, []> {
51 def : WriteRes<GroupAlone3, []> {
57 // Incoming latency removed from the register operand which is used together
58 // with a memory operand by the instruction.
59 def : ReadAdvance<RegReadAdv, 4>;
61 // LoadLatency (above) is not used for instructions in this file. This is
62 // instead the role of LSULatency, which is the latency value added to the
63 // result of loads and instructions with folded memory operands.
64 def : WriteRes<LSULatency, []> { let Latency = 4; let NumMicroOps = 0; }
66 let NumMicroOps = 0 in {
68 def : WriteRes<!cast<SchedWrite>("WLat"#L), []> { let Latency = L; }
73 def ZEC12_FXUnit : ProcResource<2>;
74 def ZEC12_LSUnit : ProcResource<2>;
75 def ZEC12_FPUnit : ProcResource<1>;
76 def ZEC12_DFUnit : ProcResource<1>;
77 def ZEC12_VBUnit : ProcResource<1>;
78 def ZEC12_MCD : ProcResource<1>;
80 // Subtarget specific definitions of scheduling resources.
81 let NumMicroOps = 0 in {
82 def : WriteRes<FXU, [ZEC12_FXUnit]>;
83 def : WriteRes<LSU, [ZEC12_LSUnit]>;
84 def : WriteRes<FPU, [ZEC12_FPUnit]>;
85 def : WriteRes<DFU, [ZEC12_DFUnit]>;
86 foreach Num = 2-6 in { let ResourceCycles = [Num] in {
87 def : WriteRes<!cast<SchedWrite>("FXU"#Num), [ZEC12_FXUnit]>;
88 def : WriteRes<!cast<SchedWrite>("LSU"#Num), [ZEC12_LSUnit]>;
89 def : WriteRes<!cast<SchedWrite>("FPU"#Num), [ZEC12_FPUnit]>;
90 def : WriteRes<!cast<SchedWrite>("DFU"#Num), [ZEC12_DFUnit]>;
93 def : WriteRes<VBU, [ZEC12_VBUnit]>; // Virtual Branching Unit
96 def : WriteRes<MCD, [ZEC12_MCD]> { let NumMicroOps = 3;
100 // -------------------------- INSTRUCTIONS ---------------------------------- //
102 // InstRW constructs have been used in order to preserve the
103 // readability of the InstrInfo files.
105 // For each instruction, as matched by a regexp, provide a list of
106 // resources that it needs. These will be combined into a SchedClass.
108 //===----------------------------------------------------------------------===//
110 //===----------------------------------------------------------------------===//
112 // Pseudo -> LA / LAY
113 def : InstRW<[WLat1, FXU, NormalGr], (instregex "ADJDYNALLOC$")>;
115 //===----------------------------------------------------------------------===//
116 // Branch instructions
117 //===----------------------------------------------------------------------===//
120 def : InstRW<[WLat1, VBU, NormalGr], (instregex "(Call)?BRC(L)?(Asm.*)?$")>;
121 def : InstRW<[WLat1, VBU, NormalGr], (instregex "(Call)?J(G)?(Asm.*)?$")>;
122 def : InstRW<[WLat1, LSU, NormalGr], (instregex "(Call)?BC(R)?(Asm.*)?$")>;
123 def : InstRW<[WLat1, LSU, NormalGr], (instregex "(Call)?B(R)?(Asm.*)?$")>;
124 def : InstRW<[WLat1, FXU, EndGroup], (instregex "BRCT(G)?$")>;
125 def : InstRW<[WLat1, FXU, LSU, GroupAlone], (instregex "BRCTH$")>;
126 def : InstRW<[WLat1, FXU, LSU, GroupAlone], (instregex "BCT(G)?(R)?$")>;
127 def : InstRW<[WLat1, FXU3, LSU, GroupAlone2],
128 (instregex "B(R)?X(H|L).*$")>;
130 // Compare and branch
131 def : InstRW<[WLat1, FXU, NormalGr], (instregex "C(L)?(G)?(I|R)J(Asm.*)?$")>;
132 def : InstRW<[WLat1, FXU, LSU, GroupAlone],
133 (instregex "C(L)?(G)?(I|R)B(Call|Return|Asm.*)?$")>;
135 //===----------------------------------------------------------------------===//
137 //===----------------------------------------------------------------------===//
140 def : InstRW<[WLat1, VBU, NormalGr], (instregex "(Cond)?Trap$")>;
143 def : InstRW<[WLat1, FXU, NormalGr], (instregex "C(G)?(I|R)T(Asm.*)?$")>;
144 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CL(G)?RT(Asm.*)?$")>;
145 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CL(F|G)IT(Asm.*)?$")>;
146 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "CL(G)?T(Asm.*)?$")>;
148 //===----------------------------------------------------------------------===//
149 // Call and return instructions
150 //===----------------------------------------------------------------------===//
153 def : InstRW<[WLat1, FXU2, VBU, GroupAlone], (instregex "(Call)?BRAS$")>;
154 def : InstRW<[WLat1, FXU2, LSU, GroupAlone], (instregex "(Call)?BRASL$")>;
155 def : InstRW<[WLat1, FXU2, LSU, GroupAlone], (instregex "(Call)?BAS(R)?$")>;
156 def : InstRW<[WLat1, FXU2, LSU, GroupAlone], (instregex "TLS_(G|L)DCALL$")>;
159 def : InstRW<[WLat1, LSU, EndGroup], (instregex "Return$")>;
160 def : InstRW<[WLat1, LSU, NormalGr], (instregex "CondReturn$")>;
162 //===----------------------------------------------------------------------===//
164 //===----------------------------------------------------------------------===//
167 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "MV(G|H)?HI$")>;
168 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "MVI(Y)?$")>;
171 def : InstRW<[WLat1, FXU, LSU3, GroupAlone], (instregex "MVC$")>;
172 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "MVCL(E|U)?$")>;
174 // Pseudo -> reg move
175 def : InstRW<[WLat1, FXU, NormalGr], (instregex "COPY(_TO_REGCLASS)?$")>;
176 def : InstRW<[WLat1, FXU, NormalGr], (instregex "EXTRACT_SUBREG$")>;
177 def : InstRW<[WLat1, FXU, NormalGr], (instregex "INSERT_SUBREG$")>;
178 def : InstRW<[WLat1, FXU, NormalGr], (instregex "REG_SEQUENCE$")>;
181 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "L(Y|FH|RL|Mux)?$")>;
182 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "LG(RL)?$")>;
183 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "L128$")>;
185 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LLIH(F|H|L)$")>;
186 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LLIL(F|H|L)$")>;
188 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LG(F|H)I$")>;
189 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LHI(Mux)?$")>;
190 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LR(Mux)?$")>;
193 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "L(FH|G)?AT$")>;
196 def : InstRW<[WLat1LSU, WLat1LSU, LSU, FXU, NormalGr], (instregex "LT(G)?$")>;
197 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LT(G)?R$")>;
200 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "STG(RL)?$")>;
201 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "ST128$")>;
202 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "ST(Y|FH|RL|Mux)?$")>;
205 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "MVST$")>;
207 //===----------------------------------------------------------------------===//
208 // Conditional move instructions
209 //===----------------------------------------------------------------------===//
211 def : InstRW<[WLat2, FXU, NormalGr], (instregex "LOC(G)?R(Asm.*)?$")>;
212 def : InstRW<[WLat2LSU, RegReadAdv, FXU, LSU, NormalGr],
213 (instregex "LOC(G)?(Asm.*)?$")>;
214 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "STOC(G)?(Asm.*)?$")>;
216 //===----------------------------------------------------------------------===//
218 //===----------------------------------------------------------------------===//
220 def : InstRW<[WLat1, FXU, NormalGr], (instregex "L(B|H|G)R$")>;
221 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LG(B|H|F)R$")>;
223 def : InstRW<[WLat1LSU, WLat1LSU, FXU, LSU, NormalGr], (instregex "LTGF$")>;
224 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LTGFR$")>;
226 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "LB(H|Mux)?$")>;
227 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "LH(Y)?$")>;
228 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "LH(H|Mux|RL)$")>;
229 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "LG(B|H|F)$")>;
230 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "LG(H|F)RL$")>;
232 //===----------------------------------------------------------------------===//
234 //===----------------------------------------------------------------------===//
236 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LLCR(Mux)?$")>;
237 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LLHR(Mux)?$")>;
238 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LLG(C|H|F|T)R$")>;
239 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "LLC(Mux)?$")>;
240 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "LLH(Mux)?$")>;
241 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "LL(C|H)H$")>;
242 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "LLHRL$")>;
243 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "LLG(C|H|F|T|HRL|FRL)$")>;
246 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "LLG(F|T)?AT$")>;
248 //===----------------------------------------------------------------------===//
250 //===----------------------------------------------------------------------===//
252 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "STC(H|Y|Mux)?$")>;
253 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "STH(H|Y|RL|Mux)?$")>;
254 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "STCM(H|Y)?$")>;
256 //===----------------------------------------------------------------------===//
257 // Multi-register moves
258 //===----------------------------------------------------------------------===//
260 // Load multiple (estimated average of 5 ops)
261 def : InstRW<[WLat10, WLat10, LSU5, GroupAlone], (instregex "LM(H|Y|G)?$")>;
263 // Load multiple disjoint
264 def : InstRW<[WLat30, WLat30, MCD], (instregex "LMD$")>;
266 // Store multiple (estimated average of 3 ops)
267 def : InstRW<[WLat1, LSU2, FXU5, GroupAlone], (instregex "STM(H|Y|G)?$")>;
269 //===----------------------------------------------------------------------===//
271 //===----------------------------------------------------------------------===//
273 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LRV(G)?R$")>;
274 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "LRV(G|H)?$")>;
275 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "STRV(G|H)?$")>;
276 def : InstRW<[WLat30, MCD], (instregex "MVCIN$")>;
278 //===----------------------------------------------------------------------===//
279 // Load address instructions
280 //===----------------------------------------------------------------------===//
282 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LA(Y|RL)?$")>;
284 // Load the Global Offset Table address
285 def : InstRW<[WLat1, FXU, NormalGr], (instregex "GOT$")>;
287 //===----------------------------------------------------------------------===//
288 // Absolute and Negation
289 //===----------------------------------------------------------------------===//
291 def : InstRW<[WLat2, WLat2, FXU, NormalGr], (instregex "LP(G)?R$")>;
292 def : InstRW<[WLat3, WLat3, FXU2, GroupAlone], (instregex "L(N|P)GFR$")>;
293 def : InstRW<[WLat2, WLat2, FXU, NormalGr], (instregex "LN(R|GR)$")>;
294 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LC(R|GR)$")>;
295 def : InstRW<[WLat2, WLat2, FXU2, GroupAlone], (instregex "LCGFR$")>;
297 //===----------------------------------------------------------------------===//
299 //===----------------------------------------------------------------------===//
301 def : InstRW<[WLat1LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "IC(Y)?$")>;
302 def : InstRW<[WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
303 (instregex "IC32(Y)?$")>;
304 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
305 (instregex "ICM(H|Y)?$")>;
306 def : InstRW<[WLat1, FXU, NormalGr], (instregex "II(F|H|L)Mux$")>;
307 def : InstRW<[WLat1, FXU, NormalGr], (instregex "IIHF(64)?$")>;
308 def : InstRW<[WLat1, FXU, NormalGr], (instregex "IIHH(64)?$")>;
309 def : InstRW<[WLat1, FXU, NormalGr], (instregex "IIHL(64)?$")>;
310 def : InstRW<[WLat1, FXU, NormalGr], (instregex "IILF(64)?$")>;
311 def : InstRW<[WLat1, FXU, NormalGr], (instregex "IILH(64)?$")>;
312 def : InstRW<[WLat1, FXU, NormalGr], (instregex "IILL(64)?$")>;
314 //===----------------------------------------------------------------------===//
316 //===----------------------------------------------------------------------===//
318 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
319 (instregex "A(L)?(Y)?$")>;
320 def : InstRW<[WLat1LSU, WLat1LSU, FXU, LSU, NormalGr], (instregex "A(L)?SI$")>;
321 def : InstRW<[WLat2LSU, WLat2LSU, RegReadAdv, FXU, LSU, NormalGr],
322 (instregex "AH(Y)?$")>;
323 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AIH$")>;
324 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AFI(Mux)?$")>;
325 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AGFI$")>;
326 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AGHI(K)?$")>;
327 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AGR(K)?$")>;
328 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AHI(K)?$")>;
329 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AHIMux(K)?$")>;
330 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AL(FI|HSIK)$")>;
331 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
332 (instregex "ALGF$")>;
333 def : InstRW<[WLat1, FXU, NormalGr], (instregex "ALGHSIK$")>;
334 def : InstRW<[WLat1, FXU, NormalGr], (instregex "ALGF(I|R)$")>;
335 def : InstRW<[WLat1, FXU, NormalGr], (instregex "ALGR(K)?$")>;
336 def : InstRW<[WLat1, FXU, NormalGr], (instregex "ALR(K)?$")>;
337 def : InstRW<[WLat1, FXU, NormalGr], (instregex "AR(K)?$")>;
338 def : InstRW<[WLat1, FXU, NormalGr], (instregex "A(L)?HHHR$")>;
339 def : InstRW<[WLat2, WLat2, FXU, NormalGr], (instregex "A(L)?HHLR$")>;
340 def : InstRW<[WLat1, FXU, NormalGr], (instregex "ALSIH(N)?$")>;
341 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
342 (instregex "A(L)?G$")>;
343 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "A(L)?GSI$")>;
345 // Logical addition with carry
346 def : InstRW<[WLat2LSU, WLat2LSU, RegReadAdv, FXU, LSU, GroupAlone],
347 (instregex "ALC(G)?$")>;
348 def : InstRW<[WLat2, WLat2, FXU, GroupAlone], (instregex "ALC(G)?R$")>;
350 // Add with sign extension (32 -> 64)
351 def : InstRW<[WLat2LSU, WLat2LSU, RegReadAdv, FXU, LSU, NormalGr],
353 def : InstRW<[WLat2, WLat2, FXU, NormalGr], (instregex "AGFR$")>;
355 //===----------------------------------------------------------------------===//
357 //===----------------------------------------------------------------------===//
359 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
360 (instregex "S(G|Y)?$")>;
361 def : InstRW<[WLat2LSU, WLat2LSU, RegReadAdv, FXU, LSU, NormalGr],
362 (instregex "SH(Y)?$")>;
363 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SGR(K)?$")>;
364 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SLFI$")>;
365 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
366 (instregex "SL(G|GF|Y)?$")>;
367 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SLGF(I|R)$")>;
368 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SLGR(K)?$")>;
369 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SLR(K)?$")>;
370 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SR(K)?$")>;
371 def : InstRW<[WLat1, FXU, NormalGr], (instregex "S(L)?HHHR$")>;
372 def : InstRW<[WLat2, WLat2, FXU, NormalGr], (instregex "S(L)?HHLR$")>;
374 // Subtraction with borrow
375 def : InstRW<[WLat2LSU, WLat2LSU, RegReadAdv, FXU, LSU, GroupAlone],
376 (instregex "SLB(G)?$")>;
377 def : InstRW<[WLat2, WLat2, FXU, GroupAlone], (instregex "SLB(G)?R$")>;
379 // Subtraction with sign extension (32 -> 64)
380 def : InstRW<[WLat2LSU, WLat2LSU, RegReadAdv, FXU, LSU, NormalGr],
382 def : InstRW<[WLat2, WLat2, FXU, NormalGr], (instregex "SGFR$")>;
384 //===----------------------------------------------------------------------===//
386 //===----------------------------------------------------------------------===//
388 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
389 (instregex "N(G|Y)?$")>;
390 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NGR(K)?$")>;
391 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NI(FMux|HMux|LMux)$")>;
392 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "NI(Y)?$")>;
393 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NIHF(64)?$")>;
394 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NIHH(64)?$")>;
395 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NIHL(64)?$")>;
396 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NILF(64)?$")>;
397 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NILH(64)?$")>;
398 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NILL(64)?$")>;
399 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NR(K)?$")>;
400 def : InstRW<[WLat5LSU, LSU2, FXU, GroupAlone], (instregex "NC$")>;
402 //===----------------------------------------------------------------------===//
404 //===----------------------------------------------------------------------===//
406 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
407 (instregex "O(G|Y)?$")>;
408 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OGR(K)?$")>;
409 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "OI(Y)?$")>;
410 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OI(FMux|HMux|LMux)$")>;
411 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OIHF(64)?$")>;
412 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OIHH(64)?$")>;
413 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OIHL(64)?$")>;
414 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OILF(64)?$")>;
415 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OILH(64)?$")>;
416 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OILL(64)?$")>;
417 def : InstRW<[WLat1, FXU, NormalGr], (instregex "OR(K)?$")>;
418 def : InstRW<[WLat5LSU, LSU2, FXU, GroupAlone], (instregex "OC$")>;
420 //===----------------------------------------------------------------------===//
422 //===----------------------------------------------------------------------===//
424 def : InstRW<[WLat1LSU, WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
425 (instregex "X(G|Y)?$")>;
426 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "XI(Y)?$")>;
427 def : InstRW<[WLat1, FXU, NormalGr], (instregex "XIFMux$")>;
428 def : InstRW<[WLat1, FXU, NormalGr], (instregex "XGR(K)?$")>;
429 def : InstRW<[WLat1, FXU, NormalGr], (instregex "XIHF(64)?$")>;
430 def : InstRW<[WLat1, FXU, NormalGr], (instregex "XILF(64)?$")>;
431 def : InstRW<[WLat1, FXU, NormalGr], (instregex "XR(K)?$")>;
432 def : InstRW<[WLat5LSU, LSU2, FXU, GroupAlone], (instregex "XC$")>;
434 //===----------------------------------------------------------------------===//
436 //===----------------------------------------------------------------------===//
438 def : InstRW<[WLat6LSU, RegReadAdv, FXU, LSU, NormalGr],
439 (instregex "MS(GF|Y)?$")>;
440 def : InstRW<[WLat6, FXU, NormalGr], (instregex "MS(R|FI)$")>;
441 def : InstRW<[WLat8LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "MSG$")>;
442 def : InstRW<[WLat8, FXU, NormalGr], (instregex "MSGR$")>;
443 def : InstRW<[WLat6, FXU, NormalGr], (instregex "MSGF(I|R)$")>;
444 def : InstRW<[WLat11LSU, RegReadAdv, FXU2, LSU, GroupAlone],
446 def : InstRW<[WLat9, FXU2, GroupAlone], (instregex "MLGR$")>;
447 def : InstRW<[WLat5, FXU, NormalGr], (instregex "MGHI$")>;
448 def : InstRW<[WLat5, FXU, NormalGr], (instregex "MHI$")>;
449 def : InstRW<[WLat5LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "MH(Y)?$")>;
450 def : InstRW<[WLat7, FXU2, GroupAlone], (instregex "M(L)?R$")>;
451 def : InstRW<[WLat7LSU, RegReadAdv, FXU2, LSU, GroupAlone],
452 (instregex "M(FY|L)?$")>;
454 //===----------------------------------------------------------------------===//
455 // Division and remainder
456 //===----------------------------------------------------------------------===//
458 def : InstRW<[WLat30, FPU4, FXU5, GroupAlone3], (instregex "DR$")>;
459 def : InstRW<[WLat30, RegReadAdv, FPU4, LSU, FXU4, GroupAlone3],
461 def : InstRW<[WLat30, FPU4, FXU4, GroupAlone3], (instregex "DSG(F)?R$")>;
462 def : InstRW<[WLat30, RegReadAdv, FPU4, LSU, FXU3, GroupAlone3],
463 (instregex "DSG(F)?$")>;
464 def : InstRW<[WLat30, FPU4, FXU5, GroupAlone3], (instregex "DL(G)?R$")>;
465 def : InstRW<[WLat30, RegReadAdv, FPU4, LSU, FXU4, GroupAlone3],
466 (instregex "DL(G)?$")>;
468 //===----------------------------------------------------------------------===//
470 //===----------------------------------------------------------------------===//
472 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SLL(G|K)?$")>;
473 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SRL(G|K)?$")>;
474 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SRA(G|K)?$")>;
475 def : InstRW<[WLat1, FXU, NormalGr], (instregex "SLA(G|K)?$")>;
476 def : InstRW<[WLat5LSU, WLat5LSU, FXU4, LSU, GroupAlone2],
477 (instregex "S(L|R)D(A|L)$")>;
480 def : InstRW<[WLat2LSU, FXU, LSU, NormalGr], (instregex "RLL(G)?$")>;
483 def : InstRW<[WLat1, FXU, NormalGr], (instregex "RISBG(N|32)?$")>;
484 def : InstRW<[WLat1, FXU, NormalGr], (instregex "RISBH(G|H|L)$")>;
485 def : InstRW<[WLat1, FXU, NormalGr], (instregex "RISBL(G|H|L)$")>;
486 def : InstRW<[WLat1, FXU, NormalGr], (instregex "RISBMux$")>;
489 def : InstRW<[WLat3, WLat3, FXU2, GroupAlone], (instregex "R(N|O|X)SBG$")>;
491 //===----------------------------------------------------------------------===//
493 //===----------------------------------------------------------------------===//
495 def : InstRW<[WLat1LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "C(G|Y|Mux|RL)?$")>;
496 def : InstRW<[WLat1, FXU, NormalGr], (instregex "C(F|H)I(Mux)?$")>;
497 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CG(F|H)I$")>;
498 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CG(HSI|RL)$")>;
499 def : InstRW<[WLat1, FXU, NormalGr], (instregex "C(G)?R$")>;
500 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CIH$")>;
501 def : InstRW<[WLat1LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "CHF$")>;
502 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CHSI$")>;
503 def : InstRW<[WLat1LSU, RegReadAdv, FXU, LSU, NormalGr],
504 (instregex "CL(Y|Mux)?$")>;
505 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CLFHSI$")>;
506 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CLFI(Mux)?$")>;
507 def : InstRW<[WLat1LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "CLG$")>;
508 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CLG(HRL|HSI)$")>;
509 def : InstRW<[WLat1LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "CLGF$")>;
510 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CLGFRL$")>;
511 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CLGF(I|R)$")>;
512 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CLGR$")>;
513 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CLGRL$")>;
514 def : InstRW<[WLat1LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "CLHF$")>;
515 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CLH(RL|HSI)$")>;
516 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CLIH$")>;
517 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CLI(Y)?$")>;
518 def : InstRW<[WLat1, FXU, NormalGr], (instregex "CLR$")>;
519 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "CLRL$")>;
520 def : InstRW<[WLat1, FXU, NormalGr], (instregex "C(L)?HHR$")>;
521 def : InstRW<[WLat2, FXU, NormalGr], (instregex "C(L)?HLR$")>;
524 def : InstRW<[WLat2LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "CH(Y)?$")>;
525 def : InstRW<[WLat2LSU, FXU, LSU, NormalGr], (instregex "CHRL$")>;
526 def : InstRW<[WLat2LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "CGH$")>;
527 def : InstRW<[WLat2LSU, FXU, LSU, NormalGr], (instregex "CGHRL$")>;
528 def : InstRW<[WLat2LSU, FXU2, LSU, GroupAlone], (instregex "CHHSI$")>;
530 // Compare with sign extension (32 -> 64)
531 def : InstRW<[WLat2LSU, RegReadAdv, FXU, LSU, NormalGr], (instregex "CGF$")>;
532 def : InstRW<[WLat2LSU, FXU, LSU, NormalGr], (instregex "CGFRL$")>;
533 def : InstRW<[WLat2, FXU, NormalGr], (instregex "CGFR$")>;
535 // Compare logical character
536 def : InstRW<[WLat9, FXU, LSU2, GroupAlone], (instregex "CLC$")>;
537 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "CLCL(E|U)?$")>;
538 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "CLST$")>;
541 def : InstRW<[WLat1LSU, FXU, LSU, NormalGr], (instregex "TM(Y)?$")>;
542 def : InstRW<[WLat1, FXU, NormalGr], (instregex "TM(H|L)Mux$")>;
543 def : InstRW<[WLat1, FXU, NormalGr], (instregex "TMHH(64)?$")>;
544 def : InstRW<[WLat1, FXU, NormalGr], (instregex "TMHL(64)?$")>;
545 def : InstRW<[WLat1, FXU, NormalGr], (instregex "TMLH(64)?$")>;
546 def : InstRW<[WLat1, FXU, NormalGr], (instregex "TMLL(64)?$")>;
548 // Compare logical characters under mask
549 def : InstRW<[WLat2LSU, RegReadAdv, FXU, LSU, NormalGr],
550 (instregex "CLM(H|Y)?$")>;
552 //===----------------------------------------------------------------------===//
553 // Prefetch and execution hint
554 //===----------------------------------------------------------------------===//
556 def : InstRW<[WLat1, LSU, NormalGr], (instregex "PFD(RL)?$")>;
557 def : InstRW<[WLat1, LSU, NormalGr], (instregex "BP(R)?P$")>;
558 def : InstRW<[WLat1, FXU, NormalGr], (instregex "NIAI$")>;
560 //===----------------------------------------------------------------------===//
562 //===----------------------------------------------------------------------===//
564 def : InstRW<[WLat1, LSU, EndGroup], (instregex "Serialize$")>;
566 def : InstRW<[WLat1LSU, WLat1LSU, FXU, LSU, NormalGr], (instregex "LAA(G)?$")>;
567 def : InstRW<[WLat1LSU, WLat1LSU, FXU, LSU, NormalGr], (instregex "LAAL(G)?$")>;
568 def : InstRW<[WLat1LSU, WLat1LSU, FXU, LSU, NormalGr], (instregex "LAN(G)?$")>;
569 def : InstRW<[WLat1LSU, WLat1LSU, FXU, LSU, NormalGr], (instregex "LAO(G)?$")>;
570 def : InstRW<[WLat1LSU, WLat1LSU, FXU, LSU, NormalGr], (instregex "LAX(G)?$")>;
573 def : InstRW<[WLat1LSU, FXU, LSU, EndGroup], (instregex "TS$")>;
576 def : InstRW<[WLat2LSU, WLat2LSU, FXU2, LSU, GroupAlone],
577 (instregex "CS(G|Y)?$")>;
579 // Compare double and swap
580 def : InstRW<[WLat5LSU, WLat5LSU, FXU5, LSU, GroupAlone2],
581 (instregex "CDS(Y)?$")>;
582 def : InstRW<[WLat12, WLat12, FXU6, LSU2, GroupAlone],
583 (instregex "CDSG$")>;
585 // Compare and swap and store
586 def : InstRW<[WLat30, MCD], (instregex "CSST$")>;
588 // Perform locked operation
589 def : InstRW<[WLat30, MCD], (instregex "PLO$")>;
591 // Load/store pair from/to quadword
592 def : InstRW<[WLat4LSU, LSU2, GroupAlone], (instregex "LPQ$")>;
593 def : InstRW<[WLat1, FXU2, LSU2, GroupAlone], (instregex "STPQ$")>;
595 // Load pair disjoint
596 def : InstRW<[WLat2LSU, WLat2LSU, LSU2, GroupAlone], (instregex "LPD(G)?$")>;
598 //===----------------------------------------------------------------------===//
599 // Translate and convert
600 //===----------------------------------------------------------------------===//
602 def : InstRW<[WLat1, LSU, GroupAlone], (instregex "TR$")>;
603 def : InstRW<[WLat30, WLat30, WLat30, FXU3, LSU2, GroupAlone2],
605 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "TRTR$")>;
606 def : InstRW<[WLat30, WLat30, MCD], (instregex "TRE$")>;
607 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "TRT(R)?E(Opt)?$")>;
608 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "TR(T|O)(T|O)(Opt)?$")>;
609 def : InstRW<[WLat30, WLat30, WLat30, MCD],
610 (instregex "CU(12|14|21|24|41|42)(Opt)?$")>;
611 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "(CUUTF|CUTFU)(Opt)?$")>;
613 //===----------------------------------------------------------------------===//
614 // Message-security assist
615 //===----------------------------------------------------------------------===//
617 def : InstRW<[WLat30, WLat30, WLat30, WLat30, MCD],
618 (instregex "KM(C|F|O|CTR)?$")>;
619 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "(KIMD|KLMD|KMAC|PCC)$")>;
621 //===----------------------------------------------------------------------===//
622 // Decimal arithmetic
623 //===----------------------------------------------------------------------===//
625 def : InstRW<[WLat30, RegReadAdv, FXU, DFU2, LSU2, GroupAlone2],
626 (instregex "CVBG$")>;
627 def : InstRW<[WLat20, RegReadAdv, FXU, DFU, LSU, GroupAlone],
628 (instregex "CVB(Y)?$")>;
629 def : InstRW<[WLat1, FXU3, DFU4, LSU, GroupAlone3], (instregex "CVDG$")>;
630 def : InstRW<[WLat1, FXU2, DFU, LSU, GroupAlone], (instregex "CVD(Y)?$")>;
631 def : InstRW<[WLat1, LSU5, GroupAlone], (instregex "MV(N|O|Z)$")>;
632 def : InstRW<[WLat1, LSU5, GroupAlone], (instregex "(PACK|PKA|PKU)$")>;
633 def : InstRW<[WLat10, LSU5, GroupAlone], (instregex "UNPK(A|U)$")>;
634 def : InstRW<[WLat1, FXU, LSU2, GroupAlone], (instregex "UNPK$")>;
636 def : InstRW<[WLat11LSU, FXU, DFU4, LSU2, GroupAlone],
637 (instregex "(A|S|ZA)P$")>;
638 def : InstRW<[WLat1, FXU, DFU4, LSU2, GroupAlone], (instregex "(M|D)P$")>;
639 def : InstRW<[WLat15, FXU2, DFU4, LSU3, GroupAlone], (instregex "SRP$")>;
640 def : InstRW<[WLat11, DFU4, LSU2, GroupAlone], (instregex "CP$")>;
641 def : InstRW<[WLat5LSU, DFU2, LSU2, GroupAlone], (instregex "TP$")>;
642 def : InstRW<[WLat30, MCD], (instregex "ED(MK)?$")>;
644 //===----------------------------------------------------------------------===//
646 //===----------------------------------------------------------------------===//
648 // Extract/set/copy access register
649 def : InstRW<[WLat3, LSU, NormalGr], (instregex "(EAR|SAR|CPYA)$")>;
651 // Load address extended
652 def : InstRW<[WLat5, LSU, FXU, GroupAlone], (instregex "LAE(Y)?$")>;
654 // Load/store access multiple (not modeled precisely)
655 def : InstRW<[WLat10, WLat10, LSU5, GroupAlone], (instregex "LAM(Y)?$")>;
656 def : InstRW<[WLat1, FXU5, LSU5, GroupAlone], (instregex "STAM(Y)?$")>;
658 //===----------------------------------------------------------------------===//
659 // Program mask and addressing mode
660 //===----------------------------------------------------------------------===//
662 // Insert Program Mask
663 def : InstRW<[WLat3, FXU, EndGroup], (instregex "IPM$")>;
666 def : InstRW<[WLat3, LSU, EndGroup], (instregex "SPM$")>;
669 def : InstRW<[WLat1, FXU2, LSU, GroupAlone], (instregex "BAL(R)?$")>;
671 // Test addressing mode
672 def : InstRW<[WLat1, FXU, NormalGr], (instregex "TAM$")>;
674 // Set addressing mode
675 def : InstRW<[WLat1, LSU, EndGroup], (instregex "SAM(24|31|64)$")>;
677 // Branch (and save) and set mode.
678 def : InstRW<[WLat1, FXU, LSU, GroupAlone], (instregex "BSM$")>;
679 def : InstRW<[WLat1, FXU2, LSU, GroupAlone], (instregex "BASSM$")>;
681 //===----------------------------------------------------------------------===//
682 // Transactional execution
683 //===----------------------------------------------------------------------===//
686 def : InstRW<[WLat9, LSU2, FXU5, GroupAlone], (instregex "TBEGIN(C)?$")>;
689 def : InstRW<[WLat4, LSU, GroupAlone], (instregex "TEND$")>;
692 def : InstRW<[WLat30, MCD], (instregex "TABORT$")>;
694 // Extract Transaction Nesting Depth
695 def : InstRW<[WLat30, MCD], (instregex "ETND$")>;
697 // Nontransactional store
698 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "NTSTG$")>;
700 //===----------------------------------------------------------------------===//
702 //===----------------------------------------------------------------------===//
704 def : InstRW<[WLat30, MCD], (instregex "PPA$")>;
706 //===----------------------------------------------------------------------===//
707 // Miscellaneous Instructions.
708 //===----------------------------------------------------------------------===//
711 def : InstRW<[WLat7, WLat7, FXU2, GroupAlone], (instregex "FLOGR$")>;
714 def : InstRW<[WLat3, WLat3, FXU, NormalGr], (instregex "POPCNT$")>;
716 // String instructions
717 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "SRST(U)?$")>;
718 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "CUSE$")>;
720 // Various complex instructions
721 def : InstRW<[WLat30, WLat30, WLat30, WLat30, MCD], (instregex "CFC$")>;
722 def : InstRW<[WLat30, WLat30, WLat30, WLat30, WLat30, WLat30, MCD],
724 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "CKSM$")>;
725 def : InstRW<[WLat30, WLat30, WLat30, WLat30, MCD], (instregex "CMPSC$")>;
728 def : InstRW<[LSU, GroupAlone], (instregex "EX(RL)?$")>;
730 //===----------------------------------------------------------------------===//
731 // .insn directive instructions
732 //===----------------------------------------------------------------------===//
734 // An "empty" sched-class will be assigned instead of the "invalid sched-class".
735 // getNumDecoderSlots() will then return 1 instead of 0.
736 def : InstRW<[], (instregex "Insn.*")>;
739 // ----------------------------- Floating point ----------------------------- //
741 //===----------------------------------------------------------------------===//
742 // FP: Move instructions
743 //===----------------------------------------------------------------------===//
746 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LZ(DR|ER)$")>;
747 def : InstRW<[WLat2, FXU2, GroupAlone], (instregex "LZXR$")>;
750 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LER$")>;
751 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LD(R|R32|GR)$")>;
752 def : InstRW<[WLat3, FXU, NormalGr], (instregex "LGDR$")>;
753 def : InstRW<[WLat2, FXU2, GroupAlone], (instregex "LXR$")>;
756 def : InstRW<[WLat9, WLat9, FPU, NormalGr], (instregex "LT(E|D)BR$")>;
757 def : InstRW<[WLat9, FPU, NormalGr], (instregex "LT(E|D)BRCompare$")>;
758 def : InstRW<[WLat10, WLat10, FPU4, GroupAlone], (instregex "LTXBR(Compare)?$")>;
761 def : InstRW<[WLat5, FXU2, GroupAlone], (instregex "CPSDR(d|s)(d|s)$")>;
763 //===----------------------------------------------------------------------===//
764 // FP: Load instructions
765 //===----------------------------------------------------------------------===//
767 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "L(E|D)(Y|E32)?$")>;
768 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "LX$")>;
770 //===----------------------------------------------------------------------===//
771 // FP: Store instructions
772 //===----------------------------------------------------------------------===//
774 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "ST(E|D)(Y)?$")>;
775 def : InstRW<[WLat1, FXU, LSU, NormalGr], (instregex "STX$")>;
777 //===----------------------------------------------------------------------===//
778 // FP: Conversion instructions
779 //===----------------------------------------------------------------------===//
782 def : InstRW<[WLat7, FPU, NormalGr], (instregex "LEDBR(A)?$")>;
783 def : InstRW<[WLat9, FPU2, NormalGr], (instregex "L(E|D)XBR(A)?$")>;
786 def : InstRW<[WLat7LSU, FPU, LSU, NormalGr], (instregex "LDEB$")>;
787 def : InstRW<[WLat7, FPU, NormalGr], (instregex "LDEBR$")>;
788 def : InstRW<[WLat11LSU, FPU4, LSU, GroupAlone], (instregex "LX(E|D)B$")>;
789 def : InstRW<[WLat10, FPU4, GroupAlone], (instregex "LX(E|D)BR$")>;
791 // Convert from fixed / logical
792 def : InstRW<[WLat8, FXU, FPU, GroupAlone], (instregex "C(E|D)(F|G)BR(A)?$")>;
793 def : InstRW<[WLat11, FXU, FPU4, GroupAlone2], (instregex "CX(F|G)BR(A?)$")>;
794 def : InstRW<[WLat8, FXU, FPU, GroupAlone], (instregex "CEL(F|G)BR$")>;
795 def : InstRW<[WLat8, FXU, FPU, GroupAlone], (instregex "CDL(F|G)BR$")>;
796 def : InstRW<[WLat11, FXU, FPU4, GroupAlone2], (instregex "CXL(F|G)BR$")>;
798 // Convert to fixed / logical
799 def : InstRW<[WLat12, WLat12, FXU, FPU, GroupAlone],
800 (instregex "C(F|G)(E|D)BR(A?)$")>;
801 def : InstRW<[WLat12, WLat12, FXU, FPU2, GroupAlone],
802 (instregex "C(F|G)XBR(A?)$")>;
803 def : InstRW<[WLat12, WLat12, FXU, FPU, GroupAlone],
804 (instregex "CL(F|G)(E|D)BR$")>;
805 def : InstRW<[WLat12, WLat12, FXU, FPU2, GroupAlone], (instregex "CL(F|G)XBR$")>;
807 //===----------------------------------------------------------------------===//
808 // FP: Unary arithmetic
809 //===----------------------------------------------------------------------===//
811 // Load Complement / Negative / Positive
812 def : InstRW<[WLat7, WLat7, FPU, NormalGr], (instregex "L(C|N|P)(E|D)BR$")>;
813 def : InstRW<[WLat1, FXU, NormalGr], (instregex "L(C|N|P)DFR(_32)?$")>;
814 def : InstRW<[WLat10, WLat10, FPU4, GroupAlone], (instregex "L(C|N|P)XBR$")>;
817 def : InstRW<[WLat30, FPU, LSU, NormalGr], (instregex "SQ(E|D)B$")>;
818 def : InstRW<[WLat30, FPU, NormalGr], (instregex "SQ(E|D)BR$")>;
819 def : InstRW<[WLat30, FPU4, GroupAlone], (instregex "SQXBR$")>;
822 def : InstRW<[WLat7, FPU, NormalGr], (instregex "FI(E|D)BR(A)?$")>;
823 def : InstRW<[WLat15, FPU4, GroupAlone], (instregex "FIXBR(A)?$")>;
825 //===----------------------------------------------------------------------===//
826 // FP: Binary arithmetic
827 //===----------------------------------------------------------------------===//
830 def : InstRW<[WLat7LSU, WLat7LSU, RegReadAdv, FPU, LSU, NormalGr],
831 (instregex "A(E|D)B$")>;
832 def : InstRW<[WLat7, WLat7, FPU, NormalGr], (instregex "A(E|D)BR$")>;
833 def : InstRW<[WLat20, WLat20, FPU4, GroupAlone], (instregex "AXBR$")>;
836 def : InstRW<[WLat7LSU, WLat7LSU, RegReadAdv, FPU, LSU, NormalGr],
837 (instregex "S(E|D)B$")>;
838 def : InstRW<[WLat7, WLat7, FPU, NormalGr], (instregex "S(E|D)BR$")>;
839 def : InstRW<[WLat20, WLat20, FPU4, GroupAlone], (instregex "SXBR$")>;
842 def : InstRW<[WLat7LSU, RegReadAdv, FPU, LSU, NormalGr],
843 (instregex "M(D|DE|EE)B$")>;
844 def : InstRW<[WLat7, FPU, NormalGr], (instregex "M(D|DE|EE)BR$")>;
845 def : InstRW<[WLat11LSU, RegReadAdv, FPU4, LSU, GroupAlone],
846 (instregex "MXDB$")>;
847 def : InstRW<[WLat10, FPU4, GroupAlone], (instregex "MXDBR$")>;
848 def : InstRW<[WLat30, FPU4, GroupAlone], (instregex "MXBR$")>;
850 // Multiply and add / subtract
851 def : InstRW<[WLat7LSU, RegReadAdv, RegReadAdv, FPU2, LSU, GroupAlone],
852 (instregex "M(A|S)EB$")>;
853 def : InstRW<[WLat7, FPU, GroupAlone], (instregex "M(A|S)EBR$")>;
854 def : InstRW<[WLat7LSU, RegReadAdv, RegReadAdv, FPU2, LSU, GroupAlone],
855 (instregex "M(A|S)DB$")>;
856 def : InstRW<[WLat7, FPU, GroupAlone], (instregex "M(A|S)DBR$")>;
859 def : InstRW<[WLat30, RegReadAdv, FPU, LSU, NormalGr], (instregex "D(E|D)B$")>;
860 def : InstRW<[WLat30, FPU, NormalGr], (instregex "D(E|D)BR$")>;
861 def : InstRW<[WLat30, FPU4, GroupAlone], (instregex "DXBR$")>;
864 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "DI(E|D)BR$")>;
866 //===----------------------------------------------------------------------===//
868 //===----------------------------------------------------------------------===//
871 def : InstRW<[WLat11LSU, RegReadAdv, FPU, LSU, NormalGr],
872 (instregex "(K|C)(E|D)B$")>;
873 def : InstRW<[WLat9, FPU, NormalGr], (instregex "(K|C)(E|D)BR$")>;
874 def : InstRW<[WLat30, FPU2, NormalGr], (instregex "(K|C)XBR$")>;
877 def : InstRW<[WLat15, FPU, LSU, NormalGr], (instregex "TC(E|D)B$")>;
878 def : InstRW<[WLat15, FPU4, LSU, GroupAlone], (instregex "TCXB$")>;
880 //===----------------------------------------------------------------------===//
881 // FP: Floating-point control register instructions
882 //===----------------------------------------------------------------------===//
884 def : InstRW<[WLat4, FXU, LSU, GroupAlone], (instregex "EFPC$")>;
885 def : InstRW<[WLat1, FXU, LSU, GroupAlone], (instregex "STFPC$")>;
886 def : InstRW<[WLat1, LSU, GroupAlone], (instregex "SFPC$")>;
887 def : InstRW<[WLat1, LSU2, GroupAlone], (instregex "LFPC$")>;
888 def : InstRW<[WLat30, MCD], (instregex "SFASR$")>;
889 def : InstRW<[WLat30, MCD], (instregex "LFAS$")>;
890 def : InstRW<[WLat2, FXU, GroupAlone], (instregex "SRNM(B|T)?$")>;
893 // --------------------- Hexadecimal floating point ------------------------- //
895 //===----------------------------------------------------------------------===//
896 // HFP: Move instructions
897 //===----------------------------------------------------------------------===//
900 def : InstRW<[WLat9, WLat9, FPU, NormalGr], (instregex "LT(E|D)R$")>;
901 def : InstRW<[WLat9, WLat9, FPU4, GroupAlone], (instregex "LTXR$")>;
903 //===----------------------------------------------------------------------===//
904 // HFP: Conversion instructions
905 //===----------------------------------------------------------------------===//
908 def : InstRW<[WLat7, FPU, NormalGr], (instregex "(LEDR|LRER)$")>;
909 def : InstRW<[WLat7, FPU, NormalGr], (instregex "LEXR$")>;
910 def : InstRW<[WLat9, FPU, NormalGr], (instregex "(LDXR|LRDR)$")>;
913 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "LDE$")>;
914 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LDER$")>;
915 def : InstRW<[WLat11LSU, FPU4, LSU, GroupAlone], (instregex "LX(E|D)$")>;
916 def : InstRW<[WLat9, FPU4, GroupAlone], (instregex "LX(E|D)R$")>;
918 // Convert from fixed
919 def : InstRW<[WLat8, FXU, FPU, GroupAlone], (instregex "C(E|D)(F|G)R$")>;
920 def : InstRW<[WLat10, FXU, FPU4, GroupAlone2], (instregex "CX(F|G)R$")>;
923 def : InstRW<[WLat12, WLat12, FXU, FPU, GroupAlone],
924 (instregex "C(F|G)(E|D)R$")>;
925 def : InstRW<[WLat30, WLat30, FXU, FPU2, GroupAlone], (instregex "C(F|G)XR$")>;
927 // Convert BFP to HFP / HFP to BFP.
928 def : InstRW<[WLat7, WLat7, FPU, NormalGr], (instregex "THD(E)?R$")>;
929 def : InstRW<[WLat7, WLat7, FPU, NormalGr], (instregex "TB(E)?DR$")>;
931 //===----------------------------------------------------------------------===//
932 // HFP: Unary arithmetic
933 //===----------------------------------------------------------------------===//
935 // Load Complement / Negative / Positive
936 def : InstRW<[WLat7, WLat7, FPU, NormalGr], (instregex "L(C|N|P)(E|D)R$")>;
937 def : InstRW<[WLat9, WLat9, FPU4, GroupAlone], (instregex "L(C|N|P)XR$")>;
940 def : InstRW<[WLat7, FPU, NormalGr], (instregex "H(E|D)R$")>;
943 def : InstRW<[WLat30, FPU, LSU, NormalGr], (instregex "SQ(E|D)$")>;
944 def : InstRW<[WLat30, FPU, NormalGr], (instregex "SQ(E|D)R$")>;
945 def : InstRW<[WLat30, FPU4, GroupAlone], (instregex "SQXR$")>;
948 def : InstRW<[WLat7, FPU, NormalGr], (instregex "FI(E|D)R$")>;
949 def : InstRW<[WLat15, FPU4, GroupAlone], (instregex "FIXR$")>;
951 //===----------------------------------------------------------------------===//
952 // HFP: Binary arithmetic
953 //===----------------------------------------------------------------------===//
956 def : InstRW<[WLat7LSU, WLat7LSU, RegReadAdv, FPU, LSU, NormalGr],
957 (instregex "A(E|D|U|W)$")>;
958 def : InstRW<[WLat7, WLat7, FPU, NormalGr], (instregex "A(E|D|U|W)R$")>;
959 def : InstRW<[WLat15, WLat15, FPU4, GroupAlone], (instregex "AXR$")>;
962 def : InstRW<[WLat7LSU, WLat7LSU, RegReadAdv, FPU, LSU, NormalGr],
963 (instregex "S(E|D|U|W)$")>;
964 def : InstRW<[WLat7, WLat7, FPU, NormalGr], (instregex "S(E|D|U|W)R$")>;
965 def : InstRW<[WLat15, WLat15, FPU4, GroupAlone], (instregex "SXR$")>;
968 def : InstRW<[WLat7LSU, RegReadAdv, FPU, LSU, NormalGr], (instregex "M(D|EE)$")>;
969 def : InstRW<[WLat8LSU, RegReadAdv, FPU, LSU, NormalGr], (instregex "M(DE|E)$")>;
970 def : InstRW<[WLat7, FPU, NormalGr], (instregex "M(D|EE)R$")>;
971 def : InstRW<[WLat8, FPU, NormalGr], (instregex "M(DE|E)R$")>;
972 def : InstRW<[WLat11LSU, RegReadAdv, FPU4, LSU, GroupAlone], (instregex "MXD$")>;
973 def : InstRW<[WLat10, FPU4, GroupAlone], (instregex "MXDR$")>;
974 def : InstRW<[WLat30, FPU4, GroupAlone], (instregex "MXR$")>;
975 def : InstRW<[WLat11LSU, RegReadAdv, FPU4, LSU, GroupAlone], (instregex "MY$")>;
976 def : InstRW<[WLat7LSU, RegReadAdv, FPU2, LSU, GroupAlone],
977 (instregex "MY(H|L)$")>;
978 def : InstRW<[WLat10, FPU4, GroupAlone], (instregex "MYR$")>;
979 def : InstRW<[WLat7, FPU, GroupAlone], (instregex "MY(H|L)R$")>;
981 // Multiply and add / subtract
982 def : InstRW<[WLat7LSU, RegReadAdv, RegReadAdv, FPU2, LSU, GroupAlone],
983 (instregex "M(A|S)(E|D)$")>;
984 def : InstRW<[WLat7, FPU, GroupAlone], (instregex "M(A|S)(E|D)R$")>;
985 def : InstRW<[WLat11LSU, RegReadAdv, RegReadAdv, FPU4, LSU, GroupAlone],
987 def : InstRW<[WLat7LSU, RegReadAdv, RegReadAdv, FPU2, LSU, GroupAlone],
988 (instregex "MAY(H|L)$")>;
989 def : InstRW<[WLat10, FPU4, GroupAlone], (instregex "MAYR$")>;
990 def : InstRW<[WLat7, FPU, GroupAlone], (instregex "MAY(H|L)R$")>;
993 def : InstRW<[WLat30, RegReadAdv, FPU, LSU, NormalGr], (instregex "D(E|D)$")>;
994 def : InstRW<[WLat30, FPU, NormalGr], (instregex "D(E|D)R$")>;
995 def : InstRW<[WLat30, FPU4, GroupAlone], (instregex "DXR$")>;
997 //===----------------------------------------------------------------------===//
999 //===----------------------------------------------------------------------===//
1002 def : InstRW<[WLat11LSU, RegReadAdv, FPU, LSU, NormalGr], (instregex "C(E|D)$")>;
1003 def : InstRW<[WLat9, FPU, NormalGr], (instregex "C(E|D)R$")>;
1004 def : InstRW<[WLat15, FPU2, NormalGr], (instregex "CXR$")>;
1007 // ------------------------ Decimal floating point -------------------------- //
1009 //===----------------------------------------------------------------------===//
1010 // DFP: Move instructions
1011 //===----------------------------------------------------------------------===//
1014 def : InstRW<[WLat4, WLat4, DFU, NormalGr], (instregex "LTDTR$")>;
1015 def : InstRW<[WLat6, WLat6, DFU4, GroupAlone], (instregex "LTXTR$")>;
1017 //===----------------------------------------------------------------------===//
1018 // DFP: Conversion instructions
1019 //===----------------------------------------------------------------------===//
1022 def : InstRW<[WLat30, DFU, NormalGr], (instregex "LEDTR$")>;
1023 def : InstRW<[WLat30, DFU2, NormalGr], (instregex "LDXTR$")>;
1026 def : InstRW<[WLat7, DFU, NormalGr], (instregex "LDETR$")>;
1027 def : InstRW<[WLat6, DFU4, GroupAlone], (instregex "LXDTR$")>;
1029 // Convert from fixed / logical
1030 def : InstRW<[WLat9, FXU, DFU, GroupAlone], (instregex "CDFTR$")>;
1031 def : InstRW<[WLat30, FXU, DFU, GroupAlone], (instregex "CDGTR(A)?$")>;
1032 def : InstRW<[WLat5, FXU, DFU4, GroupAlone2], (instregex "CXFTR(A)?$")>;
1033 def : InstRW<[WLat30, FXU, DFU4, GroupAlone2], (instregex "CXGTR(A)?$")>;
1034 def : InstRW<[WLat9, FXU, DFU, GroupAlone], (instregex "CDL(F|G)TR$")>;
1035 def : InstRW<[WLat9, FXU, DFU4, GroupAlone2], (instregex "CXLFTR$")>;
1036 def : InstRW<[WLat5, FXU, DFU4, GroupAlone2], (instregex "CXLGTR$")>;
1038 // Convert to fixed / logical
1039 def : InstRW<[WLat11, WLat11, FXU, DFU, GroupAlone], (instregex "CFDTR(A)?$")>;
1040 def : InstRW<[WLat30, WLat30, FXU, DFU, GroupAlone], (instregex "CGDTR(A)?$")>;
1041 def : InstRW<[WLat7, WLat7, FXU, DFU2, GroupAlone], (instregex "CFXTR$")>;
1042 def : InstRW<[WLat30, WLat30, FXU, DFU2, GroupAlone], (instregex "CGXTR(A)?$")>;
1043 def : InstRW<[WLat11, WLat11, FXU, DFU, GroupAlone], (instregex "CL(F|G)DTR$")>;
1044 def : InstRW<[WLat7, WLat7, FXU, DFU2, GroupAlone], (instregex "CL(F|G)XTR$")>;
1046 // Convert from / to signed / unsigned packed
1047 def : InstRW<[WLat5, FXU, DFU, GroupAlone], (instregex "CD(S|U)TR$")>;
1048 def : InstRW<[WLat8, FXU2, DFU4, GroupAlone2], (instregex "CX(S|U)TR$")>;
1049 def : InstRW<[WLat7, FXU, DFU, GroupAlone], (instregex "C(S|U)DTR$")>;
1050 def : InstRW<[WLat12, FXU2, DFU4, GroupAlone2], (instregex "C(S|U)XTR$")>;
1052 // Convert from / to zoned
1053 def : InstRW<[WLat4LSU, LSU, DFU2, GroupAlone], (instregex "CDZT$")>;
1054 def : InstRW<[WLat11LSU, LSU2, DFU4, GroupAlone3], (instregex "CXZT$")>;
1055 def : InstRW<[WLat1, FXU, LSU, DFU2, GroupAlone], (instregex "CZDT$")>;
1056 def : InstRW<[WLat1, FXU, LSU, DFU2, GroupAlone], (instregex "CZXT$")>;
1058 // Perform floating-point operation
1059 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "PFPO$")>;
1061 //===----------------------------------------------------------------------===//
1062 // DFP: Unary arithmetic
1063 //===----------------------------------------------------------------------===//
1066 def : InstRW<[WLat8, DFU, NormalGr], (instregex "FIDTR$")>;
1067 def : InstRW<[WLat10, DFU4, GroupAlone], (instregex "FIXTR$")>;
1069 // Extract biased exponent
1070 def : InstRW<[WLat7, FXU, DFU, GroupAlone], (instregex "EEDTR$")>;
1071 def : InstRW<[WLat8, FXU, DFU2, GroupAlone], (instregex "EEXTR$")>;
1073 // Extract significance
1074 def : InstRW<[WLat7, FXU, DFU, GroupAlone], (instregex "ESDTR$")>;
1075 def : InstRW<[WLat8, FXU, DFU2, GroupAlone], (instregex "ESXTR$")>;
1077 //===----------------------------------------------------------------------===//
1078 // DFP: Binary arithmetic
1079 //===----------------------------------------------------------------------===//
1082 def : InstRW<[WLat9, WLat9, DFU, NormalGr], (instregex "ADTR(A)?$")>;
1083 def : InstRW<[WLat30, WLat30, DFU4, GroupAlone], (instregex "AXTR(A)?$")>;
1086 def : InstRW<[WLat9, WLat9, DFU, NormalGr], (instregex "SDTR(A)?$")>;
1087 def : InstRW<[WLat30, WLat30, DFU4, GroupAlone], (instregex "SXTR(A)?$")>;
1090 def : InstRW<[WLat30, DFU, NormalGr], (instregex "MDTR(A)?$")>;
1091 def : InstRW<[WLat30, DFU4, GroupAlone], (instregex "MXTR(A)?$")>;
1094 def : InstRW<[WLat30, DFU, NormalGr], (instregex "DDTR(A)?$")>;
1095 def : InstRW<[WLat30, DFU4, GroupAlone], (instregex "DXTR(A)?$")>;
1098 def : InstRW<[WLat8, WLat8, DFU, NormalGr], (instregex "QADTR$")>;
1099 def : InstRW<[WLat10, WLat10, DFU4, GroupAlone], (instregex "QAXTR$")>;
1102 def : InstRW<[WLat11, WLat11, FXU, DFU, GroupAlone], (instregex "RRDTR$")>;
1103 def : InstRW<[WLat30, WLat30, FXU, DFU4, GroupAlone2], (instregex "RRXTR$")>;
1105 // Shift significand left/right
1106 def : InstRW<[WLat7LSU, LSU, DFU, GroupAlone], (instregex "S(L|R)DT$")>;
1107 def : InstRW<[WLat11LSU, LSU, DFU4, GroupAlone], (instregex "S(L|R)XT$")>;
1109 // Insert biased exponent
1110 def : InstRW<[WLat5, FXU, DFU, GroupAlone], (instregex "IEDTR$")>;
1111 def : InstRW<[WLat7, FXU, DFU4, GroupAlone2], (instregex "IEXTR$")>;
1113 //===----------------------------------------------------------------------===//
1115 //===----------------------------------------------------------------------===//
1118 def : InstRW<[WLat9, DFU, NormalGr], (instregex "(K|C)DTR$")>;
1119 def : InstRW<[WLat10, DFU2, NormalGr], (instregex "(K|C)XTR$")>;
1121 // Compare biased exponent
1122 def : InstRW<[WLat4, DFU, NormalGr], (instregex "CEDTR$")>;
1123 def : InstRW<[WLat5, DFU2, NormalGr], (instregex "CEXTR$")>;
1125 // Test Data Class/Group
1126 def : InstRW<[WLat9, LSU, DFU, NormalGr], (instregex "TD(C|G)DT$")>;
1127 def : InstRW<[WLat10, LSU, DFU, NormalGr], (instregex "TD(C|G)ET$")>;
1128 def : InstRW<[WLat10, LSU, DFU2, NormalGr], (instregex "TD(C|G)XT$")>;
1131 // -------------------------------- System ---------------------------------- //
1133 //===----------------------------------------------------------------------===//
1134 // System: Program-Status Word Instructions
1135 //===----------------------------------------------------------------------===//
1137 def : InstRW<[WLat30, WLat30, MCD], (instregex "EPSW$")>;
1138 def : InstRW<[WLat30, MCD], (instregex "LPSW(E)?$")>;
1139 def : InstRW<[WLat3, FXU, GroupAlone], (instregex "IPK$")>;
1140 def : InstRW<[WLat1, LSU, EndGroup], (instregex "SPKA$")>;
1141 def : InstRW<[WLat1, LSU, EndGroup], (instregex "SSM$")>;
1142 def : InstRW<[WLat1, FXU, LSU, GroupAlone], (instregex "ST(N|O)SM$")>;
1143 def : InstRW<[WLat3, FXU, NormalGr], (instregex "IAC$")>;
1144 def : InstRW<[WLat1, LSU, EndGroup], (instregex "SAC(F)?$")>;
1146 //===----------------------------------------------------------------------===//
1147 // System: Control Register Instructions
1148 //===----------------------------------------------------------------------===//
1150 def : InstRW<[WLat10, WLat10, FXU, LSU, NormalGr], (instregex "LCTL(G)?$")>;
1151 def : InstRW<[WLat1, FXU5, LSU5, GroupAlone], (instregex "STCT(L|G)$")>;
1152 def : InstRW<[LSULatency, LSU, NormalGr], (instregex "E(P|S)A(I)?R$")>;
1153 def : InstRW<[WLat30, MCD], (instregex "SSA(I)?R$")>;
1154 def : InstRW<[WLat30, MCD], (instregex "ESEA$")>;
1156 //===----------------------------------------------------------------------===//
1157 // System: Prefix-Register Instructions
1158 //===----------------------------------------------------------------------===//
1160 def : InstRW<[WLat30, MCD], (instregex "S(T)?PX$")>;
1162 //===----------------------------------------------------------------------===//
1163 // System: Storage-Key and Real Memory Instructions
1164 //===----------------------------------------------------------------------===//
1166 def : InstRW<[WLat30, MCD], (instregex "ISKE$")>;
1167 def : InstRW<[WLat30, MCD], (instregex "IVSK$")>;
1168 def : InstRW<[WLat30, MCD], (instregex "SSKE(Opt)?$")>;
1169 def : InstRW<[WLat30, MCD], (instregex "RRB(E|M)$")>;
1170 def : InstRW<[WLat30, MCD], (instregex "PFMF$")>;
1171 def : InstRW<[WLat30, WLat30, MCD], (instregex "TB$")>;
1172 def : InstRW<[WLat30, MCD], (instregex "PGIN$")>;
1173 def : InstRW<[WLat30, MCD], (instregex "PGOUT$")>;
1175 //===----------------------------------------------------------------------===//
1176 // System: Dynamic-Address-Translation Instructions
1177 //===----------------------------------------------------------------------===//
1179 def : InstRW<[WLat30, MCD], (instregex "IPTE(Opt)?(Opt)?$")>;
1180 def : InstRW<[WLat30, MCD], (instregex "IDTE(Opt)?$")>;
1181 def : InstRW<[WLat30, MCD], (instregex "CRDTE(Opt)?$")>;
1182 def : InstRW<[WLat30, MCD], (instregex "PTLB$")>;
1183 def : InstRW<[WLat30, WLat30, MCD], (instregex "CSP(G)?$")>;
1184 def : InstRW<[WLat30, WLat30, WLat30, MCD], (instregex "LPTEA$")>;
1185 def : InstRW<[WLat30, WLat30, MCD], (instregex "LRA(Y|G)?$")>;
1186 def : InstRW<[WLat30, MCD], (instregex "STRAG$")>;
1187 def : InstRW<[WLat30, MCD], (instregex "LURA(G)?$")>;
1188 def : InstRW<[WLat30, MCD], (instregex "STUR(A|G)$")>;
1189 def : InstRW<[WLat30, MCD], (instregex "TPROT$")>;
1191 //===----------------------------------------------------------------------===//
1192 // System: Memory-move Instructions
1193 //===----------------------------------------------------------------------===//
1195 def : InstRW<[WLat30, MCD], (instregex "MVC(K|P|S)$")>;
1196 def : InstRW<[WLat30, MCD], (instregex "MVC(S|D)K$")>;
1197 def : InstRW<[WLat30, MCD], (instregex "MVCOS$")>;
1198 def : InstRW<[WLat30, MCD], (instregex "MVPG$")>;
1200 //===----------------------------------------------------------------------===//
1201 // System: Address-Space Instructions
1202 //===----------------------------------------------------------------------===//
1204 def : InstRW<[WLat30, MCD], (instregex "LASP$")>;
1205 def : InstRW<[WLat1, LSU, GroupAlone], (instregex "PALB$")>;
1206 def : InstRW<[WLat30, MCD], (instregex "PC$")>;
1207 def : InstRW<[WLat30, MCD], (instregex "PR$")>;
1208 def : InstRW<[WLat30, MCD], (instregex "PT(I)?$")>;
1209 def : InstRW<[WLat30, MCD], (instregex "RP$")>;
1210 def : InstRW<[WLat30, MCD], (instregex "BS(G|A)$")>;
1211 def : InstRW<[WLat30, MCD], (instregex "TAR$")>;
1213 //===----------------------------------------------------------------------===//
1214 // System: Linkage-Stack Instructions
1215 //===----------------------------------------------------------------------===//
1217 def : InstRW<[WLat30, MCD], (instregex "BAKR$")>;
1218 def : InstRW<[WLat30, MCD], (instregex "EREG(G)?$")>;
1219 def : InstRW<[WLat30, WLat30, MCD], (instregex "(E|M)STA$")>;
1221 //===----------------------------------------------------------------------===//
1222 // System: Time-Related Instructions
1223 //===----------------------------------------------------------------------===//
1225 def : InstRW<[WLat30, MCD], (instregex "PTFF$")>;
1226 def : InstRW<[WLat30, MCD], (instregex "SCK$")>;
1227 def : InstRW<[WLat30, MCD], (instregex "SCKPF$")>;
1228 def : InstRW<[WLat30, MCD], (instregex "SCKC$")>;
1229 def : InstRW<[WLat30, MCD], (instregex "SPT$")>;
1230 def : InstRW<[WLat9, FXU, LSU2, GroupAlone], (instregex "STCK(F)?$")>;
1231 def : InstRW<[WLat20, LSU4, FXU2, GroupAlone2], (instregex "STCKE$")>;
1232 def : InstRW<[WLat30, MCD], (instregex "STCKC$")>;
1233 def : InstRW<[WLat30, MCD], (instregex "STPT$")>;
1235 //===----------------------------------------------------------------------===//
1236 // System: CPU-Related Instructions
1237 //===----------------------------------------------------------------------===//
1239 def : InstRW<[WLat30, MCD], (instregex "STAP$")>;
1240 def : InstRW<[WLat30, MCD], (instregex "STIDP$")>;
1241 def : InstRW<[WLat30, WLat30, MCD], (instregex "STSI$")>;
1242 def : InstRW<[WLat30, WLat30, MCD], (instregex "STFL(E)?$")>;
1243 def : InstRW<[WLat30, MCD], (instregex "ECAG$")>;
1244 def : InstRW<[WLat30, WLat30, MCD], (instregex "ECTG$")>;
1245 def : InstRW<[WLat30, MCD], (instregex "PTF$")>;
1246 def : InstRW<[WLat30, MCD], (instregex "PCKMO$")>;
1248 //===----------------------------------------------------------------------===//
1249 // System: Miscellaneous Instructions
1250 //===----------------------------------------------------------------------===//
1252 def : InstRW<[WLat30, MCD], (instregex "SVC$")>;
1253 def : InstRW<[WLat1, FXU, GroupAlone], (instregex "MC$")>;
1254 def : InstRW<[WLat30, MCD], (instregex "DIAG$")>;
1255 def : InstRW<[WLat1, FXU, NormalGr], (instregex "TRAC(E|G)$")>;
1256 def : InstRW<[WLat30, MCD], (instregex "TRAP(2|4)$")>;
1257 def : InstRW<[WLat30, MCD], (instregex "SIG(P|A)$")>;
1258 def : InstRW<[WLat30, MCD], (instregex "SIE$")>;
1260 //===----------------------------------------------------------------------===//
1261 // System: CPU-Measurement Facility Instructions
1262 //===----------------------------------------------------------------------===//
1264 def : InstRW<[WLat1, FXU, NormalGr], (instregex "LPP$")>;
1265 def : InstRW<[WLat30, WLat30, MCD], (instregex "ECPGA$")>;
1266 def : InstRW<[WLat30, WLat30, MCD], (instregex "E(C|P)CTR$")>;
1267 def : InstRW<[WLat30, MCD], (instregex "LCCTL$")>;
1268 def : InstRW<[WLat30, MCD], (instregex "L(P|S)CTL$")>;
1269 def : InstRW<[WLat30, MCD], (instregex "Q(S|CTR)I$")>;
1270 def : InstRW<[WLat30, MCD], (instregex "S(C|P)CTR$")>;
1272 //===----------------------------------------------------------------------===//
1273 // System: I/O Instructions
1274 //===----------------------------------------------------------------------===//
1276 def : InstRW<[WLat30, MCD], (instregex "(C|H|R|X)SCH$")>;
1277 def : InstRW<[WLat30, MCD], (instregex "(M|S|ST|T)SCH$")>;
1278 def : InstRW<[WLat30, MCD], (instregex "RCHP$")>;
1279 def : InstRW<[WLat30, MCD], (instregex "SCHM$")>;
1280 def : InstRW<[WLat30, MCD], (instregex "STC(PS|RW)$")>;
1281 def : InstRW<[WLat30, MCD], (instregex "TPI$")>;
1282 def : InstRW<[WLat30, MCD], (instregex "SAL$")>;