New testcase
[oota-llvm.git] / test / Transforms / PiNodeInserter / substitutetest.ll
1 ; RUN: if as < %s | opt -pinodes -instcombine -die | dis | grep add
2 ; RUN: then exit 1
3 ; RUN: else exit 0
4 ; RUN: fi
5
6 int "test"(int %i, int %j) {
7         %c = seteq int %i, 0
8         br bool %c, label %iIsZero, label %iIsNotZero
9
10 iIsZero:
11         %j2 = add int %j, %i      ; This is always equal to j
12         ret int %j2
13
14 iIsNotZero:
15         ret int 1
16 }