mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-21 18:29:46 +00:00
Convert -indvars tests that rely on SCEV expansion to -loop-reduce tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@153259 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
f6399a65f0
commit
0c0a3effde
@ -1,13 +1,17 @@
|
||||
; RUN: opt < %s -indvars -S -enable-iv-rewrite | FileCheck %s
|
||||
; CHECK: getelementptr
|
||||
; CHECK: mul {{.*}}, 37
|
||||
; CHECK: add {{.*}}, 5203
|
||||
; RUN: opt < %s -loop-reduce -S | FileCheck %s
|
||||
; CHECK: bb1:
|
||||
; CHECK: load double* [[IV:%[^,]+]]
|
||||
; CHECK: store double {{.*}}, double* [[IV]]
|
||||
; CHECK: getelementptr double*
|
||||
; CHECK-NOT: cast
|
||||
; CHECK: br {{.*}} label %bb1
|
||||
|
||||
; This test tests several things. The load and store should use the
|
||||
; same address instead of having it computed twice, and SCEVExpander should
|
||||
; be able to reconstruct the full getelementptr, despite it having a few
|
||||
; obstacles set in its way.
|
||||
; We only check that the inner loop (bb1-bb2) is "reduced" because LSR
|
||||
; currently only operates on inner loops.
|
||||
|
||||
target datalayout = "e-p:64:64:64-n32:64"
|
||||
|
@ -1,4 +1,4 @@
|
||||
; RUN: opt < %s -indvars -S -enable-iv-rewrite | FileCheck %s
|
||||
; RUN: opt < %s -loop-reduce -S | FileCheck %s
|
||||
; CHECK-NOT: {{inttoptr|ptrtoint}}
|
||||
; CHECK: scevgep
|
||||
; CHECK-NOT: {{inttoptr|ptrtoint}}
|
Loading…
Reference in New Issue
Block a user