Benjamin Kramer | ce750f0 | 2010-11-22 09:45:38 +0000 | [diff] [blame] | 1 | ; RUN: llc -march=x86 -asm-verbose=false < %s | FileCheck %s |
2 | |||||
3 | ; Check that merging switch cases that differ in one bit works. | ||||
4 | ; CHECK: orl $2 | ||||
5 | ; CHECK-NEXT: cmpl $6 | ||||
6 | |||||
7 | define void @foo(i32 %variable) nounwind { | ||||
8 | entry: | ||||
9 | switch i32 %variable, label %if.end [ | ||||
10 | i32 4, label %if.then | ||||
11 | i32 6, label %if.then | ||||
12 | ] | ||||
13 | |||||
14 | if.then: | ||||
15 | %call = tail call i32 (...)* @bar() nounwind | ||||
16 | ret void | ||||
17 | |||||
18 | if.end: | ||||
19 | ret void | ||||
20 | } | ||||
21 | |||||
22 | declare i32 @bar(...) nounwind |