| OLD | NEW |
| 1 ; RUIN: %llvm2ice -verbose inst %s | FileCheck %s | 1 ; This test is lowered from C code that does some simple aritmetic |
| 2 ; RUIN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s | 2 ; with struct members. |
| 3 |
| 4 ; RUN: %llvm2ice --verbose inst %s | FileCheck %s |
| 5 ; RUN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s |
| 3 ; RUN: %llvm2iceinsts %s | %szdiff %s | FileCheck --check-prefix=DUMP %s | 6 ; RUN: %llvm2iceinsts %s | %szdiff %s | FileCheck --check-prefix=DUMP %s |
| 4 ; RUN: %llvm2iceinsts --pnacl %s | %szdiff %s \ | 7 ; RUN: %llvm2iceinsts --pnacl %s | %szdiff %s \ |
| 5 ; RUN: | FileCheck --check-prefix=DUMP %s | 8 ; RUN: | FileCheck --check-prefix=DUMP %s |
| 6 | 9 |
| 7 ; This file is lowered from C code that does some simple aritmetic with | |
| 8 ; struct members. It's also built with the PNaCl toolchain so this is the | |
| 9 ; stable ABI subset of LLVM IR (structs are gone, pointers turned into i32, | |
| 10 ; geps gone, etc.) | |
| 11 | |
| 12 define internal i32 @compute_important_function(i32 %v1, i32 %v2) { | 10 define internal i32 @compute_important_function(i32 %v1, i32 %v2) { |
| 13 entry: | 11 entry: |
| 14 %__2 = inttoptr i32 %v1 to i32* | 12 %__2 = inttoptr i32 %v1 to i32* |
| 15 %_v0 = load i32* %__2, align 1 | 13 %_v0 = load i32* %__2, align 1 |
| 16 | 14 |
| 17 ; CHECK: entry: | 15 ; CHECK: entry: |
| 18 ; CHECK-NEXT: %__2 = i32 %v1 | 16 ; CHECK-NEXT: %__2 = i32 %v1 |
| 19 ; CHECK-NEXT: %_v0 = load i32* {{.*}}, align 1 | 17 ; CHECK-NEXT: %_v0 = load i32* {{.*}}, align 1 |
| 20 | 18 |
| 21 %__4 = inttoptr i32 %v2 to i32* | 19 %__4 = inttoptr i32 %v2 to i32* |
| (...skipping 26 matching lines...) Expand all Loading... |
| 48 %sub = sub i32 %add, %mul3 | 46 %sub = sub i32 %add, %mul3 |
| 49 %sub12 = sub i32 %sub, %mul11 | 47 %sub12 = sub i32 %sub, %mul11 |
| 50 ret i32 %sub12 | 48 ret i32 %sub12 |
| 51 | 49 |
| 52 ; CHECK: %sub12 = sub i32 %sub, %mul11 | 50 ; CHECK: %sub12 = sub i32 %sub, %mul11 |
| 53 ; CHECK-NEXT: ret i32 %sub12 | 51 ; CHECK-NEXT: ret i32 %sub12 |
| 54 } | 52 } |
| 55 | 53 |
| 56 ; ERRORS-NOT: ICE translation error | 54 ; ERRORS-NOT: ICE translation error |
| 57 ; DUMP-NOT: SZ | 55 ; DUMP-NOT: SZ |
| OLD | NEW |