~pali/+junk/llvm-toolchain-3.7

« back to all changes in this revision

Viewing changes to test/CodeGen/X86/coalescer-subreg.ll

  • Committer: Package Import Robot
  • Author(s): Sylvestre Ledru
  • Date: 2015-07-15 17:51:08 UTC
  • Revision ID: package-import@ubuntu.com-20150715175108-l8mynwovkx4zx697
Tags: upstream-3.7~+rc2
ImportĀ upstreamĀ versionĀ 3.7~+rc2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
; RUN: llc -o - %s -verify-machineinstrs
 
2
; This used to crash when coalescing a regclass like GR16 which did not support
 
3
; the sub_8bit_hi subregister with a class like GR16_ABCD that did.
 
4
target triple = "x86_64-apple-macosx10.10.0"
 
5
 
 
6
define void @test() #0 {
 
7
entry:
 
8
  br i1 undef, label %loop, label %for.end597
 
9
 
 
10
loop:
 
11
  %0 = load i16, i16* null, align 4
 
12
  %1 = load i16, i16* undef, align 4
 
13
  %or1 = or i16 %1, %0
 
14
  %or2 = trunc i16 %or1 to i8
 
15
  store i8 %or2, i8* undef, align 4
 
16
  %2 = or i16 %1, %0
 
17
  %or3 = lshr i16 %2, 8
 
18
  %or4 = trunc i16 %or3 to i8
 
19
  store i8 %or4, i8* undef, align 1
 
20
  %3 = load i32, i32* undef, align 4
 
21
  %4 = load i32, i32* undef, align 4
 
22
  %or5 = or i32 %4, %3
 
23
  store i32 %or5, i32* undef, align 4
 
24
  store i32 0, i32* undef, align 4
 
25
  br label %loop
 
26
 
 
27
for.end597:
 
28
  ret void
 
29
}