~pali/+junk/llvm-toolchain-3.7

« back to all changes in this revision

Viewing changes to test/Transforms/IndVarSimplify/lftr-zext.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: opt < %s -indvars -S | FileCheck %s
 
2
target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128"
 
3
target triple = "x86_64-apple-macosx10.9.0"
 
4
 
 
5
@data = common global [240 x i8] zeroinitializer, align 16
 
6
 
 
7
define void @foo(i8* %a) nounwind uwtable ssp {
 
8
; CHECK: %exitcond
 
9
; CHECK-NOT: ([240 x i8]* @data, i64 0, i64 -16)
 
10
  br label %1
 
11
 
 
12
; <label>:1                                       ; preds = %0, %1
 
13
  %i.0 = phi i8 [ 0, %0 ], [ %5, %1 ]
 
14
  %p.0 = phi i8* [ getelementptr inbounds ([240 x i8], [240 x i8]* @data, i64 0, i64 0), %0 ], [ %4, %1 ]
 
15
  %.0 = phi i8* [ %a, %0 ], [ %2, %1 ]
 
16
  %2 = getelementptr inbounds i8, i8* %.0, i64 1
 
17
  %3 = load i8, i8* %.0, align 1
 
18
  %4 = getelementptr inbounds i8, i8* %p.0, i64 1
 
19
  store i8 %3, i8* %p.0, align 1
 
20
  %5 = add i8 %i.0, 1
 
21
  %6 = icmp ult i8 %5, -16
 
22
  br i1 %6, label %1, label %7
 
23
 
 
24
; <label>:7                                       ; preds = %1
 
25
  ret void
 
26
}