forked from WebAssembly/binaryen
-
Notifications
You must be signed in to change notification settings - Fork 0
/
20000412-6.c.s
88 lines (84 loc) · 2.54 KB
/
20000412-6.c.s
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
.text
.file "/b/build/slave/linux/build/src/src/work/gcc/gcc/testsuite/gcc.c-torture/execute/20000412-6.c"
.section .text.main,"ax",@progbits
.hidden main
.globl main
.type main,@function
main: # @main
.result i32
# BB#0: # %entry
block
i32.const $push1=, 512
i32.const $push13=, 0
i32.load16_u $push0=, buf($pop13)
i32.sub $push2=, $pop1, $pop0
i32.const $push12=, 0
i32.load16_u $push3=, buf+2($pop12)
i32.sub $push4=, $pop2, $pop3
i32.const $push11=, 0
i32.load16_u $push5=, buf+4($pop11)
i32.sub $push6=, $pop4, $pop5
i32.const $push7=, 65535
i32.and $push8=, $pop6, $pop7
i32.const $push9=, 491
i32.ne $push10=, $pop8, $pop9
br_if 0, $pop10 # 0: down to label0
# BB#1: # %if.end
i32.const $push14=, 0
call exit@FUNCTION, $pop14
unreachable
.LBB0_2: # %if.then
end_block # label0:
call abort@FUNCTION
unreachable
.endfunc
.Lfunc_end0:
.size main, .Lfunc_end0-main
.section .text.bug,"ax",@progbits
.hidden bug
.globl bug
.type bug,@function
bug: # @bug
.param i32, i32, i32
.result i32
# BB#0: # %entry
block
i32.ge_u $push0=, $1, $2
br_if 0, $pop0 # 0: down to label1
# BB#1: # %for.body.preheader
.LBB1_2: # %for.body
# =>This Inner Loop Header: Depth=1
loop # label2:
i32.const $push9=, 65535
i32.and $push1=, $0, $pop9
i32.load16_u $push2=, 0($1)
i32.sub $0=, $pop1, $pop2
i32.const $push8=, 2
i32.add $push7=, $1, $pop8
tee_local $push6=, $1=, $pop7
i32.lt_u $push3=, $pop6, $2
br_if 0, $pop3 # 0: up to label2
.LBB1_3: # %for.end
end_loop # label3:
end_block # label1:
i32.const $push4=, 65535
i32.and $push5=, $0, $pop4
# fallthrough-return: $pop5
.endfunc
.Lfunc_end1:
.size bug, .Lfunc_end1-bug
.hidden buf # @buf
.type buf,@object
.section .data.buf,"aw",@progbits
.globl buf
.p2align 1
buf:
.int16 1 # 0x1
.int16 4 # 0x4
.int16 16 # 0x10
.int16 64 # 0x40
.int16 256 # 0x100
.size buf, 10
.ident "clang version 3.9.0 "
.functype abort, void
.functype exit, void, i32