aboutsummaryrefslogtreecommitdiffstats
path: root/test/Transforms/PiNodeInserter/substitutetest.ll
blob: a08a968ea4bbecb9e3c782dc1c7e8739cc2fdb61 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
; RUN: as < %s | opt -pinodes -instcombine -die | dis | not grep add

int "test"(int %i, int %j) {
	%c = seteq int %i, 0
	br bool %c, label %iIsZero, label %iIsNotZero

iIsZero:
	%j2 = add int %j, %i      ; This is always equal to j
	ret int %j2

iIsNotZero:
	ret int 1
}