summaryrefslogtreecommitdiff
path: root/test/Transforms/SimplifyCFG/2002-09-24-PHIAssertion.ll
blob: b3c94859ef8ffc639d588cde3c2f2d4702de22a2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
; RUN: llvm-as < %s | opt -simplifycfg

int %test(int %A, int %B, bool %cond) {
J:
	%C = add int %A, 12
	br bool %cond, label %L, label %L
L:
	%Q = phi int [%C, %J], [%C, %J]  ; PHI node is obviously redundant
	%D = add int %C, %B
	%E = add int %Q, %D
	ret int %E
}