Daniel Dunbar | 46a2716 | 2010-11-13 00:28:01 +0000 | [diff] [blame] | 1 | ; This testcase should return with an exit code of 1. |
Chris Lattner | 7c87e40 | 2003-05-06 19:41:25 +0000 | [diff] [blame] | 2 | ; |
Eli Bendersky | a66a185 | 2012-01-16 08:56:09 +0000 | [diff] [blame] | 3 | ; RUN: not %lli %s |
Andrew Trick | 0005cc7 | 2011-08-26 23:39:30 +0000 | [diff] [blame] | 4 | ; XFAIL: arm |
Chris Lattner | 7c87e40 | 2003-05-06 19:41:25 +0000 | [diff] [blame] | 5 | |
Tanya Lattner | ceca194 | 2008-03-10 07:21:50 +0000 | [diff] [blame] | 6 | @test = global i64 0 ; <i64*> [#uses=1] |
Chris Lattner | 7c87e40 | 2003-05-06 19:41:25 +0000 | [diff] [blame] | 7 | |
Tanya Lattner | ceca194 | 2008-03-10 07:21:50 +0000 | [diff] [blame] | 8 | define internal i64 @test.upgrd.1() { |
| 9 | %tmp.0 = load i64* @test ; <i64> [#uses=1] |
| 10 | %tmp.1 = add i64 %tmp.0, 1 ; <i64> [#uses=1] |
| 11 | ret i64 %tmp.1 |
Chris Lattner | 7c87e40 | 2003-05-06 19:41:25 +0000 | [diff] [blame] | 12 | } |
| 13 | |
Tanya Lattner | ceca194 | 2008-03-10 07:21:50 +0000 | [diff] [blame] | 14 | define i32 @main() { |
| 15 | %L = call i64 @test.upgrd.1( ) ; <i64> [#uses=1] |
| 16 | %I = trunc i64 %L to i32 ; <i32> [#uses=1] |
| 17 | ret i32 %I |
Chris Lattner | 7c87e40 | 2003-05-06 19:41:25 +0000 | [diff] [blame] | 18 | } |
| 19 | |
Tanya Lattner | ceca194 | 2008-03-10 07:21:50 +0000 | [diff] [blame] | 20 | |