* Build with warnings

* Add a bunch of testcases.

llvm-svn: 3393
This commit is contained in:
Chris Lattner 2002-08-19 23:09:30 +00:00
parent ddd1d61b21
commit 1e0dd6d404
5 changed files with 19 additions and 1 deletions

View File

@ -0,0 +1,5 @@
; Test const pointer refs & forward references
%t3 = global int * %t1 ;; Forward reference
%t1 = global int 4

View File

@ -0,0 +1,7 @@
global int* cast (float* %0 to int*) ;; Forward numeric reference
global float* %0 ;; Duplicate forward numeric reference
global float 0.0
%array = constant [2 x int] [ int 12, int 52 ]
%arrayPtr = global int* getelementptr ([2 x int]* %array, uint 0, uint 0) ;; int* &%array[0][0]

View File

@ -0,0 +1,3 @@
%sptr1 = global [11x sbyte]* %somestr ;; Forward ref to a constant
%somestr = constant [11x sbyte] c"hello world"

View File

@ -0,0 +1,3 @@
%fptr = global void() * %f ;; Forward ref method defn
declare void "f"() ;; External method

View File

@ -15,7 +15,7 @@ all:: $(addprefix Output/, $(TESTS:%.ll=%.to))
Output/%.to: Output/%.c
gcc -c $< -o $@ || \
gcc -c -W -Wall $< -o $@ || \
(rm -f $@; $(FAILURE) $@ )
Output/%.c: %.ll Output/.dir $(LAS) $(LDIS)