mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-27 13:30:05 +00:00
Checkin of autoconf-style object root.
Updated TestRunner tests so that they work correctly in a separate object root directory. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8383 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ee29d2aa20
commit
e3e7c474f2
@ -5,9 +5,9 @@
|
||||
; of the bug that was causing the Olden Health benchmark to output incorrect
|
||||
; results!
|
||||
;
|
||||
; RUN: as < %s | opt -constprop | dis > Output/%s && \
|
||||
; RUN: as < %s | dis | as | opt -constprop | dis > Output/%s2 && \
|
||||
; RUN: diff Output/%s Output/%s2
|
||||
; RUN: as < %s | opt -constprop | dis > s1 && \
|
||||
; RUN: as < %s | dis | as | opt -constprop | dis > s2 && \
|
||||
; RUN: diff s1 s2
|
||||
|
||||
implementation
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
|
||||
; RUN: as < %s | dis -c > Output/%s.cbe.c
|
||||
; RUN: gcc -B/usr/bin/ Output/%s.cbe.c -o Output/%s.cbe
|
||||
; RUN: Output/%s.cbe
|
||||
; RUN: as < %s | dis -c > f1.cbe.c
|
||||
; RUN: gcc -B/usr/bin/ f1.cbe.c -o f1.cbe
|
||||
; RUN: ./f1.cbe
|
||||
|
||||
bool %doTest(ubyte %x) {
|
||||
%dec.0 = add ubyte %x, 255
|
||||
|
@ -1,7 +1,7 @@
|
||||
|
||||
; RUN: as < %s | dis -c > Output/%s.cbe.c
|
||||
; RUN: gcc -B/usr/bin/ Output/%s.cbe.c -o Output/%s.cbe
|
||||
; RUN: Output/%s.cbe
|
||||
; RUN: as < %s | dis -c > f1.cbe.c
|
||||
; RUN: gcc -B/usr/bin/ f1.cbe.c -o f1.cbe
|
||||
; RUN: ./f1.cbe
|
||||
|
||||
bool %doTest(ubyte %x) {
|
||||
%dec.0 = add ubyte %x, 255
|
||||
|
@ -1,6 +1,6 @@
|
||||
; RUN: as < %s > Output/%s.bc
|
||||
; RUN: echo | as > Output/%s.tmp.bc
|
||||
; RUN: link Output/%s.tmp.bc Output/%s.bc
|
||||
; RUN: as < %s > %t.bc
|
||||
; RUN: echo | as > %t.tmp.bc
|
||||
; RUN: link %t.tmp.bc %t.bc
|
||||
|
||||
%X = constant int 5
|
||||
%Y = internal global [2 x int*] [ int* %X, int * %X]
|
||||
|
@ -1,8 +1,8 @@
|
||||
; This fails linking when it is linked with an empty file as the first object file
|
||||
|
||||
; RUN: as > Output/LinkTest1.bc < /dev/null
|
||||
; RUN: as < %s > Output/LinkTest2.bc
|
||||
; RUN: link Output/LinkTest[12].bc
|
||||
; RUN: as > %t1.bc < /dev/null
|
||||
; RUN: as < %s > %t2.bc
|
||||
; RUN: link %t[12].bc
|
||||
|
||||
%work = global int (int, int)* %zip
|
||||
|
||||
|
@ -1,8 +1,8 @@
|
||||
; This fails linking when it is linked with an empty file as the first object file
|
||||
|
||||
; RUN: as > Output/%s.LinkTest.bc < /dev/null
|
||||
; RUN: as < %s > Output/%s.bc
|
||||
; RUN: link Output/%s.LinkTest.bc Output/%s.bc
|
||||
; RUN: as > %t.LinkTest.bc < /dev/null
|
||||
; RUN: as < %s > %t.bc
|
||||
; RUN: link %t.LinkTest.bc %t.bc
|
||||
|
||||
%work = global int 4
|
||||
%test = global int* getelementptr( int* %work, long 1)
|
||||
|
@ -1,9 +1,9 @@
|
||||
; This fails because the linker renames the external symbol not the internal
|
||||
; one...
|
||||
|
||||
; RUN: echo "implementation internal int %foo() { ret int 7 }" | as > Output/%s.1.bc
|
||||
; RUN: as < %s > Output/%s.2.bc
|
||||
; RUN: link Output/%s.[12].bc | dis | grep '%foo()' | grep -v internal
|
||||
; RUN: echo "implementation internal int %foo() { ret int 7 }" | as > %t.1.bc
|
||||
; RUN: as < %s > %t.2.bc
|
||||
; RUN: link %t.[12].bc | dis | grep '%foo()' | grep -v internal
|
||||
|
||||
implementation
|
||||
int %foo() { ret int 0 }
|
||||
|
@ -1,9 +1,9 @@
|
||||
; This fails because the linker renames the non-opaque type not the opaque
|
||||
; one...
|
||||
|
||||
; RUN: echo "%Ty = type opaque" | as > Output/%s.1.bc
|
||||
; RUN: as < %s > Output/%s.2.bc
|
||||
; RUN: link Output/%s.[12].bc | dis | grep '%Ty ' | grep -v opaque
|
||||
; RUN: echo "%Ty = type opaque" | as > %t.1.bc
|
||||
; RUN: as < %s > %t.2.bc
|
||||
; RUN: link %t.[12].bc | dis | grep '%Ty ' | grep -v opaque
|
||||
|
||||
%Ty = type int
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
; RUN: echo "%X = linkonce global int 5 implementation linkonce int %foo() { ret int 7 }" | as > Output/%s.1.bc
|
||||
; RUN: as < %s > Output/%s.2.bc
|
||||
; RUN: link Output/%s.[12].bc
|
||||
; RUN: echo "%X = linkonce global int 5 implementation linkonce int %foo() { ret int 7 }" | as > %t.1.bc
|
||||
; RUN: as < %s > %t.2.bc
|
||||
; RUN: link %t.[12].bc
|
||||
%X = external global int
|
||||
|
||||
implementation
|
||||
|
@ -1,8 +1,8 @@
|
||||
; This fails because the linker renames the non-opaque type not the opaque
|
||||
; one...
|
||||
|
||||
; RUN: echo "implementation linkonce void %foo() { ret void } " | as > Output/%s.2.bc
|
||||
; RUN: as < %s > Output/%s.1.bc
|
||||
; RUN: link Output/%s.[12].bc | dis | grep foo | grep linkonce
|
||||
; RUN: echo "implementation linkonce void %foo() { ret void } " | as > %t.2.bc
|
||||
; RUN: as < %s > %t.1.bc
|
||||
; RUN: link %t.[12].bc | dis | grep foo | grep linkonce
|
||||
|
||||
declare void %foo()
|
||||
|
@ -1,9 +1,9 @@
|
||||
; This one fails because the LLVM runtime is allowing two null pointers of
|
||||
; the same type to be created!
|
||||
|
||||
; RUN: echo "%T = type int" | as > Output/%s.2.bc
|
||||
; RUN: as < %s > Output/%s.1.bc
|
||||
; RUN: link Output/%s.[12].bc
|
||||
; RUN: echo "%T = type int" | as > %t.2.bc
|
||||
; RUN: as < %s > %t.1.bc
|
||||
; RUN: link %t.[12].bc
|
||||
|
||||
%T = type opaque
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
; This one fails because the LLVM runtime is allowing two null pointers of
|
||||
; the same type to be created!
|
||||
|
||||
; RUN: echo "%S = type { %T*} %T = type opaque" | as > Output/%s.2.bc
|
||||
; RUN: as < %s > Output/%s.1.bc
|
||||
; RUN: link Output/%s.[12].bc
|
||||
; RUN: echo "%S = type { %T*} %T = type opaque" | as > %t.2.bc
|
||||
; RUN: as < %s > %t.1.bc
|
||||
; RUN: link %t.[12].bc
|
||||
|
||||
%S = type { %T* }
|
||||
%T = type int
|
||||
|
@ -3,9 +3,9 @@
|
||||
; a program that already has an external declaration for the function name, we must
|
||||
; rename the internal function to something that does not conflict.
|
||||
|
||||
; RUN: echo "implementation internal int %foo() { ret int 7 }" | as > Output/%s.1.bc
|
||||
; RUN: as < %s > Output/%s.2.bc
|
||||
; RUN: link Output/%s.[12].bc | dis | grep 'internal' | not grep '%foo('
|
||||
; RUN: echo "implementation internal int %foo() { ret int 7 }" | as > %t.1.bc
|
||||
; RUN: as < %s > %t.2.bc
|
||||
; RUN: link %t.[12].bc | dis | grep 'internal' | not grep '%foo('
|
||||
|
||||
implementation
|
||||
declare int %foo()
|
||||
|
@ -1,6 +1,6 @@
|
||||
; RUN: echo "%T = type opaque" | as > Output/%s.2.bc
|
||||
; RUN: as < %s > Output/%s.1.bc
|
||||
; RUN: link Output/%s.[12].bc
|
||||
; RUN: echo "%T = type opaque" | as > %t.2.bc
|
||||
; RUN: as < %s > %t.1.bc
|
||||
; RUN: link %t.[12].bc
|
||||
|
||||
%T = type opaque
|
||||
%a = constant { %T* } { %T* null }
|
||||
|
@ -1,6 +1,6 @@
|
||||
; RUN: echo "%T = type int" | as > Output/%s.1.bc
|
||||
; RUN: as < %s > Output/%s.2.bc
|
||||
; RUN: link Output/%s.[12].bc
|
||||
; RUN: echo "%T = type int" | as > %t.1.bc
|
||||
; RUN: as < %s > %t.2.bc
|
||||
; RUN: link %t.[12].bc
|
||||
|
||||
%T = type opaque
|
||||
|
||||
|
@ -1,8 +1,8 @@
|
||||
; Test that appending linkage works correctly.
|
||||
|
||||
; RUN: echo "%X = appending global [1x int] [int 8]" | as > Output/%s.2.bc
|
||||
; RUN: as < %s > Output/%s.1.bc
|
||||
; RUN: link Output/%s.[12].bc | dis | grep 7 | grep 4 | grep 8
|
||||
; RUN: echo "%X = appending global [1x int] [int 8]" | as > %t.2.bc
|
||||
; RUN: as < %s > %t.1.bc
|
||||
; RUN: link %t.[12].bc | dis | grep 7 | grep 4 | grep 8
|
||||
|
||||
%X = appending global [2 x int] [int 7, int 4]
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
; Test that appending linkage works correctly when arrays are the same size.
|
||||
|
||||
; RUN: echo "%X = appending global [1x int] [int 8]" | as > Output/%s.2.bc
|
||||
; RUN: as < %s > Output/%s.1.bc
|
||||
; RUN: link Output/%s.[12].bc | dis | grep 7 | grep 8
|
||||
; RUN: echo "%X = appending global [1x int] [int 8]" | as > %t.2.bc
|
||||
; RUN: as < %s > %t.1.bc
|
||||
; RUN: link %t.[12].bc | dis | grep 7 | grep 8
|
||||
|
||||
%X = appending global [1 x int] [int 7]
|
||||
|
@ -1,8 +1,8 @@
|
||||
; This fails because the linker renames the non-opaque type not the opaque
|
||||
; one...
|
||||
|
||||
; RUN: echo "%X = linkonce global int 8" | as > Output/%s.2.bc
|
||||
; RUN: as < %s > Output/%s.1.bc
|
||||
; RUN: link Output/%s.[12].bc | dis
|
||||
; RUN: echo "%X = linkonce global int 8" | as > %t.2.bc
|
||||
; RUN: as < %s > %t.1.bc
|
||||
; RUN: link %t.[12].bc | dis
|
||||
|
||||
%X = linkonce global int 7
|
||||
|
@ -1,6 +1,6 @@
|
||||
; RUN: as < %s > Output/%s.bc
|
||||
; RUN: as < testlink2.ll > Output/testlink2.bc
|
||||
; RUN: link Output/%s.bc Output/testlink2.bc
|
||||
; RUN: as < %s > %t.bc
|
||||
; RUN: as < `dirname %s`/testlink2.ll > %t2.bc
|
||||
; RUN: link %t.bc %t2.bc
|
||||
|
||||
%MyVar = external global int
|
||||
%MyIntList = global { \2 *, int } { { \2, int }* null, int 17 }
|
||||
|
Loading…
Reference in New Issue
Block a user