Changed all of these tests to be TestRunner tests (or, at least they can be
[oota-llvm.git] / test / Transforms / DSAnalysis / arraymerge.ll
1 ; This testcase is used to make sure that the outer element of arrays are 
2 ; folded completely away if possible.  This is a very common case, so it should
3 ; be efficient.
4 ;
5 ; RUN: analyze %s -tddatastructure
6 ;
7 implementation
8
9 sbyte* %merge1([100 x sbyte] *%A, long %N) {
10         %P = getelementptr [100 x sbyte] *%A, long 0, long %N
11         ret sbyte* %P
12 }
13
14 sbyte* %merge2([100 x sbyte] *%A, long %N) {
15         ; The graph for this example should end up exactly the same as for merge1
16         %P1 = getelementptr [100 x sbyte] *%A, long 0, long 0
17         %P2 = getelementptr sbyte* %P1, long %N
18         ret sbyte* %P2
19 }
20