P10InstrResources.td 45 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087
  1. //===--- P10InstrResources.td - P10 Scheduling Definitions -*- tablegen -*-===//
  2. //
  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
  6. //
  7. //===----------------------------------------------------------------------===//
  8. // Automatically generated file, do not edit!
  9. //
  10. // This file defines the itinerary class data for the POWER10 processor.
  11. //
  12. //===----------------------------------------------------------------------===//
  13. // 22 Cycles Binary Floating Point operations, 2 input operands
  14. def : InstRW<[P10W_BF_22C, P10W_DISP_ANY, P10BF_Read, P10BF_Read],
  15. (instrs
  16. FDIVS,
  17. XSDIVSP
  18. )>;
  19. // 2-way crack instructions
  20. // 22 Cycles Binary Floating Point operations, and 3 Cycles ALU operations, 2 input operands
  21. def : InstRW<[P10W_BF_22C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  22. (instrs
  23. FDIVS_rec
  24. )>;
  25. // 24 Cycles Binary Floating Point operations, 2 input operands
  26. def : InstRW<[P10W_BF_24C, P10W_DISP_ANY, P10BF_Read, P10BF_Read],
  27. (instrs
  28. XVDIVSP
  29. )>;
  30. // 26 Cycles Binary Floating Point operations, 1 input operands
  31. def : InstRW<[P10W_BF_26C, P10W_DISP_ANY, P10BF_Read],
  32. (instrs
  33. FSQRTS,
  34. XSSQRTSP
  35. )>;
  36. // 2-way crack instructions
  37. // 26 Cycles Binary Floating Point operations, and 3 Cycles ALU operations, 1 input operands
  38. def : InstRW<[P10W_BF_26C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  39. (instrs
  40. FSQRTS_rec
  41. )>;
  42. // 27 Cycles Binary Floating Point operations, 1 input operands
  43. def : InstRW<[P10W_BF_27C, P10W_DISP_ANY, P10BF_Read],
  44. (instrs
  45. XVSQRTSP
  46. )>;
  47. // 27 Cycles Binary Floating Point operations, 2 input operands
  48. def : InstRW<[P10W_BF_27C, P10W_DISP_ANY, P10BF_Read, P10BF_Read],
  49. (instrs
  50. FDIV,
  51. XSDIVDP,
  52. XVDIVDP
  53. )>;
  54. // 2-way crack instructions
  55. // 27 Cycles Binary Floating Point operations, and 3 Cycles ALU operations, 2 input operands
  56. def : InstRW<[P10W_BF_27C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  57. (instrs
  58. FDIV_rec
  59. )>;
  60. // 36 Cycles Binary Floating Point operations, 1 input operands
  61. def : InstRW<[P10W_BF_36C, P10W_DISP_ANY, P10BF_Read],
  62. (instrs
  63. FSQRT,
  64. XSSQRTDP,
  65. XVSQRTDP
  66. )>;
  67. // 2-way crack instructions
  68. // 36 Cycles Binary Floating Point operations, and 3 Cycles ALU operations, 1 input operands
  69. def : InstRW<[P10W_BF_36C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  70. (instrs
  71. FSQRT_rec
  72. )>;
  73. // 7 Cycles Binary Floating Point operations, 1 input operands
  74. def : InstRW<[P10W_BF_7C, P10W_DISP_ANY, P10BF_Read],
  75. (instrs
  76. FCFID,
  77. FCFIDS,
  78. FCFIDU,
  79. FCFIDUS,
  80. FCTID,
  81. FCTIDU,
  82. FCTIDUZ,
  83. FCTIDZ,
  84. FCTIW,
  85. FCTIWU,
  86. FCTIWUZ,
  87. FCTIWZ,
  88. FRE,
  89. FRES,
  90. FRIMD, FRIMS,
  91. FRIND, FRINS,
  92. FRIPD, FRIPS,
  93. FRIZD, FRIZS,
  94. FRSP,
  95. FRSQRTE,
  96. FRSQRTES,
  97. VCFSX, VCFSX_0,
  98. VCFUX, VCFUX_0,
  99. VCTSXS, VCTSXS_0,
  100. VCTUXS, VCTUXS_0,
  101. VLOGEFP,
  102. VREFP,
  103. VRFIM,
  104. VRFIN,
  105. VRFIP,
  106. VRFIZ,
  107. VRSQRTEFP,
  108. XSCVDPHP,
  109. XSCVDPSP,
  110. XSCVDPSPN,
  111. XSCVDPSXDS, XSCVDPSXDSs,
  112. XSCVDPSXWS, XSCVDPSXWSs,
  113. XSCVDPUXDS, XSCVDPUXDSs,
  114. XSCVDPUXWS, XSCVDPUXWSs,
  115. XSCVSPDP,
  116. XSCVSXDDP,
  117. XSCVSXDSP,
  118. XSCVUXDDP,
  119. XSCVUXDSP,
  120. XSRDPI,
  121. XSRDPIC,
  122. XSRDPIM,
  123. XSRDPIP,
  124. XSRDPIZ,
  125. XSREDP,
  126. XSRESP,
  127. XSRSP,
  128. XSRSQRTEDP,
  129. XSRSQRTESP,
  130. XVCVDPSP,
  131. XVCVDPSXDS,
  132. XVCVDPSXWS,
  133. XVCVDPUXDS,
  134. XVCVDPUXWS,
  135. XVCVSPBF16,
  136. XVCVSPDP,
  137. XVCVSPHP,
  138. XVCVSPSXDS,
  139. XVCVSPSXWS,
  140. XVCVSPUXDS,
  141. XVCVSPUXWS,
  142. XVCVSXDDP,
  143. XVCVSXDSP,
  144. XVCVSXWDP,
  145. XVCVSXWSP,
  146. XVCVUXDDP,
  147. XVCVUXDSP,
  148. XVCVUXWDP,
  149. XVCVUXWSP,
  150. XVRDPI,
  151. XVRDPIC,
  152. XVRDPIM,
  153. XVRDPIP,
  154. XVRDPIZ,
  155. XVREDP,
  156. XVRESP,
  157. XVRSPI,
  158. XVRSPIC,
  159. XVRSPIM,
  160. XVRSPIP,
  161. XVRSPIZ,
  162. XVRSQRTEDP,
  163. XVRSQRTESP
  164. )>;
  165. // 7 Cycles Binary Floating Point operations, 2 input operands
  166. def : InstRW<[P10W_BF_7C, P10W_DISP_ANY, P10BF_Read, P10BF_Read],
  167. (instrs
  168. FADD,
  169. FADDS,
  170. FMUL,
  171. FMULS,
  172. FSUB,
  173. FSUBS,
  174. VADDFP,
  175. VSUBFP,
  176. XSADDDP,
  177. XSADDSP,
  178. XSMULDP,
  179. XSMULSP,
  180. XSSUBDP,
  181. XSSUBSP,
  182. XVADDDP,
  183. XVADDSP,
  184. XVMULDP,
  185. XVMULSP,
  186. XVSUBDP,
  187. XVSUBSP
  188. )>;
  189. // 7 Cycles Binary Floating Point operations, 3 input operands
  190. def : InstRW<[P10W_BF_7C, P10W_DISP_ANY, P10BF_Read, P10BF_Read, P10BF_Read],
  191. (instrs
  192. FMADD,
  193. FMADDS,
  194. FMSUB,
  195. FMSUBS,
  196. FNMADD,
  197. FNMADDS,
  198. FNMSUB,
  199. FNMSUBS,
  200. FSELD, FSELS,
  201. VMADDFP,
  202. VNMSUBFP,
  203. XSMADDADP,
  204. XSMADDASP,
  205. XSMADDMDP,
  206. XSMADDMSP,
  207. XSMSUBADP,
  208. XSMSUBASP,
  209. XSMSUBMDP,
  210. XSMSUBMSP,
  211. XSNMADDADP,
  212. XSNMADDASP,
  213. XSNMADDMDP,
  214. XSNMADDMSP,
  215. XSNMSUBADP,
  216. XSNMSUBASP,
  217. XSNMSUBMDP,
  218. XSNMSUBMSP,
  219. XVMADDADP,
  220. XVMADDASP,
  221. XVMADDMDP,
  222. XVMADDMSP,
  223. XVMSUBADP,
  224. XVMSUBASP,
  225. XVMSUBMDP,
  226. XVMSUBMSP,
  227. XVNMADDADP,
  228. XVNMADDASP,
  229. XVNMADDMDP,
  230. XVNMADDMSP,
  231. XVNMSUBADP,
  232. XVNMSUBASP,
  233. XVNMSUBMDP,
  234. XVNMSUBMSP
  235. )>;
  236. // 2-way crack instructions
  237. // 7 Cycles Binary Floating Point operations, and 7 Cycles Binary Floating Point operations, 1 input operands
  238. def : InstRW<[P10W_BF_7C, P10W_DISP_EVEN, P10W_BF_7C, P10W_DISP_ANY, P10BF_Read],
  239. (instrs
  240. VEXPTEFP
  241. )>;
  242. // 2-way crack instructions
  243. // 7 Cycles Binary Floating Point operations, and 3 Cycles ALU operations, 2 input operands
  244. def : InstRW<[P10W_BF_7C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  245. (instrs
  246. FADD_rec,
  247. FADDS_rec,
  248. FMUL_rec,
  249. FMULS_rec,
  250. FSUB_rec,
  251. FSUBS_rec
  252. )>;
  253. // 2-way crack instructions
  254. // 7 Cycles Binary Floating Point operations, and 3 Cycles ALU operations, 1 input operands
  255. def : InstRW<[P10W_BF_7C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  256. (instrs
  257. FCFID_rec,
  258. FCFIDS_rec,
  259. FCFIDU_rec,
  260. FCFIDUS_rec,
  261. FCTID_rec,
  262. FCTIDU_rec,
  263. FCTIDUZ_rec,
  264. FCTIDZ_rec,
  265. FCTIW_rec,
  266. FCTIWU_rec,
  267. FCTIWUZ_rec,
  268. FCTIWZ_rec,
  269. FRE_rec,
  270. FRES_rec,
  271. FRIMD_rec, FRIMS_rec,
  272. FRIND_rec, FRINS_rec,
  273. FRIPD_rec, FRIPS_rec,
  274. FRIZD_rec, FRIZS_rec,
  275. FRSP_rec,
  276. FRSQRTE_rec,
  277. FRSQRTES_rec
  278. )>;
  279. // 2-way crack instructions
  280. // 7 Cycles Binary Floating Point operations, and 3 Cycles ALU operations, 3 input operands
  281. def : InstRW<[P10W_BF_7C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  282. (instrs
  283. FMADD_rec,
  284. FMADDS_rec,
  285. FMSUB_rec,
  286. FMSUBS_rec,
  287. FNMADD_rec,
  288. FNMADDS_rec,
  289. FNMSUB_rec,
  290. FNMSUBS_rec,
  291. FSELD_rec, FSELS_rec
  292. )>;
  293. // 2 Cycles Branch operations, 0 input operands
  294. def : InstRW<[P10W_BR_2C, P10W_DISP_ANY],
  295. (instrs
  296. BCLR, BCLRn, BDNZLR, BDNZLR8, BDNZLRm, BDNZLRp, BDZLR, BDZLR8, BDZLRm, BDZLRp, gBCLR,
  297. BCLRL, BCLRLn, BDNZLRL, BDNZLRLm, BDNZLRLp, BDZLRL, BDZLRLm, BDZLRLp, gBCLRL,
  298. BL, BL8, BL8_NOP, BL8_NOP_RM, BL8_NOP_TLS, BL8_NOTOC, BL8_NOTOC_RM, BL8_NOTOC_TLS, BL8_RM, BL8_TLS, BL8_TLS_, BLR, BLR8, BLRL, BL_NOP, BL_NOP_RM, BL_RM, BL_TLS
  299. )>;
  300. // 2 Cycles Branch operations, 1 input operands
  301. def : InstRW<[P10W_BR_2C, P10W_DISP_ANY, P10BR_Read],
  302. (instrs
  303. B, BCC, BCCA, BCCCTR, BCCCTR8, BCCCTRL, BCCCTRL8, BCCL, BCCLA, BCCLR, BCCLRL, CTRL_DEP, TAILB, TAILB8,
  304. BA, TAILBA, TAILBA8,
  305. BC, BCTR, BCTR8, BCTRL, BCTRL8, BCTRL8_LDinto_toc, BCTRL8_LDinto_toc_RM, BCTRL8_RM, BCTRL_LWZinto_toc, BCTRL_LWZinto_toc_RM, BCTRL_RM, BCn, BDNZ, BDNZ8, BDNZm, BDNZp, BDZ, BDZ8, BDZm, BDZp, TAILBCTR, TAILBCTR8, gBC, gBCat,
  306. BCL, BCLalways, BCLn, BDNZL, BDNZLm, BDNZLp, BDZL, BDZLm, BDZLp, gBCL, gBCLat,
  307. BLA, BLA8, BLA8_NOP, BLA8_NOP_RM, BLA8_RM, BLA_RM
  308. )>;
  309. // 2 Cycles Branch operations, 3 input operands
  310. def : InstRW<[P10W_BR_2C, P10W_DISP_ANY, P10BR_Read, P10BR_Read, P10BR_Read],
  311. (instrs
  312. BCCTR, BCCTR8, BCCTR8n, BCCTRn, gBCCTR,
  313. BCCTRL, BCCTRL8, BCCTRL8n, BCCTRLn, gBCCTRL
  314. )>;
  315. // 2 Cycles Branch operations, 4 input operands
  316. def : InstRW<[P10W_BR_2C, P10W_DISP_ANY, P10BR_Read, P10BR_Read, P10BR_Read, P10BR_Read],
  317. (instrs
  318. BDNZA, BDNZAm, BDNZAp, BDZA, BDZAm, BDZAp, gBCA, gBCAat,
  319. BDNZLA, BDNZLAm, BDNZLAp, BDZLA, BDZLAm, BDZLAp, gBCLA, gBCLAat
  320. )>;
  321. // 7 Cycles Crypto operations, 1 input operands
  322. def : InstRW<[P10W_CY_7C, P10W_DISP_ANY, P10CY_Read],
  323. (instrs
  324. VSBOX
  325. )>;
  326. // 7 Cycles Crypto operations, 2 input operands
  327. def : InstRW<[P10W_CY_7C, P10W_DISP_ANY, P10CY_Read, P10CY_Read],
  328. (instrs
  329. CFUGED,
  330. CNTLZDM,
  331. CNTTZDM,
  332. PDEPD,
  333. PEXTD,
  334. VCFUGED,
  335. VCIPHER,
  336. VCIPHERLAST,
  337. VCLZDM,
  338. VCTZDM,
  339. VGNB,
  340. VNCIPHER,
  341. VNCIPHERLAST,
  342. VPDEPD,
  343. VPEXTD,
  344. VPMSUMB,
  345. VPMSUMD,
  346. VPMSUMH,
  347. VPMSUMW
  348. )>;
  349. // 13 Cycles Decimal Floating Point operations, 1 input operands
  350. def : InstRW<[P10W_DF_13C, P10W_DISP_ANY, P10DF_Read],
  351. (instrs
  352. XSCVDPQP,
  353. XSCVQPDP,
  354. XSCVQPDPO,
  355. XSCVQPSDZ,
  356. XSCVQPSQZ,
  357. XSCVQPSWZ,
  358. XSCVQPUDZ,
  359. XSCVQPUQZ,
  360. XSCVQPUWZ,
  361. XSCVSDQP,
  362. XSCVSQQP,
  363. XSCVUDQP,
  364. XSCVUQQP
  365. )>;
  366. // 13 Cycles Decimal Floating Point operations, 2 input operands
  367. def : InstRW<[P10W_DF_13C, P10W_DISP_ANY, P10DF_Read, P10DF_Read],
  368. (instrs
  369. XSADDQP,
  370. XSADDQPO,
  371. XSSUBQP,
  372. XSSUBQPO
  373. )>;
  374. // 13 Cycles Decimal Floating Point operations, 3 input operands
  375. def : InstRW<[P10W_DF_13C, P10W_DISP_ANY, P10DF_Read, P10DF_Read, P10DF_Read],
  376. (instrs
  377. BCDSR_rec,
  378. XSRQPI,
  379. XSRQPIX,
  380. XSRQPXP
  381. )>;
  382. // 2-way crack instructions
  383. // 13 Cycles Decimal Floating Point operations, and 3 Cycles Store operations, 2 input operands
  384. def : InstRW<[P10W_DF_13C, P10W_DISP_EVEN, P10W_ST_3C, P10W_DISP_ANY],
  385. (instrs
  386. HASHST, HASHST8,
  387. HASHSTP, HASHSTP8
  388. )>;
  389. // 24 Cycles Decimal Floating Point operations, 1 input operands
  390. def : InstRW<[P10W_DF_24C, P10W_DISP_ANY, P10DF_Read],
  391. (instrs
  392. BCDCTSQ_rec
  393. )>;
  394. // 25 Cycles Decimal Floating Point operations, 2 input operands
  395. def : InstRW<[P10W_DF_25C, P10W_DISP_ANY, P10DF_Read, P10DF_Read],
  396. (instrs
  397. XSMULQP,
  398. XSMULQPO
  399. )>;
  400. // 25 Cycles Decimal Floating Point operations, 3 input operands
  401. def : InstRW<[P10W_DF_25C, P10W_DISP_ANY, P10DF_Read, P10DF_Read, P10DF_Read],
  402. (instrs
  403. XSMADDQP,
  404. XSMADDQPO,
  405. XSMSUBQP,
  406. XSMSUBQPO,
  407. XSNMADDQP,
  408. XSNMADDQPO,
  409. XSNMSUBQP,
  410. XSNMSUBQPO
  411. )>;
  412. // 38 Cycles Decimal Floating Point operations, 2 input operands
  413. def : InstRW<[P10W_DF_38C, P10W_DISP_ANY, P10DF_Read, P10DF_Read],
  414. (instrs
  415. BCDCFSQ_rec
  416. )>;
  417. // 59 Cycles Decimal Floating Point operations, 2 input operands
  418. def : InstRW<[P10W_DF_59C, P10W_DISP_ANY, P10DF_Read, P10DF_Read],
  419. (instrs
  420. XSDIVQP,
  421. XSDIVQPO
  422. )>;
  423. // 61 Cycles Decimal Floating Point operations, 2 input operands
  424. def : InstRW<[P10W_DF_61C, P10W_DISP_ANY, P10DF_Read, P10DF_Read],
  425. (instrs
  426. VDIVESQ,
  427. VDIVEUQ,
  428. VDIVSQ,
  429. VDIVUQ
  430. )>;
  431. // 68 Cycles Decimal Floating Point operations, 2 input operands
  432. def : InstRW<[P10W_DF_68C, P10W_DISP_ANY, P10DF_Read, P10DF_Read],
  433. (instrs
  434. VMODSQ,
  435. VMODUQ
  436. )>;
  437. // 77 Cycles Decimal Floating Point operations, 1 input operands
  438. def : InstRW<[P10W_DF_77C, P10W_DISP_ANY, P10DF_Read],
  439. (instrs
  440. XSSQRTQP,
  441. XSSQRTQPO
  442. )>;
  443. // 20 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  444. def : InstRW<[P10W_DV_20C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  445. (instrs
  446. DIVW,
  447. DIVWO,
  448. DIVWU,
  449. DIVWUO,
  450. MODSW
  451. )>;
  452. // 2-way crack instructions
  453. // 20 Cycles Scalar Fixed-Point Divide operations, and 3 Cycles ALU operations, 2 input operands
  454. def : InstRW<[P10W_DV_20C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  455. (instrs
  456. DIVW_rec,
  457. DIVWO_rec,
  458. DIVWU_rec,
  459. DIVWUO_rec
  460. )>;
  461. // 25 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  462. def : InstRW<[P10W_DV_25C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  463. (instrs
  464. DIVD,
  465. DIVDO,
  466. DIVDU,
  467. DIVDUO,
  468. DIVWE,
  469. DIVWEO,
  470. DIVWEU,
  471. DIVWEUO
  472. )>;
  473. // 2-way crack instructions
  474. // 25 Cycles Scalar Fixed-Point Divide operations, and 3 Cycles ALU operations, 2 input operands
  475. def : InstRW<[P10W_DV_25C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  476. (instrs
  477. DIVD_rec,
  478. DIVDO_rec,
  479. DIVDU_rec,
  480. DIVDUO_rec,
  481. DIVWE_rec,
  482. DIVWEO_rec,
  483. DIVWEU_rec,
  484. DIVWEUO_rec
  485. )>;
  486. // 27 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  487. def : InstRW<[P10W_DV_27C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  488. (instrs
  489. MODSD,
  490. MODUD,
  491. MODUW
  492. )>;
  493. // 41 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  494. def : InstRW<[P10W_DV_41C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  495. (instrs
  496. DIVDE,
  497. DIVDEO,
  498. DIVDEU,
  499. DIVDEUO
  500. )>;
  501. // 2-way crack instructions
  502. // 41 Cycles Scalar Fixed-Point Divide operations, and 3 Cycles ALU operations, 2 input operands
  503. def : InstRW<[P10W_DV_41C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  504. (instrs
  505. DIVDE_rec,
  506. DIVDEO_rec,
  507. DIVDEU_rec,
  508. DIVDEUO_rec
  509. )>;
  510. // 43 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  511. def : InstRW<[P10W_DV_43C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  512. (instrs
  513. VDIVSD,
  514. VDIVUD
  515. )>;
  516. // 47 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  517. def : InstRW<[P10W_DV_47C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  518. (instrs
  519. VMODSD,
  520. VMODUD
  521. )>;
  522. // 54 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  523. def : InstRW<[P10W_DV_54C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  524. (instrs
  525. VDIVSW,
  526. VDIVUW
  527. )>;
  528. // 60 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  529. def : InstRW<[P10W_DV_60C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  530. (instrs
  531. VMODSW,
  532. VMODUW
  533. )>;
  534. // 75 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  535. def : InstRW<[P10W_DV_75C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  536. (instrs
  537. VDIVESD,
  538. VDIVEUD
  539. )>;
  540. // 83 Cycles Scalar Fixed-Point Divide operations, 2 input operands
  541. def : InstRW<[P10W_DV_83C, P10W_DISP_ANY, P10DV_Read, P10DV_Read],
  542. (instrs
  543. VDIVESW,
  544. VDIVEUW
  545. )>;
  546. // 5 Cycles Fixed-Point and BCD operations, 1 input operands
  547. def : InstRW<[P10W_DX_5C, P10W_DISP_ANY, P10DX_Read],
  548. (instrs
  549. BCDCTN_rec,
  550. VMUL10CUQ,
  551. VMUL10UQ,
  552. XSXSIGQP
  553. )>;
  554. // 5 Cycles Fixed-Point and BCD operations, 2 input operands
  555. def : InstRW<[P10W_DX_5C, P10W_DISP_ANY, P10DX_Read, P10DX_Read],
  556. (instrs
  557. BCDCFN_rec,
  558. BCDCFZ_rec,
  559. BCDCPSGN_rec,
  560. BCDCTZ_rec,
  561. BCDSETSGN_rec,
  562. BCDUS_rec,
  563. BCDUTRUNC_rec,
  564. VADDCUQ,
  565. VADDUQM,
  566. VMUL10ECUQ,
  567. VMUL10EUQ,
  568. VSUBCUQ,
  569. VSUBUQM,
  570. XSCMPEQQP,
  571. XSCMPEXPQP,
  572. XSCMPGEQP,
  573. XSCMPGTQP,
  574. XSCMPOQP,
  575. XSCMPUQP,
  576. XSMAXCQP,
  577. XSMINCQP,
  578. XSTSTDCQP,
  579. XXGENPCVBM
  580. )>;
  581. // 5 Cycles Fixed-Point and BCD operations, 3 input operands
  582. def : InstRW<[P10W_DX_5C, P10W_DISP_ANY, P10DX_Read, P10DX_Read, P10DX_Read],
  583. (instrs
  584. BCDADD_rec,
  585. BCDS_rec,
  586. BCDSUB_rec,
  587. BCDTRUNC_rec,
  588. VADDECUQ,
  589. VADDEUQM,
  590. VSUBECUQ,
  591. VSUBEUQM
  592. )>;
  593. // 4 Cycles ALU2 operations, 0 input operands
  594. def : InstRW<[P10W_F2_4C, P10W_DISP_ANY],
  595. (instrs
  596. TRAP, TW
  597. )>;
  598. // 4 Cycles ALU2 operations, 1 input operands
  599. def : InstRW<[P10W_F2_4C, P10W_DISP_ANY, P10F2_Read],
  600. (instrs
  601. CNTLZD,
  602. CNTLZD_rec,
  603. CNTLZW, CNTLZW8,
  604. CNTLZW8_rec, CNTLZW_rec,
  605. CNTTZD,
  606. CNTTZD_rec,
  607. CNTTZW, CNTTZW8,
  608. CNTTZW8_rec, CNTTZW_rec,
  609. FTSQRT,
  610. MTVSRBM,
  611. MTVSRBMI,
  612. MTVSRDM,
  613. MTVSRHM,
  614. MTVSRQM,
  615. MTVSRWM,
  616. POPCNTB, POPCNTB8,
  617. POPCNTD,
  618. POPCNTW,
  619. VCLZB,
  620. VCLZD,
  621. VCLZH,
  622. VCLZW,
  623. VCTZB,
  624. VCTZD,
  625. VCTZH,
  626. VCTZW,
  627. VEXPANDBM,
  628. VEXPANDDM,
  629. VEXPANDHM,
  630. VEXPANDQM,
  631. VEXPANDWM,
  632. VEXTRACTBM,
  633. VEXTRACTDM,
  634. VEXTRACTHM,
  635. VEXTRACTQM,
  636. VEXTRACTWM,
  637. VPOPCNTB,
  638. VPOPCNTD,
  639. VPOPCNTH,
  640. VPOPCNTW,
  641. VPRTYBD,
  642. VPRTYBW,
  643. XSCVHPDP,
  644. XSCVSPDPN,
  645. XSTSQRTDP,
  646. XVCVHPSP,
  647. XVTLSBB,
  648. XVTSQRTDP,
  649. XVTSQRTSP
  650. )>;
  651. // 4 Cycles ALU2 operations, 2 input operands
  652. def : InstRW<[P10W_F2_4C, P10W_DISP_ANY, P10F2_Read, P10F2_Read],
  653. (instrs
  654. CMPEQB,
  655. EXTSWSLI_32_64_rec, EXTSWSLI_rec,
  656. FCMPOD, FCMPOS,
  657. FCMPUD, FCMPUS,
  658. FTDIV,
  659. SLD_rec,
  660. SLW8_rec, SLW_rec,
  661. SRD_rec,
  662. SRW8_rec, SRW_rec,
  663. VABSDUB,
  664. VABSDUH,
  665. VABSDUW,
  666. VADDCUW,
  667. VADDSBS,
  668. VADDSHS,
  669. VADDSWS,
  670. VADDUBS,
  671. VADDUHS,
  672. VADDUWS,
  673. VAVGSB,
  674. VAVGSH,
  675. VAVGSW,
  676. VAVGUB,
  677. VAVGUH,
  678. VAVGUW,
  679. VCMPBFP,
  680. VCMPBFP_rec,
  681. VCMPEQFP,
  682. VCMPEQFP_rec,
  683. VCMPEQUB_rec,
  684. VCMPEQUD_rec,
  685. VCMPEQUH_rec,
  686. VCMPEQUQ,
  687. VCMPEQUQ_rec,
  688. VCMPEQUW_rec,
  689. VCMPGEFP,
  690. VCMPGEFP_rec,
  691. VCMPGTFP,
  692. VCMPGTFP_rec,
  693. VCMPGTSB_rec,
  694. VCMPGTSD_rec,
  695. VCMPGTSH_rec,
  696. VCMPGTSQ,
  697. VCMPGTSQ_rec,
  698. VCMPGTSW_rec,
  699. VCMPGTUB_rec,
  700. VCMPGTUD_rec,
  701. VCMPGTUH_rec,
  702. VCMPGTUQ,
  703. VCMPGTUQ_rec,
  704. VCMPGTUW_rec,
  705. VCMPNEB_rec,
  706. VCMPNEH_rec,
  707. VCMPNEW_rec,
  708. VCMPNEZB_rec,
  709. VCMPNEZH_rec,
  710. VCMPNEZW_rec,
  711. VCMPSQ,
  712. VCMPUQ,
  713. VCNTMBB,
  714. VCNTMBD,
  715. VCNTMBH,
  716. VCNTMBW,
  717. VMAXFP,
  718. VMINFP,
  719. VSUBCUW,
  720. VSUBSBS,
  721. VSUBSHS,
  722. VSUBSWS,
  723. VSUBUBS,
  724. VSUBUHS,
  725. VSUBUWS,
  726. XSCMPEQDP,
  727. XSCMPEXPDP,
  728. XSCMPGEDP,
  729. XSCMPGTDP,
  730. XSCMPODP,
  731. XSCMPUDP,
  732. XSMAXCDP,
  733. XSMAXDP,
  734. XSMAXJDP,
  735. XSMINCDP,
  736. XSMINDP,
  737. XSMINJDP,
  738. XSTDIVDP,
  739. XSTSTDCDP,
  740. XSTSTDCSP,
  741. XVCMPEQDP,
  742. XVCMPEQDP_rec,
  743. XVCMPEQSP,
  744. XVCMPEQSP_rec,
  745. XVCMPGEDP,
  746. XVCMPGEDP_rec,
  747. XVCMPGESP,
  748. XVCMPGESP_rec,
  749. XVCMPGTDP,
  750. XVCMPGTDP_rec,
  751. XVCMPGTSP,
  752. XVCMPGTSP_rec,
  753. XVMAXDP,
  754. XVMAXSP,
  755. XVMINDP,
  756. XVMINSP,
  757. XVTDIVDP,
  758. XVTDIVSP,
  759. XVTSTDCDP,
  760. XVTSTDCSP
  761. )>;
  762. // 4 Cycles ALU2 operations, 3 input operands
  763. def : InstRW<[P10W_F2_4C, P10W_DISP_ANY, P10F2_Read, P10F2_Read, P10F2_Read],
  764. (instrs
  765. CMPRB, CMPRB8,
  766. RLDCL_rec,
  767. RLDCR_rec,
  768. RLDIC_rec,
  769. RLDICL_32_rec, RLDICL_rec,
  770. RLDICR_rec,
  771. TD,
  772. TDI,
  773. TWI,
  774. VSHASIGMAD,
  775. VSHASIGMAW
  776. )>;
  777. // 4 Cycles ALU2 operations, 4 input operands
  778. def : InstRW<[P10W_F2_4C, P10W_DISP_ANY, P10F2_Read, P10F2_Read, P10F2_Read, P10F2_Read],
  779. (instrs
  780. RLDIMI_rec,
  781. RLWINM8_rec, RLWINM_rec,
  782. RLWNM8_rec, RLWNM_rec
  783. )>;
  784. // 4 Cycles ALU2 operations, 5 input operands
  785. def : InstRW<[P10W_F2_4C, P10W_DISP_ANY, P10F2_Read, P10F2_Read, P10F2_Read, P10F2_Read, P10F2_Read],
  786. (instrs
  787. RLWIMI8_rec, RLWIMI_rec
  788. )>;
  789. // Single crack instructions
  790. // 4 Cycles ALU2 operations, 2 input operands
  791. def : InstRW<[P10W_F2_4C, P10W_DISP_EVEN, P10W_DISP_ANY, P10F2_Read, P10F2_Read],
  792. (instrs
  793. SRAD_rec,
  794. SRADI_rec,
  795. SRAW_rec,
  796. SRAWI_rec
  797. )>;
  798. // Single crack instructions
  799. // 4 Cycles ALU2 operations, 3 input operands
  800. def : InstRW<[P10W_F2_4C, P10W_DISP_EVEN, P10W_DISP_ANY, P10F2_Read, P10F2_Read, P10F2_Read],
  801. (instrs
  802. TABORTDC,
  803. TABORTDCI,
  804. TABORTWC,
  805. TABORTWCI
  806. )>;
  807. // 2-way crack instructions
  808. // 4 Cycles ALU2 operations, and 4 Cycles Permute operations, 2 input operands
  809. def : InstRW<[P10W_F2_4C, P10W_DISP_EVEN, P10W_PM_4C, P10W_DISP_ANY],
  810. (instrs
  811. VRLQ,
  812. VRLQNM,
  813. VSLQ,
  814. VSRAQ,
  815. VSRQ
  816. )>;
  817. // 2-way crack instructions
  818. // 4 Cycles ALU2 operations, and 4 Cycles Permute operations, 3 input operands
  819. def : InstRW<[P10W_F2_4C, P10W_DISP_EVEN, P10W_PM_4C, P10W_DISP_ANY],
  820. (instrs
  821. VRLQMI
  822. )>;
  823. // 2-way crack instructions
  824. // 4 Cycles ALU2 operations, and 4 Cycles ALU2 operations, 0 input operands
  825. def : InstRW<[P10W_F2_4C, P10W_DISP_PAIR, P10W_F2_4C],
  826. (instrs
  827. MFCR, MFCR8
  828. )>;
  829. // 2 Cycles ALU operations, 1 input operands
  830. def : InstRW<[P10W_FX_2C, P10W_DISP_ANY, P10FX_Read],
  831. (instrs
  832. MTCTR, MTCTR8, MTCTR8loop, MTCTRloop,
  833. MTLR, MTLR8
  834. )>;
  835. // 3 Cycles ALU operations, 0 input operands
  836. def : InstRW<[P10W_FX_3C, P10W_DISP_ANY],
  837. (instrs
  838. CR6SET, CREQV, CRSET,
  839. DSS, DSSALL,
  840. MCRXRX,
  841. MFCTR, MFCTR8,
  842. MFLR, MFLR8,
  843. NOP, NOP_GT_PWR6, NOP_GT_PWR7, ORI, ORI8,
  844. VXOR, V_SET0, V_SET0B, V_SET0H,
  845. XXLEQV, XXLEQVOnes,
  846. XXLXOR, XXLXORdpz, XXLXORspz, XXLXORz
  847. )>;
  848. // 3 Cycles ALU operations, 1 input operands
  849. def : InstRW<[P10W_FX_3C, P10W_DISP_ANY, P10FX_Read],
  850. (instrs
  851. ADDI, ADDI8, ADDIdtprelL32, ADDItlsldLADDR32, ADDItocL, LI, LI8,
  852. ADDIS, ADDIS8, ADDISdtprelHA32, ADDIStocHA, ADDIStocHA8, LIS, LIS8,
  853. ADDME, ADDME8,
  854. ADDME8O, ADDMEO,
  855. ADDZE, ADDZE8,
  856. ADDZE8O, ADDZEO,
  857. EXTSB, EXTSB8, EXTSB8_32_64,
  858. EXTSB8_rec, EXTSB_rec,
  859. EXTSH, EXTSH8, EXTSH8_32_64,
  860. EXTSH8_rec, EXTSH_rec,
  861. EXTSW, EXTSW_32, EXTSW_32_64,
  862. EXTSW_32_64_rec, EXTSW_rec,
  863. FABSD, FABSS,
  864. FMR,
  865. FNABSD, FNABSS,
  866. FNEGD, FNEGS,
  867. MCRF,
  868. MFOCRF, MFOCRF8,
  869. MFVRD, MFVSRD,
  870. MFVRWZ, MFVSRWZ,
  871. MTOCRF, MTOCRF8,
  872. MTVRD, MTVSRD,
  873. MTVRWA, MTVSRWA,
  874. MTVRWZ, MTVSRWZ,
  875. NEG, NEG8,
  876. NEG8_rec, NEG_rec,
  877. NEG8O, NEGO,
  878. SETB, SETB8,
  879. SETBC, SETBC8,
  880. SETBCR, SETBCR8,
  881. SETNBC, SETNBC8,
  882. SETNBCR, SETNBCR8,
  883. SUBFME, SUBFME8,
  884. SUBFME8O, SUBFMEO,
  885. SUBFZE, SUBFZE8,
  886. SUBFZE8O, SUBFZEO,
  887. VEXTSB2D, VEXTSB2Ds,
  888. VEXTSB2W, VEXTSB2Ws,
  889. VEXTSD2Q,
  890. VEXTSH2D, VEXTSH2Ds,
  891. VEXTSH2W, VEXTSH2Ws,
  892. VEXTSW2D, VEXTSW2Ds,
  893. VNEGD,
  894. VNEGW,
  895. WAIT,
  896. XSABSDP,
  897. XSABSQP,
  898. XSNABSDP, XSNABSDPs,
  899. XSNABSQP,
  900. XSNEGDP,
  901. XSNEGQP,
  902. XSXEXPDP,
  903. XSXEXPQP,
  904. XSXSIGDP,
  905. XVABSDP,
  906. XVABSSP,
  907. XVNABSDP,
  908. XVNABSSP,
  909. XVNEGDP,
  910. XVNEGSP,
  911. XVXEXPDP,
  912. XVXEXPSP,
  913. XVXSIGDP,
  914. XVXSIGSP
  915. )>;
  916. // 3 Cycles ALU operations, 2 input operands
  917. def : InstRW<[P10W_FX_3C, P10W_DISP_ANY, P10FX_Read, P10FX_Read],
  918. (instrs
  919. ADD4, ADD4TLS, ADD8, ADD8TLS, ADD8TLS_,
  920. ADD4_rec, ADD8_rec,
  921. ADDE, ADDE8,
  922. ADDE8O, ADDEO,
  923. ADDIC, ADDIC8,
  924. ADD4O, ADD8O,
  925. AND, AND8,
  926. AND8_rec, AND_rec,
  927. ANDC, ANDC8,
  928. ANDC8_rec, ANDC_rec,
  929. ANDI8_rec, ANDI_rec,
  930. ANDIS8_rec, ANDIS_rec,
  931. CMPD, CMPW,
  932. CMPB, CMPB8,
  933. CMPDI, CMPWI,
  934. CMPLD, CMPLW,
  935. CMPLDI, CMPLWI,
  936. CRAND,
  937. CRANDC,
  938. CRNAND,
  939. CRNOR,
  940. CROR,
  941. CRORC,
  942. CR6UNSET, CRUNSET, CRXOR,
  943. EQV, EQV8,
  944. EQV8_rec, EQV_rec,
  945. EXTSWSLI, EXTSWSLI_32_64,
  946. FCPSGND, FCPSGNS,
  947. NAND, NAND8,
  948. NAND8_rec, NAND_rec,
  949. NOR, NOR8,
  950. NOR8_rec, NOR_rec,
  951. COPY, OR, OR8,
  952. OR8_rec, OR_rec,
  953. ORC, ORC8,
  954. ORC8_rec, ORC_rec,
  955. ORIS, ORIS8,
  956. SLD,
  957. SLW, SLW8,
  958. SRAD,
  959. SRADI, SRADI_32,
  960. SRAW,
  961. SRAWI,
  962. SRD,
  963. SRW, SRW8,
  964. SUBF, SUBF8,
  965. SUBF8_rec, SUBF_rec,
  966. SUBFE, SUBFE8,
  967. SUBFE8O, SUBFEO,
  968. SUBFIC, SUBFIC8,
  969. SUBF8O, SUBFO,
  970. VADDUBM,
  971. VADDUDM,
  972. VADDUHM,
  973. VADDUWM,
  974. VAND,
  975. VANDC,
  976. VCMPEQUB,
  977. VCMPEQUD,
  978. VCMPEQUH,
  979. VCMPEQUW,
  980. VCMPGTSB,
  981. VCMPGTSD,
  982. VCMPGTSH,
  983. VCMPGTSW,
  984. VCMPGTUB,
  985. VCMPGTUD,
  986. VCMPGTUH,
  987. VCMPGTUW,
  988. VCMPNEB,
  989. VCMPNEH,
  990. VCMPNEW,
  991. VCMPNEZB,
  992. VCMPNEZH,
  993. VCMPNEZW,
  994. VEQV,
  995. VMAXSB,
  996. VMAXSD,
  997. VMAXSH,
  998. VMAXSW,
  999. VMAXUB,
  1000. VMAXUD,
  1001. VMAXUH,
  1002. VMAXUW,
  1003. VMINSB,
  1004. VMINSD,
  1005. VMINSH,
  1006. VMINSW,
  1007. VMINUB,
  1008. VMINUD,
  1009. VMINUH,
  1010. VMINUW,
  1011. VMRGEW,
  1012. VMRGOW,
  1013. VNAND,
  1014. VNOR,
  1015. VOR,
  1016. VORC,
  1017. VRLB,
  1018. VRLD,
  1019. VRLDNM,
  1020. VRLH,
  1021. VRLW,
  1022. VRLWNM,
  1023. VSLB,
  1024. VSLD,
  1025. VSLH,
  1026. VSLW,
  1027. VSRAB,
  1028. VSRAD,
  1029. VSRAH,
  1030. VSRAW,
  1031. VSRB,
  1032. VSRD,
  1033. VSRH,
  1034. VSRW,
  1035. VSUBUBM,
  1036. VSUBUDM,
  1037. VSUBUHM,
  1038. VSUBUWM,
  1039. XOR, XOR8,
  1040. XOR8_rec, XOR_rec,
  1041. XORI, XORI8,
  1042. XORIS, XORIS8,
  1043. XSCPSGNDP,
  1044. XSCPSGNQP,
  1045. XSIEXPDP,
  1046. XSIEXPQP,
  1047. XVCPSGNDP,
  1048. XVCPSGNSP,
  1049. XVIEXPDP,
  1050. XVIEXPSP,
  1051. XXLAND,
  1052. XXLANDC,
  1053. XXLNAND,
  1054. XXLNOR,
  1055. XXLOR, XXLORf,
  1056. XXLORC
  1057. )>;
  1058. // 3 Cycles ALU operations, 3 input operands
  1059. def : InstRW<[P10W_FX_3C, P10W_DISP_ANY, P10FX_Read, P10FX_Read, P10FX_Read],
  1060. (instrs
  1061. ADDEX, ADDEX8,
  1062. DST, DST64, DSTT, DSTT64,
  1063. DSTST, DSTST64, DSTSTT, DSTSTT64,
  1064. ISEL, ISEL8,
  1065. RLDCL,
  1066. RLDCR,
  1067. RLDIC,
  1068. RLDICL, RLDICL_32, RLDICL_32_64,
  1069. RLDICR, RLDICR_32,
  1070. VRLDMI,
  1071. VRLWMI,
  1072. VSEL,
  1073. XXSEL
  1074. )>;
  1075. // 3 Cycles ALU operations, 4 input operands
  1076. def : InstRW<[P10W_FX_3C, P10W_DISP_ANY, P10FX_Read, P10FX_Read, P10FX_Read, P10FX_Read],
  1077. (instrs
  1078. RLDIMI,
  1079. RLWINM, RLWINM8,
  1080. RLWNM, RLWNM8
  1081. )>;
  1082. // 3 Cycles ALU operations, 5 input operands
  1083. def : InstRW<[P10W_FX_3C, P10W_DISP_ANY, P10FX_Read, P10FX_Read, P10FX_Read, P10FX_Read, P10FX_Read],
  1084. (instrs
  1085. RLWIMI, RLWIMI8
  1086. )>;
  1087. // Single crack instructions
  1088. // 3 Cycles ALU operations, 0 input operands
  1089. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_DISP_ANY],
  1090. (instrs
  1091. MFFS,
  1092. MFFS_rec,
  1093. MFFSL,
  1094. MFVSCR,
  1095. TRECHKPT
  1096. )>;
  1097. // Single crack instructions
  1098. // 3 Cycles ALU operations, 1 input operands
  1099. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_DISP_ANY, P10FX_Read],
  1100. (instrs
  1101. ADDME8_rec, ADDME_rec,
  1102. ADDME8O_rec, ADDMEO_rec,
  1103. ADDZE8_rec, ADDZE_rec,
  1104. ADDZE8O_rec, ADDZEO_rec,
  1105. MCRFS,
  1106. MFFSCDRN,
  1107. MFFSCDRNI,
  1108. MFFSCRN,
  1109. MFFSCRNI,
  1110. MTFSB0,
  1111. MTVSCR,
  1112. NEG8O_rec, NEGO_rec,
  1113. SUBFME8_rec, SUBFME_rec,
  1114. SUBFME8O_rec, SUBFMEO_rec,
  1115. SUBFZE8_rec, SUBFZE_rec,
  1116. SUBFZE8O_rec, SUBFZEO_rec,
  1117. TABORT,
  1118. TBEGIN,
  1119. TRECLAIM,
  1120. TSR
  1121. )>;
  1122. // Single crack instructions
  1123. // 3 Cycles ALU operations, 2 input operands
  1124. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_DISP_ANY, P10FX_Read, P10FX_Read],
  1125. (instrs
  1126. ADDE8_rec, ADDE_rec,
  1127. ADDE8O_rec, ADDEO_rec,
  1128. ADDIC_rec,
  1129. ADD4O_rec, ADD8O_rec,
  1130. SUBFE8_rec, SUBFE_rec,
  1131. SUBFE8O_rec, SUBFEO_rec,
  1132. SUBF8O_rec, SUBFO_rec
  1133. )>;
  1134. // 2-way crack instructions
  1135. // 3 Cycles ALU operations, and 3 Cycles ALU operations, 0 input operands
  1136. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  1137. (instrs
  1138. HRFID,
  1139. MFFSCE,
  1140. RFID,
  1141. STOP
  1142. )>;
  1143. // 2-way crack instructions
  1144. // 3 Cycles ALU operations, and 3 Cycles ALU operations, 1 input operands
  1145. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY, P10FX_Read],
  1146. (instrs
  1147. FABSD_rec, FABSS_rec,
  1148. FMR_rec,
  1149. FNABSD_rec, FNABSS_rec,
  1150. FNEGD_rec, FNEGS_rec,
  1151. MTFSB1,
  1152. RFEBB,
  1153. SC
  1154. )>;
  1155. // 2-way crack instructions
  1156. // 3 Cycles ALU operations, and 3 Cycles ALU operations, 2 input operands
  1157. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY, P10FX_Read, P10FX_Read],
  1158. (instrs
  1159. ADDC, ADDC8,
  1160. ADDC8_rec, ADDC_rec,
  1161. ADDC8O, ADDCO,
  1162. FCPSGND_rec, FCPSGNS_rec,
  1163. MTFSF, MTFSFb,
  1164. MTFSFI, MTFSFIb,
  1165. SUBFC, SUBFC8,
  1166. SUBFC8_rec, SUBFC_rec,
  1167. SUBFC8O, SUBFCO
  1168. )>;
  1169. // 2-way crack instructions
  1170. // 3 Cycles ALU operations, and 3 Cycles ALU operations, 3 input operands
  1171. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY, P10FX_Read, P10FX_Read, P10FX_Read],
  1172. (instrs
  1173. MTFSFI_rec
  1174. )>;
  1175. // 2-way crack instructions
  1176. // 3 Cycles ALU operations, and 3 Cycles ALU operations, 4 input operands
  1177. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY, P10FX_Read, P10FX_Read, P10FX_Read, P10FX_Read],
  1178. (instrs
  1179. MTFSF_rec
  1180. )>;
  1181. // 4-way crack instructions
  1182. // 3 Cycles ALU operations, 3 Cycles ALU operations, 3 Cycles ALU operations, and 3 Cycles ALU operations, 2 input operands
  1183. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY, P10W_FX_3C, P10W_DISP_ANY, P10W_FX_3C, P10W_DISP_ANY, P10FX_Read, P10FX_Read],
  1184. (instrs
  1185. ADDC8O_rec, ADDCO_rec,
  1186. SUBFC8O_rec, SUBFCO_rec
  1187. )>;
  1188. // 2-way crack instructions
  1189. // 3 Cycles ALU operations, and 4 Cycles Permute operations, 1 input operands
  1190. def : InstRW<[P10W_FX_3C, P10W_DISP_EVEN, P10W_PM_4C, P10W_DISP_ANY],
  1191. (instrs
  1192. VSTRIBL_rec,
  1193. VSTRIBR_rec,
  1194. VSTRIHL_rec,
  1195. VSTRIHR_rec
  1196. )>;
  1197. // 2-way crack instructions
  1198. // 3 Cycles ALU operations, and 3 Cycles ALU operations, 2 input operands
  1199. def : InstRW<[P10W_FX_3C, P10W_DISP_PAIR, P10W_FX_3C, P10FX_Read, P10FX_Read],
  1200. (instrs
  1201. MTCRF, MTCRF8
  1202. )>;
  1203. // 6 Cycles Load operations, 1 input operands
  1204. def : InstRW<[P10W_LD_6C, P10W_DISP_ANY, P10LD_Read],
  1205. (instrs
  1206. LBZ, LBZ8,
  1207. LD, LDtoc, LDtocBA, LDtocCPT, LDtocJTI, LDtocL, SPILLTOVSR_LD,
  1208. LDBRX,
  1209. DFLOADf32, DFLOADf64, LFD,
  1210. LFDX, XFLOADf32, XFLOADf64,
  1211. LFIWAX, LIWAX,
  1212. LFIWZX, LIWZX,
  1213. LHA, LHA8,
  1214. LHAX, LHAX8,
  1215. LHBRX, LHBRX8,
  1216. LHZ, LHZ8,
  1217. LVEBX,
  1218. LVEHX,
  1219. LVEWX,
  1220. LVX,
  1221. LVXL,
  1222. LWA, LWA_32,
  1223. LWAX, LWAX_32,
  1224. LWBRX, LWBRX8,
  1225. LWZ, LWZ8, LWZtoc, LWZtocL,
  1226. LXSD,
  1227. LXSDX,
  1228. LXSIBZX,
  1229. LXSIHZX,
  1230. LXSIWAX,
  1231. LXSIWZX,
  1232. LXV,
  1233. LXVB16X,
  1234. LXVD2X,
  1235. LXVDSX,
  1236. LXVH8X,
  1237. LXVRBX,
  1238. LXVRDX,
  1239. LXVRHX,
  1240. LXVRWX,
  1241. LXVW4X,
  1242. LXVWSX,
  1243. LXVX
  1244. )>;
  1245. // 6 Cycles Load operations, 2 input operands
  1246. def : InstRW<[P10W_LD_6C, P10W_DISP_ANY, P10LD_Read, P10LD_Read],
  1247. (instrs
  1248. DCBT,
  1249. DCBTST,
  1250. ICBT,
  1251. LBZX, LBZX8, LBZXTLS, LBZXTLS_, LBZXTLS_32,
  1252. LDX, LDXTLS, LDXTLS_, SPILLTOVSR_LDX,
  1253. LHZX, LHZX8, LHZXTLS, LHZXTLS_, LHZXTLS_32,
  1254. LWZX, LWZX8, LWZXTLS, LWZXTLS_, LWZXTLS_32,
  1255. LXVL,
  1256. LXVLL
  1257. )>;
  1258. // 2-way crack instructions
  1259. // 6 Cycles Load operations, and 13 Cycles Decimal Floating Point operations, 2 input operands
  1260. def : InstRW<[P10W_LD_6C, P10W_DISP_EVEN, P10W_DF_13C, P10W_DISP_ANY],
  1261. (instrs
  1262. HASHCHK, HASHCHK8,
  1263. HASHCHKP, HASHCHKP8
  1264. )>;
  1265. // Single crack instructions
  1266. // 6 Cycles Load operations, 0 input operands
  1267. def : InstRW<[P10W_LD_6C, P10W_DISP_EVEN, P10W_DISP_ANY],
  1268. (instrs
  1269. SLBIA
  1270. )>;
  1271. // Single crack instructions
  1272. // 6 Cycles Load operations, 1 input operands
  1273. def : InstRW<[P10W_LD_6C, P10W_DISP_EVEN, P10W_DISP_ANY, P10LD_Read],
  1274. (instrs
  1275. DARN,
  1276. LBARX, LBARXL,
  1277. LDARX, LDARXL,
  1278. LHARX, LHARXL,
  1279. LWARX, LWARXL,
  1280. SLBFEE_rec,
  1281. SLBIE,
  1282. SLBMFEE,
  1283. SLBMFEV
  1284. )>;
  1285. // Single crack instructions
  1286. // 6 Cycles Load operations, 2 input operands
  1287. def : InstRW<[P10W_LD_6C, P10W_DISP_EVEN, P10W_DISP_ANY, P10LD_Read, P10LD_Read],
  1288. (instrs
  1289. LBZCIX,
  1290. LDCIX,
  1291. LHZCIX,
  1292. LWZCIX,
  1293. MTSPR, MTSPR8, MTSR, MTUDSCR, MTVRSAVE, MTVRSAVEv
  1294. )>;
  1295. // Expand instructions
  1296. // 6 Cycles Load operations, 6 Cycles Load operations, 6 Cycles Load operations, and 6 Cycles Load operations, 1 input operands
  1297. def : InstRW<[P10W_LD_6C, P10W_DISP_EVEN, P10W_LD_6C, P10W_DISP_ANY, P10W_LD_6C, P10W_DISP_ANY, P10W_LD_6C, P10W_DISP_ANY, P10LD_Read],
  1298. (instrs
  1299. LMW
  1300. )>;
  1301. // Expand instructions
  1302. // 6 Cycles Load operations, 6 Cycles Load operations, 6 Cycles Load operations, and 6 Cycles Load operations, 2 input operands
  1303. def : InstRW<[P10W_LD_6C, P10W_DISP_EVEN, P10W_LD_6C, P10W_DISP_ANY, P10W_LD_6C, P10W_DISP_ANY, P10W_LD_6C, P10W_DISP_ANY, P10LD_Read, P10LD_Read],
  1304. (instrs
  1305. LSWI
  1306. )>;
  1307. // 2-way crack instructions
  1308. // 6 Cycles Load operations, and 3 Cycles Simple Fixed-point (SFX) operations, 1 input operands
  1309. def : InstRW<[P10W_LD_6C, P10W_DISP_EVEN, P10W_SX_3C, P10W_DISP_ANY],
  1310. (instrs
  1311. LBZU, LBZU8,
  1312. LBZUX, LBZUX8,
  1313. LDU,
  1314. LDUX,
  1315. LFDU,
  1316. LFDUX,
  1317. LHAU, LHAU8,
  1318. LHAUX, LHAUX8,
  1319. LHZU, LHZU8,
  1320. LHZUX, LHZUX8,
  1321. LWAUX,
  1322. LWZU, LWZU8,
  1323. LWZUX, LWZUX8
  1324. )>;
  1325. // 6 Cycles Load operations, 1 input operands
  1326. def : InstRW<[P10W_LD_6C, P10W_DISP_PAIR, P10LD_Read],
  1327. (instrs
  1328. PLBZ, PLBZ8, PLBZ8pc, PLBZpc,
  1329. PLD, PLDpc,
  1330. PLFD, PLFDpc,
  1331. PLFS, PLFSpc,
  1332. PLHA, PLHA8, PLHA8pc, PLHApc,
  1333. PLHZ, PLHZ8, PLHZ8pc, PLHZpc,
  1334. PLWA, PLWA8, PLWA8pc, PLWApc,
  1335. PLWZ, PLWZ8, PLWZ8pc, PLWZpc,
  1336. PLXSD, PLXSDpc,
  1337. PLXSSP, PLXSSPpc,
  1338. PLXV, PLXVpc,
  1339. PLXVP, PLXVPpc
  1340. )>;
  1341. // 2-way crack instructions
  1342. // 6 Cycles Load operations, and 4 Cycles ALU2 operations, 1 input operands
  1343. def : InstRW<[P10W_LD_6C, P10W_DISP_PAIR, P10W_F2_4C],
  1344. (instrs
  1345. LFS,
  1346. LFSX,
  1347. LXSSP,
  1348. LXSSPX
  1349. )>;
  1350. // 4-way crack instructions
  1351. // 6 Cycles Load operations, 4 Cycles ALU2 operations, 3 Cycles Simple Fixed-point (SFX) operations, and 3 Cycles ALU operations, 1 input operands
  1352. def : InstRW<[P10W_LD_6C, P10W_DISP_PAIR, P10W_F2_4C, P10W_SX_3C, P10W_DISP_ANY, P10W_FX_3C, P10W_DISP_ANY],
  1353. (instrs
  1354. LFSU,
  1355. LFSUX
  1356. )>;
  1357. // 2-way crack instructions
  1358. // 6 Cycles Load operations, and 6 Cycles Load operations, 1 input operands
  1359. def : InstRW<[P10W_LD_6C, P10W_DISP_PAIR, P10W_LD_6C, P10W_DISP_PAIR, P10LD_Read],
  1360. (instrs
  1361. TLBIEL
  1362. )>;
  1363. // 2-way crack instructions
  1364. // 6 Cycles Load operations, and 6 Cycles Load operations, 2 input operands
  1365. def : InstRW<[P10W_LD_6C, P10W_DISP_PAIR, P10W_LD_6C, P10W_DISP_PAIR, P10LD_Read, P10LD_Read],
  1366. (instrs
  1367. SLBMTE
  1368. )>;
  1369. // 2-way crack instructions
  1370. // 6 Cycles Load operations, and 3 Cycles Simple Fixed-point (SFX) operations, 1 input operands
  1371. def : InstRW<[P10W_LD_6C, P10W_DISP_PAIR, P10W_SX_3C],
  1372. (instrs
  1373. LXVP,
  1374. LXVPX
  1375. )>;
  1376. // Single crack instructions
  1377. // 13 Cycles Unknown operations, 1 input operands
  1378. def : InstRW<[P10W_MFL_13C, P10W_DISP_EVEN, P10W_DISP_ANY],
  1379. (instrs
  1380. MFSPR, MFSPR8, MFSR, MFTB8, MFUDSCR, MFVRSAVE, MFVRSAVEv
  1381. )>;
  1382. // 10 Cycles SIMD Matrix Multiply Engine operations, 0 input operands
  1383. def : InstRW<[P10W_MM_10C, P10W_DISP_ANY],
  1384. (instrs
  1385. XXSETACCZ
  1386. )>;
  1387. // 10 Cycles SIMD Matrix Multiply Engine operations, 2 input operands
  1388. def : InstRW<[P10W_MM_10C, P10W_DISP_ANY, P10MM_Read, P10MM_Read],
  1389. (instrs
  1390. XVBF16GER2,
  1391. XVF16GER2,
  1392. XVF32GER,
  1393. XVF64GER,
  1394. XVI16GER2,
  1395. XVI16GER2S,
  1396. XVI4GER8,
  1397. XVI8GER4
  1398. )>;
  1399. // 10 Cycles SIMD Matrix Multiply Engine operations, 3 input operands
  1400. def : InstRW<[P10W_MM_10C, P10W_DISP_ANY, P10MM_Read, P10MM_Read, P10MM_Read],
  1401. (instrs
  1402. XVBF16GER2NN,
  1403. XVBF16GER2NP,
  1404. XVBF16GER2PN,
  1405. XVBF16GER2PP,
  1406. XVF16GER2NN,
  1407. XVF16GER2NP,
  1408. XVF16GER2PN,
  1409. XVF16GER2PP,
  1410. XVF32GERNN,
  1411. XVF32GERNP,
  1412. XVF32GERPN,
  1413. XVF32GERPP,
  1414. XVF64GERNN,
  1415. XVF64GERNP,
  1416. XVF64GERPN,
  1417. XVF64GERPP,
  1418. XVI16GER2PP,
  1419. XVI16GER2SPP,
  1420. XVI4GER8PP,
  1421. XVI8GER4PP,
  1422. XVI8GER4SPP
  1423. )>;
  1424. // 10 Cycles SIMD Matrix Multiply Engine operations, 4 input operands
  1425. def : InstRW<[P10W_MM_10C, P10W_DISP_PAIR, P10MM_Read, P10MM_Read, P10MM_Read, P10MM_Read],
  1426. (instrs
  1427. PMXVF32GER,
  1428. PMXVF64GER
  1429. )>;
  1430. // 10 Cycles SIMD Matrix Multiply Engine operations, 5 input operands
  1431. def : InstRW<[P10W_MM_10C, P10W_DISP_PAIR, P10MM_Read, P10MM_Read, P10MM_Read, P10MM_Read, P10MM_Read],
  1432. (instrs
  1433. PMXVBF16GER2,
  1434. PMXVF16GER2,
  1435. PMXVF32GERNN,
  1436. PMXVF32GERNP,
  1437. PMXVF32GERPN,
  1438. PMXVF32GERPP,
  1439. PMXVF64GERNN,
  1440. PMXVF64GERNP,
  1441. PMXVF64GERPN,
  1442. PMXVF64GERPP,
  1443. PMXVI16GER2,
  1444. PMXVI16GER2S,
  1445. PMXVI4GER8,
  1446. PMXVI8GER4
  1447. )>;
  1448. // 10 Cycles SIMD Matrix Multiply Engine operations, 6 input operands
  1449. def : InstRW<[P10W_MM_10C, P10W_DISP_PAIR, P10MM_Read, P10MM_Read, P10MM_Read, P10MM_Read, P10MM_Read, P10MM_Read],
  1450. (instrs
  1451. PMXVBF16GER2NN,
  1452. PMXVBF16GER2NP,
  1453. PMXVBF16GER2PN,
  1454. PMXVBF16GER2PP,
  1455. PMXVF16GER2NN,
  1456. PMXVF16GER2NP,
  1457. PMXVF16GER2PN,
  1458. PMXVF16GER2PP,
  1459. PMXVI16GER2PP,
  1460. PMXVI16GER2SPP,
  1461. PMXVI4GER8PP,
  1462. PMXVI8GER4PP,
  1463. PMXVI8GER4SPP
  1464. )>;
  1465. // 2-way crack instructions
  1466. // 10 Cycles SIMD Matrix Multiply Engine operations, and 3 Cycles ALU operations, 1 input operands
  1467. def : InstRW<[P10W_MM_10C, P10W_DISP_PAIR, P10W_FX_3C],
  1468. (instrs
  1469. XXMTACC
  1470. )>;
  1471. // 4-way crack instructions
  1472. // 10 Cycles SIMD Matrix Multiply Engine operations, 3 Cycles ALU operations, 10 Cycles SIMD Matrix Multiply Engine operations, and 3 Cycles ALU operations, 1 input operands
  1473. def : InstRW<[P10W_MM_10C, P10W_DISP_PAIR, P10W_FX_3C, P10W_MM_10C, P10W_DISP_PAIR, P10W_FX_3C],
  1474. (instrs
  1475. XXMFACC
  1476. )>;
  1477. // 5 Cycles GPR Multiply operations, 2 input operands
  1478. def : InstRW<[P10W_MU_5C, P10W_DISP_ANY, P10MU_Read, P10MU_Read],
  1479. (instrs
  1480. MULHD,
  1481. MULHDU,
  1482. MULHW,
  1483. MULHWU,
  1484. MULLD,
  1485. MULLDO,
  1486. MULLI, MULLI8,
  1487. MULLW,
  1488. MULLWO,
  1489. VMULHSD,
  1490. VMULHUD,
  1491. VMULLD
  1492. )>;
  1493. // 5 Cycles GPR Multiply operations, 3 input operands
  1494. def : InstRW<[P10W_MU_5C, P10W_DISP_ANY, P10MU_Read, P10MU_Read, P10MU_Read],
  1495. (instrs
  1496. MADDHD,
  1497. MADDHDU,
  1498. MADDLD, MADDLD8
  1499. )>;
  1500. // 2-way crack instructions
  1501. // 5 Cycles GPR Multiply operations, and 3 Cycles ALU operations, 2 input operands
  1502. def : InstRW<[P10W_MU_5C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  1503. (instrs
  1504. MULHD_rec,
  1505. MULHDU_rec,
  1506. MULHW_rec,
  1507. MULHWU_rec,
  1508. MULLD_rec,
  1509. MULLDO_rec,
  1510. MULLW_rec,
  1511. MULLWO_rec
  1512. )>;
  1513. // 4 Cycles Permute operations, 0 input operands
  1514. def : InstRW<[P10W_PM_4C, P10W_DISP_ANY],
  1515. (instrs
  1516. VSPLTISW, V_SETALLONES, V_SETALLONESB, V_SETALLONESH
  1517. )>;
  1518. // 4 Cycles Permute operations, 1 input operands
  1519. def : InstRW<[P10W_PM_4C, P10W_DISP_ANY, P10PM_Read],
  1520. (instrs
  1521. BRD,
  1522. BRH, BRH8,
  1523. BRW, BRW8,
  1524. LVSL,
  1525. LVSR,
  1526. LXVKQ,
  1527. MFVSRLD,
  1528. MTVSRWS,
  1529. VCLZLSBB,
  1530. VCTZLSBB,
  1531. VGBBD,
  1532. VPRTYBQ,
  1533. VSPLTISB,
  1534. VSPLTISH,
  1535. VSTRIBL,
  1536. VSTRIBR,
  1537. VSTRIHL,
  1538. VSTRIHR,
  1539. VUPKHPX,
  1540. VUPKHSB,
  1541. VUPKHSH,
  1542. VUPKHSW,
  1543. VUPKLPX,
  1544. VUPKLSB,
  1545. VUPKLSH,
  1546. VUPKLSW,
  1547. XVCVBF16SPN,
  1548. XXBRD,
  1549. XXBRH,
  1550. XXBRQ,
  1551. XXBRW,
  1552. XXSPLTIB
  1553. )>;
  1554. // 4 Cycles Permute operations, 2 input operands
  1555. def : InstRW<[P10W_PM_4C, P10W_DISP_ANY, P10PM_Read, P10PM_Read],
  1556. (instrs
  1557. BPERMD,
  1558. MTVSRDD,
  1559. VBPERMD,
  1560. VBPERMQ,
  1561. VCLRLB,
  1562. VCLRRB,
  1563. VEXTRACTD,
  1564. VEXTRACTUB,
  1565. VEXTRACTUH,
  1566. VEXTRACTUW,
  1567. VEXTUBLX,
  1568. VEXTUBRX,
  1569. VEXTUHLX,
  1570. VEXTUHRX,
  1571. VEXTUWLX,
  1572. VEXTUWRX,
  1573. VINSERTD,
  1574. VINSERTW,
  1575. VMRGHB,
  1576. VMRGHH,
  1577. VMRGHW,
  1578. VMRGLB,
  1579. VMRGLH,
  1580. VMRGLW,
  1581. VPKPX,
  1582. VPKSDSS,
  1583. VPKSDUS,
  1584. VPKSHSS,
  1585. VPKSHUS,
  1586. VPKSWSS,
  1587. VPKSWUS,
  1588. VPKUDUM,
  1589. VPKUDUS,
  1590. VPKUHUM,
  1591. VPKUHUS,
  1592. VPKUWUM,
  1593. VPKUWUS,
  1594. VSL,
  1595. VSLO,
  1596. VSLV,
  1597. VSPLTB, VSPLTBs,
  1598. VSPLTH, VSPLTHs,
  1599. VSPLTW,
  1600. VSR,
  1601. VSRO,
  1602. VSRV,
  1603. XXEXTRACTUW,
  1604. XXGENPCVDM,
  1605. XXGENPCVHM,
  1606. XXGENPCVWM,
  1607. XXMRGHW,
  1608. XXMRGLW,
  1609. XXPERMDI, XXPERMDIs,
  1610. XXSLDWI, XXSLDWIs,
  1611. XXSPLTW, XXSPLTWs
  1612. )>;
  1613. // 4 Cycles Permute operations, 3 input operands
  1614. def : InstRW<[P10W_PM_4C, P10W_DISP_ANY, P10PM_Read, P10PM_Read, P10PM_Read],
  1615. (instrs
  1616. VEXTDDVLX,
  1617. VEXTDDVRX,
  1618. VEXTDUBVLX,
  1619. VEXTDUBVRX,
  1620. VEXTDUHVLX,
  1621. VEXTDUHVRX,
  1622. VEXTDUWVLX,
  1623. VEXTDUWVRX,
  1624. VINSBLX,
  1625. VINSBRX,
  1626. VINSBVLX,
  1627. VINSBVRX,
  1628. VINSD,
  1629. VINSDLX,
  1630. VINSDRX,
  1631. VINSERTB,
  1632. VINSERTH,
  1633. VINSHLX,
  1634. VINSHRX,
  1635. VINSHVLX,
  1636. VINSHVRX,
  1637. VINSW,
  1638. VINSWLX,
  1639. VINSWRX,
  1640. VINSWVLX,
  1641. VINSWVRX,
  1642. VPERM,
  1643. VPERMR,
  1644. VPERMXOR,
  1645. VSLDBI,
  1646. VSLDOI,
  1647. VSRDBI,
  1648. XXINSERTW,
  1649. XXPERM,
  1650. XXPERMR
  1651. )>;
  1652. // 2-way crack instructions
  1653. // 4 Cycles Permute operations, and 7 Cycles VMX Multiply operations, 2 input operands
  1654. def : InstRW<[P10W_PM_4C, P10W_DISP_EVEN, P10W_vMU_7C, P10W_DISP_ANY],
  1655. (instrs
  1656. VSUMSWS
  1657. )>;
  1658. // 4 Cycles Permute operations, 1 input operands
  1659. def : InstRW<[P10W_PM_4C, P10W_DISP_PAIR, P10PM_Read],
  1660. (instrs
  1661. XXSPLTIDP,
  1662. XXSPLTIW
  1663. )>;
  1664. // 4 Cycles Permute operations, 3 input operands
  1665. def : InstRW<[P10W_PM_4C, P10W_DISP_PAIR, P10PM_Read, P10PM_Read, P10PM_Read],
  1666. (instrs
  1667. XXBLENDVB,
  1668. XXBLENDVD,
  1669. XXBLENDVH,
  1670. XXBLENDVW,
  1671. XXSPLTI32DX
  1672. )>;
  1673. // 4 Cycles Permute operations, 4 input operands
  1674. def : InstRW<[P10W_PM_4C, P10W_DISP_PAIR, P10PM_Read, P10PM_Read, P10PM_Read, P10PM_Read],
  1675. (instrs
  1676. XXEVAL,
  1677. XXPERMX
  1678. )>;
  1679. // 3 Cycles Store operations, 1 input operands
  1680. def : InstRW<[P10W_ST_3C, P10W_DISP_ANY, P10ST_Read],
  1681. (instrs
  1682. DCBST,
  1683. DCBZ,
  1684. ICBI
  1685. )>;
  1686. // 3 Cycles Store operations, 2 input operands
  1687. def : InstRW<[P10W_ST_3C, P10W_DISP_ANY, P10ST_Read, P10ST_Read],
  1688. (instrs
  1689. DCBF,
  1690. PSTXVP, PSTXVPpc,
  1691. STB, STB8,
  1692. STBU, STBU8,
  1693. STBUX, STBUX8,
  1694. SPILLTOVSR_ST, STD,
  1695. STDBRX,
  1696. STDU,
  1697. STDUX,
  1698. DFSTOREf32, DFSTOREf64, STFD,
  1699. STFDU,
  1700. STFDUX,
  1701. STFDX,
  1702. STFIWX, STIWX,
  1703. STFS,
  1704. STFSU,
  1705. STFSUX,
  1706. STFSX,
  1707. STH, STH8,
  1708. STHBRX,
  1709. STHU, STHU8,
  1710. STHUX, STHUX8,
  1711. STVEBX,
  1712. STVEHX,
  1713. STVEWX,
  1714. STVX,
  1715. STVXL,
  1716. STW, STW8,
  1717. STWBRX,
  1718. STWU, STWU8,
  1719. STWUX, STWUX8,
  1720. STXSD,
  1721. STXSDX,
  1722. STXSIBX, STXSIBXv,
  1723. STXSIHX, STXSIHXv,
  1724. STXSIWX,
  1725. STXSSP,
  1726. STXSSPX,
  1727. STXV,
  1728. STXVB16X,
  1729. STXVD2X,
  1730. STXVH8X,
  1731. STXVRBX,
  1732. STXVRDX,
  1733. STXVRHX,
  1734. STXVRWX,
  1735. STXVW4X,
  1736. STXVX
  1737. )>;
  1738. // 3 Cycles Store operations, 3 input operands
  1739. def : InstRW<[P10W_ST_3C, P10W_DISP_ANY, P10ST_Read, P10ST_Read, P10ST_Read],
  1740. (instrs
  1741. CP_COPY, CP_COPY8,
  1742. STBX, STBX8, STBXTLS, STBXTLS_, STBXTLS_32,
  1743. SPILLTOVSR_STX, STDX, STDXTLS, STDXTLS_,
  1744. STHX, STHX8, STHXTLS, STHXTLS_, STHXTLS_32,
  1745. STWX, STWX8, STWXTLS, STWXTLS_, STWXTLS_32,
  1746. STXVL,
  1747. STXVLL
  1748. )>;
  1749. // Single crack instructions
  1750. // 3 Cycles Store operations, 0 input operands
  1751. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_DISP_ANY],
  1752. (instrs
  1753. EnforceIEIO,
  1754. MSGSYNC,
  1755. SLBSYNC,
  1756. TCHECK,
  1757. TLBSYNC
  1758. )>;
  1759. // Single crack instructions
  1760. // 3 Cycles Store operations, 1 input operands
  1761. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_DISP_ANY, P10ST_Read],
  1762. (instrs
  1763. TEND
  1764. )>;
  1765. // Single crack instructions
  1766. // 3 Cycles Store operations, 2 input operands
  1767. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_DISP_ANY, P10ST_Read, P10ST_Read],
  1768. (instrs
  1769. SLBIEG,
  1770. STBCX,
  1771. STDCX,
  1772. STHCX,
  1773. STWCX,
  1774. TLBIE
  1775. )>;
  1776. // Single crack instructions
  1777. // 3 Cycles Store operations, 3 input operands
  1778. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_DISP_ANY, P10ST_Read, P10ST_Read, P10ST_Read],
  1779. (instrs
  1780. CP_PASTE8_rec, CP_PASTE_rec,
  1781. STBCIX,
  1782. STDCIX,
  1783. STHCIX,
  1784. STWCIX
  1785. )>;
  1786. // 2-way crack instructions
  1787. // 3 Cycles Store operations, and 3 Cycles ALU operations, 0 input operands
  1788. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  1789. (instrs
  1790. ISYNC
  1791. )>;
  1792. // 2-way crack instructions
  1793. // 3 Cycles Store operations, and 3 Cycles ALU operations, 1 input operands
  1794. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  1795. (instrs
  1796. SYNC
  1797. )>;
  1798. // Expand instructions
  1799. // 3 Cycles Store operations, 3 Cycles ALU operations, 3 Cycles Store operations, 3 Cycles ALU operations, 3 Cycles Store operations, 3 Cycles ALU operations, 6 Cycles Load operations, and 3 Cycles Store operations, 2 input operands
  1800. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY, P10W_FX_3C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY, P10W_FX_3C, P10W_DISP_ANY, P10W_LD_6C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY],
  1801. (instrs
  1802. LDAT,
  1803. LWAT
  1804. )>;
  1805. // 4-way crack instructions
  1806. // 3 Cycles Store operations, 3 Cycles ALU operations, 3 Cycles Store operations, and 3 Cycles Store operations, 3 input operands
  1807. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY],
  1808. (instrs
  1809. STDAT,
  1810. STWAT
  1811. )>;
  1812. // Expand instructions
  1813. // 3 Cycles Store operations, 3 Cycles Store operations, 3 Cycles Store operations, and 3 Cycles Store operations, 2 input operands
  1814. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_ST_3C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY, P10ST_Read, P10ST_Read],
  1815. (instrs
  1816. STMW
  1817. )>;
  1818. // Expand instructions
  1819. // 3 Cycles Store operations, 3 Cycles Store operations, 3 Cycles Store operations, and 3 Cycles Store operations, 3 input operands
  1820. def : InstRW<[P10W_ST_3C, P10W_DISP_EVEN, P10W_ST_3C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY, P10W_ST_3C, P10W_DISP_ANY, P10ST_Read, P10ST_Read, P10ST_Read],
  1821. (instrs
  1822. STSWI
  1823. )>;
  1824. // 3 Cycles Store operations, 2 input operands
  1825. def : InstRW<[P10W_ST_3C, P10W_DISP_PAIR, P10ST_Read, P10ST_Read],
  1826. (instrs
  1827. PSTB, PSTB8, PSTB8pc, PSTBpc,
  1828. PSTD, PSTDpc,
  1829. PSTFD, PSTFDpc,
  1830. PSTFS, PSTFSpc,
  1831. PSTH, PSTH8, PSTH8pc, PSTHpc,
  1832. PSTW, PSTW8, PSTW8pc, PSTWpc,
  1833. PSTXSD, PSTXSDpc,
  1834. PSTXSSP, PSTXSSPpc,
  1835. PSTXV, PSTXVpc
  1836. )>;
  1837. // 2-way crack instructions
  1838. // 3 Cycles Store operations, and 3 Cycles Store operations, 2 input operands
  1839. def : InstRW<[P10W_ST_3C, P10W_DISP_PAIR, P10W_ST_3C, P10ST_Read, P10ST_Read],
  1840. (instrs
  1841. STXVP,
  1842. STXVPX
  1843. )>;
  1844. // FIXME - Miss scheduling information from datasheet
  1845. // Temporary set it as 1 Cycles Simple Fixed-point (SFX) operations, 0 input operands
  1846. def : InstRW<[P10W_SX, P10W_DISP_ANY],
  1847. (instrs
  1848. ATTN,
  1849. CP_ABORT,
  1850. CRNOT,
  1851. DCBA,
  1852. DCBI,
  1853. DCBZL,
  1854. DCCCI,
  1855. ICBLC,
  1856. ICBLQ,
  1857. ICBTLS,
  1858. ICCCI,
  1859. LA, LA8,
  1860. MFDCR,
  1861. MFPMR,
  1862. MFSRIN,
  1863. MSYNC,
  1864. MTDCR,
  1865. MTPMR,
  1866. MTSRIN,
  1867. NAP,
  1868. TLBIA,
  1869. TLBLD,
  1870. TLBLI,
  1871. TLBRE2,
  1872. TLBSX2,
  1873. TLBSX2D,
  1874. TLBWE2
  1875. )>;
  1876. // Single crack instructions
  1877. // 3 Cycles Simple Fixed-point (SFX) operations, 0 input operands
  1878. def : InstRW<[P10W_SX_3C, P10W_DISP_EVEN, P10W_DISP_ANY],
  1879. (instrs
  1880. CLRBHRB,
  1881. MFMSR
  1882. )>;
  1883. // Single crack instructions
  1884. // 3 Cycles Simple Fixed-point (SFX) operations, 1 input operands
  1885. def : InstRW<[P10W_SX_3C, P10W_DISP_EVEN, P10W_DISP_ANY, P10SX_Read],
  1886. (instrs
  1887. MFTB
  1888. )>;
  1889. // Single crack instructions
  1890. // 3 Cycles Simple Fixed-point (SFX) operations, 2 input operands
  1891. def : InstRW<[P10W_SX_3C, P10W_DISP_EVEN, P10W_DISP_ANY, P10SX_Read, P10SX_Read],
  1892. (instrs
  1893. MFBHRBE,
  1894. MTMSR,
  1895. MTMSRD
  1896. )>;
  1897. // 2-way crack instructions
  1898. // 3 Cycles Simple Fixed-point (SFX) operations, and 3 Cycles ALU operations, 1 input operands
  1899. def : InstRW<[P10W_SX_3C, P10W_DISP_EVEN, P10W_FX_3C, P10W_DISP_ANY],
  1900. (instrs
  1901. ADDPCIS
  1902. )>;
  1903. // 3 Cycles Simple Fixed-point (SFX) operations, 1 input operands
  1904. def : InstRW<[P10W_SX_3C, P10W_DISP_PAIR, P10SX_Read],
  1905. (instrs
  1906. PADDI, PADDI8, PADDI8pc, PADDIpc, PLI, PLI8
  1907. )>;
  1908. // 7 Cycles VMX Multiply operations, 2 input operands
  1909. def : InstRW<[P10W_vMU_7C, P10W_DISP_ANY, P10vMU_Read, P10vMU_Read],
  1910. (instrs
  1911. VMULESB,
  1912. VMULESD,
  1913. VMULESH,
  1914. VMULESW,
  1915. VMULEUB,
  1916. VMULEUD,
  1917. VMULEUH,
  1918. VMULEUW,
  1919. VMULHSW,
  1920. VMULHUW,
  1921. VMULOSB,
  1922. VMULOSD,
  1923. VMULOSH,
  1924. VMULOSW,
  1925. VMULOUB,
  1926. VMULOUD,
  1927. VMULOUH,
  1928. VMULOUW,
  1929. VMULUWM,
  1930. VSUM2SWS,
  1931. VSUM4SBS,
  1932. VSUM4SHS,
  1933. VSUM4UBS
  1934. )>;
  1935. // 7 Cycles VMX Multiply operations, 3 input operands
  1936. def : InstRW<[P10W_vMU_7C, P10W_DISP_ANY, P10vMU_Read, P10vMU_Read, P10vMU_Read],
  1937. (instrs
  1938. VMHADDSHS,
  1939. VMHRADDSHS,
  1940. VMLADDUHM,
  1941. VMSUMCUD,
  1942. VMSUMMBM,
  1943. VMSUMSHM,
  1944. VMSUMSHS,
  1945. VMSUMUBM,
  1946. VMSUMUDM,
  1947. VMSUMUHM,
  1948. VMSUMUHS
  1949. )>;