~ubuntu-branches/ubuntu/quantal/llvm-3.1/quantal

« back to all changes in this revision

Viewing changes to test/CodeGen/CellSPU/jumptable.ll

  • Committer: Package Import Robot
  • Author(s): Sylvestre Ledru
  • Date: 2012-03-29 19:09:51 UTC
  • Revision ID: package-import@ubuntu.com-20120329190951-aq83ivog4cg8bxun
Tags: upstream-3.1~svn153643
ImportĀ upstreamĀ versionĀ 3.1~svn153643

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
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
}