You've already forked linux-packaging-mono
Imported Upstream version 5.18.0.167
Former-commit-id: 289509151e0fee68a1b591a20c9f109c3c789d3a
This commit is contained in:
parent
e19d552987
commit
b084638f15
@ -1,8 +0,0 @@
|
||||
; RUN: %lli -force-interpreter=true %s
|
||||
|
||||
define i32 @main() {
|
||||
%a = add i32 0, undef
|
||||
%b = fadd float 0.0, undef
|
||||
%c = fadd double 0.0, undef
|
||||
ret i32 0
|
||||
}
|
@ -1,35 +0,0 @@
|
||||
; RUN: lli -O0 -force-interpreter < %s
|
||||
|
||||
; libffi does not support fp128 so we don’t test it
|
||||
declare float @llvm.sin.f32(float)
|
||||
declare double @llvm.sin.f64(double)
|
||||
declare float @llvm.cos.f32(float)
|
||||
declare double @llvm.cos.f64(double)
|
||||
declare float @llvm.floor.f32(float)
|
||||
declare double @llvm.floor.f64(double)
|
||||
declare float @llvm.ceil.f32(float)
|
||||
declare double @llvm.ceil.f64(double)
|
||||
declare float @llvm.trunc.f32(float)
|
||||
declare double @llvm.trunc.f64(double)
|
||||
declare float @llvm.round.f32(float)
|
||||
declare double @llvm.round.f64(double)
|
||||
declare float @llvm.copysign.f32(float, float)
|
||||
declare double @llvm.copysign.f64(double, double)
|
||||
|
||||
define i32 @main() {
|
||||
%sin32 = call float @llvm.sin.f32(float 0.000000e+00)
|
||||
%sin64 = call double @llvm.sin.f64(double 0.000000e+00)
|
||||
%cos32 = call float @llvm.cos.f32(float 0.000000e+00)
|
||||
%cos64 = call double @llvm.cos.f64(double 0.000000e+00)
|
||||
%floor32 = call float @llvm.floor.f32(float 0.000000e+00)
|
||||
%floor64 = call double @llvm.floor.f64(double 0.000000e+00)
|
||||
%ceil32 = call float @llvm.ceil.f32(float 0.000000e+00)
|
||||
%ceil64 = call double @llvm.ceil.f64(double 0.000000e+00)
|
||||
%trunc32 = call float @llvm.trunc.f32(float 0.000000e+00)
|
||||
%trunc64 = call double @llvm.trunc.f64(double 0.000000e+00)
|
||||
%round32 = call float @llvm.round.f32(float 0.000000e+00)
|
||||
%round64 = call double @llvm.round.f64(double 0.000000e+00)
|
||||
%copysign32 = call float @llvm.copysign.f32(float 0.000000e+00, float 0.000000e+00)
|
||||
%copysign64 = call double @llvm.copysign.f64(double 0.000000e+00, double 0.000000e+00)
|
||||
ret i32 0
|
||||
}
|
@ -1,3 +0,0 @@
|
||||
# These tests require foreign function calls
|
||||
if not config.enable_ffi:
|
||||
config.unsupported = True
|
@ -1,37 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
@.LC0 = internal global [10 x i8] c"argc: %d\0A\00" ; <[10 x i8]*> [#uses=1]
|
||||
|
||||
declare i32 @puts(i8*)
|
||||
|
||||
define void @getoptions(i32* %argc) {
|
||||
bb0:
|
||||
ret void
|
||||
}
|
||||
|
||||
declare i32 @printf(i8*, ...)
|
||||
|
||||
define i32 @main(i32 %argc, i8** %argv) {
|
||||
bb0:
|
||||
call i32 (i8*, ...) @printf( i8* getelementptr ([10 x i8], [10 x i8]* @.LC0, i64 0, i64 0), i32 %argc ) ; <i32>:0 [#uses=0]
|
||||
%cast224 = bitcast i8** %argv to i8* ; <i8*> [#uses=1]
|
||||
%local = alloca i8* ; <i8**> [#uses=3]
|
||||
store i8* %cast224, i8** %local
|
||||
%cond226 = icmp sle i32 %argc, 0 ; <i1> [#uses=1]
|
||||
br i1 %cond226, label %bb3, label %bb2
|
||||
bb2: ; preds = %bb2, %bb0
|
||||
%cann-indvar = phi i32 [ 0, %bb0 ], [ %add1-indvar, %bb2 ] ; <i32> [#uses=2]
|
||||
%add1-indvar = add i32 %cann-indvar, 1 ; <i32> [#uses=2]
|
||||
%cann-indvar-idxcast = sext i32 %cann-indvar to i64 ; <i64> [#uses=1]
|
||||
%CT = bitcast i8** %local to i8*** ; <i8***> [#uses=1]
|
||||
%reg115 = load i8**, i8*** %CT ; <i8**> [#uses=1]
|
||||
%cast235 = getelementptr i8*, i8** %reg115, i64 %cann-indvar-idxcast ; <i8**> [#uses=1]
|
||||
%reg117 = load i8*, i8** %cast235 ; <i8*> [#uses=1]
|
||||
%reg236 = call i32 @puts( i8* %reg117 ) ; <i32> [#uses=0]
|
||||
%cond239 = icmp slt i32 %add1-indvar, %argc ; <i1> [#uses=1]
|
||||
br i1 %cond239, label %bb2, label %bb3
|
||||
bb3: ; preds = %bb2, %bb0
|
||||
%cast243 = bitcast i8** %local to i32* ; <i32*> [#uses=1]
|
||||
call void @getoptions( i32* %cast243 )
|
||||
ret i32 0
|
||||
}
|
@ -1,13 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
define i32 @foo(i32 %X, i32 %Y, double %A) {
|
||||
%cond212 = fcmp une double %A, 1.000000e+00 ; <i1> [#uses=1]
|
||||
%cast110 = zext i1 %cond212 to i32 ; <i32> [#uses=1]
|
||||
ret i32 %cast110
|
||||
}
|
||||
|
||||
define i32 @main() {
|
||||
%reg212 = call i32 @foo( i32 0, i32 1, double 1.000000e+00 ) ; <i32> [#uses=1]
|
||||
ret i32 %reg212
|
||||
}
|
||||
|
@ -1,20 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
define i32 @main() {
|
||||
call i32 @mylog( i32 4 ) ; <i32>:1 [#uses=0]
|
||||
ret i32 0
|
||||
}
|
||||
|
||||
define internal i32 @mylog(i32 %num) {
|
||||
bb0:
|
||||
br label %bb2
|
||||
bb2: ; preds = %bb2, %bb0
|
||||
%reg112 = phi i32 [ 10, %bb2 ], [ 1, %bb0 ] ; <i32> [#uses=1]
|
||||
%cann-indvar = phi i32 [ %cann-indvar, %bb2 ], [ 0, %bb0 ] ; <i32> [#uses=1]
|
||||
%reg114 = add i32 %reg112, 1 ; <i32> [#uses=2]
|
||||
%cond222 = icmp slt i32 %reg114, %num ; <i1> [#uses=1]
|
||||
br i1 %cond222, label %bb2, label %bb3
|
||||
bb3: ; preds = %bb2
|
||||
ret i32 %reg114
|
||||
}
|
||||
|
@ -1,12 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
define i32 @main() {
|
||||
; <label>:0
|
||||
br label %Loop
|
||||
Loop: ; preds = %Loop, %0
|
||||
%X = phi i32 [ 0, %0 ], [ 1, %Loop ] ; <i32> [#uses=1]
|
||||
br i1 true, label %Out, label %Loop
|
||||
Out: ; preds = %Loop
|
||||
ret i32 %X
|
||||
}
|
||||
|
@ -1,11 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
; We were accidentally inverting the signedness of right shifts. Whoops.
|
||||
|
||||
define i32 @main() {
|
||||
%X = ashr i32 -1, 16 ; <i32> [#uses=1]
|
||||
%Y = ashr i32 %X, 16 ; <i32> [#uses=1]
|
||||
%Z = add i32 %Y, 1 ; <i32> [#uses=1]
|
||||
ret i32 %Z
|
||||
}
|
||||
|
@ -1,10 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
define i32 @main() {
|
||||
%X = fadd double 0.000000e+00, 1.000000e+00 ; <double> [#uses=1]
|
||||
%Y = fsub double 0.000000e+00, 1.000000e+00 ; <double> [#uses=2]
|
||||
%Z = fcmp oeq double %X, %Y ; <i1> [#uses=0]
|
||||
fadd double %Y, 0.000000e+00 ; <double>:1 [#uses=0]
|
||||
ret i32 0
|
||||
}
|
||||
|
@ -1,17 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
define i32 @bar(i8* %X) {
|
||||
; pointer should be 4 byte aligned!
|
||||
%P = alloca double ; <double*> [#uses=1]
|
||||
%R = ptrtoint double* %P to i32 ; <i32> [#uses=1]
|
||||
%A = and i32 %R, 3 ; <i32> [#uses=1]
|
||||
ret i32 %A
|
||||
}
|
||||
|
||||
define i32 @main() {
|
||||
%SP = alloca i8 ; <i8*> [#uses=1]
|
||||
%X = add i32 0, 0 ; <i32> [#uses=1]
|
||||
alloca i8, i32 %X ; <i8*>:1 [#uses=0]
|
||||
call i32 @bar( i8* %SP ) ; <i32>:2 [#uses=1]
|
||||
ret i32 %2
|
||||
}
|
@ -1,19 +0,0 @@
|
||||
; This testcase should return with an exit code of 1.
|
||||
;
|
||||
; RUN: not %lli %s
|
||||
|
||||
@test = global i64 0 ; <i64*> [#uses=1]
|
||||
|
||||
define internal i64 @test.upgrd.1() {
|
||||
%tmp.0 = load i64, i64* @test ; <i64> [#uses=1]
|
||||
%tmp.1 = add i64 %tmp.0, 1 ; <i64> [#uses=1]
|
||||
ret i64 %tmp.1
|
||||
}
|
||||
|
||||
define i32 @main() {
|
||||
%L = call i64 @test.upgrd.1( ) ; <i64> [#uses=1]
|
||||
%I = trunc i64 %L to i32 ; <i32> [#uses=1]
|
||||
ret i32 %I
|
||||
}
|
||||
|
||||
|
@ -1,11 +0,0 @@
|
||||
; RUN: %lli %s test
|
||||
|
||||
declare i32 @puts(i8*)
|
||||
|
||||
define i32 @main(i32 %argc.1, i8** %argv.1) {
|
||||
%tmp.5 = getelementptr i8*, i8** %argv.1, i64 1 ; <i8**> [#uses=1]
|
||||
%tmp.6 = load i8*, i8** %tmp.5 ; <i8*> [#uses=1]
|
||||
%tmp.0 = call i32 @puts( i8* %tmp.6 ) ; <i32> [#uses=0]
|
||||
ret i32 0
|
||||
}
|
||||
|
@ -1,13 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
define i32 @main() {
|
||||
entry:
|
||||
br label %endif
|
||||
then: ; No predecessors!
|
||||
br label %endif
|
||||
endif: ; preds = %then, %entry
|
||||
%x = phi i32 [ 4, %entry ], [ 27, %then ] ; <i32> [#uses=0]
|
||||
%result = phi i32 [ 32, %then ], [ 0, %entry ] ; <i32> [#uses=0]
|
||||
ret i32 0
|
||||
}
|
||||
|
@ -1,17 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
; Testcase distilled from 256.bzip2.
|
||||
|
||||
define i32 @main() {
|
||||
entry:
|
||||
br label %loopentry.0
|
||||
loopentry.0: ; preds = %loopentry.0, %entry
|
||||
%h.0 = phi i32 [ %tmp.2, %loopentry.0 ], [ -1, %entry ] ; <i32> [#uses=1]
|
||||
%tmp.2 = add i32 %h.0, 1 ; <i32> [#uses=3]
|
||||
%tmp.4 = icmp ne i32 %tmp.2, 0 ; <i1> [#uses=1]
|
||||
br i1 %tmp.4, label %loopentry.0, label %loopentry.1
|
||||
loopentry.1: ; preds = %loopentry.0
|
||||
%h.1 = phi i32 [ %tmp.2, %loopentry.0 ] ; <i32> [#uses=1]
|
||||
ret i32 %h.1
|
||||
}
|
||||
|
@ -1,15 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
; Testcase distilled from 256.bzip2.
|
||||
|
||||
define i32 @main() {
|
||||
entry:
|
||||
%X = add i32 1, -1 ; <i32> [#uses=3]
|
||||
br label %Next
|
||||
Next: ; preds = %entry
|
||||
%A = phi i32 [ %X, %entry ] ; <i32> [#uses=0]
|
||||
%B = phi i32 [ %X, %entry ] ; <i32> [#uses=0]
|
||||
%C = phi i32 [ %X, %entry ] ; <i32> [#uses=1]
|
||||
ret i32 %C
|
||||
}
|
||||
|
@ -1,11 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
; This testcase failed to work because two variable sized allocas confused the
|
||||
; local register allocator.
|
||||
|
||||
define i32 @main(i32 %X) {
|
||||
%A = alloca i32, i32 %X ; <i32*> [#uses=0]
|
||||
%B = alloca float, i32 %X ; <float*> [#uses=0]
|
||||
ret i32 0
|
||||
}
|
||||
|
@ -1,21 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
;
|
||||
; Regression Test: EnvironmentTest.ll
|
||||
;
|
||||
; Description:
|
||||
; This is a regression test that verifies that the JIT passes the
|
||||
; environment to the main() function.
|
||||
;
|
||||
|
||||
|
||||
declare i32 @strlen(i8*)
|
||||
|
||||
define i32 @main(i32 %argc.1, i8** %argv.1, i8** %envp.1) {
|
||||
%tmp.2 = load i8*, i8** %envp.1 ; <i8*> [#uses=1]
|
||||
%tmp.3 = call i32 @strlen( i8* %tmp.2 ) ; <i32> [#uses=1]
|
||||
%T = icmp eq i32 %tmp.3, 0 ; <i1> [#uses=1]
|
||||
%R = zext i1 %T to i32 ; <i32> [#uses=1]
|
||||
ret i32 %R
|
||||
}
|
||||
|
@ -1,34 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
; This testcase exposes a bug in the local register allocator where it runs out
|
||||
; of registers (due to too many overlapping live ranges), but then attempts to
|
||||
; use the ESP register (which is not allocatable) to hold a value.
|
||||
|
||||
define i32 @main(i32 %A) {
|
||||
; ESP gets used again...
|
||||
%Ap2 = alloca i32, i32 %A ; <i32*> [#uses=11]
|
||||
; Produce lots of overlapping live ranges
|
||||
%B = add i32 %A, 1 ; <i32> [#uses=1]
|
||||
%C = add i32 %A, 2 ; <i32> [#uses=1]
|
||||
%D = add i32 %A, 3 ; <i32> [#uses=1]
|
||||
%E = add i32 %A, 4 ; <i32> [#uses=1]
|
||||
%F = add i32 %A, 5 ; <i32> [#uses=1]
|
||||
%G = add i32 %A, 6 ; <i32> [#uses=1]
|
||||
%H = add i32 %A, 7 ; <i32> [#uses=1]
|
||||
%I = add i32 %A, 8 ; <i32> [#uses=1]
|
||||
%J = add i32 %A, 9 ; <i32> [#uses=1]
|
||||
%K = add i32 %A, 10 ; <i32> [#uses=1]
|
||||
; Uses of all of the values
|
||||
store i32 %A, i32* %Ap2
|
||||
store i32 %B, i32* %Ap2
|
||||
store i32 %C, i32* %Ap2
|
||||
store i32 %D, i32* %Ap2
|
||||
store i32 %E, i32* %Ap2
|
||||
store i32 %F, i32* %Ap2
|
||||
store i32 %G, i32* %Ap2
|
||||
store i32 %H, i32* %Ap2
|
||||
store i32 %I, i32* %Ap2
|
||||
store i32 %J, i32* %Ap2
|
||||
store i32 %K, i32* %Ap2
|
||||
ret i32 0
|
||||
}
|
@ -1,23 +0,0 @@
|
||||
; RUN: %lli %s > /dev/null
|
||||
|
||||
@A = global i32 0 ; <i32*> [#uses=1]
|
||||
|
||||
define i32 @main() {
|
||||
%Ret = call i32 @test( i1 true, i32 0 ) ; <i32> [#uses=1]
|
||||
ret i32 %Ret
|
||||
}
|
||||
|
||||
define i32 @test(i1 %c, i32 %A) {
|
||||
br i1 %c, label %Taken1, label %NotTaken
|
||||
Cont: ; preds = %Taken1, %NotTaken
|
||||
%V = phi i32 [ 0, %NotTaken ], [ sub (i32 ptrtoint (i32* @A to i32), i32 1234), %Taken1 ] ; <i32> [#uses=0]
|
||||
ret i32 0
|
||||
NotTaken: ; preds = %0
|
||||
br label %Cont
|
||||
Taken1: ; preds = %0
|
||||
%B = icmp eq i32 %A, 0 ; <i1> [#uses=1]
|
||||
br i1 %B, label %Cont, label %ExitError
|
||||
ExitError: ; preds = %Taken1
|
||||
ret i32 12
|
||||
}
|
||||
|
@ -1,22 +0,0 @@
|
||||
; PR672
|
||||
; RUN: %lli %s
|
||||
; XFAIL: mcjit-ia32
|
||||
|
||||
define i32 @main() {
|
||||
%f = bitcast i32 (i32, i32*, i32)* @check_tail to i32* ; <i32*> [#uses=1]
|
||||
%res = tail call fastcc i32 @check_tail( i32 10, i32* %f, i32 10 ) ; <i32> [#uses=1]
|
||||
ret i32 %res
|
||||
}
|
||||
|
||||
define fastcc i32 @check_tail(i32 %x, i32* %f, i32 %g) {
|
||||
%tmp1 = icmp sgt i32 %x, 0 ; <i1> [#uses=1]
|
||||
br i1 %tmp1, label %if-then, label %if-else
|
||||
if-then: ; preds = %0
|
||||
%fun_ptr = bitcast i32* %f to i32 (i32, i32*, i32)* ; <i32 (i32, i32*, i32)*> [#uses=1]
|
||||
%arg1 = add i32 %x, -1 ; <i32> [#uses=1]
|
||||
%res = tail call fastcc i32 %fun_ptr( i32 %arg1, i32* %f, i32 %g ) ; <i32> [#uses=1]
|
||||
ret i32 %res
|
||||
if-else: ; preds = %0
|
||||
ret i32 %x
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user