Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 ; RUN: opt < %s -rewrite-pnacl-library-calls -S | FileCheck %s | |
| 2 ; Check that the rewrite pass behaves correctly in the presence | |
| 3 ; of various uses of longjmp that are not calls. | |
| 4 | |
| 5 @fp = global void (i64*, i32)* @longjmp, align 8 | |
| 6 ; CHECK: @fp = global void (i64*, i32)* @longjmp, align 8 | |
| 7 @arrfp = global [3 x void (i64*, i32)*] [void (i64*, i32)* null, void (i64*, i32 )* @longjmp, void (i64*, i32)* null], align 16 | |
| 8 ; CHECK: @arrfp = global [3 x void (i64*, i32)*] [void (i64*, i32)* null, void ( i64*, i32)* @longjmp, void (i64*, i32)* null], align 16 | |
| 9 | |
| 10 ; CHECK: define internal void @longjmp(i64* %env, i32 %val) { | |
|
Mark Seaborn
2013/05/13 23:39:58
Check definition of longjmp() too.
eliben
2013/05/14 17:38:58
Done elsewhere
| |
| 11 | |
| 12 declare void @longjmp(i64*, i32) | |
| 13 | |
| 14 ; Function Attrs: nounwind | |
|
Mark Seaborn
2013/05/13 23:39:58
What's this comment for? Remove?
eliben
2013/05/14 17:38:58
Done.
| |
| 15 define void @foo() { | |
| 16 entry: | |
| 17 call void @somefunc(i8* bitcast (void (i64*, i32)* @longjmp to i8*)) | |
| 18 ; CHECK: call void @somefunc(i8* bitcast (void (i64*, i32)* @longjmp to i8*)) | |
| 19 ret void | |
| 20 } | |
| 21 | |
| 22 declare void @somefunc(i8*) | |
|
Mark Seaborn
2013/05/13 23:39:58
Put declaration before use?
eliben
2013/05/14 17:38:58
Done.
| |
| 23 | |
| OLD | NEW |