blob: ed58e118437769e014f56fb18189c26171336ee7 [file] [log] [blame]
Eli Benderskya66a1852012-01-16 08:56:09 +00001; RUN: %lli %s > /dev/null
Tanya Lattnere9789ef2004-11-06 23:32:43 +00002
Chris Lattner4a8068f2003-01-13 01:03:16 +00003; We were accidentally inverting the signedness of right shifts. Whoops.
4
Tanya Lattnerceca1942008-03-10 07:21:50 +00005define i32 @main() {
6 %X = ashr i32 -1, 16 ; <i32> [#uses=1]
7 %Y = ashr i32 %X, 16 ; <i32> [#uses=1]
8 %Z = add i32 %Y, 1 ; <i32> [#uses=1]
9 ret i32 %Z
Chris Lattner4a8068f2003-01-13 01:03:16 +000010}
Tanya Lattnerceca1942008-03-10 07:21:50 +000011