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

Side by Side Diff: tests_lit/llvm2ice_tests/pnacl-reader.ll

Issue 395193005: Start processing function blocks in Subzero. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Fix nits in patch set 4. Created 6 years, 5 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
« src/PNaClTranslator.cpp ('K') | « src/llvm2ice.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 ; Tests the current state of the translator using PNaCl bitcode.
jvoung (off chromium) 2014/07/23 16:10:17 Should we start making new directories for lit tes
Karl 2014/07/23 20:22:21 Creating Reader directory for this test. Also add
2
3 ; RUN: llvm-as < %s | pnacl-freeze \
4 ; RUN: | %llvm2ice -notranslate -verbose=inst -build-on-read \
5 ; RUN: -allow-pnacl-reader-error-recovery \
6 ; RUN: | FileCheck %s
7
8 define i32 @Add(i32 %a, i32 %b) {
9 %add = add i32 %b, %a
10 ret i32 %add
11 }
12
13 ; CHECK: define i32 @Add(i32 %__0, i32 %__1) {
14 ; CHECK-NEXT: bb0:
15 ; CHECK-NEXT: %__2 = add i32 %__1, %__0
16 ; CHECK-NEXT: ret i32 %__2
17 ; CHECK-NEXT: }
18
19 define i32 @And(i32 %a, i32 %b) {
20 %and = and i32 %b, %a
21 ret i32 %and
22 }
23
24 ; CHECK-NEXT: define i32 @And(i32 %__0, i32 %__1) {
25 ; CHECK-NEXT: bb0:
26 ; CHECK-NEXT: %__2 = and i32 %__1, %__0
27 ; CHECK-NEXT: ret i32 %__2
28 ; CHECK-NEXT: }
29
30 define i32 @Or(i32 %a, i32 %b) {
31 %or = or i32 %b, %a
32 ret i32 %or
33 }
34
35 ; CHECK-NEXT: define i32 @Or(i32 %__0, i32 %__1) {
36 ; CHECK-NEXT: bb0:
37 ; CHECK-NEXT: %__2 = or i32 %__1, %__0
38 ; CHECK-NEXT: ret i32 %__2
39 ; CHECK-NEXT: }
40
41 define i32 @Xor(i32 %a, i32 %b) {
42 %xor = xor i32 %b, %a
43 ret i32 %xor
44 }
45
46 ; CHECK-NEXT: define i32 @Xor(i32 %__0, i32 %__1) {
47 ; CHECK-NEXT: bb0:
48 ; CHECK-NEXT: %__2 = xor i32 %__1, %__0
49 ; CHECK-NEXT: ret i32 %__2
50 ; CHECK-NEXT: }
51
52 define i32 @Sub(i32 %a, i32 %b) {
53 %sub = sub i32 %a, %b
54 ret i32 %sub
55 }
56
57 ; CHECK-NEXT: define i32 @Sub(i32 %__0, i32 %__1) {
58 ; CHECK-NEXT: bb0:
59 ; CHECK-NEXT: %__2 = sub i32 %__0, %__1
60 ; CHECK-NEXT: ret i32 %__2
61 ; CHECK-NEXT: }
62
63 define i32 @Mul(i32 %a, i32 %b) {
64 %mul = mul i32 %b, %a
65 ret i32 %mul
66 }
67
68 ; CHECK-NEXT: define i32 @Mul(i32 %__0, i32 %__1) {
69 ; CHECK-NEXT: bb0:
70 ; CHECK-NEXT: %__2 = mul i32 %__1, %__0
71 ; CHECK-NEXT: ret i32 %__2
72 ; CHECK-NEXT: }
73
74 define i32 @Sdiv(i32 %a, i32 %b) {
75 %div = sdiv i32 %a, %b
76 ret i32 %div
77 }
78
79 ; CHECK-NEXT: define i32 @Sdiv(i32 %__0, i32 %__1) {
80 ; CHECK-NEXT: bb0:
81 ; CHECK-NEXT: %__2 = sdiv i32 %__0, %__1
82 ; CHECK-NEXT: ret i32 %__2
83 ; CHECK-NEXT: }
84
85 define i32 @Srem(i32 %a, i32 %b) {
86 %rem = srem i32 %a, %b
87 ret i32 %rem
88 }
89
90 ; CHECK-NEXT: define i32 @Srem(i32 %__0, i32 %__1) {
91 ; CHECK-NEXT: bb0:
92 ; CHECK-NEXT: %__2 = srem i32 %__0, %__1
93 ; CHECK-NEXT: ret i32 %__2
94 ; CHECK-NEXT: }
95
96 define i32 @Udiv(i32 %a, i32 %b) {
97 %div = udiv i32 %a, %b
98 ret i32 %div
99 }
100
101 ; CHECK-NEXT: define i32 @Udiv(i32 %__0, i32 %__1) {
102 ; CHECK-NEXT: bb0:
103 ; CHECK-NEXT: %__2 = udiv i32 %__0, %__1
104 ; CHECK-NEXT: ret i32 %__2
105 ; CHECK-NEXT: }
106
107 define i32 @Urem(i32 %a, i32 %b) {
108 %rem = urem i32 %a, %b
109 ret i32 %rem
110 }
111
112 ; CHECK-NEXT: define i32 @Urem(i32 %__0, i32 %__1) {
113 ; CHECK-NEXT: bb0:
114 ; CHECK-NEXT: %__2 = urem i32 %__0, %__1
115 ; CHECK-NEXT: ret i32 %__2
116 ; CHECK-NEXT: }
117
OLDNEW
« src/PNaClTranslator.cpp ('K') | « src/llvm2ice.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698