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

Side by Side Diff: tests_lit/llvm2ice_tests/rng.ll

Issue 1306713002: Fix bug in the call to random number generator in Cfg's ctor (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Created 5 years, 4 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 ; This is a smoke test of random number generator. 1 ; This is a smoke test of random number generator.
2 ; The random number generators for different randomization passes should be 2 ; The random number generators for different randomization passes should be
3 ; decoupled. The random number used in one randomization pass should not be 3 ; decoupled. The random number used in one randomization pass should not be
4 ; influenced by the existence of other randomization passes. 4 ; influenced by the existence of other randomization passes.
5 5
6 ; REQUIRES: allow_dump, target_X8632 6 ; REQUIRES: allow_dump, target_X8632
7 7
8 ; Command for checking constant blinding (Need to turn off nop-insertion) 8 ; Command for checking constant blinding (Need to turn off nop-insertion)
9 ; RUN: %p2i --target x8632 -i %s --filetype=obj --disassemble --args -O2 \ 9 ; RUN: %p2i --target x8632 -i %s --filetype=obj --disassemble --args -O2 \
10 ; RUN: -sz-seed=1 -randomize-pool-immediates=randomize \ 10 ; RUN: -sz-seed=1 -randomize-pool-immediates=randomize \
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 138
139 define float @func2(float* %arg) { 139 define float @func2(float* %arg) {
140 entry: 140 entry:
141 %arg.int = ptrtoint float* %arg to i32 141 %arg.int = ptrtoint float* %arg to i32
142 %addr.int = add i32 %arg.int, 200000 142 %addr.int = add i32 %arg.int, 200000
143 %addr.ptr = inttoptr i32 %addr.int to float* 143 %addr.ptr = inttoptr i32 %addr.int to float*
144 %addr.load = load float, float* %addr.ptr, align 4 144 %addr.load = load float, float* %addr.ptr, align 4
145 ret float %addr.load 145 ret float %addr.load
146 146
147 ; BLINDINGO2-LABEL: func2 147 ; BLINDINGO2-LABEL: func2
148 ; BLINDINGO2: lea [[REG:e[a-z]*]],{{[[]}}{{e[a-z]*}}+0x32c814{{[]]}} 148 ; BLINDINGO2: lea [[REG:e[a-z]*]],{{[[]}}{{e[a-z]*}}+0x69ed4ee7{{[]]}}
149 } 149 }
150 150
151 define float @func3(i32 %arg, float %input) { 151 define float @func3(i32 %arg, float %input) {
152 entry: 152 entry:
153 switch i32 %arg, label %return [ 153 switch i32 %arg, label %return [
154 i32 0, label %sw.bb 154 i32 0, label %sw.bb
155 i32 1, label %sw.bb1 155 i32 1, label %sw.bb1
156 i32 2, label %sw.bb2 156 i32 2, label %sw.bb2
157 i32 3, label %sw.bb3 157 i32 3, label %sw.bb3
158 i32 4, label %sw.bb4 158 i32 4, label %sw.bb4
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 ; BBREORDERING: .Lfunc5$BB4: 222 ; BBREORDERING: .Lfunc5$BB4:
223 ; BBREORDERING: .Lfunc5$BB3 223 ; BBREORDERING: .Lfunc5$BB3
224 } 224 }
225 225
226 define i32 @func6(i32 %arg) { 226 define i32 @func6(i32 %arg) {
227 entry: 227 entry:
228 %res = add i32 200000, %arg 228 %res = add i32 200000, %arg
229 ret i32 %res 229 ret i32 %res
230 230
231 ; BLINDINGO2-LABEL: func6 231 ; BLINDINGO2-LABEL: func6
232 ; BLINDINGO2: mov [[REG:e[a-z]*]],0xb178f 232 ; BLINDINGO2: mov [[REG:e[a-z]*]],0x77254ee7
233 ; BLINDINGO2-NEXT: lea [[REG]],{{[[]}}[[REG]]-0x80a4f{{[]]}} 233 ; BLINDINGO2-NEXT: lea [[REG]],{{[[]}}[[REG]]-0x772241a7{{[]]}}
234 } 234 }
235 235
236 ; Check for function reordering 236 ; Check for function reordering
237 ; FUNCREORDERING-LABEL: func1 237 ; FUNCREORDERING-LABEL: func1
238 ; FUNCREORDERING-LABEL: func4 238 ; FUNCREORDERING-LABEL: func4
239 ; FUNCREORDERING-LABEL: func5 239 ; FUNCREORDERING-LABEL: func5
240 ; FUNCREORDERING-LABEL: func2 240 ; FUNCREORDERING-LABEL: func2
241 ; FUNCREORDERING-LABEL: func6 241 ; FUNCREORDERING-LABEL: func6
242 ; FUNCREORDERING-LABEL: func3 242 ; FUNCREORDERING-LABEL: func3
243 243
244 ; Check for global variable reordering 244 ; Check for global variable reordering
245 ; GLOBALVARS-LABEL: ArrayInit 245 ; GLOBALVARS-LABEL: ArrayInit
246 ; GLOBALVARS-LABEL: PrimitiveInit 246 ; GLOBALVARS-LABEL: PrimitiveInit
247 ; GLOBALVARS-LABEL: ArrayInitPartial 247 ; GLOBALVARS-LABEL: ArrayInitPartial
248 ; GLOBALVARS-LABEL: PrimitiveUninit 248 ; GLOBALVARS-LABEL: PrimitiveUninit
249 ; GLOBALVARS-LABEL: ArrayUninit 249 ; GLOBALVARS-LABEL: ArrayUninit
250 ; GLOBALVARS-LABEL: PrimitiveInitStatic 250 ; GLOBALVARS-LABEL: PrimitiveInitStatic
251 ; GLOBALVARS-LABEL: ArrayUninitConstDouble 251 ; GLOBALVARS-LABEL: ArrayUninitConstDouble
252 ; GLOBALVARS-LABEL: ArrayUninitConstInt 252 ; GLOBALVARS-LABEL: ArrayUninitConstInt
253 ; GLOBALVARS-LABEL: PrimitiveInitConst 253 ; GLOBALVARS-LABEL: PrimitiveInitConst
254 254
255 ; Check for pooled constant reordering 255 ; Check for pooled constant reordering
256 ; POOLEDCONSTANTS-LABEL: .rodata.cst4 256 ; POOLEDCONSTANTS-LABEL: .rodata.cst4
257 ; POOLEDCONSTANTS: 0000803e 0000803f 00000000 0000003f 257 ; POOLEDCONSTANTS: 0000803e 0000803f 00000000 0000003f
258 ; POOLEDCONSTANTS: 00008040 00000040 258 ; POOLEDCONSTANTS: 00008040 00000040
OLDNEW
« src/IceCfg.cpp ('K') | « tests_lit/llvm2ice_tests/randomize-pool-immediate-basic.ll ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698