brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.4 KiB · faadce6 Raw
38 lines · plain
1; RUN: opt < %s -passes=loop-vectorize -force-vector-interleave=2 -force-vector-width=1 -S | FileCheck --enable-var-scope %s2 3; Make sure we attach memcheck metadata to scalarized memory operations even if4; we're only unrolling.5 6target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"7 8; CHECK-LABEL: vector.memcheck:9; CHECK-LABEL: vector.body:10; CHECK: load i32, {{.*}} !alias.scope ![[$MD1:[0-9]+]]11; CHECK-LABEL: middle.block:12; CHECK-DAG: ![[$MD1]] = !{![[MD2:[0-9]+]]}13; CHECK-DAG: ![[MD2]] = distinct !{![[MD2]], ![[MD3:[0-9]+]]}14; CHECK-DAG: ![[MD3]] = distinct !{![[MD3]], !"LVerDomain"}15 16; Function Attrs: norecurse nounwind uwtable17define void @test(ptr nocapture readonly %a, ptr nocapture %b) local_unnamed_addr #0 {18entry:19  br label %for.body20 21for.body:                                         ; preds = %for.body, %entry22  %indvars.iv = phi i64 [ 0, %entry ], [ %indvars.iv.next, %for.body ]23  %arrayidx = getelementptr inbounds i32, ptr %a, i64 %indvars.iv24  %l.1 = load i32, ptr %arrayidx, align 425  %arrayidx2 = getelementptr inbounds i32, ptr %b, i64 %indvars.iv26  %l.2 = load i32, ptr %arrayidx227  %add = add nsw i32 %l.1, %l.228  store i32 %add, ptr %arrayidx2, align 429  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 130  %exitcond = icmp eq i64 %indvars.iv.next, 1000031  br i1 %exitcond, label %for.end, label %for.body32 33for.end:                                          ; preds = %for.body34  ret void35}36 37attributes #0 = { norecurse nounwind uwtable }38