diff options
Diffstat (limited to 'test/Transforms/IndVarSimplify/ult-sub-to-eq.ll')
-rw-r--r-- | test/Transforms/IndVarSimplify/ult-sub-to-eq.ll | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/test/Transforms/IndVarSimplify/ult-sub-to-eq.ll b/test/Transforms/IndVarSimplify/ult-sub-to-eq.ll index a421003..7272ef1 100644 --- a/test/Transforms/IndVarSimplify/ult-sub-to-eq.ll +++ b/test/Transforms/IndVarSimplify/ult-sub-to-eq.ll @@ -1,5 +1,9 @@ ; RUN: opt -S -indvars < %s | FileCheck %s +; Provide legal integer types. +target datalayout = "n8:16:32:64" + + define void @test1(float* nocapture %autoc, float* nocapture %data, float %d, i32 %data_len, i32 %sample) nounwind { entry: %sub = sub i32 %data_len, %sample @@ -11,11 +15,11 @@ for.body: ; preds = %entry, %for.body %0 = trunc i64 %indvars.iv to i32 %add = add i32 %0, %sample %idxprom = zext i32 %add to i64 - %arrayidx = getelementptr inbounds float* %data, i64 %idxprom - %1 = load float* %arrayidx, align 4 + %arrayidx = getelementptr inbounds float, float* %data, i64 %idxprom + %1 = load float, float* %arrayidx, align 4 %mul = fmul float %1, %d - %arrayidx2 = getelementptr inbounds float* %autoc, i64 %indvars.iv - %2 = load float* %arrayidx2, align 4 + %arrayidx2 = getelementptr inbounds float, float* %autoc, i64 %indvars.iv + %2 = load float, float* %arrayidx2, align 4 %add3 = fadd float %2, %mul store float %add3, float* %arrayidx2, align 4 %indvars.iv.next = add i64 %indvars.iv, 1 |