mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 04:02:41 +01:00
5d3a0ce4e5
another mechanical change accomplished though the power of terrible Perl scripts. I have manually switched some "s to 's to make escaping simpler. While I started this to fix tests that aren't run in all configurations, the massive number of tests is due to a really frustrating fragility of our testing infrastructure: things like 'grep -v', 'not grep', and 'expected failures' can mask broken tests all too easily. Essentially, I'm deeply disturbed that I can change the testsuite so radically without causing any change in results for most platforms. =/ llvm-svn: 159547
27 lines
800 B
LLVM
27 lines
800 B
LLVM
; RUN: llc < %s -march=x86 | grep "jc" | count 1
|
|
; XFAIL: *
|
|
|
|
; FIXME: umul-with-overflow not supported yet.
|
|
|
|
@ok = internal constant [4 x i8] c"%d\0A\00"
|
|
@no = internal constant [4 x i8] c"no\0A\00"
|
|
|
|
define i1 @func(i32 %v1, i32 %v2) nounwind {
|
|
entry:
|
|
%t = call {i32, i1} @llvm.umul.with.overflow.i32(i32 %v1, i32 %v2)
|
|
%sum = extractvalue {i32, i1} %t, 0
|
|
%obit = extractvalue {i32, i1} %t, 1
|
|
br i1 %obit, label %carry, label %normal
|
|
|
|
normal:
|
|
%t1 = tail call i32 (i8*, ...)* @printf( i8* getelementptr ([4 x i8]* @ok, i32 0, i32 0), i32 %sum ) nounwind
|
|
ret i1 true
|
|
|
|
carry:
|
|
%t2 = tail call i32 (i8*, ...)* @printf( i8* getelementptr ([4 x i8]* @no, i32 0, i32 0) ) nounwind
|
|
ret i1 false
|
|
}
|
|
|
|
declare i32 @printf(i8*, ...) nounwind
|
|
declare {i32, i1} @llvm.umul.with.overflow.i32(i32, i32)
|