[llvm-commits] CVS: llvm/test/Regression/Analysis/DSGraph/constant_globals.ll

Chris Lattner lattner at cs.uiuc.edu
Wed Feb 25 17:35:01 PST 2004


Changes in directory llvm/test/Regression/Analysis/DSGraph:

constant_globals.ll added (r1.1)

---
Log message:

New testcase


---
Diffs of the changes:  (+22 -0)

Index: llvm/test/Regression/Analysis/DSGraph/constant_globals.ll
diff -c /dev/null llvm/test/Regression/Analysis/DSGraph/constant_globals.ll:1.1
*** /dev/null	Wed Feb 25 17:34:14 2004
--- llvm/test/Regression/Analysis/DSGraph/constant_globals.ll	Wed Feb 25 17:34:04 2004
***************
*** 0 ****
--- 1,22 ----
+ ; RUN: analyze %s -datastructure-gc -dsgc-dspass=bu -dsgc-check-flags=A:SM
+ ; Constant globals should not mark stuff incomplete.  This should allow the 
+ ; bu pass to resolve the indirect call immediately in "test", allowing %A to
+ ; be marked complete and the store to happen.
+ 
+ ; This is the common case for handling vtables aggressively.
+ 
+ %G = constant void (int*)* %foo 
+ 
+ implementation
+ 
+ void %foo(int *%X) {
+   store int 0, int* %X
+   ret void
+ }
+ 
+ void %test() {
+   %Fp = load void (int*)** %G
+   %A = alloca int
+   call void %Fp(int* %A)
+   ret void
+ }





More information about the llvm-commits mailing list