OLD | NEW |
1 ; Show that we know how to translate mul. | 1 ; Show that we know how to translate mul. |
2 | 2 |
3 ; NOTE: We use -O2 to get rid of memory stores. | 3 ; NOTE: We use -O2 to get rid of memory stores. |
4 | 4 |
5 ; REQUIRES: allow_dump | 5 ; REQUIRES: allow_dump |
6 | 6 |
7 ; Compile using standalone assembler. | 7 ; Compile using standalone assembler. |
8 ; RUN: %p2i --filetype=asm -i %s --target=arm32 --args -O2 \ | 8 ; RUN: %p2i --filetype=asm -i %s --target=arm32 --args -O2 \ |
9 ; RUN: | FileCheck %s --check-prefix=ASM | 9 ; RUN: | FileCheck %s --check-prefix=ASM |
10 | 10 |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 define internal i64 @MulTwoI64Regs(i64 %a, i64 %b) { | 42 define internal i64 @MulTwoI64Regs(i64 %a, i64 %b) { |
43 %v = mul i64 %a, %b | 43 %v = mul i64 %a, %b |
44 ret i64 %v | 44 ret i64 %v |
45 } | 45 } |
46 | 46 |
47 ; ASM-LABEL:MulTwoI64Regs: | 47 ; ASM-LABEL:MulTwoI64Regs: |
48 ; ASM-NEXT:.LMulTwoI64Regs$__0: | 48 ; ASM-NEXT:.LMulTwoI64Regs$__0: |
49 ; ASM-NEXT: mul r3, r0, r3 | 49 ; ASM-NEXT: mul r3, r0, r3 |
50 ; ASM-NEXT: mla r1, r2, r1, r3 | 50 ; ASM-NEXT: mla r1, r2, r1, r3 |
51 ; ASM-NEXT: umull r0, r2, r0, r2 | 51 ; ASM-NEXT: umull r0, r2, r0, r2 |
52 ; ASM: add r2, r2, r1 | 52 ; ASM-NEXT: # r2 = def.pseudo r0 |
| 53 ; ASM-NEXT: add r2, r2, r1 |
53 ; ASM-NEXT: mov r1, r2 | 54 ; ASM-NEXT: mov r1, r2 |
54 ; ASM: bx lr | 55 ; ASM-NEXT: bx lr |
55 | 56 |
56 | 57 |
57 ; DIS-LABEL:00000010 <MulTwoI64Regs>: | 58 ; DIS-LABEL:00000010 <MulTwoI64Regs>: |
58 ; DIS-NEXT: 10: e0030390 | 59 ; DIS-NEXT: 10: e0030390 |
59 ; DIS-NEXT: 14: e0213192 | 60 ; DIS-NEXT: 14: e0213192 |
60 ; DIS-NEXT: 18: e0820290 | 61 ; DIS-NEXT: 18: e0820290 |
61 ; DIS-NEXT: 1c: e0822001 | 62 ; DIS-NEXT: 1c: e0822001 |
62 ; DIS-NEXT: 20: e1a01002 | 63 ; DIS-NEXT: 20: e1a01002 |
63 ; DIS-NEXT: 24: e12fff1e | 64 ; DIS-NEXT: 24: e12fff1e |
64 | 65 |
(...skipping 21 matching lines...) Expand all Loading... |
86 | 87 |
87 ; IASM-NEXT: .byte 0x2 | 88 ; IASM-NEXT: .byte 0x2 |
88 ; IASM-NEXT: .byte 0x10 | 89 ; IASM-NEXT: .byte 0x10 |
89 ; IASM-NEXT: .byte 0xa0 | 90 ; IASM-NEXT: .byte 0xa0 |
90 ; IASM-NEXT: .byte 0xe1 | 91 ; IASM-NEXT: .byte 0xe1 |
91 | 92 |
92 ; IASM-NEXT: .byte 0x1e | 93 ; IASM-NEXT: .byte 0x1e |
93 ; IASM-NEXT: .byte 0xff | 94 ; IASM-NEXT: .byte 0xff |
94 ; IASM-NEXT: .byte 0x2f | 95 ; IASM-NEXT: .byte 0x2f |
95 ; IASM-NEXT: .byte 0xe1 | 96 ; IASM-NEXT: .byte 0xe1 |
OLD | NEW |