69 lines · plain
1# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py2# RUN: llc -mtriple=m68k -run-pass=legalizer -verify-machineinstrs %s -o - | FileCheck %s3 4---5name: test_scalar_small6fixedStack:7 - { id: 0, type: default, offset: 4, size: 1, alignment: 4, stack-id: default,8 isImmutable: true, isAliased: false, callee-saved-register: '', callee-saved-restored: true,9 debug-info-variable: '', debug-info-expression: '', debug-info-location: '' }10 - { id: 1, type: default, offset: 0, size: 1, alignment: 8, stack-id: default,11 isImmutable: true, isAliased: false, callee-saved-register: '', callee-saved-restored: true,12 debug-info-variable: '', debug-info-expression: '', debug-info-location: '' }13 14body: |15 bb.1:16 ; CHECK-LABEL: name: test_scalar_small17 ; CHECK: [[FRAME_INDEX:%[0-9]+]]:_(p0) = G_FRAME_INDEX %fixed-stack.018 ; CHECK-NEXT: [[LOAD:%[0-9]+]]:_(s32) = G_LOAD [[FRAME_INDEX]](p0) :: (load (s8) from %fixed-stack.0, align 8)19 ; CHECK-NEXT: [[FRAME_INDEX1:%[0-9]+]]:_(p0) = G_FRAME_INDEX %fixed-stack.120 ; CHECK-NEXT: [[LOAD1:%[0-9]+]]:_(s32) = G_LOAD [[FRAME_INDEX1]](p0) :: (load (s8) from %fixed-stack.1, align 4)21 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:_(s8) = G_TRUNC [[LOAD]](s32)22 ; CHECK-NEXT: [[TRUNC1:%[0-9]+]]:_(s8) = G_TRUNC [[LOAD1]](s32)23 ; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s8) = G_SUB [[TRUNC]], [[TRUNC1]]24 ; CHECK-NEXT: $bd0 = COPY [[SUB]](s8)25 ; CHECK-NEXT: RTS implicit $bd026 %3:_(p0) = G_FRAME_INDEX %fixed-stack.127 %2:_(s32) = G_LOAD %3(p0) :: (load (s8) from %fixed-stack.1, align 8)28 %0:_(s2) = G_TRUNC %2(s32)29 %5:_(p0) = G_FRAME_INDEX %fixed-stack.030 %4:_(s32) = G_LOAD %5(p0) :: (load (s8) from %fixed-stack.0, align 4)31 %1:_(s2) = G_TRUNC %4(s32)32 %6:_(s2) = G_SUB %0, %133 %7:_(s8) = G_ANYEXT %6(s2)34 $bd0 = COPY %7(s8)35 RTS implicit $bd036 37...38---39name: test_scalar_nonpow240fixedStack:41 - { id: 0, type: default, offset: 4, size: 4, alignment: 4, stack-id: default,42 isImmutable: true, isAliased: false, callee-saved-register: '', callee-saved-restored: true,43 debug-info-variable: '', debug-info-expression: '', debug-info-location: '' }44 - { id: 1, type: default, offset: 0, size: 4, alignment: 8, stack-id: default,45 isImmutable: true, isAliased: false, callee-saved-register: '', callee-saved-restored: true,46 debug-info-variable: '', debug-info-expression: '', debug-info-location: '' }47body: |48 bb.1:49 ; CHECK-LABEL: name: test_scalar_nonpow250 ; CHECK: [[FRAME_INDEX:%[0-9]+]]:_(p0) = G_FRAME_INDEX %fixed-stack.051 ; CHECK-NEXT: [[LOAD:%[0-9]+]]:_(s32) = G_LOAD [[FRAME_INDEX]](p0) :: (load (s32) from %fixed-stack.0, align 8)52 ; CHECK-NEXT: [[FRAME_INDEX1:%[0-9]+]]:_(p0) = G_FRAME_INDEX %fixed-stack.153 ; CHECK-NEXT: [[LOAD1:%[0-9]+]]:_(s32) = G_LOAD [[FRAME_INDEX1]](p0) :: (load (s32) from %fixed-stack.1)54 ; CHECK-NEXT: [[SUB:%[0-9]+]]:_(s32) = G_SUB [[LOAD]], [[LOAD1]]55 ; CHECK-NEXT: $d0 = COPY [[SUB]](s32)56 ; CHECK-NEXT: RTS implicit $d057 %3:_(p0) = G_FRAME_INDEX %fixed-stack.158 %2:_(s32) = G_LOAD %3(p0) :: (load (s32) from %fixed-stack.1, align 8)59 %0:_(s17) = G_TRUNC %2(s32)60 %5:_(p0) = G_FRAME_INDEX %fixed-stack.061 %4:_(s32) = G_LOAD %5(p0) :: (load (s32) from %fixed-stack.0)62 %1:_(s17) = G_TRUNC %4(s32)63 %6:_(s17) = G_SUB %0, %164 %7:_(s32) = G_ANYEXT %6(s17)65 $d0 = COPY %7(s32)66 RTS implicit $d067 68...69