aboutsummaryrefslogtreecommitdiffstats
path: root/test/Transforms/ADCE/2002-05-28-Crash-distilled.ll
blob: 0d5adf907f1f828f43193bb9688ac87d95438884 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
; This testcase is a distilled form of: 2002-05-28-Crash.ll

; RUN: llvm-upgrade < %s | llvm-as | opt -adce 

float "test"(int %i) {
	%F = cast int %i to float    ; This BB is not dead
	%I = cast int %i to uint     ; future dead inst
	br label %Loop

Loop:                                ; This block is dead
	%B = cast uint %I to bool
	br bool %B, label %Out, label %Loop

Out:
	ret float %F
}