brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.2 KiB · bbba345 Raw
63 lines · plain
1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py2# RUN: llc -mtriple aarch64 -run-pass=aarch64-postlegalizer-combiner -verify-machineinstrs %s -o - | FileCheck %s3 4---5name:            test_combine_sext_trunc_of_sextload6legalized:       true7tracksRegLiveness: true8body: |9  bb.0.entry:10    liveins: $x011    ; CHECK-LABEL: name: test_combine_sext_trunc_of_sextload12    ; CHECK: liveins: $x013    ; CHECK-NEXT: {{  $}}14    ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p0) = COPY $x015    ; CHECK-NEXT: [[SEXTLOAD:%[0-9]+]]:_(s64) = G_SEXTLOAD [[COPY]](p0) :: (load (s16))16    ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:_(s32) = G_TRUNC [[SEXTLOAD]](s64)17    ; CHECK-NEXT: $w0 = COPY [[TRUNC]](s32)18    %0:_(p0) = COPY $x019    %1:_(s64) = G_SEXTLOAD %0:_(p0) :: (load (s16))20    %2:_(s32) = G_TRUNC %1:_(s64)21    %3:_(s32) = G_SEXT_INREG %2:_(s32), 1622    $w0 = COPY %3(s32)23...24---25name:            test_combine_sext_of_sextload26legalized:       true27tracksRegLiveness: true28body: |29  bb.0.entry:30    liveins: $x031    ; CHECK-LABEL: name: test_combine_sext_of_sextload32    ; CHECK: liveins: $x033    ; CHECK-NEXT: {{  $}}34    ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p0) = COPY $x035    ; CHECK-NEXT: [[SEXTLOAD:%[0-9]+]]:_(s32) = G_SEXTLOAD [[COPY]](p0) :: (load (s16))36    ; CHECK-NEXT: $w0 = COPY [[SEXTLOAD]](s32)37    %0:_(p0) = COPY $x038    %1:_(s32) = G_SEXTLOAD %0:_(p0) :: (load (s16))39    %2:_(s32) = COPY %1:_(s32)40    %3:_(s32) = G_SEXT_INREG %2:_(s32), 1641    $w0 = COPY %3(s32)42...43---44name:            test_combine_sext_of_sextload_not_matching45legalized:       true46tracksRegLiveness: true47body: |48  bb.0.entry:49    liveins: $x050    ; Here we're trying to extend from a smaller value than was extended in the load.51    ; CHECK-LABEL: name: test_combine_sext_of_sextload_not_matching52    ; CHECK: liveins: $x053    ; CHECK-NEXT: {{  $}}54    ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p0) = COPY $x055    ; CHECK-NEXT: [[SEXTLOAD:%[0-9]+]]:_(s32) = G_SEXTLOAD [[COPY]](p0) :: (load (s16))56    ; CHECK-NEXT: $w0 = COPY [[SEXTLOAD]](s32)57    %0:_(p0) = COPY $x058    %1:_(s32) = G_SEXTLOAD %0:_(p0) :: (load (s16))59    %2:_(s32) = COPY %1:_(s32)60    %3:_(s32) = G_SEXT_INREG %2:_(s32), 2461    $w0 = COPY %3(s32)62...63