summaryrefslogtreecommitdiff
path: root/test/Transforms/LICM/basictest.ll
blob: 6458f035c2e5b4ffa30b04a140218dccf33328b5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
; RUN: llvm-upgrade < %s | llvm-as | opt -licm | llvm-dis

void "testfunc"(int %i) {

	br label %Loop

Loop:
	%j = phi uint [0, %0], [%Next, %Loop]
	%i = cast int %i to uint
	%i2 = mul uint %i, 17
	%Next = add uint %j, %i2
	%cond = seteq uint %Next, 0
	br bool %cond, label %Out, label %Loop

Out:
	ret void
}