OLD | NEW |
| (Empty) |
1 ; RUN: llc < %s -disable-cfi -disable-fp-elim -mtriple x86_64-apple-darwin11 | F
ileCheck %s | |
2 | |
3 %ty = type { i8* } | |
4 | |
5 @gv = external global i32 | |
6 | |
7 ; This is aligning the stack with a push of a random register. | |
8 ; CHECK: pushq %rax | |
9 | |
10 ; Even though we can't encode %rax into the compact unwind, We still want to be | |
11 ; able to generate a compact unwind encoding in this particular case. | |
12 ; | |
13 ; CHECK: __LD,__compact_unwind | |
14 ; CHECK: _foo ## Range Start | |
15 ; CHECK: 16842753 ## Compact Unwind Encoding: 0x1010001 | |
16 | |
17 define i8* @foo(i64 %size) { | |
18 %addr = alloca i64, align 8 | |
19 %tmp20 = load i32* @gv, align 4 | |
20 %tmp21 = call i32 @bar() | |
21 %tmp25 = load i64* %addr, align 8 | |
22 %tmp26 = inttoptr i64 %tmp25 to %ty* | |
23 %tmp29 = getelementptr inbounds %ty* %tmp26, i64 0, i32 0 | |
24 %tmp34 = load i8** %tmp29, align 8 | |
25 %tmp35 = getelementptr inbounds i8* %tmp34, i64 %size | |
26 store i8* %tmp35, i8** %tmp29, align 8 | |
27 ret i8* null | |
28 } | |
29 | |
30 declare i32 @bar() | |
OLD | NEW |