brintos

brintos / llvm-project-archived public Read only

0
0
Text · 8.8 KiB · 476c500 Raw
289 lines · plain
1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py2# RUN: llc -mtriple=amdgcn -mcpu=tahiti -run-pass=instruction-select -verify-machineinstrs -o - %s | FileCheck -check-prefix=GFX6 %s3 4---5 6name:            fadd_s64_vvv7legalized:       true8regBankSelected: true9 10body: |11  bb.0:12    liveins: $vgpr0_vgpr1, $vgpr2_vgpr313    ; GFX6-LABEL: name: fadd_s64_vvv14    ; GFX6: liveins: $vgpr0_vgpr1, $vgpr2_vgpr315    ; GFX6-NEXT: {{  $}}16    ; GFX6-NEXT: [[COPY:%[0-9]+]]:vreg_64 = COPY $vgpr0_vgpr117    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vreg_64 = COPY $vgpr2_vgpr318    ; GFX6-NEXT: %2:vreg_64 = nofpexcept V_ADD_F64_e64 0, [[COPY]], 0, [[COPY1]], 0, 0, implicit $mode, implicit $exec19    ; GFX6-NEXT: S_ENDPGM 0, implicit %220    %0:vgpr(s64) = COPY $vgpr0_vgpr121    %1:vgpr(s64) = COPY $vgpr2_vgpr322    %2:vgpr(s64) = G_FADD %0, %123    S_ENDPGM 0, implicit %224 25...26 27---28 29name:            fadd_s64_vsv30legalized:       true31regBankSelected: true32 33body: |34  bb.0:35    liveins: $vgpr0_vgpr1, $sgpr0_sgpr136    ; GFX6-LABEL: name: fadd_s64_vsv37    ; GFX6: liveins: $vgpr0_vgpr1, $sgpr0_sgpr138    ; GFX6-NEXT: {{  $}}39    ; GFX6-NEXT: [[COPY:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr140    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vreg_64 = COPY $vgpr0_vgpr141    ; GFX6-NEXT: %2:vreg_64 = nofpexcept V_ADD_F64_e64 0, [[COPY]], 0, [[COPY1]], 0, 0, implicit $mode, implicit $exec42    ; GFX6-NEXT: S_ENDPGM 0, implicit %243    %0:sgpr(s64) = COPY $sgpr0_sgpr144    %1:vgpr(s64) = COPY $vgpr0_vgpr145    %2:vgpr(s64) = G_FADD %0, %146    S_ENDPGM 0, implicit %247 48...49 50---51 52name:            fadd_s64_vvs53legalized:       true54regBankSelected: true55 56body: |57  bb.0:58    liveins: $vgpr0_vgpr1, $sgpr0_sgpr159    ; GFX6-LABEL: name: fadd_s64_vvs60    ; GFX6: liveins: $vgpr0_vgpr1, $sgpr0_sgpr161    ; GFX6-NEXT: {{  $}}62    ; GFX6-NEXT: [[COPY:%[0-9]+]]:vreg_64 = COPY $vgpr0_vgpr163    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr164    ; GFX6-NEXT: %2:vreg_64 = nofpexcept V_ADD_F64_e64 0, [[COPY]], 0, [[COPY1]], 0, 0, implicit $mode, implicit $exec65    ; GFX6-NEXT: S_ENDPGM 0, implicit %266    %0:vgpr(s64) = COPY $vgpr0_vgpr167    %1:sgpr(s64) = COPY $sgpr0_sgpr168    %2:vgpr(s64) = G_FADD %0, %169    S_ENDPGM 0, implicit %270 71...72 73---74 75name:            fadd_s64_vvv_fabs_lhs76legalized:       true77regBankSelected: true78 79body: |80  bb.0:81    liveins: $vgpr0_vgpr1, $vgpr2_vgpr382    ; GFX6-LABEL: name: fadd_s64_vvv_fabs_lhs83    ; GFX6: liveins: $vgpr0_vgpr1, $vgpr2_vgpr384    ; GFX6-NEXT: {{  $}}85    ; GFX6-NEXT: [[COPY:%[0-9]+]]:vreg_64 = COPY $vgpr0_vgpr186    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vreg_64 = COPY $vgpr2_vgpr387    ; GFX6-NEXT: %3:vreg_64 = nofpexcept V_ADD_F64_e64 2, [[COPY]], 0, [[COPY1]], 0, 0, implicit $mode, implicit $exec88    ; GFX6-NEXT: S_ENDPGM 0, implicit %389    %0:vgpr(s64) = COPY $vgpr0_vgpr190    %1:vgpr(s64) = COPY $vgpr2_vgpr391    %2:vgpr(s64) = G_FABS %092    %3:vgpr(s64) = G_FADD %2, %193    S_ENDPGM 0, implicit %394 95...96 97---98 99name:            fadd_s64_vvv_fabs_rhs100legalized:       true101regBankSelected: true102 103body: |104  bb.0:105    liveins: $vgpr0_vgpr1, $vgpr2_vgpr3106    ; GFX6-LABEL: name: fadd_s64_vvv_fabs_rhs107    ; GFX6: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3108    ; GFX6-NEXT: {{  $}}109    ; GFX6-NEXT: [[COPY:%[0-9]+]]:vreg_64 = COPY $vgpr2_vgpr3110    ; GFX6-NEXT: %3:vreg_64 = nofpexcept V_ADD_F64_e64 0, [[COPY]], 2, [[COPY]], 0, 0, implicit $mode, implicit $exec111    ; GFX6-NEXT: S_ENDPGM 0, implicit %3112    %0:vgpr(s64) = COPY $vgpr0_vgpr1113    %1:vgpr(s64) = COPY $vgpr2_vgpr3114    %2:vgpr(s64) = G_FABS %1115    %3:vgpr(s64) = G_FADD %1, %2116    S_ENDPGM 0, implicit %3117 118...119 120---121 122name:            fadd_s64_vvv_fneg_fabs_lhs123legalized:       true124regBankSelected: true125 126body: |127  bb.0:128    liveins: $vgpr0_vgpr1, $vgpr2_vgpr3129    ; GFX6-LABEL: name: fadd_s64_vvv_fneg_fabs_lhs130    ; GFX6: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3131    ; GFX6-NEXT: {{  $}}132    ; GFX6-NEXT: [[COPY:%[0-9]+]]:vreg_64 = COPY $vgpr0_vgpr1133    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vreg_64 = COPY $vgpr2_vgpr3134    ; GFX6-NEXT: %4:vreg_64 = nofpexcept V_ADD_F64_e64 3, [[COPY]], 0, [[COPY1]], 0, 0, implicit $mode, implicit $exec135    ; GFX6-NEXT: S_ENDPGM 0, implicit %4136    %0:vgpr(s64) = COPY $vgpr0_vgpr1137    %1:vgpr(s64) = COPY $vgpr2_vgpr3138    %2:vgpr(s64) = G_FABS %0139    %3:vgpr(s64) = G_FNEG %2140    %4:vgpr(s64) = G_FADD %3, %1141    S_ENDPGM 0, implicit %4142 143...144 145---146 147name:            fadd_s64_vvv_fneg_fabs_rhs148legalized:       true149regBankSelected: true150 151body: |152  bb.0:153    liveins: $vgpr0_vgpr1, $vgpr2_vgpr3154    ; GFX6-LABEL: name: fadd_s64_vvv_fneg_fabs_rhs155    ; GFX6: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3156    ; GFX6-NEXT: {{  $}}157    ; GFX6-NEXT: [[COPY:%[0-9]+]]:vreg_64 = COPY $vgpr0_vgpr1158    ; GFX6-NEXT: %4:vreg_64 = nofpexcept V_ADD_F64_e64 0, [[COPY]], 3, [[COPY]], 0, 0, implicit $mode, implicit $exec159    ; GFX6-NEXT: S_ENDPGM 0, implicit %4160    %0:vgpr(s64) = COPY $vgpr0_vgpr1161    %1:vgpr(s64) = COPY $vgpr0_vgpr1162    %2:vgpr(s64) = G_FABS %1163    %3:vgpr(s64) = G_FNEG %2164    %4:vgpr(s64) = G_FADD %1, %3165    S_ENDPGM 0, implicit %4166 167...168 169# Need to look through reg bank copy to find source modifiers170 171---172 173name:            fadd_s64_fneg_copy_sgpr174legalized:       true175regBankSelected: true176 177body: |178  bb.0:179    liveins: $vgpr0_vgpr1, $sgpr0_sgpr1180    ; GFX6-LABEL: name: fadd_s64_fneg_copy_sgpr181    ; GFX6: liveins: $vgpr0_vgpr1, $sgpr0_sgpr1182    ; GFX6-NEXT: {{  $}}183    ; GFX6-NEXT: [[COPY:%[0-9]+]]:vreg_64 = COPY $vgpr0_vgpr1184    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr1185    ; GFX6-NEXT: [[COPY2:%[0-9]+]]:vreg_64 = COPY [[COPY1]]186    ; GFX6-NEXT: %4:vreg_64 = nofpexcept V_ADD_F64_e64 0, [[COPY]], 1, [[COPY2]], 0, 0, implicit $mode, implicit $exec187    ; GFX6-NEXT: S_ENDPGM 0, implicit %4188    %0:vgpr(s64) = COPY $vgpr0_vgpr1189    %1:sgpr(s64) = COPY $sgpr0_sgpr1190    %2:sgpr(s64) = G_FNEG %1191    %3:vgpr(s64) = COPY %2192    %4:vgpr(s64) = G_FADD %0, %3193    S_ENDPGM 0, implicit %4194 195...196 197# The source modifier lookup searches through SGPR->VGPR copies. Make198# sure we don't violate the constant bus restriction when we look at199# the source.200 201---202 203name:            fadd_s64_copy_fabs_sgpr_copy_fabs_sgpr204legalized:       true205regBankSelected: true206 207body: |208  bb.0:209    liveins: $sgpr0_sgpr1, $sgpr2_sgpr3210    ; GFX6-LABEL: name: fadd_s64_copy_fabs_sgpr_copy_fabs_sgpr211    ; GFX6: liveins: $sgpr0_sgpr1, $sgpr2_sgpr3212    ; GFX6-NEXT: {{  $}}213    ; GFX6-NEXT: [[COPY:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr1214    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:sreg_64 = COPY $sgpr2_sgpr3215    ; GFX6-NEXT: [[COPY2:%[0-9]+]]:vreg_64 = COPY [[COPY]]216    ; GFX6-NEXT: [[COPY3:%[0-9]+]]:vreg_64 = COPY [[COPY1]]217    ; GFX6-NEXT: %6:vreg_64 = nofpexcept V_ADD_F64_e64 2, [[COPY2]], 2, [[COPY3]], 0, 0, implicit $mode, implicit $exec218    ; GFX6-NEXT: S_ENDPGM 0, implicit %6219    %0:sgpr(s64) = COPY $sgpr0_sgpr1220    %1:sgpr(s64) = COPY $sgpr2_sgpr3221    %2:sgpr(s64) = G_FABS %0222    %3:sgpr(s64) = G_FABS %1223    %4:vgpr(s64) = COPY %2224    %5:vgpr(s64) = COPY %3225    %6:vgpr(s64) = G_FADD %4, %5226    S_ENDPGM 0, implicit %6227 228...229 230---231 232name:            fadd_s64_copy_fneg_sgpr_copy_fneg_sgpr233legalized:       true234regBankSelected: true235 236body: |237  bb.0:238    liveins: $sgpr0, $sgpr1239    ; GFX6-LABEL: name: fadd_s64_copy_fneg_sgpr_copy_fneg_sgpr240    ; GFX6: liveins: $sgpr0, $sgpr1241    ; GFX6-NEXT: {{  $}}242    ; GFX6-NEXT: [[COPY:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr1243    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:sreg_64 = COPY $sgpr2_sgpr3244    ; GFX6-NEXT: [[COPY2:%[0-9]+]]:vreg_64 = COPY [[COPY]]245    ; GFX6-NEXT: [[COPY3:%[0-9]+]]:vreg_64 = COPY [[COPY1]]246    ; GFX6-NEXT: %6:vreg_64 = nofpexcept V_ADD_F64_e64 1, [[COPY2]], 1, [[COPY3]], 0, 0, implicit $mode, implicit $exec247    ; GFX6-NEXT: S_ENDPGM 0, implicit %6248    %0:sgpr(s64) = COPY $sgpr0_sgpr1249    %1:sgpr(s64) = COPY $sgpr2_sgpr3250    %2:sgpr(s64) = G_FNEG %0251    %3:sgpr(s64) = G_FNEG %1252    %4:vgpr(s64) = COPY %2253    %5:vgpr(s64) = COPY %3254    %6:vgpr(s64) = G_FADD %4, %5255    S_ENDPGM 0, implicit %6256 257...258 259---260 261name:            fadd_s64_copy_fneg_fabs_sgpr_copy_fneg_fabs_sgpr262legalized:       true263regBankSelected: true264 265body: |266  bb.0:267    liveins: $sgpr0, $sgpr1268    ; GFX6-LABEL: name: fadd_s64_copy_fneg_fabs_sgpr_copy_fneg_fabs_sgpr269    ; GFX6: liveins: $sgpr0, $sgpr1270    ; GFX6-NEXT: {{  $}}271    ; GFX6-NEXT: [[COPY:%[0-9]+]]:sreg_64 = COPY $sgpr0_sgpr1272    ; GFX6-NEXT: [[COPY1:%[0-9]+]]:sreg_64 = COPY $sgpr2_sgpr3273    ; GFX6-NEXT: [[COPY2:%[0-9]+]]:vreg_64 = COPY [[COPY]]274    ; GFX6-NEXT: [[COPY3:%[0-9]+]]:vreg_64 = COPY [[COPY1]]275    ; GFX6-NEXT: %8:vreg_64 = nofpexcept V_ADD_F64_e64 3, [[COPY2]], 3, [[COPY3]], 0, 0, implicit $mode, implicit $exec276    ; GFX6-NEXT: S_ENDPGM 0, implicit %8277    %0:sgpr(s64) = COPY $sgpr0_sgpr1278    %1:sgpr(s64) = COPY $sgpr2_sgpr3279    %2:sgpr(s64) = G_FABS %0280    %3:sgpr(s64) = G_FABS %1281    %4:sgpr(s64) = G_FNEG %2282    %5:sgpr(s64) = G_FNEG %3283    %6:vgpr(s64) = COPY %4284    %7:vgpr(s64) = COPY %5285    %8:vgpr(s64) = G_FADD %6, %7286    S_ENDPGM 0, implicit %8287 288...289