Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(243)

Side by Side Diff: tests_lit/llvm2ice_tests/branch-simple.ll

Issue 539743002: Subzero: Render constants in dump() to be more like LLVM. (Closed) Base URL: https://gerrit.chromium.org/gerrit/p/native_client/pnacl-subzero.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 ; 1. Trivial smoke test of compare and branch, with multiple basic 1 ; 1. Trivial smoke test of compare and branch, with multiple basic
2 ; blocks. 2 ; blocks.
3 ; 2. For a conditional branch on a constant boolean value, make sure 3 ; 2. For a conditional branch on a constant boolean value, make sure
4 ; we don't lower to a cmp instructions with an immediate as the first 4 ; we don't lower to a cmp instructions with an immediate as the first
5 ; source operand. 5 ; source operand.
6 6
7 ; RUN: %llvm2ice -O2 --verbose inst %s | FileCheck %s 7 ; RUN: %llvm2ice -O2 --verbose inst %s | FileCheck %s
8 ; RUN: %llvm2ice -Om1 --verbose inst %s | FileCheck %s 8 ; RUN: %llvm2ice -Om1 --verbose inst %s | FileCheck %s
9 ; RUN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s 9 ; RUN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s
10 ; RUN: %llvm2iceinsts %s | %szdiff %s | FileCheck --check-prefix=DUMP %s 10 ; RUN: %llvm2iceinsts %s | %szdiff %s | FileCheck --check-prefix=DUMP %s
(...skipping 11 matching lines...) Expand all
22 ; CHECK-LABEL: simple_cond_branch 22 ; CHECK-LABEL: simple_cond_branch
23 ; CHECK: br i1 %r1, label %Equal, label %Unequal 23 ; CHECK: br i1 %r1, label %Equal, label %Unequal
24 ; CHECK: Equal: 24 ; CHECK: Equal:
25 ; CHECK: ret i32 %foo 25 ; CHECK: ret i32 %foo
26 ; CHECK: Unequal: 26 ; CHECK: Unequal:
27 ; CHECK: ret i32 %bar 27 ; CHECK: ret i32 %bar
28 } 28 }
29 29
30 define internal i32 @test_br_const() { 30 define internal i32 @test_br_const() {
31 __0: 31 __0:
32 br i1 1, label %__1, label %__2 32 br i1 true, label %__1, label %__2
33 __1: 33 __1:
34 ret i32 21 34 ret i32 21
35 __2: 35 __2:
36 ret i32 43 36 ret i32 43
37 } 37 }
38 ; CHECK-LABEL: test_br_const 38 ; CHECK-LABEL: test_br_const
39 ; CHECK-NOT: cmp {{[0-9]*}}, 39 ; CHECK-NOT: cmp {{[0-9]*}},
40 40
41 ; ERRORS-NOT: ICE translation error 41 ; ERRORS-NOT: ICE translation error
42 ; DUMP-NOT: SZ 42 ; DUMP-NOT: SZ
OLDNEW
« no previous file with comments | « tests_lit/llvm2ice_tests/64bit.pnacl.ll ('k') | tests_lit/llvm2ice_tests/nacl-other-intrinsics.ll » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698