brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.4 KiB · ae04163 Raw
36 lines · plain
1; RUN: opt < %s -force-vector-width=1 -force-vector-interleave=2 -passes=loop-vectorize -S | FileCheck %s2 3target datalayout = "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128"4target triple = "aarch64--linux-gnu"5 6; CHECK-LABEL: @non_primary_iv_trunc_free(7; CHECK:       vector.body:8; CHECK-NEXT:    [[INDEX:%.*]] = phi i64 [ 0, %vector.ph ], [ [[INDEX_NEXT:%.*]], %vector.body ]9; CHECK-NEXT:    [[OFFSET_IDX:%.*]] = mul i64 [[INDEX]], 510; CHECK-NEXT:    [[INDUCTION1:%.*]] = add i64 [[OFFSET_IDX]], 511; CHECK-NEXT:    [[TMP4:%.*]] = trunc i64 [[OFFSET_IDX]] to i3212; CHECK-NEXT:    [[TMP5:%.*]] = trunc i64 [[INDUCTION1]] to i3213; CHECK-NEXT:    [[GEP0:%.+]] = getelementptr inbounds i32, ptr %dst, i32 [[TMP4]]14; CHECK-NEXT:    [[GEP1:%.+]] = getelementptr inbounds i32, ptr %dst, i32 [[TMP5]]15; CHECK-NEXT:    store i32 0, ptr [[GEP0]], align 416; CHECK-NEXT:    store i32 0, ptr [[GEP1]], align 417; CHECK-NEXT:    [[INDEX_NEXT]] = add nuw i64 [[INDEX]], 218; CHECK:         br i1 {{.*}}, label %middle.block, label %vector.body19;20define void @non_primary_iv_trunc_free(i64 %n, ptr %dst) {21entry:22  br label %for.body23 24for.body:25  %i = phi i64 [ %i.next, %for.body ], [ 0, %entry ]26  %tmp0 = trunc i64 %i to i3227  %gep.dst = getelementptr inbounds i32, ptr %dst, i32 %tmp028  store i32 0, ptr %gep.dst29  %i.next = add nuw nsw i64 %i, 530  %cond = icmp slt i64 %i.next, %n31  br i1 %cond, label %for.body, label %for.end32 33for.end:34  ret void35}36