New testcase
[oota-llvm.git] / test / Transforms / Mem2Reg / DifferingTypes.ll
1 ; This is a feature test.  Hopefully one day this will be implemented.  The 
2 ; generated code should perform the appropriate masking operations required 
3 ; depending on the endianness of the target...
4
5 ; RUN: if as < %s | opt -mem2reg | dis | grep 'alloca'
6 ; RUN: then exit 1
7 ; RUN: else exit 0
8 ; RUN: fi
9
10 implementation
11
12 int %testfunc(int %i, sbyte %j) {
13         %I = alloca int
14
15         store int %i, int* %I
16
17         %P = cast int* %I to sbyte*
18         store sbyte %j, sbyte* %P
19
20         %t = load int* %I
21         ret int %t
22 }