Eliminate LegalizeOps' LegalizedNodes map and have it just call RAUW
[oota-llvm.git] / test / CodeGen / CellSPU / jumptable.ll
1 ;RUN: llc --march=cellspu -disable-cgp-branch-opts %s -o - | FileCheck %s
2 ; This is to check that emitting jumptables doesn't crash llc
3 define i32 @test(i32 %param) {
4 entry:
5 ;CHECK:        ai      {{\$.}}, $3, -1
6 ;CHECK:        clgti   {{\$., \$.}}, 3
7 ;CHECK:        brnz    {{\$.}},.LBB0_
8   switch i32 %param, label %bb2 [
9     i32 1, label %bb1
10     i32 2, label %bb2
11     i32 3, label %bb3
12     i32 4, label %bb2
13   ]
14 ;CHECK-NOT: # BB#2
15 bb1:                                            
16   ret i32 1
17 bb2:      
18   ret i32 2
19 bb3:     
20   ret i32 %param
21 }