[TTI] getTypeBasedIntrinsicInstrCost - add basic handling for strided load/store...
[llvm-project.git] / llvm / test / CodeGen / X86 / twoaddr-mul2.mir
blobb24c893cc11fc4892f0898a1f204f45708cca8d1
1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=x86_64-unknown -mcpu=haswell -run-pass=twoaddressinstruction -verify-machineinstrs %s -o - | FileCheck %s
3 # RUN: llc -mtriple=x86_64-unknown -mcpu=haswell --passes=two-address-instruction -verify-each %s -o - | FileCheck %s
5 # Check that we don't have any uses of [[COPY]] after it is killed.
6 ---
7 name: test_mul_by_2
8 tracksRegLiveness: true
9 body: |
10   bb.0:
11     liveins: $edi
13     ; CHECK-LABEL: name: test_mul_by_2
14     ; CHECK: liveins: $edi
15     ; CHECK-NEXT: {{  $}}
16     ; CHECK-NEXT: [[COPY:%[0-9]+]]:gr32 = COPY killed $edi
17     ; CHECK-NEXT: undef %2.sub_32bit:gr64_nosp = COPY killed [[COPY]]
18     ; CHECK-NEXT: [[LEA64_32r:%[0-9]+]]:gr32 = LEA64_32r killed %2, 1, killed %2, 0, $noreg
19     ; CHECK-NEXT: $eax = COPY killed [[LEA64_32r]]
20     ; CHECK-NEXT: RET 0, killed $eax
21     %0:gr32 = COPY killed $edi
22     %1:gr32 = ADD32rr killed %0, %0, implicit-def dead $eflags
23     $eax = COPY killed %1
24     RET 0, killed $eax
25 ...