Mercurial > hg > CbC > CbC_llvm
comparison test/Transforms/ADCE/2002-05-28-Crash-distilled.ll @ 121:803732b1fca8
LLVM 5.0
author | kono |
---|---|
date | Fri, 27 Oct 2017 17:07:41 +0900 |
parents | 95c75e76d11b |
children |
comparison
equal
deleted
inserted
replaced
120:1172e4bd9c6f | 121:803732b1fca8 |
---|---|
1 ; This testcase is a distilled form of: 2002-05-28-Crash.ll | 1 ; This testcase is a distilled form of: 2002-05-28-Crash.ll |
2 | 2 |
3 ; RUN: opt < %s -adce | 3 ; RUN: opt < %s -adce |
4 ; RUN: opt < %s -adce -adce-remove-loops -S | FileCheck %s | |
4 | 5 |
5 define float @test(i32 %i) { | 6 define float @test(i32 %i) { |
6 %F = sitofp i32 %i to float ; <float> [#uses=1] | 7 %F = sitofp i32 %i to float ; <float> [#uses=1] |
7 %I = bitcast i32 %i to i32 ; <i32> [#uses=1] | 8 %I = bitcast i32 %i to i32 ; <i32> [#uses=1] |
8 br label %Loop | 9 br label %Loop |
9 | 10 |
10 Loop: ; preds = %Loop, %0 | 11 Loop: ; preds = %Loop, %0 |
11 %B = icmp ne i32 %I, 0 ; <i1> [#uses=1] | 12 %B = icmp ne i32 %I, 0 ; <i1> [#uses=1] |
13 ; CHECK: br label %Out | |
12 br i1 %B, label %Out, label %Loop | 14 br i1 %B, label %Out, label %Loop |
13 | 15 |
14 Out: ; preds = %Loop | 16 Out: ; preds = %Loop |
15 ret float %F | 17 ret float %F |
16 } | 18 } |