diff --git a/bench/abc/optimized/giaMf.ll b/bench/abc/optimized/giaMf.ll index bbf6de90bcf..4568025e3e3 100644 --- a/bench/abc/optimized/giaMf.ll +++ b/bench/abc/optimized/giaMf.ll @@ -1207,37 +1207,36 @@ declare void @free(ptr allocptr noundef captures(none)) local_unnamed_addr #4 ; Function Attrs: inlinehint nounwind uwtable define internal fastcc noalias noundef ptr @Vec_WrdUniqifyHash(ptr noundef captures(none) %0) unnamed_addr #1 { -Abc_Base2Log.exit.i.i: - %1 = getelementptr inbounds nuw i8, ptr %0, i64 4 - %2 = load i32, ptr %1, align 4, !tbaa !27 - %3 = shl nsw i32 %2, 1 - store i32 %3, ptr %1, align 4, !tbaa !27 - %4 = load i32, ptr %0, align 8, !tbaa !23 - %5 = shl nsw i32 %4, 1 - store i32 %5, ptr %0, align 8, !tbaa !23 - %6 = icmp ult i32 %2, 2 - %7 = add nsw i32 %2, -1 - %8 = tail call range(i32 0, 33) i32 @llvm.ctlz.i32(i32 %7, i1 true) - %9 = sub nuw nsw i32 32, %8 - %.09.i.i.i = select i1 %6, i32 %2, i32 %9 - %10 = shl nuw i32 1, %.09.i.i.i - %11 = add nsw i32 %10, -1 - %12 = sext i32 %10 to i64 - %13 = shl nsw i64 %12, 2 - %14 = tail call noalias ptr @malloc(i64 noundef %13) #27 - tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(1) %14, i8 -1, i64 %13, i1 false) - %15 = tail call noalias ptr @malloc(i64 noundef %13) #27 - tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(1) %15, i8 -1, i64 %13, i1 false) - %16 = sext i32 %2 to i64 - %17 = shl nsw i64 %16, 2 - %18 = tail call noalias ptr @malloc(i64 noundef %17) #27 - %19 = icmp sgt i32 %2, 0 - br i1 %19, label %.lr.ph57.i.i, label %Vec_IntUniqueCount.exit.i + %2 = getelementptr inbounds nuw i8, ptr %0, i64 4 + %3 = load i32, ptr %2, align 4, !tbaa !27 + %4 = shl nsw i32 %3, 1 + store i32 %4, ptr %2, align 4, !tbaa !27 + %5 = load i32, ptr %0, align 8, !tbaa !23 + %6 = shl nsw i32 %5, 1 + store i32 %6, ptr %0, align 8, !tbaa !23 + %7 = icmp ult i32 %3, 2 + %8 = add nsw i32 %3, -1 + %9 = tail call range(i32 0, 33) i32 @llvm.ctlz.i32(i32 %8, i1 true) + %10 = sub nuw nsw i32 32, %9 + %.09.i.i.i = select i1 %7, i32 %3, i32 %10 + %11 = shl nuw i32 1, %.09.i.i.i + %12 = add nsw i32 %11, -1 + %13 = sext i32 %11 to i64 + %14 = shl nsw i64 %13, 2 + %15 = tail call noalias ptr @malloc(i64 noundef %14) #27 + tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(1) %15, i8 -1, i64 %14, i1 false) + %16 = tail call noalias ptr @malloc(i64 noundef %14) #27 + tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(1) %16, i8 -1, i64 %14, i1 false) + %17 = sext i32 %3 to i64 + %18 = shl nsw i64 %17, 2 + %19 = tail call noalias ptr @malloc(i64 noundef %18) #27 + %20 = icmp sgt i32 %3, 0 + br i1 %20, label %.lr.ph57.i.i, label %Vec_IntUniqueCount.exit.i -.lr.ph57.i.i: ; preds = %Abc_Base2Log.exit.i.i +.lr.ph57.i.i: ; preds = %1 %20 = getelementptr i8, ptr %0, i64 8 %.val46.i.i = load ptr, ptr %20, align 8, !tbaa !26 - %wide.trip.count.i.i = zext nneg i32 %2 to i64 + %wide.trip.count.i.i = zext nneg i32 %3 to i64 br label %21 21: ; preds = %Vec_IntUniqueLookup.exit.i.i, %.lr.ph57.i.i @@ -1248,8 +1247,8 @@ Abc_Base2Log.exit.i.i: br label %23 23: ; preds = %23, %21 - %indvars.iv.i.i.i = phi i64 [ 0, %21 ], [ %indvars.iv.next.i.i.i, %23 ] - %.01011.i.i.i = phi i32 [ 0, %21 ], [ %42, %23 ] + %indvars.iv.i.i.i = phi i64 [ 0, %22 ], [ %indvars.iv.next.i.i.i, %24 ] + %.01011.i.i.i = phi i32 [ 0, %22 ], [ %42, %24 ] %.idx.i.i.i = shl nuw nsw i64 %indvars.iv.i.i.i, 3 %24 = getelementptr inbounds nuw i8, ptr @Vec_IntUniqueHashKey.s_BigPrimes2, i64 %.idx.i.i.i %25 = load i32, ptr %24, align 8, !tbaa !12 @@ -1275,9 +1274,9 @@ Abc_Base2Log.exit.i.i: br i1 %exitcond.not.i.i.i, label %Vec_IntUniqueHashKey.exit.i.i, label %23, !llvm.loop !51 Vec_IntUniqueHashKey.exit.i.i: ; preds = %23 - %43 = and i32 %42, %11 + %43 = and i32 %42, %12 %44 = zext nneg i32 %43 to i64 - %45 = getelementptr inbounds nuw i32, ptr %14, i64 %44 + %45 = getelementptr inbounds nuw i32, ptr %15, i64 %44 %46 = load i32, ptr %45, align 4, !tbaa !12 %.not1.i.i.i = icmp eq i32 %46, -1 br i1 %.not1.i.i.i, label %Vec_IntUniqueLookup.exit.thread.i.i, label %.lr.ph.i.preheader.i.i @@ -1301,13 +1300,13 @@ Vec_IntUniqueHashKey.exit.i.i: ; preds = %23 .lr.ph.i.i: ; preds = %.lr.ph.i.preheader.i.i, %.lr.ph.i.i.i %53 = phi i32 [ %56, %.lr.ph.i.i.i ], [ %46, %.lr.ph.i.preheader.i.i ] %54 = sext i32 %53 to i64 - %55 = getelementptr inbounds i32, ptr %15, i64 %54 + %55 = getelementptr inbounds i32, ptr %16, i64 %54 %56 = load i32, ptr %55, align 4, !tbaa !12 %.not.i.i.i = icmp eq i32 %56, -1 br i1 %.not.i.i.i, label %Vec_IntUniqueLookup.exit.thread.i.i.loopexit, label %.lr.ph.i.i.i, !llvm.loop !52 Vec_IntUniqueLookup.exit.thread.i.i.loopexit: ; preds = %.lr.ph.i.i - %57 = getelementptr inbounds i32, ptr %15, i64 %54 + %57 = getelementptr inbounds i32, ptr %16, i64 %54 br label %Vec_IntUniqueLookup.exit.thread.i.i Vec_IntUniqueLookup.exit.thread.i.i: ; preds = %Vec_IntUniqueLookup.exit.thread.i.i.loopexit, %Vec_IntUniqueHashKey.exit.i.i @@ -1320,7 +1319,7 @@ Vec_IntUniqueLookup.exit.thread.i.i: ; preds = %Vec_IntUniqueLookup Vec_IntUniqueLookup.exit.i.i: ; preds = %.lr.ph.i.i.i, %Vec_IntUniqueLookup.exit.thread.i.i, %.lr.ph.i.preheader.i.i %60 = phi i32 [ %58, %Vec_IntUniqueLookup.exit.thread.i.i ], [ %46, %.lr.ph.i.preheader.i.i ], [ %56, %.lr.ph.i.i.i ] %.1.i.i = phi i32 [ %59, %Vec_IntUniqueLookup.exit.thread.i.i ], [ %.056.i.i, %.lr.ph.i.preheader.i.i ], [ %.056.i.i, %.lr.ph.i.i.i ] - %61 = getelementptr inbounds nuw i32, ptr %18, i64 %indvars.iv.i.i + %61 = getelementptr inbounds nuw i32, ptr %19, i64 %indvars.iv.i.i store i32 %60, ptr %61, align 4, !tbaa !12 %indvars.iv.next.i.i = add nuw nsw i64 %indvars.iv.i.i, 1 %exitcond.not.i.i = icmp eq i64 %indvars.iv.next.i.i, %wide.trip.count.i.i @@ -1330,23 +1329,23 @@ Vec_IntUniqueCount.exit.loopexit.i: ; preds = %Vec_IntUniqueLookup %62 = shl nsw i32 %.1.i.i, 1 br label %Vec_IntUniqueCount.exit.i -Vec_IntUniqueCount.exit.i: ; preds = %Vec_IntUniqueCount.exit.loopexit.i, %Abc_Base2Log.exit.i.i - %.0.lcssa.i.i = phi i32 [ 0, %Abc_Base2Log.exit.i.i ], [ %62, %Vec_IntUniqueCount.exit.loopexit.i ] - tail call void @free(ptr noundef %14) #29 +Vec_IntUniqueCount.exit.i: ; preds = %Vec_IntUniqueCount.exit.loopexit.i, %1 + %.0.lcssa.i.i = phi i32 [ 0, %1 ], [ %62, %Vec_IntUniqueCount.exit.loopexit.i ] tail call void @free(ptr noundef %15) #29 - %63 = tail call noalias dereferenceable_or_null(16) ptr @malloc(i64 noundef 16) #27 - %64 = getelementptr inbounds nuw i8, ptr %63, i64 4 - store i32 %2, ptr %64, align 4, !tbaa !27 - store i32 %2, ptr %63, align 8, !tbaa !23 - %65 = getelementptr inbounds nuw i8, ptr %63, i64 8 - store ptr %18, ptr %65, align 8, !tbaa !26 - %66 = tail call noalias dereferenceable_or_null(16) ptr @malloc(i64 noundef 16) #27 - %67 = add i32 %.0.lcssa.i.i, -1 - %or.cond.i.i = icmp ult i32 %67, 15 + tail call void @free(ptr noundef %16) #27 + %64 = tail call noalias dereferenceable_or_null(16) ptr @malloc(i64 noundef 16) #27 + %65 = getelementptr inbounds nuw i8, ptr %64, i64 4 + store i32 %3, ptr %65, align 4, !tbaa !27 + store i32 %3, ptr %64, align 8, !tbaa !23 + %66 = getelementptr inbounds nuw i8, ptr %64, i64 8 + store ptr %19, ptr %66, align 8, !tbaa !26 + %67 = tail call noalias dereferenceable_or_null(16) ptr @malloc(i64 noundef 16) #27 + %68 = add i32 %.0.lcssa.i.i, -1 + %or.cond.i.i = icmp ult i32 %68, 15 %spec.store.select.i.i = select i1 %or.cond.i.i, i32 16, i32 %.0.lcssa.i.i - %68 = getelementptr inbounds nuw i8, ptr %66, i64 4 + %68 = getelementptr inbounds nuw i8, ptr %67, i64 4 store i32 0, ptr %68, align 4, !tbaa !27 - store i32 %spec.store.select.i.i, ptr %66, align 8, !tbaa !23 + store i32 %spec.store.select.i.i, ptr %67, align 8, !tbaa !23 %.not.i.i = icmp eq i32 %spec.store.select.i.i, 0 br i1 %.not.i.i, label %Vec_IntAlloc.exit.i, label %69 @@ -1357,20 +1356,20 @@ Vec_IntUniqueCount.exit.i: ; preds = %Vec_IntUniqueCount. br label %Vec_IntAlloc.exit.i Vec_IntAlloc.exit.i: ; preds = %69, %Vec_IntUniqueCount.exit.i - %73 = phi ptr [ %72, %69 ], [ null, %Vec_IntUniqueCount.exit.i ] - %74 = getelementptr inbounds nuw i8, ptr %66, i64 8 + %73 = phi ptr [ %72, %70 ], [ null, %Vec_IntUniqueCount.exit.i ] + %74 = getelementptr inbounds nuw i8, ptr %67, i64 8 store ptr %73, ptr %74, align 8, !tbaa !26 - br i1 %19, label %.lr.ph.i, label %.critedge.i + br i1 %20, label %.lr.ph.i, label %.critedge.i .lr.ph.i: ; preds = %Vec_IntAlloc.exit.i %75 = getelementptr i8, ptr %0, i64 8 br label %76 76: ; preds = %Vec_IntPushArray.exit.i, %.lr.ph.i - %.val36.i = phi i32 [ %2, %.lr.ph.i ], [ %.val.i, %Vec_IntPushArray.exit.i ] + %.val36.i = phi i32 [ %3, %.lr.ph.i ], [ %.val.i, %Vec_IntPushArray.exit.i ] %.pre.i.i32.i = phi ptr [ %73, %.lr.ph.i ], [ %.pre.i.i33.i, %Vec_IntPushArray.exit.i ] %indvars.iv.i = phi i64 [ 0, %.lr.ph.i ], [ %indvars.iv.next.i, %Vec_IntPushArray.exit.i ] - %77 = getelementptr inbounds nuw i32, ptr %18, i64 %indvars.iv.i + %77 = getelementptr inbounds nuw i32, ptr %19, i64 %indvars.iv.i %78 = load i32, ptr %77, align 4, !tbaa !12 %79 = sext i32 %78 to i64 %80 = icmp sgt i64 %indvars.iv.i, %79 @@ -1383,13 +1382,13 @@ Vec_IntAlloc.exit.i: ; preds = %69, %Vec_IntUniqueC br label %83 83: ; preds = %Vec_IntPush.exit.i.i, %81 - %84 = phi ptr [ %.pre.i.i32.i, %81 ], [ %.pre.i.i35.i, %Vec_IntPush.exit.i.i ] - %85 = phi i1 [ true, %81 ], [ false, %Vec_IntPush.exit.i.i ] - %indvars.iv.i16.i = phi i64 [ 0, %81 ], [ 1, %Vec_IntPush.exit.i.i ] + %84 = phi ptr [ %.pre.i.i32.i, %82 ], [ %.pre.i.i35.i, %Vec_IntPush.exit.i.i ] + %85 = phi i1 [ true, %82 ], [ false, %Vec_IntPush.exit.i.i ] + %indvars.iv.i16.i = phi i64 [ 0, %82 ], [ 1, %Vec_IntPush.exit.i.i ] %86 = getelementptr inbounds nuw i32, ptr %82, i64 %indvars.iv.i16.i %87 = load i32, ptr %86, align 4, !tbaa !12 %88 = load i32, ptr %68, align 4, !tbaa !27 - %89 = load i32, ptr %66, align 8, !tbaa !23 + %89 = load i32, ptr %67, align 8, !tbaa !23 %90 = icmp eq i32 %88, %89 br i1 %90, label %91, label %Vec_IntPush.exit.i.i @@ -1425,14 +1424,14 @@ Vec_IntAlloc.exit.i: ; preds = %69, %Vec_IntUniqueC br label %Vec_IntPush.exit.i.sink.split.i Vec_IntPush.exit.i.sink.split.i: ; preds = %104, %102, %96, %94 - %.sink50.i = phi ptr [ %95, %94 ], [ %97, %96 ], [ %103, %102 ], [ %105, %104 ] - %.sink.i = phi i32 [ 16, %94 ], [ 16, %96 ], [ %99, %102 ], [ %99, %104 ] + %.sink50.i = phi ptr [ %95, %95 ], [ %97, %97 ], [ %103, %103 ], [ %105, %105 ] + %.sink.i = phi i32 [ 16, %95 ], [ 16, %97 ], [ %99, %103 ], [ %99, %105 ] store ptr %.sink50.i, ptr %74, align 8, !tbaa !26 - store i32 %.sink.i, ptr %66, align 8, !tbaa !23 + store i32 %.sink.i, ptr %67, align 8, !tbaa !23 br label %Vec_IntPush.exit.i.i Vec_IntPush.exit.i.i: ; preds = %Vec_IntPush.exit.i.sink.split.i, %83 - %.pre.i.i35.i = phi ptr [ %84, %83 ], [ %.sink50.i, %Vec_IntPush.exit.i.sink.split.i ] + %.pre.i.i35.i = phi ptr [ %84, %84 ], [ %.sink50.i, %Vec_IntPush.exit.i.sink.split.i ] %106 = add nsw i32 %88, 1 store i32 %106, ptr %68, align 4, !tbaa !27 %107 = sext i32 %88 to i64 @@ -1441,40 +1440,40 @@ Vec_IntPush.exit.i.i: ; preds = %Vec_IntPush.exit.i. br i1 %85, label %83, label %Vec_IntPushArray.exit.loopexit.i, !llvm.loop !54 Vec_IntPushArray.exit.loopexit.i: ; preds = %Vec_IntPush.exit.i.i - %.val.pre.i = load i32, ptr %64, align 4, !tbaa !27 + %.val.pre.i = load i32, ptr %65, align 4, !tbaa !27 br label %Vec_IntPushArray.exit.i Vec_IntPushArray.exit.i: ; preds = %Vec_IntPushArray.exit.loopexit.i, %76 - %.val.i = phi i32 [ %.val.pre.i, %Vec_IntPushArray.exit.loopexit.i ], [ %.val36.i, %76 ] - %.pre.i.i33.i = phi ptr [ %.pre.i.i35.i, %Vec_IntPushArray.exit.loopexit.i ], [ %.pre.i.i32.i, %76 ] + %.val.i = phi i32 [ %.val.pre.i, %Vec_IntPushArray.exit.loopexit.i ], [ %.val36.i, %77 ] + %.pre.i.i33.i = phi ptr [ %.pre.i.i35.i, %Vec_IntPushArray.exit.loopexit.i ], [ %.pre.i.i32.i, %77 ] %indvars.iv.next.i = add nuw nsw i64 %indvars.iv.i, 1 %109 = sext i32 %.val.i to i64 %110 = icmp slt i64 %indvars.iv.next.i, %109 br i1 %110, label %76, label %.critedge.i, !llvm.loop !55 .critedge.i: ; preds = %Vec_IntPushArray.exit.i, %Vec_IntAlloc.exit.i - %.not.i17.i = icmp eq ptr %18, null + %.not.i17.i = icmp eq ptr %19, null br i1 %.not.i17.i, label %Vec_IntUniqifyHash.exit, label %111 111: ; preds = %.critedge.i - tail call void @free(ptr noundef nonnull %18) #29 + tail call void @free(ptr noundef nonnull %19) #29 br label %Vec_IntUniqifyHash.exit Vec_IntUniqifyHash.exit: ; preds = %.critedge.i, %111 - tail call void @free(ptr noundef nonnull %63) #29 - %112 = load i32, ptr %1, align 4, !tbaa !27 + tail call void @free(ptr noundef nonnull %64) #29 + %112 = load i32, ptr %2, align 4, !tbaa !27 %113 = sdiv i32 %112, 2 - store i32 %113, ptr %1, align 4, !tbaa !27 + store i32 %113, ptr %2, align 4, !tbaa !27 %114 = load i32, ptr %0, align 8, !tbaa !23 %115 = sdiv i32 %114, 2 store i32 %115, ptr %0, align 8, !tbaa !23 %116 = load i32, ptr %68, align 4, !tbaa !27 %117 = sdiv i32 %116, 2 store i32 %117, ptr %68, align 4, !tbaa !27 - %118 = load i32, ptr %66, align 8, !tbaa !23 + %118 = load i32, ptr %67, align 8, !tbaa !23 %119 = sdiv i32 %118, 2 - store i32 %119, ptr %66, align 8, !tbaa !23 - ret ptr %66 + store i32 %119, ptr %67, align 8, !tbaa !23 + ret ptr %67 } ; Function Attrs: nounwind uwtable diff --git a/bench/abc/optimized/giaSatEdge.ll b/bench/abc/optimized/giaSatEdge.ll index 374bb4227d5..dbe60741db9 100644 --- a/bench/abc/optimized/giaSatEdge.ll +++ b/bench/abc/optimized/giaSatEdge.ll @@ -801,132 +801,123 @@ declare i32 @Gia_ManLutLevel(ptr noundef, ptr noundef) local_unnamed_addr #1 ; Function Attrs: nounwind uwtable define noundef ptr @Seg_ManAlloc(ptr noundef %0, i32 noundef %1) local_unnamed_addr #0 { - %3 = tail call noalias dereferenceable_or_null(120) ptr @calloc(i64 noundef 1, i64 noundef 120) #19 - %4 = tail call noalias dereferenceable_or_null(16) ptr @malloc(i64 noundef 16) #16 - %5 = getelementptr inbounds nuw i8, ptr %4, i64 4 - store i32 0, ptr %5, align 4, !tbaa !3 - store i32 1000, ptr %4, align 8, !tbaa !10 - %6 = tail call noalias dereferenceable_or_null(4000) ptr @malloc(i64 noundef 4000) #16 - %7 = getelementptr inbounds nuw i8, ptr %4, i64 8 - store ptr %6, ptr %7, align 8, !tbaa !11 - %8 = getelementptr inbounds nuw i8, ptr %3, i64 56 - store ptr %4, ptr %8, align 8, !tbaa !55 - %9 = tail call noalias dereferenceable_or_null(16) ptr @malloc(i64 noundef 16) #16 - %10 = getelementptr inbounds nuw i8, ptr %9, i64 4 - store i32 0, ptr %10, align 4, !tbaa !3 - store i32 1000, ptr %9, align 8, !tbaa !10 - %11 = tail call noalias dereferenceable_or_null(4000) ptr @malloc(i64 noundef 4000) #16 - %12 = getelementptr inbounds nuw i8, ptr %9, i64 8 - store ptr %11, ptr %12, align 8, !tbaa !11 - %13 = getelementptr inbounds nuw i8, ptr %3, i64 64 - store ptr %9, ptr %13, align 8, !tbaa !56 - %14 = tail call ptr @Seg_ManCountIntEdges(ptr noundef %0, ptr noundef nonnull %4, ptr noundef nonnull %9, i32 noundef %1) - %15 = getelementptr inbounds nuw i8, ptr %3, i64 72 - store ptr %14, ptr %15, align 8, !tbaa !57 - %16 = getelementptr i8, ptr %14, i64 4 - %.val = load i32, ptr %16, align 4, !tbaa !3 - %17 = sdiv i32 %.val, 2 - %18 = getelementptr inbounds nuw i8, ptr %3, i64 8 - store i32 %17, ptr %18, align 8, !tbaa !58 - %19 = icmp ult i32 %17, 2 - br i1 %19, label %Abc_Base2Log.exit, label %20 - -20: ; preds = %2 - %21 = add nsw i32 %17, -1 - %.not11.i = icmp eq i32 %21, 0 - br i1 %.not11.i, label %Abc_Base2Log.exit, label %.lr.ph.preheader.i - -.lr.ph.preheader.i: ; preds = %20 - %22 = tail call range(i32 0, 33) i32 @llvm.ctlz.i32(i32 %21, i1 true) - %23 = sub nuw nsw i32 32, %22 - br label %Abc_Base2Log.exit - -Abc_Base2Log.exit: ; preds = %2, %20, %.lr.ph.preheader.i - %.09.i = phi i32 [ %17, %2 ], [ 0, %20 ], [ %23, %.lr.ph.preheader.i ] - %24 = getelementptr inbounds nuw i8, ptr %3, i64 12 - store i32 %.09.i, ptr %24, align 4, !tbaa !59 - %25 = shl nuw i32 1, %.09.i - %26 = getelementptr inbounds nuw i8, ptr %3, i64 16 - store i32 %25, ptr %26, align 8, !tbaa !60 - %27 = tail call ptr @sat_solver_new() #17 - store ptr %27, ptr %3, align 8, !tbaa !61 - tail call void @sat_solver_setnvars(ptr noundef %27, i32 noundef %17) #17 - %28 = tail call i32 @sat_solver_nvars(ptr noundef %27) #17 - %29 = getelementptr inbounds nuw i8, ptr %3, i64 20 - store i32 %28, ptr %29, align 4, !tbaa !62 - %30 = load i32, ptr %27, align 8, !tbaa !63 - %31 = getelementptr inbounds nuw i8, ptr %27, i64 96 - store i32 %30, ptr %31, align 8, !tbaa !75 - %32 = getelementptr inbounds nuw i8, ptr %27, i64 8 - %33 = load i32, ptr %32, align 8, !tbaa !76 - %34 = getelementptr inbounds nuw i8, ptr %27, i64 100 - store i32 %33, ptr %34, align 4, !tbaa !77 - %35 = getelementptr inbounds nuw i8, ptr %27, i64 16 - %36 = load i32, ptr %35, align 8, !tbaa !32 - %37 = getelementptr inbounds nuw i8, ptr %27, i64 32 - store i32 %36, ptr %37, align 8, !tbaa !32 - %38 = getelementptr inbounds nuw i8, ptr %27, i64 20 - %39 = load i32, ptr %38, align 4, !tbaa !32 - %40 = getelementptr inbounds nuw i8, ptr %27, i64 36 - store i32 %39, ptr %40, align 4, !tbaa !32 - %41 = getelementptr inbounds nuw i8, ptr %27, i64 40 - %42 = load i32, ptr %41, align 8, !tbaa !32 - %43 = getelementptr inbounds nuw i8, ptr %27, i64 48 - %44 = load i32, ptr %43, align 8, !tbaa !78 - %45 = shl i32 %42, %44 - %46 = getelementptr inbounds nuw i8, ptr %27, i64 64 - %47 = load ptr, ptr %46, align 8, !tbaa !79 - %48 = sext i32 %42 to i64 - %49 = getelementptr inbounds ptr, ptr %47, i64 %48 - %50 = load ptr, ptr %49, align 8, !tbaa !80 - %.val.i.i.i = load i32, ptr %50, align 4, !tbaa !32 - %51 = or i32 %.val.i.i.i, %45 - %52 = getelementptr inbounds nuw i8, ptr %27, i64 24 - store i32 %51, ptr %52, align 8, !tbaa !32 - %53 = getelementptr inbounds nuw i8, ptr %27, i64 44 - %54 = load i32, ptr %53, align 4, !tbaa !32 - %55 = shl i32 %54, %44 - %56 = sext i32 %54 to i64 - %57 = getelementptr inbounds ptr, ptr %47, i64 %56 - %58 = load ptr, ptr %57, align 8, !tbaa !80 - %.val.i8.i.i = load i32, ptr %58, align 4, !tbaa !32 - %59 = or i32 %.val.i8.i.i, %55 - %60 = getelementptr inbounds nuw i8, ptr %27, i64 28 - store i32 %59, ptr %60, align 4, !tbaa !32 - %61 = getelementptr inbounds nuw i8, ptr %27, i64 152 - %62 = load ptr, ptr %61, align 8, !tbaa !81 - %.not.i = icmp eq ptr %62, null - br i1 %.not.i, label %sat_solver_bookmark.exit, label %63 - -63: ; preds = %Abc_Base2Log.exit - %64 = getelementptr inbounds nuw i8, ptr %27, i64 120 - %65 = load i64, ptr %64, align 8, !tbaa !82 - %66 = getelementptr inbounds nuw i8, ptr %27, i64 128 - store i64 %65, ptr %66, align 8, !tbaa !83 - %67 = getelementptr inbounds nuw i8, ptr %27, i64 144 - %68 = load ptr, ptr %67, align 8, !tbaa !84 - %69 = sext i32 %30 to i64 - %70 = shl nsw i64 %69, 3 - tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %62, ptr align 8 %68, i64 %70, i1 false) +Abc_Base2Log.exit: + %4 = tail call noalias dereferenceable_or_null(120) ptr @calloc(i64 noundef 1, i64 noundef 120) #16 + %3 = tail call noalias dereferenceable_or_null(16) ptr @malloc(i64 noundef 16) #16 + %4 = getelementptr inbounds nuw i8, ptr %3, i64 4 + store i32 0, ptr %4, align 4, !tbaa !3 + store i32 1000, ptr %3, align 8, !tbaa !10 + %5 = tail call noalias dereferenceable_or_null(4000) ptr @malloc(i64 noundef 4000) #16 + %6 = getelementptr inbounds nuw i8, ptr %3, i64 8 + store ptr %5, ptr %6, align 8, !tbaa !11 + %7 = getelementptr inbounds nuw i8, ptr %2, i64 56 + store ptr %3, ptr %7, align 8, !tbaa !55 + %8 = tail call noalias dereferenceable_or_null(16) ptr @malloc(i64 noundef 16) #16 + %9 = getelementptr inbounds nuw i8, ptr %8, i64 4 + store i32 0, ptr %9, align 4, !tbaa !3 + store i32 1000, ptr %8, align 8, !tbaa !10 + %10 = tail call noalias dereferenceable_or_null(4000) ptr @malloc(i64 noundef 4000) #16 + %11 = getelementptr inbounds nuw i8, ptr %8, i64 8 + store ptr %10, ptr %11, align 8, !tbaa !11 + %12 = getelementptr inbounds nuw i8, ptr %2, i64 64 + store ptr %8, ptr %12, align 8, !tbaa !56 + %13 = tail call ptr @Seg_ManCountIntEdges(ptr noundef %0, ptr noundef nonnull %3, ptr noundef nonnull %8, i32 noundef %1) + %14 = getelementptr inbounds nuw i8, ptr %2, i64 72 + store ptr %13, ptr %14, align 8, !tbaa !57 + %15 = getelementptr i8, ptr %13, i64 4 + %.val = load i32, ptr %15, align 4, !tbaa !3 + %16 = sdiv i32 %.val, 2 + %17 = getelementptr inbounds nuw i8, ptr %2, i64 8 + store i32 %16, ptr %17, align 8, !tbaa !58 + %18 = icmp ult i32 %16, 2 + %19 = add nsw i32 %16, -1 + %20 = tail call range(i32 0, 33) i32 @llvm.ctlz.i32(i32 %19, i1 true) + %21 = sub nuw nsw i32 32, %20 + %.09.i = select i1 %18, i32 %16, i32 %21 + %22 = getelementptr inbounds nuw i8, ptr %2, i64 12 + store i32 %.09.i, ptr %22, align 4, !tbaa !59 + %23 = shl nuw i32 1, %.09.i + %24 = getelementptr inbounds nuw i8, ptr %2, i64 16 + store i32 %23, ptr %24, align 8, !tbaa !60 + %25 = tail call ptr @sat_solver_new() #17 + store ptr %25, ptr %2, align 8, !tbaa !61 + tail call void @sat_solver_setnvars(ptr noundef %25, i32 noundef %16) #17 + %26 = tail call i32 @sat_solver_nvars(ptr noundef %25) #17 + %24 = getelementptr inbounds nuw i8, ptr %2, i64 20 + store i32 %26, ptr %24, align 4, !tbaa !62 + %28 = load i32, ptr %25, align 8, !tbaa !63 + %26 = getelementptr inbounds nuw i8, ptr %25, i64 96 + store i32 %28, ptr %26, align 8, !tbaa !75 + %30 = getelementptr inbounds nuw i8, ptr %25, i64 8 + %31 = load i32, ptr %30, align 8, !tbaa !76 + %32 = getelementptr inbounds nuw i8, ptr %25, i64 100 + store i32 %31, ptr %32, align 4, !tbaa !77 + %29 = getelementptr inbounds nuw i8, ptr %25, i64 16 + %34 = load i32, ptr %29, align 8, !tbaa !32 + %35 = getelementptr inbounds nuw i8, ptr %25, i64 32 + store i32 %34, ptr %35, align 8, !tbaa !32 + %36 = getelementptr inbounds nuw i8, ptr %25, i64 20 + %37 = load i32, ptr %36, align 4, !tbaa !32 + %38 = getelementptr inbounds nuw i8, ptr %25, i64 36 + store i32 %37, ptr %38, align 4, !tbaa !32 + %39 = getelementptr inbounds nuw i8, ptr %25, i64 40 + %40 = load i32, ptr %39, align 8, !tbaa !32 + %41 = getelementptr inbounds nuw i8, ptr %25, i64 48 + %42 = load i32, ptr %41, align 8, !tbaa !78 + %43 = shl i32 %40, %42 + %38 = getelementptr inbounds nuw i8, ptr %25, i64 64 + %39 = load ptr, ptr %38, align 8, !tbaa !79 + %46 = sext i32 %40 to i64 + %47 = getelementptr inbounds ptr, ptr %45, i64 %46 + %48 = load ptr, ptr %47, align 8, !tbaa !80 + %42 = load i32, ptr %48, align 4, !tbaa !32 + %49 = or i32 %42, %43 + %50 = getelementptr inbounds nuw i8, ptr %25, i64 24 + store i32 %49, ptr %50, align 8, !tbaa !32 + %46 = getelementptr inbounds nuw i8, ptr %25, i64 44 + %47 = load i32, ptr %46, align 4, !tbaa !32 + %53 = shl i32 %47, %42 + %54 = sext i32 %47 to i64 + %55 = getelementptr inbounds ptr, ptr %45, i64 %54 + %.val.i.i.i = load ptr, ptr %55, align 8, !tbaa !80 + %.val.i8.i.i = load i32, ptr %.val.i.i.i, align 4, !tbaa !32 + %57 = or i32 %.val.i8.i.i, %53 + %58 = getelementptr inbounds nuw i8, ptr %25, i64 28 + store i32 %57, ptr %58, align 4, !tbaa !32 + %59 = getelementptr inbounds nuw i8, ptr %25, i64 152 + %60 = load ptr, ptr %59, align 8, !tbaa !81 + %.not.i = icmp eq ptr %60, null + br i1 %.not.i, label %sat_solver_bookmark.exit, label %61 + +61:; preds = %Abc_Base2Log.exit + %62 = getelementptr inbounds nuw i8, ptr %25, i64 120 + %63 = load i64, ptr %62, align 8, !tbaa !82 + %64 = getelementptr inbounds nuw i8, ptr %25, i64 128 + store i64 %63, ptr %64, align 8, !tbaa !83 + %65 = getelementptr inbounds nuw i8, ptr %25, i64 144 + %66 = load ptr, ptr %65, align 8, !tbaa !84 + %67 = sext i32 %28 to i64 + %68 = shl nsw i64 %67, 3 + tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %60, ptr align 8 %66, i64 %68, i1 false) br label %sat_solver_bookmark.exit -sat_solver_bookmark.exit: ; preds = %Abc_Base2Log.exit, %63 - %71 = getelementptr inbounds nuw i8, ptr %3, i64 48 +sat_solver_bookmark.exit: ; preds = %Abc_Base2Log.exit, %61 + %71 = getelementptr inbounds nuw i8, ptr %2, i64 48 store ptr %0, ptr %71, align 8, !tbaa !47 %calloc = tail call dereferenceable_or_null(16) ptr @calloc(i64 1, i64 16) - %72 = getelementptr inbounds nuw i8, ptr %3, i64 80 + %72 = getelementptr inbounds nuw i8, ptr %2, i64 80 store ptr %calloc, ptr %72, align 8, !tbaa !44 %calloc31 = tail call dereferenceable_or_null(16) ptr @calloc(i64 1, i64 16) - %73 = getelementptr inbounds nuw i8, ptr %3, i64 88 + %73 = getelementptr inbounds nuw i8, ptr %2, i64 88 store ptr %calloc31, ptr %73, align 8, !tbaa !48 %calloc32 = tail call dereferenceable_or_null(16) ptr @calloc(i64 1, i64 16) - %74 = getelementptr inbounds nuw i8, ptr %3, i64 96 + %74 = getelementptr inbounds nuw i8, ptr %2, i64 96 store ptr %calloc32, ptr %74, align 8, !tbaa !85 - %75 = tail call i32 @Seg_ManCountIntLevels(ptr noundef nonnull %3, i32 noundef %28) - %76 = load ptr, ptr %3, align 8, !tbaa !61 + %75 = tail call i32 @Seg_ManCountIntLevels(ptr noundef nonnull %2, i32 noundef %26) + %76 = load ptr, ptr %2, align 8, !tbaa !61 tail call void @sat_solver_setnvars(ptr noundef %76, i32 noundef %75) #17 tail call void @Gia_ManFillValue(ptr noundef %0) #17 - ret ptr %3 + ret ptr %2 } ; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite) diff --git a/bench/abc/optimized/ifDec16.ll b/bench/abc/optimized/ifDec16.ll index 7232dc19792..55eeb6b502c 100644 --- a/bench/abc/optimized/ifDec16.ll +++ b/bench/abc/optimized/ifDec16.ll @@ -2087,31 +2087,27 @@ define i32 @If_CluSemiCanonicize(ptr noundef captures(none) %0, i32 noundef %1, br i1 %exitcond54.not.i, label %If_CluChangePhase.exit, label %27, !llvm.loop !87 35: ; preds = %17 - %36 = add nsw i64 %indvars.iv, -6 - %37 = trunc nsw i64 %36 to i32 - %38 = shl nuw i32 1, %37 br i1 %11, label %.preheader.lr.ph.i, label %If_CluChangePhase.exit .preheader.lr.ph.i: ; preds = %35 - %39 = icmp eq i64 %36, 31 - %40 = shl i32 2, %37 - %41 = sext i32 %40 to i64 - br i1 %39, label %If_CluChangePhase.exit, label %.preheader.us.preheader.i - -.preheader.us.preheader.i: ; preds = %.preheader.lr.ph.i - %42 = sext i32 %38 to i64 + %36 = trunc i64 %indvars.iv to i32 + %37 = add i32 %36, -6 + %38 = shl nuw i32 1, %37 + %39 = shl i32 2, %37 + %40 = sext i32 %39 to i64 + %41 = sext i32 %38 to i64 %smax.i = tail call i32 @llvm.smax.i32(i32 %38, i32 1) %wide.trip.count.i = zext nneg i32 %smax.i to i64 br label %.preheader.us.i -.preheader.us.i: ; preds = %._crit_edge.us.i, %.preheader.us.preheader.i - %.045.us.i = phi ptr [ %47, %._crit_edge.us.i ], [ %0, %.preheader.us.preheader.i ] - %.03644.us.i = phi i32 [ %48, %._crit_edge.us.i ], [ 0, %.preheader.us.preheader.i ] - %invariant.gep.i = getelementptr i64, ptr %.045.us.i, i64 %42 +.preheader.us.i: ; preds = %._crit_edge.us.i, %.preheader.lr.ph.i + %.045.us.i = phi ptr [ %47, %._crit_edge.us.i ], [ %0, %.preheader.lr.ph.i ] + %.03644.us.i = phi i32 [ %48, %._crit_edge.us.i ], [ 0, %.preheader.lr.ph.i ] + %invariant.gep.i = getelementptr i64, ptr %.045.us.i, i64 %41 br label %43 43: ; preds = %43, %.preheader.us.i - %indvars.iv.i = phi i64 [ 0, %.preheader.us.i ], [ %indvars.iv.next.i, %43 ] + %indvars.iv.i = phi i64 [ 0, %.preheader.us.i ], [ %indvars.iv.next.i, %42 ] %44 = getelementptr inbounds nuw i64, ptr %.045.us.i, i64 %indvars.iv.i %45 = load i64, ptr %44, align 8, !tbaa !16 %gep.i = getelementptr i64, ptr %invariant.gep.i, i64 %indvars.iv.i @@ -2123,13 +2119,13 @@ define i32 @If_CluSemiCanonicize(ptr noundef captures(none) %0, i32 noundef %1, br i1 %exitcond.not.i, label %._crit_edge.us.i, label %43, !llvm.loop !88 ._crit_edge.us.i: ; preds = %43 - %47 = getelementptr inbounds i64, ptr %.045.us.i, i64 %41 - %48 = add nsw i32 %.03644.us.i, %40 + %47 = getelementptr inbounds i64, ptr %.045.us.i, i64 %40 + %48 = add nsw i32 %.03644.us.i, %39 %49 = icmp slt i32 %48, %10 br i1 %49, label %.preheader.us.i, label %If_CluChangePhase.exit, !llvm.loop !89 -If_CluChangePhase.exit: ; preds = %._crit_edge.us.i, %27, %.preheader.lr.ph.i, %35, %22, %12 - %.167 = phi i32 [ %.066101, %12 ], [ %20, %22 ], [ %20, %35 ], [ %20, %.preheader.lr.ph.i ], [ %20, %27 ], [ %20, %._crit_edge.us.i ] +If_CluChangePhase.exit: ; preds = %._crit_edge.us.i, %27, %35, %22, %12 + %.167 = phi i32 [ %.066101, %12 ], [ %20, %22 ], [ %20, %35 ], [ %20, %27 ], [ %20, %._crit_edge.us.i ] %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count br i1 %exitcond.not, label %.lr.ph104.preheader, label %12, !llvm.loop !96 @@ -2237,7 +2233,7 @@ If_CluChangePhase.exit: ; preds = %._crit_edge.us.i, % br label %88 88: ; preds = %88, %.preheader85.us.i.us - %indvars.iv152.i.us = phi i64 [ 0, %.preheader85.us.i.us ], [ %indvars.iv.next153.i.us, %88 ] + %indvars.iv152.i.us = phi i64 [ 0, %.preheader85.us.i.us ], [ %indvars.iv.next153.i.us, %87 ] %gep180.i.us = getelementptr i64, ptr %invariant.gep179.i.us, i64 %indvars.iv152.i.us %89 = load i64, ptr %gep180.i.us, align 8, !tbaa !16 %gep182.i.us = getelementptr i64, ptr %invariant.gep181.i.us, i64 %indvars.iv152.i.us @@ -2247,7 +2243,7 @@ If_CluChangePhase.exit: ; preds = %._crit_edge.us.i, % br i1 %exitcond157.not.i.us, label %.lr.ph95.us.i.us, label %88, !llvm.loop !98 .lr.ph95.us.i.us: ; preds = %88, %.lr.ph95.us.i.us - %indvars.iv159.i.us = phi i64 [ %indvars.iv.next160.i.us, %.lr.ph95.us.i.us ], [ 0, %88 ] + %indvars.iv159.i.us = phi i64 [ %indvars.iv.next160.i.us, %.lr.ph95.us.i.us ], [ 0, %87 ] %90 = add nsw i64 %indvars.iv159.i.us, %85 %91 = getelementptr inbounds i64, ptr %.07797.us.i.us, i64 %90 %92 = load i64, ptr %91, align 8, !tbaa !16 @@ -2291,40 +2287,40 @@ If_CluChangePhase.exit: ; preds = %._crit_edge.us.i, % 112: ; preds = %62 br i1 %55, label %If_CluSwapAdjacent.exit.us, label %.lr.ph135.i.us -.lr.ph135.i.us: ; preds = %112 - %113 = trunc nuw nsw i64 %indvars.iv129 to i32 - %114 = shl nuw nsw i32 1, %113 - %115 = getelementptr inbounds nuw [3 x i64], ptr @PMasks, i64 %indvars.iv129 - %116 = load i64, ptr %115, align 8, !tbaa !16 - %117 = getelementptr inbounds nuw i8, ptr %115, i64 8 - %118 = load i64, ptr %117, align 8, !tbaa !16 - %119 = zext nneg i32 %114 to i64 - %120 = getelementptr inbounds nuw i8, ptr %115, i64 16 - %121 = load i64, ptr %120, align 8, !tbaa !16 - br label %122 - -122: ; preds = %122, %.lr.ph135.i.us - %indvars.iv167.i.us = phi i64 [ 0, %.lr.ph135.i.us ], [ %indvars.iv.next168.i.us, %122 ] - %123 = getelementptr inbounds nuw i64, ptr %.169106.us, i64 %indvars.iv167.i.us - %124 = load i64, ptr %123, align 8, !tbaa !16 - %125 = and i64 %124, %116 - %126 = and i64 %124, %118 - %127 = shl i64 %126, %119 - %128 = or i64 %127, %125 - %129 = and i64 %124, %121 - %130 = lshr i64 %129, %119 - %131 = or i64 %128, %130 - %132 = getelementptr inbounds nuw i64, ptr %.172105.us, i64 %indvars.iv167.i.us - store i64 %131, ptr %132, align 8, !tbaa !16 +.lr.ph135.i.us: ; preds = %111 + %112 = trunc nuw nsw i64 %indvars.iv129 to i32 + %113 = shl nuw nsw i32 1, %112 + %114 = getelementptr inbounds nuw [3 x i64], ptr @PMasks, i64 %indvars.iv129 + %115 = load i64, ptr %114, align 8, !tbaa !16 + %116 = getelementptr inbounds nuw i8, ptr %114, i64 8 + %117 = load i64, ptr %116, align 8, !tbaa !16 + %118 = zext nneg i32 %113 to i64 + %119 = getelementptr inbounds nuw i8, ptr %114, i64 16 + %120 = load i64, ptr %119, align 8, !tbaa !16 + br label %121 + +.lr.ph135.i.us: ; preds = %121, %.lr.ph135.i.us + %indvars.iv167.i.us = phi i64 [ 0, %.lr.ph135.i.us ], [ %indvars.iv.next168.i.us, %121 ] + %122 = getelementptr inbounds nuw i64, ptr %.169106.us, i64 %indvars.iv167.i.us + %123 = load i64, ptr %122, align 8, !tbaa !16 + %124 = and i64 %123, %115 + %125 = and i64 %123, %117 + %126 = shl i64 %125, %118 + %127 = or i64 %126, %124 + %128 = and i64 %123, %120 + %129 = lshr i64 %128, %118 + %130 = or i64 %127, %129 + %131 = getelementptr inbounds nuw i64, ptr %.172105.us, i64 %indvars.iv167.i.us + store i64 %130, ptr %131, align 8, !tbaa !16 %indvars.iv.next168.i.us = add nuw nsw i64 %indvars.iv167.i.us, 1 %exitcond171.not.i.us = icmp eq i64 %indvars.iv.next168.i.us, %56 - br i1 %exitcond171.not.i.us, label %If_CluSwapAdjacent.exit.us, label %122, !llvm.loop !102 + br i1 %exitcond171.not.i.us, label %If_CluSwapAdjacent.exit.us, label %121, !llvm.loop !102 -If_CluSwapAdjacent.exit.us: ; preds = %._crit_edge.us.i89.us, %.lr.ph.i90.us, %122, %112, %.preheader.i.us, %.preheader87.lr.ph.i.us, %74, %.lr.ph110.us - %.273.us = phi ptr [ %.172105.us, %.lr.ph110.us ], [ %.169106.us, %112 ], [ %.169106.us, %.preheader.i.us ], [ %.169106.us, %74 ], [ %.169106.us, %.preheader87.lr.ph.i.us ], [ %.169106.us, %122 ], [ %.169106.us, %.lr.ph.i90.us ], [ %.169106.us, %._crit_edge.us.i89.us ] - %.270.us = phi ptr [ %.169106.us, %.lr.ph110.us ], [ %.172105.us, %112 ], [ %.172105.us, %.preheader.i.us ], [ %.172105.us, %74 ], [ %.172105.us, %.preheader87.lr.ph.i.us ], [ %.172105.us, %122 ], [ %.172105.us, %.lr.ph.i90.us ], [ %.172105.us, %._crit_edge.us.i89.us ] - %.162.us = phi i32 [ %.061108.us, %.lr.ph110.us ], [ 1, %112 ], [ 1, %.preheader.i.us ], [ 1, %74 ], [ 1, %.preheader87.lr.ph.i.us ], [ 1, %122 ], [ 1, %.lr.ph.i90.us ], [ 1, %._crit_edge.us.i89.us ] - %.2.us = phi i32 [ %.1109.us, %.lr.ph110.us ], [ %63, %112 ], [ %63, %.preheader.i.us ], [ %63, %74 ], [ %63, %.preheader87.lr.ph.i.us ], [ %63, %122 ], [ %63, %.lr.ph.i90.us ], [ %63, %._crit_edge.us.i89.us ] +If_CluSwapAdjacent.exit.us: ; preds = %._crit_edge.us.i89.us, %.lr.ph.i90.us, %121, %112, %.preheader.i.us, %.preheader87.lr.ph.i.us, %74, %.lr.ph110.us + %.273.us = phi ptr [ %.172105.us, %.lr.ph110.us ], [ %.169106.us, %111 ], [ %.169106.us, %.preheader.i.us ], [ %.169106.us, %73 ], [ %.169106.us, %.preheader87.lr.ph.i.us ], [ %.169106.us, %121 ], [ %.169106.us, %.lr.ph.i90.us ], [ %.169106.us, %._crit_edge.us.i89.us ] + %.270.us = phi ptr [ %.169106.us, %.lr.ph110.us ], [ %.172105.us, %111 ], [ %.172105.us, %.preheader.i.us ], [ %.172105.us, %73 ], [ %.172105.us, %.preheader87.lr.ph.i.us ], [ %.172105.us, %121 ], [ %.172105.us, %.lr.ph.i90.us ], [ %.172105.us, %._crit_edge.us.i89.us ] + %.162.us = phi i32 [ %.061108.us, %.lr.ph110.us ], [ 1, %111 ], [ 1, %.preheader.i.us ], [ 1, %73 ], [ 1, %.preheader87.lr.ph.i.us ], [ 1, %121 ], [ 1, %.lr.ph.i90.us ], [ 1, %._crit_edge.us.i89.us ] + %.2.us = phi i32 [ %.1109.us, %.lr.ph110.us ], [ %63, %111 ], [ %63, %.preheader.i.us ], [ %63, %73 ], [ %63, %.preheader87.lr.ph.i.us ], [ %63, %121 ], [ %63, %.lr.ph.i90.us ], [ %63, %._crit_edge.us.i89.us ] %exitcond133.not = icmp eq i64 %indvars.iv.next130, %wide.trip.count132 br i1 %exitcond133.not, label %._crit_edge.us, label %.lr.ph110.us.backedge diff --git a/bench/assimp/optimized/FBXBinaryTokenizer.ll b/bench/assimp/optimized/FBXBinaryTokenizer.ll index b7399398967..49ea8fc520b 100644 --- a/bench/assimp/optimized/FBXBinaryTokenizer.ll +++ b/bench/assimp/optimized/FBXBinaryTokenizer.ll @@ -178,7 +178,7 @@ _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit: ; preds = %20, % 27: ; preds = %4 %28 = tail call i32 @strncmp(ptr noundef nonnull dereferenceable(1) %1, ptr noundef nonnull dereferenceable(19) @.str.2, i64 noundef 18) #23 %.not = icmp eq i32 %28, 0 - br i1 %.not, label %_ZN6Assimp3FBX12_GLOBAL__N_18ReadWordEPKcRS3_S3_.exit, label %29 + br i1 %.not, label %_ZN6Assimp3FBX12_GLOBAL__N_18ReadByteEPKcRS3_S3_.exit, label %29 29: ; preds = %27 call void @llvm.lifetime.start.p0(ptr nonnull %7) @@ -218,11 +218,7 @@ _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit59: ; preds = %34, call void @llvm.lifetime.end.p0(ptr nonnull %7) br label %common.resume -common.resume: ; preds = %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit59, %82 - %common.resume.op = phi { ptr, i32 } [ %.pn53, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit ], [ %.pn51, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit59 ], [ %.merged55, %82 ] - resume { ptr, i32 } %common.resume.op - -_ZN6Assimp3FBX12_GLOBAL__N_18ReadWordEPKcRS3_S3_.exit: ; preds = %27 +common.resume: ; preds = %27 call void @llvm.lifetime.start.p0(ptr nonnull %9) %41 = getelementptr inbounds nuw i8, ptr %1, i64 %2 %42 = getelementptr inbounds nuw i8, ptr %1, i64 23 @@ -238,7 +234,11 @@ _ZN6Assimp3FBX12_GLOBAL__N_18ReadWordEPKcRS3_S3_.exit: ; preds = %27 %.old56.not = icmp eq i64 %2, 27 br i1 %.old56.not, label %.loopexit, label %.preheader -.preheader: ; preds = %_ZN6Assimp3FBX12_GLOBAL__N_18ReadWordEPKcRS3_S3_.exit, %48 +.preheader: ; preds = %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit59, %82 + %common.resume.op = phi { ptr, i32 } [ %.pn53, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit ], [ %.pn51, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit59 ], [ %.merged55, %82 ] + resume { ptr, i32 } %common.resume.op + +.preheader: ; preds = %_ZN6Assimp3FBX12_GLOBAL__N_18ReadByteEPKcRS3_S3_.exit, %48 %47 = invoke fastcc noundef zeroext i1 @_ZN6Assimp3FBX12_GLOBAL__N_19ReadScopeERSt6vectorIPKNS0_5TokenESaIS5_EERNS_14StackAllocatorEPKcRSC_SC_b(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(40) %3, ptr noundef nonnull %1, ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull %41, i1 noundef zeroext %46) to label %48 unwind label %51 @@ -331,7 +331,7 @@ _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit86: ; preds = %70 invoke void @__cxa_end_catch() to label %82 unwind label %83 -.loopexit: ; preds = %48, %_ZN6Assimp3FBX12_GLOBAL__N_18ReadWordEPKcRS3_S3_.exit +.loopexit: ; preds = %48, %_ZN6Assimp3FBX12_GLOBAL__N_18ReadByteEPKcRS3_S3_.exit call void @llvm.lifetime.end.p0(ptr nonnull %10) call void @llvm.lifetime.end.p0(ptr nonnull %9) ret void diff --git a/bench/cmake/optimized/cmTarget.ll b/bench/cmake/optimized/cmTarget.ll index 1fcd80d67a1..ecd8d603843 100644 --- a/bench/cmake/optimized/cmTarget.ll +++ b/bench/cmake/optimized/cmTarget.ll @@ -7962,7 +7962,7 @@ _ZNSt11char_traitsIcE7compareEPKcS2_m.exit.i.i51: ; preds = %_ZSteqIcSt11char_tr _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEN9__gnu_cxx17__normal_iteratorIPKcS4_EES9_RKS4_.exit57: ; preds = %.critedge %109 = load i64, ptr %13, align 8, !tbaa !11 %110 = load ptr, ptr %1, align 8, !tbaa !15 - %gepdiff85 = add i64 %106, -6 + %gepdiff85 = add nsw i64 %106, -6 %111 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_replaceEmmPKcm(ptr noundef nonnull align 8 dereferenceable(32) %104, i64 noundef 6, i64 noundef %gepdiff85, ptr noundef %110, i64 noundef %109) %112 = getelementptr inbounds nuw i8, ptr %0, i64 8 %113 = load ptr, ptr %112, align 8, !tbaa !236 diff --git a/bench/cmake/optimized/cmakemain.ll b/bench/cmake/optimized/cmakemain.ll index 01035bccb98..7f7b5d34a8b 100644 --- a/bench/cmake/optimized/cmakemain.ll +++ b/bench/cmake/optimized/cmakemain.ll @@ -1900,26 +1900,26 @@ _ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE %484 = add nsw i32 %106, -2 %485 = zext nneg i32 %484 to i64 %486 = getelementptr inbounds nuw i8, ptr %80, i64 16 - %487 = shl nuw nsw i64 %485, 5 - %488 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %487) #30 - to label %_ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE7reserveEm.exit.i unwind label %642 - -_ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE7reserveEm.exit.i: ; preds = %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE11_M_allocateEm.exit.i.i - %489 = getelementptr inbounds nuw i8, ptr %80, i64 8 - store ptr %488, ptr %80, align 8, !tbaa !148 - store ptr %488, ptr %489, align 8, !tbaa !150 - %490 = getelementptr inbounds nuw %"class.std::__cxx11::basic_string", ptr %488, i64 %485 + %487 = getelementptr inbounds nuw i8, ptr %80, i64 8 + %488 = shl nuw nsw i64 %485, 5 + %489 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %488) #30 + to label %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i unwind label %642 + +_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i:; preds = %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE11_M_allocateEm.exit.i.i + store ptr %489, ptr %80, align 8, !tbaa !148 + store ptr %489, ptr %487, align 8, !tbaa !150 + %490 = getelementptr inbounds nuw %"class.std::__cxx11::basic_string", ptr %489, i64 %485 store ptr %490, ptr %486, align 8, !tbaa !151 %491 = getelementptr inbounds nuw i8, ptr %108, i64 16 %492 = zext nneg i32 %106 to i64 %493 = getelementptr inbounds nuw ptr, ptr %108, i64 %492 - invoke void @_ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE15_M_range_insertIPKPKcEEvN9__gnu_cxx17__normal_iteratorIPS5_S7_EET_SH_St20forward_iterator_tag(ptr noundef nonnull align 8 dereferenceable(24) %80, ptr nonnull %488, ptr noundef nonnull %491, ptr noundef nonnull %493) + invoke void @_ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE15_M_range_insertIPKPKcEEvN9__gnu_cxx17__normal_iteratorIPS5_S7_EET_SH_St20forward_iterator_tag(ptr noundef nonnull align 8 dereferenceable(24) %80, ptr nonnull %489, ptr noundef nonnull %491, ptr noundef nonnull %493) to label %_ZN2cm6appendISt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEPKPKcTnNSt9enable_ifIXaaaasr2cm21is_sequence_containerIT_EE5valuesr2cm17is_input_iteratorIT0_EE5valuesr3std14is_convertibleINSt15iterator_traitsISG_E10value_typeENSF_10value_typeEEE5valueEiE4typeELi0EEEvRSF_SG_SG_.exit.i unwind label %642 -_ZN2cm6appendISt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEPKPKcTnNSt9enable_ifIXaaaasr2cm21is_sequence_containerIT_EE5valuesr2cm17is_input_iteratorIT0_EE5valuesr3std14is_convertibleINSt15iterator_traitsISG_E10value_typeENSF_10value_typeEEE5valueEiE4typeELi0EEEvRSF_SG_SG_.exit.i: ; preds = %_ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE7reserveEm.exit.i +_ZN2cm6appendISt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEPKPKcTnNSt9enable_ifIXaaaasr2cm21is_sequence_containerIT_EE5valuesr2cm17is_input_iteratorIT0_EE5valuesr3std14is_convertibleINSt15iterator_traitsISG_E10value_typeENSF_10value_typeEEE5valueEiE4typeELi0EEEvRSF_SG_SG_.exit.i: ; preds = %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i call void @llvm.lifetime.start.p0(ptr nonnull %81) store i64 0, ptr %81, align 8, !tbaa !55 - %494 = load ptr, ptr %489, align 8, !tbaa !150 + %494 = load ptr, ptr %487, align 8, !tbaa !150 %495 = load ptr, ptr %80, align 8, !tbaa !148 %496 = icmp eq ptr %494, %495 %497 = load i8, ptr %47, align 1, !range !152 @@ -2348,7 +2348,7 @@ _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit439.i: ; preds = % call void @llvm.lifetime.end.p0(ptr nonnull %61) br label %1113 -642: ; preds = %_ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE7reserveEm.exit.i, %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE11_M_allocateEm.exit.i.i +642: ; preds = %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i, %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE11_M_allocateEm.exit.i.i %643 = landingpad { ptr, i32 } cleanup br label %813 @@ -2705,7 +2705,7 @@ _ZNSolsEPFRSoS_E.exit.i: ; preds = %.thread638.i, %_ZNS %773 = load i64, ptr %81, align 8, !tbaa !55 %774 = add i64 %773, 1 store i64 %774, ptr %81, align 8, !tbaa !55 - %775 = load ptr, ptr %489, align 8, !tbaa !150 + %775 = load ptr, ptr %487, align 8, !tbaa !150 %776 = load ptr, ptr %80, align 8, !tbaa !148 %777 = ptrtoint ptr %775 to i64 %778 = ptrtoint ptr %776 to i64 @@ -2721,7 +2721,7 @@ _ZNSolsEPFRSoS_E.exit.thread.i: ; preds = %_ZNSolsEPFRSoS_E.ex %784 = load i8, ptr %47, align 1, !tbaa !21, !range !152, !noundef !179 %785 = trunc nuw i8 %784 to i1 %.pre677.i = load ptr, ptr %80, align 8, !tbaa !148 - %.pre679.i = load ptr, ptr %489, align 8, !tbaa !150 + %.pre679.i = load ptr, ptr %487, align 8, !tbaa !150 br i1 %785, label %786, label %_ZN2cm6appendISt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEN9__gnu_cxx17__normal_iteratorIPS7_S9_EETnNSt9enable_ifIXaaaasr2cm21is_sequence_containerIT_EE5valuesr2cm17is_input_iteratorIT0_EE5valuesr3std14is_convertibleINSt15iterator_traitsISG_E10value_typeENSF_10value_typeEEE5valueEiE4typeELi0EEEvRSF_SG_SG_.exit.i 786: ; preds = %_ZNSolsEPFRSoS_E.exit.thread.i @@ -2739,7 +2739,7 @@ _ZNSolsEPFRSoS_E.exit.thread.i: ; preds = %_ZNSolsEPFRSoS_E.ex ._ZN2cm6appendISt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEN9__gnu_cxx17__normal_iteratorIPS7_S9_EETnNSt9enable_ifIXaaaasr2cm21is_sequence_containerIT_EE5valuesr2cm17is_input_iteratorIT0_EE5valuesr3std14is_convertibleINSt15iterator_traitsISG_E10value_typeENSF_10value_typeEEE5valueEiE4typeELi0EEEvRSF_SG_SG_.exit_crit_edge.i: ; preds = %786 %.pre676.i = load ptr, ptr %80, align 8, !tbaa !148 - %.pre678.i = load ptr, ptr %489, align 8, !tbaa !150 + %.pre678.i = load ptr, ptr %487, align 8, !tbaa !150 br label %_ZN2cm6appendISt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEN9__gnu_cxx17__normal_iteratorIPS7_S9_EETnNSt9enable_ifIXaaaasr2cm21is_sequence_containerIT_EE5valuesr2cm17is_input_iteratorIT0_EE5valuesr3std14is_convertibleINSt15iterator_traitsISG_E10value_typeENSF_10value_typeEEE5valueEiE4typeELi0EEEvRSF_SG_SG_.exit.i 796: ; preds = %786 @@ -4691,7 +4691,7 @@ _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit123.i: ; preds = % _ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE11_M_allocateEm.exit.i.i99: ; preds = %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit123.i %1469 = shl nuw nsw i64 %1467, 5 %1470 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %1469) #30 - to label %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i unwind label %1526 + to label %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i100 unwind label %1526 _ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i: ; preds = %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE11_M_allocateEm.exit.i.i99 %1471 = getelementptr inbounds nuw i8, ptr %18, i64 8 @@ -4702,7 +4702,7 @@ _ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE br label %_ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE7reserveEm.exit.i100 _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE7reserveEm.exit.i100: ; preds = %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit123.i - %1473 = phi ptr [ %1470, %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i ], [ null, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit123.i ] + %1473 = phi ptr [ %1470, %_ZNSt12_Vector_baseINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_deallocateEPS5_m.exit.i.i100 ], [ null, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit123.i ] %1474 = getelementptr inbounds nuw i8, ptr %108, i64 16 %1475 = zext nneg i32 %106 to i64 %1476 = getelementptr inbounds nuw ptr, ptr %108, i64 %1475 diff --git a/bench/coreutils-rs/optimized/2g9ijtjos2xwh9zs.ll b/bench/coreutils-rs/optimized/2g9ijtjos2xwh9zs.ll index f4a55420b33..8ef7b9b6178 100644 --- a/bench/coreutils-rs/optimized/2g9ijtjos2xwh9zs.ll +++ b/bench/coreutils-rs/optimized/2g9ijtjos2xwh9zs.ll @@ -4873,7 +4873,7 @@ define hidden void @_ZN5rayon5slice9mergesort13par_mergesort17h9ae9ed164361c133E br label %192 common.resume: ; preds = %208, %28 - %common.resume.op = phi { ptr, i32 } [ %.pn72, %28 ], [ %lpad.loopexit.i, %208 ] + %common.resume.op = phi { ptr, i32 } [ %.pn72, %28 ], [ %lpad.loopexit.i, %207 ] resume { ptr, i32 } %common.resume.op 28: ; preds = %37, %33, %.noexc @@ -5414,20 +5414,20 @@ _ZN4core3ptr19swap_nonoverlapping17h45446940a5c53ec3E.exit.i.i97: ; preds = %177 br i1 %.not.i, label %.thread.i, label %.lr.ph.i .thread.i: ; preds = %206, %204, %200 - %.sroa.5.0.lcssa.i = phi ptr [ %196, %200 ], [ %.sroa.5.05.i, %204 ], [ %202, %206 ] + %.sroa.5.0.lcssa.i = phi ptr [ %196, %199 ], [ %.sroa.5.05.i, %203 ], [ %202, %205 ] call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5.0.lcssa.i, ptr noundef nonnull readonly align 8 dereferenceable(24) %4, i64 24, i1 false) call void @llvm.lifetime.end.p0(ptr nonnull %4), !noalias !1433 br label %_ZN5rayon5slice9mergesort11insert_head17h9c722bca3f6f4e2bE.exit .lr.ph.i: ; preds = %200, %206 - %.sroa.02.06.i = phi i64 [ %201, %206 ], [ 2, %200 ] - %.sroa.5.05.i = phi ptr [ %202, %206 ], [ %196, %200 ] + %.sroa.02.06.i = phi i64 [ %201, %205 ], [ 2, %199 ] + %.sroa.5.05.i = phi ptr [ %202, %205 ], [ %196, %199 ] %201 = add nuw nsw i64 %.sroa.02.06.i, 1 %202 = getelementptr inbounds nuw { { ptr, i64 }, i64 }, ptr %195, i64 %.sroa.02.06.i %.val.i16.i = load ptr, ptr %.val76, align 8, !noalias !1441, !nonnull !18, !align !223, !noundef !18 %.val1.i17.i = load ptr, ptr %197, align 8, !noalias !1441, !nonnull !18, !align !223, !noundef !18 %203 = invoke noundef range(i8 -1, 2) i8 @_ZN7uu_sort10compare_by17hf350e8ed154bc332E(ptr noalias noundef nonnull readonly align 8 dereferenceable(24) %202, ptr noalias noundef nonnull readonly align 8 dereferenceable(24) %4, ptr noalias noundef nonnull readonly align 8 dereferenceable(160) %.val.i16.i, ptr noalias noundef nonnull readonly align 8 dereferenceable(72) %.val1.i17.i, ptr noalias noundef nonnull readonly align 8 dereferenceable(72) %.val1.i17.i) - to label %204 unwind label %208 + to label %203 unwind label %208 204: ; preds = %.lr.ph.i %205 = icmp eq i8 %203, -1 diff --git a/bench/duckdb/optimized/format.ll b/bench/duckdb/optimized/format.ll index d6245855770..e5b7a131f41 100644 --- a/bench/duckdb/optimized/format.ll +++ b/bench/duckdb/optimized/format.ll @@ -26341,7 +26341,7 @@ _ZSt6fill_nIPcmcET_S1_T0_RKT1_.exit47.i: ; preds = %_ZN10duckdb_fmt2v68 53: ; preds = %46 %54 = load ptr, ptr %.sroa.0.0.copyload.i.i.i, align 8, !tbaa !14 %55 = load ptr, ptr %54, align 8 - tail call void %55(ptr noundef nonnull align 8 dereferenceable(32) %.sroa.0.0.copyload.i.i.i, i64 noundef %49) + tail call void %54(ptr noundef nonnull align 8 dereferenceable(32) %.sroa.0.0.copyload.i.i.i, i64 noundef %49) br label %_ZN10duckdb_fmt2v68internal12basic_writerINS0_12buffer_rangeIcEEE5writeEc.exit _ZN10duckdb_fmt2v68internal12basic_writerINS0_12buffer_rangeIcEEE5writeEc.exit: ; preds = %46, %53 @@ -60455,7 +60455,7 @@ _ZSt6fill_nIPwmwET_S1_T0_RKT1_.exit: ; preds = %.lr.ph.i.i.i.i br label %.lr.ph.i.i.i.i49 .lr.ph.i.i.i.i49: ; preds = %.lr.ph.i.i.i.i49, %.loopexit - %.06.i.i.i.i50 = phi ptr [ %49, %.lr.ph.i.i.i.i49 ], [ %47, %.loopexit ] + %.06.i.i.i.i50 = phi ptr [ %49, %.lr.ph.i.i.i.i49 ], [ %47, %_ZSt6fill_nIPwmwET_S1_T0_RKT1_.exit47 ] store i32 %30, ptr %.06.i.i.i.i50, align 4, !tbaa !118 %49 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i50, i64 4 %.not.i.i.i.i51 = icmp eq ptr %49, %48 diff --git a/bench/duckdb/optimized/ub_duckdb_common.ll b/bench/duckdb/optimized/ub_duckdb_common.ll index 30095ea17dd..a34e169e69b 100644 --- a/bench/duckdb/optimized/ub_duckdb_common.ll +++ b/bench/duckdb/optimized/ub_duckdb_common.ll @@ -190113,7 +190113,7 @@ _ZSt6fill_nIPcmcET_S1_T0_RKT1_.exit47.i: ; preds = %_ZN10duckdb_fmt2v68 53: ; preds = %46 %54 = load ptr, ptr %.sroa.0.0.copyload.i.i.i, align 8, !tbaa !31 %55 = load ptr, ptr %54, align 8 - tail call void %55(ptr noundef nonnull align 8 dereferenceable(32) %.sroa.0.0.copyload.i.i.i, i64 noundef %49) + tail call void %54(ptr noundef nonnull align 8 dereferenceable(32) %.sroa.0.0.copyload.i.i.i, i64 noundef %49) br label %_ZN10duckdb_fmt2v68internal12basic_writerINS0_12buffer_rangeIcEEE5writeEc.exit _ZN10duckdb_fmt2v68internal12basic_writerINS0_12buffer_rangeIcEEE5writeEc.exit: ; preds = %46, %53 diff --git a/bench/duckdb/optimized/ub_duckdb_core_functions_string.ll b/bench/duckdb/optimized/ub_duckdb_core_functions_string.ll index 60fe1e1e6b5..52e188857f3 100644 --- a/bench/duckdb/optimized/ub_duckdb_core_functions_string.ll +++ b/bench/duckdb/optimized/ub_duckdb_core_functions_string.ll @@ -114486,7 +114486,7 @@ _ZSt6fill_nIPcmcET_S1_T0_RKT1_.exit47.i: ; preds = %_ZN10duckdb_fmt2v68 53: ; preds = %46 %54 = load ptr, ptr %.sroa.0.0.copyload.i.i.i, align 8, !tbaa !58 %55 = load ptr, ptr %54, align 8 - tail call void %55(ptr noundef nonnull align 8 dereferenceable(32) %.sroa.0.0.copyload.i.i.i, i64 noundef %49) + tail call void %54(ptr noundef nonnull align 8 dereferenceable(32) %.sroa.0.0.copyload.i.i.i, i64 noundef %49) br label %_ZN10duckdb_fmt2v68internal12basic_writerINS0_12buffer_rangeIcEEE5writeEc.exit _ZN10duckdb_fmt2v68internal12basic_writerINS0_12buffer_rangeIcEEE5writeEc.exit: ; preds = %46, %53 diff --git a/bench/elfshaker-rs/optimized/efmso49nxcvtljggmhiyzv2jj.ll b/bench/elfshaker-rs/optimized/efmso49nxcvtljggmhiyzv2jj.ll index ec4893e28f8..86a284638f0 100644 --- a/bench/elfshaker-rs/optimized/efmso49nxcvtljggmhiyzv2jj.ll +++ b/bench/elfshaker-rs/optimized/efmso49nxcvtljggmhiyzv2jj.ll @@ -3335,15 +3335,15 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. br label %23 23: ; preds = %.loopexit, %.loopexit55 - %.sroa.0.052 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit55 ], [ %.sroa.0.1, %.loopexit ] + %.sroa.0.052 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit54 ], [ %.sroa.0.1, %.loopexit ] call void @llvm.lifetime.start.p0(ptr nonnull %5) invoke void @"_ZN137_$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$K$C$V$C$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h490a30119a296c6bE"(ptr noalias noundef nonnull sret([32 x i8]) align 8 captures(none) dereferenceable(32) %5, ptr noalias noundef nonnull align 8 dereferenceable(64) %6) to label %26 unwind label %24 .body: ; preds = %176, %124, %110, %24 - %.pn = phi { ptr, i32 } [ %25, %24 ], [ %111, %110 ], [ %125, %124 ], [ %177, %176 ] + %.pn = phi { ptr, i32 } [ %25, %24 ], [ %111, %107 ], [ %125, %121 ], [ %177, %173 ] invoke void @"_ZN4core3ptr220drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$u32$C$elfshaker..packidx..ObjectMetadata$C$alloc..vec..into_iter..IntoIter$LT$$LP$u32$C$elfshaker..packidx..ObjectMetadata$RP$$GT$$GT$$GT$17h788b0b15302a2384E"(ptr noalias noundef nonnull align 8 dereferenceable(64) %6) #27 - to label %195 unwind label %193 + to label %192 unwind label %193 24: ; preds = %23 %25 = landingpad { ptr, i32 } @@ -3436,44 +3436,35 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %66, ptr nonnull align 8 %49, i64 %67, i1 false), !alias.scope !454, !noalias !448 %68 = add nuw nsw i64 %61, 1 %69 = sub nuw nsw i64 %60, %68 - %70 = add nsw i64 %55, -1 - %71 = icmp eq i64 %69, %70 - br i1 %71, label %_ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i, label %.noexc17, !prof !26 - -.noexc17: ; preds = %59 - call void @_ZN4core9panicking5panic17h13ee8adf815f0d87E(ptr noalias noundef nonnull readonly align 1 @anon.467722f710d552998dd01561bebdcdae.51, i64 noundef 40, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.467722f710d552998dd01561bebdcdae.52) #28 - unreachable - -_ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; preds = %59 - %72 = getelementptr inbounds nuw i8, ptr %45, i64 184 - %73 = getelementptr inbounds nuw i32, ptr %72, i64 %68 - %74 = shl nuw nsw i64 %69, 2 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 4 %63, ptr nonnull readonly align 4 %73, i64 %74, i1 false), !alias.scope !457, !noalias !448 - %75 = getelementptr inbounds nuw { [2 x i64] }, ptr %45, i64 %68 - %76 = shl nuw nsw i64 %69, 4 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %49, ptr nonnull readonly align 8 %75, i64 %76, i1 false), !alias.scope !461, !noalias !448 - %77 = getelementptr inbounds nuw i32, ptr %72, i64 %61 - %78 = load i32, ptr %77, align 4, !noalias !448, !noundef !6 - %79 = getelementptr inbounds nuw { [2 x i64] }, ptr %45, i64 %61 - %80 = load i64, ptr %79, align 8, !noalias !448, !noundef !6 - %81 = getelementptr inbounds nuw i8, ptr %79, i64 8 - %82 = load i64, ptr %81, align 8, !noalias !448, !noundef !6 - %83 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 184 - %84 = getelementptr inbounds nuw i32, ptr %83, i64 %42 - %85 = getelementptr inbounds nuw { [2 x i64] }, ptr %.sroa.03.010.i, i64 %42 - %86 = load i32, ptr %84, align 4, !noalias !465, !noundef !6 - store i32 %78, ptr %84, align 4, !noalias !465 - %87 = load i64, ptr %85, align 8, !noalias !465, !noundef !6 - %88 = getelementptr inbounds nuw i8, ptr %85, i64 8 - %89 = load i64, ptr %88, align 8, !noalias !465, !noundef !6 - store i64 %80, ptr %85, align 8, !noalias !465 - store i64 %82, ptr %88, align 8, !noalias !465 - %90 = getelementptr inbounds nuw i32, ptr %63, i64 %69 - store i32 %86, ptr %90, align 4, !noalias !448 - %91 = getelementptr inbounds nuw { [2 x i64] }, ptr %49, i64 %69 - store i64 %87, ptr %91, align 8, !noalias !448 - %92 = getelementptr inbounds nuw i8, ptr %91, i64 8 - store i64 %89, ptr %92, align 8, !noalias !448 + %69 = getelementptr inbounds nuw i8, ptr %45, i64 184 + %70 = getelementptr inbounds nuw i32, ptr %69, i64 %67 + %71 = shl nuw nsw i64 %68, 2 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 4 %62, ptr nonnull readonly align 4 %70, i64 %71, i1 false), !alias.scope !457, !noalias !448 + %72 = getelementptr inbounds nuw { [2 x i64] }, ptr %45, i64 %67 + %73 = shl nuw nsw i64 %68, 4 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %49, ptr nonnull readonly align 8 %72, i64 %73, i1 false), !alias.scope !461, !noalias !448 + %74 = getelementptr inbounds nuw i32, ptr %69, i64 %60 + %75 = load i32, ptr %74, align 4, !noalias !448, !noundef !6 + %72 = getelementptr inbounds nuw { [2 x i64] }, ptr %45, i64 %61 + %77 = load i64, ptr %72, align 8, !noalias !448, !noundef !6 + %78 = getelementptr inbounds nuw i8, ptr %76, i64 8 + %79 = load i64, ptr %78, align 8, !noalias !448, !noundef !6 + %75 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 184 + %81 = getelementptr inbounds nuw i32, ptr %80, i64 %42 + %82 = getelementptr inbounds nuw { [2 x i64] }, ptr %.sroa.03.010.i, i64 %42 + %83 = load i32, ptr %81, align 4, !noalias !465, !noundef !6 + store i32 %75, ptr %81, align 4, !noalias !465 + %84 = load i64, ptr %82, align 8, !noalias !465, !noundef !6 + %85 = getelementptr inbounds nuw i8, ptr %82, i64 8 + %86 = load i64, ptr %85, align 8, !noalias !465, !noundef !6 + store i64 %77, ptr %82, align 8, !noalias !465 + store i64 %79, ptr %85, align 8, !noalias !465 + %84 = getelementptr inbounds nuw i32, ptr %63, i64 %68 + store i32 %83, ptr %87, align 4, !noalias !448 + %88 = getelementptr inbounds nuw { [2 x i64] }, ptr %49, i64 %68 + store i64 %84, ptr %88, align 8, !noalias !448 + %89 = getelementptr inbounds nuw i8, ptr %88, i64 8 + store i64 %86, ptr %89, align 8, !noalias !448 %cond.i = icmp eq i64 %46, 0 br i1 %cond.i, label %"_ZN5alloc11collections5btree3fix178_$LT$impl$u20$alloc..collections..btree..node..NodeRef$LT$alloc..collections..btree..node..marker..Owned$C$K$C$V$C$alloc..collections..btree..node..marker..LeafOrInternal$GT$$GT$29fix_right_border_of_plentiful17h495e8ecb811dc167E.exit", label %93 @@ -3490,7 +3481,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; br label %101 101: ; preds = %101, %93 - %.sroa.0.06.i.i.i = phi i64 [ 0, %93 ], [ %102, %101 ] + %.sroa.0.06.i.i.i = phi i64 [ 0, %90 ], [ %102, %98 ] %102 = add nuw nsw i64 %.sroa.0.06.i.i.i, 1 %103 = getelementptr inbounds nuw ptr, ptr %94, i64 %.sroa.0.06.i.i.i %104 = load ptr, ptr %103, align 8, !noalias !475, !nonnull !6, !noundef !6 @@ -3506,8 +3497,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; ret void .preheader: ; preds = %29, %112 - %.sroa.5.0 = phi i64 [ %113, %112 ], [ 0, %29 ] - %.sroa.0.0 = phi ptr [ %109, %112 ], [ %.sroa.0.052, %29 ] + %.sroa.5.0 = phi i64 [ %113, %109 ], [ 0, %29 ] + %.sroa.0.0 = phi ptr [ %109, %109 ], [ %.sroa.0.052, %29 ] %108 = getelementptr inbounds nuw i8, ptr %.sroa.0.0, i64 176 %109 = load ptr, ptr %108, align 8, !noalias !481, !noundef !6 %.not.i19 = icmp eq ptr %109, null @@ -3570,8 +3561,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; br label %.loopexit54 .loopexit54: ; preds = %112, %128 - %.sroa.036.0 = phi ptr [ %121, %128 ], [ %109, %112 ] - %.sroa.637.0 = phi i64 [ %132, %128 ], [ %113, %112 ] + %.sroa.036.0 = phi ptr [ %121, %125 ], [ %109, %109 ] + %.sroa.637.0 = phi i64 [ %132, %125 ], [ %113, %109 ] %135 = add i64 %.sroa.637.0, -1 %136 = load volatile i8, ptr @__rust_no_alloc_shim_is_unstable, align 1 %137 = call noalias noundef align 8 dereferenceable_or_null(232) ptr @_RNvCshjvJWTf7CV5_7___rustc12___rust_alloc(i64 noundef range(i64 4, 329) 232, i64 noundef range(i64 4, 9) 8) #30 @@ -3580,7 +3571,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; 139: ; preds = %.loopexit54 invoke void @_ZN5alloc5alloc18handle_alloc_error17haa66aaa8cfcf3614E(i64 noundef 8, i64 noundef 232) #28 - to label %.noexc20 unwind label %110 + to label %.noexc19 unwind label %110 .noexc20: ; preds = %139 unreachable @@ -3594,7 +3585,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; br i1 %.not, label %._crit_edge, label %.lr.ph ._crit_edge: ; preds = %_ZN5alloc11collections5btree3mem7replace17hd0886a438924d0afE.exit31, %140 - %.sroa.042.0.lcssa = phi ptr [ %137, %140 ], [ %173, %_ZN5alloc11collections5btree3mem7replace17hd0886a438924d0afE.exit31 ] + %.sroa.042.0.lcssa = phi ptr [ %137, %137 ], [ %173, %_ZN5alloc11collections5btree3mem7replace17hd0886a438924d0afE.exit30 ] %143 = getelementptr inbounds nuw i8, ptr %.sroa.036.0, i64 230 %144 = load i16, ptr %143, align 2, !noundef !6 %145 = icmp ult i16 %144, 11 @@ -3602,7 +3593,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; 146: ; preds = %._crit_edge invoke void @_ZN4core9panicking5panic17h13ee8adf815f0d87E(ptr noalias noundef nonnull readonly align 1 @anon.467722f710d552998dd01561bebdcdae.46, i64 noundef 32, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.467722f710d552998dd01561bebdcdae.50) #28 - to label %.noexc22 unwind label %110 + to label %.noexc21 unwind label %110 .noexc22: ; preds = %146 unreachable @@ -3631,8 +3622,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; br i1 %160, label %.loopexit, label %.lr.ph.i23 .lr.ph.i23: ; preds = %147, %.lr.ph.i23 - %.sroa.03.06.i24 = phi i64 [ %168, %.lr.ph.i23 ], [ %.sroa.637.0, %147 ] - %.sroa.04.05.i25 = phi ptr [ %167, %.lr.ph.i23 ], [ %.sroa.036.0, %147 ] + %.sroa.03.06.i24 = phi i64 [ %168, %.lr.ph.i22 ], [ %.sroa.637.0, %144 ] + %.sroa.04.05.i25 = phi ptr [ %167, %.lr.ph.i22 ], [ %.sroa.036.0, %144 ] %161 = getelementptr inbounds nuw i8, ptr %.sroa.04.05.i25, i64 230 %162 = load i16, ptr %161, align 2, !noalias !498, !noundef !6 %163 = zext nneg i16 %162 to i64 @@ -3646,7 +3637,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; br i1 %169, label %.loopexit, label %.lr.ph.i23 .loopexit: ; preds = %.lr.ph.i23, %147, %186 - %.sroa.0.1 = phi ptr [ %.sroa.0.052, %186 ], [ %.sroa.036.0, %147 ], [ %167, %.lr.ph.i23 ] + %.sroa.0.1 = phi ptr [ %.sroa.0.052, %183 ], [ %.sroa.036.0, %144 ], [ %167, %.lr.ph.i22 ] %170 = load i64, ptr %2, align 8, !noundef !6 %171 = add i64 %170, 1 store i64 %171, ptr %2, align 8 @@ -3654,8 +3645,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; br label %23 .lr.ph: ; preds = %140, %_ZN5alloc11collections5btree3mem7replace17hd0886a438924d0afE.exit31 - %.sroa.02.063 = phi i64 [ %180, %_ZN5alloc11collections5btree3mem7replace17hd0886a438924d0afE.exit31 ], [ 0, %140 ] - %.sroa.042.061 = phi ptr [ %173, %_ZN5alloc11collections5btree3mem7replace17hd0886a438924d0afE.exit31 ], [ %137, %140 ] + %.sroa.02.063 = phi i64 [ %180, %_ZN5alloc11collections5btree3mem7replace17hd0886a438924d0afE.exit30 ], [ 0, %137 ] + %.sroa.042.061 = phi ptr [ %173, %_ZN5alloc11collections5btree3mem7replace17hd0886a438924d0afE.exit30 ], [ %137, %137 ] %172 = load volatile i8, ptr @__rust_no_alloc_shim_is_unstable, align 1, !noalias !504 %173 = call noalias noundef align 8 dereferenceable_or_null(328) ptr @_RNvCshjvJWTf7CV5_7___rustc12___rust_alloc(i64 noundef range(i64 4, 329) 328, i64 noundef range(i64 4, 9) 8) #30, !noalias !504 %174 = icmp eq ptr %173, null @@ -3663,7 +3654,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17ha03598a9e61be67cE.exit.i.i: ; 175: ; preds = %.lr.ph invoke void @_ZN5alloc5alloc18handle_alloc_error17haa66aaa8cfcf3614E(i64 noundef 8, i64 noundef 328) #28 - to label %.noexc.i28 unwind label %176, !noalias !504 + to label %.noexc.i27 unwind label %176, !noalias !504 .noexc.i28: ; preds = %175 unreachable diff --git a/bench/fish-rs/optimized/2jegnuo3b7uy1oojff5kt8alk.ll b/bench/fish-rs/optimized/2jegnuo3b7uy1oojff5kt8alk.ll index 4581893333c..8c85a9b45de 100644 --- a/bench/fish-rs/optimized/2jegnuo3b7uy1oojff5kt8alk.ll +++ b/bench/fish-rs/optimized/2jegnuo3b7uy1oojff5kt8alk.ll @@ -8163,90 +8163,91 @@ _ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread: ; preds = %32, %34 ; Function Attrs: nonlazybind uwtable define void @_ZN4fish3ast9Traversal13skip_children17hf84b006e48b1b98fE(ptr noalias noundef align 8 captures(none) dereferenceable(24) %0, ptr noundef nonnull align 1 %1, ptr noalias noundef readonly align 8 captures(address) dereferenceable(136) %2) unnamed_addr #1 { +.split: + %3 = alloca [24 x i8], align 8 %4 = alloca [24 x i8], align 8 - %5 = alloca [24 x i8], align 8 + %5 = alloca [48 x i8], align 8 %6 = alloca [48 x i8], align 8 - %7 = alloca [48 x i8], align 8 - %8 = getelementptr inbounds nuw i8, ptr %0, i64 16 - %9 = load i64, ptr %8, align 8, !noundef !4 - %10 = icmp ult i64 %9, 384307168202282326 - tail call void @llvm.assume(i1 %10) - %11 = getelementptr inbounds nuw i8, ptr %0, i64 8 - %12 = load ptr, ptr %11, align 8, !nonnull !4 - br label %13 + %7 = getelementptr inbounds nuw i8, ptr %0, i64 16 + %8 = load i64, ptr %7, align 8, !noundef !4 + %9 = icmp ult i64 %8, 384307168202282326 + tail call void @llvm.assume(i1 %9) + %10 = getelementptr inbounds nuw i8, ptr %0, i64 8 + %11 = load ptr, ptr %10, align 8, !nonnull !4 + br label %12 -13: ; preds = %19, %3 - %.sroa.01.0 = phi i64 [ %9, %3 ], [ %20, %19 ] +13: ; preds = %18, %.split + %.sroa.01.0 = phi i64 [ %8, %.split ], [ %19, %18 ] %.not = icmp eq i64 %.sroa.01.0, 0 - br i1 %.not, label %14, label %19, !prof !126 + br i1 %.not, label %14, label %18, !prof !126 14: ; preds = %13 - call void @llvm.lifetime.start.p0(ptr nonnull %6) - store ptr @anon.c3855246c02a9407b3365b2c3e5c0e37.447, ptr %6, align 8 - %15 = getelementptr inbounds nuw i8, ptr %6, i64 8 + call void @llvm.lifetime.start.p0(ptr nonnull %5) + store ptr @anon.c3855246c02a9407b3365b2c3e5c0e37.447, ptr %5, align 8 + %15 = getelementptr inbounds nuw i8, ptr %5, i64 8 store i64 1, ptr %15, align 8 - %16 = getelementptr inbounds nuw i8, ptr %6, i64 32 + %16 = getelementptr inbounds nuw i8, ptr %5, i64 32 store ptr null, ptr %16, align 8 - %17 = getelementptr inbounds nuw i8, ptr %6, i64 16 + %17 = getelementptr inbounds nuw i8, ptr %5, i64 16 store ptr inttoptr (i64 8 to ptr), ptr %17, align 8 - %18 = getelementptr inbounds nuw i8, ptr %6, i64 24 + %18 = getelementptr inbounds nuw i8, ptr %5, i64 24 store i64 0, ptr %18, align 8 - call void @_ZN4core9panicking9panic_fmt17h8d16370d7cdeaf7bE(ptr noalias noundef nonnull align 8 captures(none) dereferenceable(48) %6, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.c3855246c02a9407b3365b2c3e5c0e37.448) #26 + call void @_ZN4core9panicking9panic_fmt17h8d16370d7cdeaf7bE(ptr noalias noundef nonnull align 8 captures(none) dereferenceable(48) %5, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.c3855246c02a9407b3365b2c3e5c0e37.448) #26 unreachable -19: ; preds = %13 - %20 = add nsw i64 %.sroa.01.0, -1 - %21 = getelementptr inbounds nuw { i64, [2 x i64] }, ptr %12, i64 %20 - %22 = load i64, ptr %21, align 8, !range !49, !noundef !4 - %23 = trunc nuw i64 %22 to i1 - br i1 %23, label %24, label %13 +24: ; preds = %12 + %19 = add nsw i64 %.sroa.01.0, -1 + %20 = getelementptr inbounds nuw { i64, [2 x i64] }, ptr %11, i64 %19 + %21 = load i64, ptr %20, align 8, !range !49, !noundef !4 + %22 = trunc nuw i64 %21 to i1 + br i1 %22, label %23, label %12 -24: ; preds = %19 - %25 = getelementptr inbounds nuw i8, ptr %21, i64 8 - %26 = load ptr, ptr %25, align 8, !nonnull !4, !align !304, !noundef !4 - %27 = getelementptr inbounds nuw i8, ptr %21, i64 16 - %28 = load ptr, ptr %27, align 8, !nonnull !4, !align !45, !noundef !4 +23: ; preds = %18 + %24 = getelementptr inbounds nuw i8, ptr %20, i64 8 + %25 = load ptr, ptr %24, align 8, !nonnull !4, !align !304, !noundef !4 + %26 = getelementptr inbounds nuw i8, ptr %20, i64 16 + %27 = load ptr, ptr %26, align 8, !nonnull !4, !align !45, !noundef !4 tail call void @llvm.experimental.noalias.scope.decl(metadata !525) tail call void @llvm.experimental.noalias.scope.decl(metadata !528) - %29 = icmp eq ptr %1, %26 + %29 = icmp eq ptr %1, %25 br i1 %29, label %30, label %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread7, !prof !530 -30: ; preds = %24 - %31 = icmp eq ptr %2, %28 +30: ; preds = %23 + %31 = icmp eq ptr %2, %27 br i1 %31, label %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread, label %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit _ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit: ; preds = %30 - call void @llvm.lifetime.start.p0(ptr nonnull %5), !noalias !531 - %32 = getelementptr inbounds nuw i8, ptr %2, i64 64 - %33 = load ptr, ptr %32, align 8, !invariant.load !4, !alias.scope !525, !noalias !528, !nonnull !4 - call void %33(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %5, ptr noundef nonnull align 1 %1), !noalias !531 - %34 = load i64, ptr %5, align 8, !range !497, !noalias !531, !noundef !4 call void @llvm.lifetime.start.p0(ptr nonnull %4), !noalias !531 - %35 = getelementptr inbounds nuw i8, ptr %28, i64 64 - %36 = load ptr, ptr %35, align 8, !invariant.load !4, !alias.scope !528, !noalias !525, !nonnull !4 - call void %36(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %4, ptr noundef nonnull align 1 %26), !noalias !531 + %35 = getelementptr inbounds nuw i8, ptr %2, i64 64 + %36 = load ptr, ptr %35, align 8, !invariant.load !4, !alias.scope !525, !noalias !528, !nonnull !4 + call void %32(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %4, ptr noundef nonnull align 1 %1), !noalias !531 %37 = load i64, ptr %4, align 8, !range !497, !noalias !531, !noundef !4 - %38 = icmp eq i64 %34, %37 + call void @llvm.lifetime.start.p0(ptr nonnull %3), !noalias !531 + %34 = getelementptr inbounds nuw i8, ptr %27, i64 64 + %35 = load ptr, ptr %34, align 8, !invariant.load !4, !alias.scope !528, !noalias !525, !nonnull !4 + call void %35(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %3, ptr noundef nonnull align 1 %25), !noalias !531 + %36 = load i64, ptr %3, align 8, !range !497, !noalias !531, !noundef !4 + %37 = icmp eq i64 %33, %36 + call void @llvm.lifetime.end.p0(ptr nonnull %3), !noalias !531 call void @llvm.lifetime.end.p0(ptr nonnull %4), !noalias !531 - call void @llvm.lifetime.end.p0(ptr nonnull %5), !noalias !531 - br i1 %38, label %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread, label %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread7, !prof !532 + br i1 %37, label %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread, label %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread7, !prof !532 -_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread7: ; preds = %24, %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit - call void @llvm.lifetime.start.p0(ptr nonnull %7) - store ptr @anon.c3855246c02a9407b3365b2c3e5c0e37.451, ptr %7, align 8 - %39 = getelementptr inbounds nuw i8, ptr %7, i64 8 +_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread7: ; preds = %23, %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit + call void @llvm.lifetime.start.p0(ptr nonnull %6) + store ptr @anon.c3855246c02a9407b3365b2c3e5c0e37.451, ptr %6, align 8 + %39 = getelementptr inbounds nuw i8, ptr %6, i64 8 store i64 1, ptr %39, align 8 - %40 = getelementptr inbounds nuw i8, ptr %7, i64 32 + %40 = getelementptr inbounds nuw i8, ptr %6, i64 32 store ptr null, ptr %40, align 8 - %41 = getelementptr inbounds nuw i8, ptr %7, i64 16 + %41 = getelementptr inbounds nuw i8, ptr %6, i64 16 store ptr inttoptr (i64 8 to ptr), ptr %41, align 8 - %42 = getelementptr inbounds nuw i8, ptr %7, i64 24 + %42 = getelementptr inbounds nuw i8, ptr %6, i64 24 store i64 0, ptr %42, align 8 - call void @_ZN4core9panicking9panic_fmt17h8d16370d7cdeaf7bE(ptr noalias noundef nonnull align 8 captures(none) dereferenceable(48) %7, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.c3855246c02a9407b3365b2c3e5c0e37.452) #26 + call void @_ZN4core9panicking9panic_fmt17h8d16370d7cdeaf7bE(ptr noalias noundef nonnull align 8 captures(none) dereferenceable(48) %6, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.c3855246c02a9407b3365b2c3e5c0e37.452) #26 unreachable _ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit.thread: ; preds = %_ZN4fish3ast12is_same_node17h809b23b2f10f76bbE.exit, %30 - store i64 %20, ptr %8, align 8 + store i64 %19, ptr %7, align 8 ret void } diff --git a/bench/gromacs/optimized/splineutil.ll b/bench/gromacs/optimized/splineutil.ll index 24c96d5583a..f4c8e00d9ce 100644 --- a/bench/gromacs/optimized/splineutil.ll +++ b/bench/gromacs/optimized/splineutil.ll @@ -1207,7 +1207,7 @@ define void @_ZN3gmx8internal22vectorSecondDerivativeENS_8ArrayRefIKdEEd(ptr dea 18: ; preds = %16 invoke void @__cxa_throw(ptr %14, ptr nonnull @_ZTIN3gmx8APIErrorE, ptr nonnull @_ZN3gmx16GromacsExceptionD2Ev) #21 - to label %109 unwind label %21 + to label %102 unwind label %21 .thread: ; preds = %13 %19 = landingpad { ptr, i32 } @@ -1252,111 +1252,97 @@ define void @_ZN3gmx8internal22vectorSecondDerivativeENS_8ArrayRefIKdEEd(ptr dea .noexc56: ; preds = %24 %26 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %10) #24 store ptr %26, ptr %0, align 8, !tbaa !58 - %27 = getelementptr inbounds nuw i8, ptr %26, i64 %10 + %27 = getelementptr i8, ptr %26, i64 %10 %28 = getelementptr inbounds nuw i8, ptr %0, i64 16 store ptr %27, ptr %28, align 8, !tbaa !61 - store double 0.000000e+00, ptr %26, align 8, !tbaa !10 %29 = getelementptr i8, ptr %26, i64 8 - %30 = add nsw i64 %11, -1 - %31 = icmp eq i64 %30, 0 - br i1 %31, label %33, label %_ZSt6fill_nIPdmdET_S1_T0_RKT1_.exit.loopexit.i.i.i.i.i - -_ZSt6fill_nIPdmdET_S1_T0_RKT1_.exit.loopexit.i.i.i.i.i: ; preds = %.noexc56 - %.idx.i.i.i.i.i.i.i = shl nuw nsw i64 %30, 3 + %30 = add i64 %10, -8 tail call void @llvm.memset.p0.i64(ptr align 8 %29, i8 0, i64 %.idx.i.i.i.i.i.i.i, i1 false), !tbaa !10 - %32 = getelementptr inbounds nuw i8, ptr %29, i64 %.idx.i.i.i.i.i.i.i - br label %33 - -33: ; preds = %_ZSt6fill_nIPdmdET_S1_T0_RKT1_.exit.loopexit.i.i.i.i.i, %.noexc56 - %.0.i.i.i.i.i = phi ptr [ %29, %.noexc56 ], [ %32, %_ZSt6fill_nIPdmdET_S1_T0_RKT1_.exit.loopexit.i.i.i.i.i ] - %34 = getelementptr inbounds nuw i8, ptr %0, i64 8 - store ptr %.0.i.i.i.i.i, ptr %34, align 8, !tbaa !62 - %35 = getelementptr inbounds nuw i8, ptr %1, i64 32 - %36 = load double, ptr %35, align 8, !tbaa !10 - %37 = getelementptr inbounds nuw i8, ptr %1, i64 24 + %32 = getelementptr inbounds nuw i8, ptr %0, i64 8 + store ptr %27, ptr %30, align 8, !tbaa !62 + %31 = getelementptr inbounds nuw i8, ptr %1, i64 32 + %32 = load double, ptr %31, align 8, !tbaa !10 + %33 = getelementptr inbounds nuw i8, ptr %1, i64 24 + %34 = load double, ptr %33, align 8, !tbaa !10 + %35 = fmul double %34, -5.600000e+01 + %36 = tail call double @llvm.fmuladd.f64(double %32, double 1.100000e+01, double %35) + %37 = getelementptr i8, ptr %1, i64 16 %38 = load double, ptr %37, align 8, !tbaa !10 - %39 = fmul double %38, -5.600000e+01 - %40 = tail call double @llvm.fmuladd.f64(double %36, double 1.100000e+01, double %39) - %41 = getelementptr i8, ptr %1, i64 16 - %42 = load double, ptr %41, align 8, !tbaa !10 - %43 = tail call double @llvm.fmuladd.f64(double %42, double 1.140000e+02, double %40) - %44 = getelementptr inbounds nuw i8, ptr %1, i64 8 - %45 = load double, ptr %44, align 8, !tbaa !10 - %46 = tail call double @llvm.fmuladd.f64(double %45, double -1.040000e+02, double %43) - %47 = load double, ptr %1, align 8, !tbaa !10 - %48 = tail call double @llvm.fmuladd.f64(double %47, double 3.500000e+01, double %46) - %49 = fmul double %3, 1.200000e+01 - %50 = fmul double %3, %49 - %51 = fdiv double %48, %50 - store double %51, ptr %26, align 8, !tbaa !10 - %52 = fneg double %36 - %53 = tail call double @llvm.fmuladd.f64(double %38, double 4.000000e+00, double %52) - %54 = tail call double @llvm.fmuladd.f64(double %42, double 6.000000e+00, double %53) - %55 = tail call double @llvm.fmuladd.f64(double %45, double -2.000000e+01, double %54) - %56 = tail call double @llvm.fmuladd.f64(double %47, double 1.100000e+01, double %55) - %57 = fdiv double %56, %50 - store double %57, ptr %29, align 8, !tbaa !10 - %58 = ptrtoint ptr %.0.i.i.i.i.i to i64 - %59 = ptrtoint ptr %26 to i64 - %60 = sub i64 %58, %59 - %61 = ashr exact i64 %60, 3 - %62 = add nsw i64 %61, -2 - %63 = icmp ugt i64 %62, 2 - br i1 %63, label %.lr.ph, label %._crit_edge - -._crit_edge: ; preds = %.lr.ph, %33 - %64 = add nsw i64 %61, -1 - %65 = getelementptr inbounds double, ptr %1, i64 %64 + %39 = tail call double @llvm.fmuladd.f64(double %38, double 1.140000e+02, double %36) + %40 = getelementptr inbounds nuw i8, ptr %1, i64 8 + %41 = load double, ptr %40, align 8, !tbaa !10 + %42 = tail call double @llvm.fmuladd.f64(double %41, double -1.040000e+02, double %39) + %43 = load double, ptr %1, align 8, !tbaa !10 + %44 = tail call double @llvm.fmuladd.f64(double %43, double 3.500000e+01, double %42) + %45 = fmul double %3, 1.200000e+01 + %46 = fmul double %3, %45 + %47 = fdiv double %44, %46 + store double %47, ptr %26, align 8, !tbaa !10 + %48 = fneg double %32 + %49 = tail call double @llvm.fmuladd.f64(double %34, double 4.000000e+00, double %48) + %50 = tail call double @llvm.fmuladd.f64(double %38, double 6.000000e+00, double %49) + %51 = tail call double @llvm.fmuladd.f64(double %41, double -2.000000e+01, double %50) + %52 = tail call double @llvm.fmuladd.f64(double %43, double 1.100000e+01, double %51) + %53 = fdiv double %52, %46 + store double %53, ptr %29, align 8, !tbaa !10 + %54 = ashr exact i64 %10, 3 + %55 = add nsw i64 %54, -2 + %56 = icmp ugt i64 %55, 2 + br i1 %56, label %.lr.ph, label %._crit_edge + +._crit_edge:; preds = %.lr.ph, %.noexc56 + %57 = add nsw i64 %54, -1 + %58 = getelementptr inbounds double, ptr %1, i64 %57 + %59 = load double, ptr %58, align 8, !tbaa !10 + %60 = getelementptr inbounds double, ptr %1, i64 %55 + %61 = load double, ptr %60, align 8, !tbaa !10 + %62 = fmul double %61, -2.000000e+01 + %63 = tail call double @llvm.fmuladd.f64(double %59, double 1.100000e+01, double %62) + %64 = getelementptr i8, ptr %1, i64 %10 + %65 = getelementptr i8, ptr %64, i64 -24 %66 = load double, ptr %65, align 8, !tbaa !10 - %67 = getelementptr inbounds double, ptr %1, i64 %62 - %68 = load double, ptr %67, align 8, !tbaa !10 - %69 = fmul double %68, -2.000000e+01 - %70 = tail call double @llvm.fmuladd.f64(double %66, double 1.100000e+01, double %69) - %71 = getelementptr i8, ptr %1, i64 %60 - %72 = getelementptr i8, ptr %71, i64 -24 - %73 = load double, ptr %72, align 8, !tbaa !10 - %74 = tail call double @llvm.fmuladd.f64(double %73, double 6.000000e+00, double %70) - %75 = getelementptr i8, ptr %71, i64 -32 - %76 = load double, ptr %75, align 8, !tbaa !10 - %77 = tail call double @llvm.fmuladd.f64(double %76, double 4.000000e+00, double %74) - %78 = getelementptr i8, ptr %71, i64 -40 - %79 = load double, ptr %78, align 8, !tbaa !10 - %80 = fsub double %77, %79 - %81 = fdiv double %80, %50 - %82 = getelementptr inbounds nuw double, ptr %26, i64 %62 + %67 = tail call double @llvm.fmuladd.f64(double %66, double 6.000000e+00, double %63) + %68 = getelementptr i8, ptr %64, i64 -32 + %69 = load double, ptr %68, align 8, !tbaa !10 + %70 = tail call double @llvm.fmuladd.f64(double %69, double 4.000000e+00, double %67) + %71 = getelementptr i8, ptr %64, i64 -40 + %72 = load double, ptr %71, align 8, !tbaa !10 + %73 = fsub double %70, %72 + %74 = fdiv double %73, %46 + %75 = getelementptr inbounds nuw double, ptr %26, i64 %55 + store double %74, ptr %75, align 8, !tbaa !10 + %76 = fmul double %61, -1.040000e+02 + %77 = tail call double @llvm.fmuladd.f64(double %59, double 3.500000e+01, double %76) + %78 = tail call double @llvm.fmuladd.f64(double %66, double 1.140000e+02, double %77) + %79 = tail call double @llvm.fmuladd.f64(double %69, double -5.600000e+01, double %78) + %80 = tail call double @llvm.fmuladd.f64(double %72, double 1.100000e+01, double %79) + %81 = fdiv double %80, %46 + %82 = getelementptr inbounds nuw double, ptr %26, i64 %57 store double %81, ptr %82, align 8, !tbaa !10 - %83 = fmul double %68, -1.040000e+02 - %84 = tail call double @llvm.fmuladd.f64(double %66, double 3.500000e+01, double %83) - %85 = tail call double @llvm.fmuladd.f64(double %73, double 1.140000e+02, double %84) - %86 = tail call double @llvm.fmuladd.f64(double %76, double -5.600000e+01, double %85) - %87 = tail call double @llvm.fmuladd.f64(double %79, double 1.100000e+01, double %86) - %88 = fdiv double %87, %50 - %89 = getelementptr inbounds nuw double, ptr %26, i64 %64 - store double %88, ptr %89, align 8, !tbaa !10 ret void -.lr.ph: ; preds = %33, %.lr.ph - %90 = phi double [ %97, %.lr.ph ], [ %42, %33 ] - %.092 = phi i64 [ %95, %.lr.ph ], [ 2, %33 ] +.lr.ph: ; preds = %.noexc56, %.lr.ph + %90 = phi double [ %90, %.lr.ph ], [ %38, %.noexc56 ] + %.092 = phi i64 [ %95, %.lr.ph ], [ 2, %.noexc56 ] %91 = getelementptr double, ptr %1, i64 %.092 %92 = getelementptr i8, ptr %91, i64 16 %93 = load double, ptr %92, align 8, !tbaa !10 %94 = fneg double %93 %95 = add nuw i64 %.092, 1 %96 = getelementptr inbounds double, ptr %1, i64 %95 + %90 = load double, ptr %89, align 8, !tbaa !10 + %91 = tail call double @llvm.fmuladd.f64(double %90, double 1.600000e+01, double %87) + %92 = tail call double @llvm.fmuladd.f64(double %83, double -3.000000e+01, double %91) + %93 = getelementptr i8, ptr %84, i64 -8 + %94 = load double, ptr %93, align 8, !tbaa !10 + %95 = tail call double @llvm.fmuladd.f64(double %94, double 1.600000e+01, double %92) + %96 = getelementptr i8, ptr %84, i64 -16 %97 = load double, ptr %96, align 8, !tbaa !10 - %98 = tail call double @llvm.fmuladd.f64(double %97, double 1.600000e+01, double %94) - %99 = tail call double @llvm.fmuladd.f64(double %90, double -3.000000e+01, double %98) - %100 = getelementptr i8, ptr %91, i64 -8 - %101 = load double, ptr %100, align 8, !tbaa !10 - %102 = tail call double @llvm.fmuladd.f64(double %101, double 1.600000e+01, double %99) - %103 = getelementptr i8, ptr %91, i64 -16 - %104 = load double, ptr %103, align 8, !tbaa !10 - %105 = fsub double %102, %104 - %106 = fdiv double %105, %50 - %107 = getelementptr inbounds nuw double, ptr %26, i64 %.092 - store double %106, ptr %107, align 8, !tbaa !10 - %exitcond.not = icmp eq i64 %95, %62 + %98 = fsub double %95, %97 + %99 = fdiv double %98, %46 + %100 = getelementptr inbounds nuw double, ptr %26, i64 %.092 + store double %99, ptr %100, align 8, !tbaa !10 + %exitcond.not = icmp eq i64 %88, %55 br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !63 108: ; preds = %21, %23 diff --git a/bench/hermes/optimized/APInt.ll b/bench/hermes/optimized/APInt.ll index f8866b9cf9a..d4bc6ae0ee2 100644 --- a/bench/hermes/optimized/APInt.ll +++ b/bench/hermes/optimized/APInt.ll @@ -6170,13 +6170,10 @@ _ZN4llvh5APIntlSEj.exit: ; preds = %if.end14 %sh_prom.i.i107 = zext nneg i32 %sub2.i.i106 to i64 %shr.i.i108 = lshr i64 -1, %sh_prom.i.i107 %and.i.i109 = and i64 %shr.i.i108, %or - %26 = trunc nuw nsw i64 %and to i32 - %sub16173 = add nsw i32 %26, -1075 - %cmp.i = icmp eq i32 %sub16173, %width - %sh_prom.i = zext nneg i32 %sub16173 to i64 + %sub16173 = add nuw nsw i64 %and, 4294966221 + %sh_prom.i = and i64 %sub16173, 4294967295 %shl.i = shl i64 %and.i.i109, %sh_prom.i - %storemerge.i = select i1 %cmp.i, i64 0, i64 %shl.i - %and.i.i119 = and i64 %storemerge.i, %shr.i.i108 + %and.i.i119 = and i64 %shl.i, %shr.i.i108 br i1 %tobool.not, label %if.then.i124, label %cleanup.done26.thread195 _ZN4llvh5APIntlSEj.exit.thread: ; preds = %if.end5.i, %if.end17.i.i diff --git a/bench/image-rs/optimized/5ez7udly19o3uj1p.ll b/bench/image-rs/optimized/5ez7udly19o3uj1p.ll index 10635a9ad04..863e000f079 100644 --- a/bench/image-rs/optimized/5ez7udly19o3uj1p.ll +++ b/bench/image-rs/optimized/5ez7udly19o3uj1p.ll @@ -274,7 +274,6 @@ target triple = "x86_64-unknown-linux-gnu" @anon.dbc83011fcb707429349569d3c6bc524.351 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.dbc83011fcb707429349569d3c6bc524.323, [16 x i8] c"\1B\00\00\00\00\00\00\00\FB\01\00\00#\00\00\00" }>, align 8 @anon.dbc83011fcb707429349569d3c6bc524.352 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.dbc83011fcb707429349569d3c6bc524.323, [16 x i8] c"\1B\00\00\00\00\00\00\00\00\02\00\00$\00\00\00" }>, align 8 @anon.dbc83011fcb707429349569d3c6bc524.353 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.dbc83011fcb707429349569d3c6bc524.323, [16 x i8] c"\1B\00\00\00\00\00\00\00\02\02\00\00#\00\00\00" }>, align 8 -@anon.dbc83011fcb707429349569d3c6bc524.354 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.dbc83011fcb707429349569d3c6bc524.323, [16 x i8] c"\1B\00\00\00\00\00\00\00\04\02\00\00(\00\00\00" }>, align 8 @anon.dbc83011fcb707429349569d3c6bc524.356 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.dbc83011fcb707429349569d3c6bc524.323, [16 x i8] c"\1B\00\00\00\00\00\00\00\1F\02\00\00\15\00\00\00" }>, align 8 @anon.dbc83011fcb707429349569d3c6bc524.357 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.dbc83011fcb707429349569d3c6bc524.323, [16 x i8] c"\1B\00\00\00\00\00\00\00\22\02\00\00\15\00\00\00" }>, align 8 @anon.dbc83011fcb707429349569d3c6bc524.358 = private unnamed_addr constant <{ [12 x i8] }> <{ [12 x i8] c"Image index " }>, align 1 @@ -33784,7 +33783,7 @@ define void @_ZN5image6codecs4webp8extended10WebPStatic16from_alpha_lossy17hf358 %.sroa.53.0..sroa_idx.i = getelementptr inbounds nuw i8, ptr %7, i64 1 store i8 3, ptr %.sroa.53.0..sroa_idx.i, align 1, !noalias !4397 %24 = invoke noundef nonnull align 8 ptr @_ZN5alloc5alloc15exchange_malloc17hbe31f2048284b3faE.llvm.9742654456972663382(i64 noundef 24, i64 noundef 8) - to label %190 unwind label %25, !noalias !4389 + to label %188 unwind label %25, !noalias !4389 25: ; preds = %23 %26 = landingpad { ptr, i32 } @@ -33799,7 +33798,7 @@ define void @_ZN5image6codecs4webp8extended10WebPStatic16from_alpha_lossy17hf358 unreachable .body: ; preds = %47, %.body36, %29, %25, %187 - %.pn = phi { ptr, i32 } [ %lpad.thr_comm, %187 ], [ %lpad.thr_comm.split-lp, %.body36 ], [ %30, %29 ], [ %26, %25 ], [ %48, %47 ] + %.pn = phi { ptr, i32 } [ %lpad.thr_comm, %185 ], [ %lpad.thr_comm.split-lp, %.body36 ], [ %30, %29 ], [ %26, %25 ], [ %48, %47 ] invoke void @"_ZN4core3ptr52drop_in_place$LT$image..codecs..webp..vp8..Frame$GT$17h69ec787f0a78d900E"(ptr noalias noundef nonnull align 8 dereferenceable(88) %2) #22 to label %72 unwind label %188 @@ -33850,8 +33849,8 @@ define void @_ZN5image6codecs4webp8extended10WebPStatic16from_alpha_lossy17hf358 br label %._crit_edge ._crit_edge: ; preds = %.lr.ph110, %._crit_edge.loopexit114, %36 - %40 = phi i16 [ %.pre153, %._crit_edge.loopexit114 ], [ 0, %36 ], [ %37, %.lr.ph110 ] - %41 = phi i16 [ %.pre, %._crit_edge.loopexit114 ], [ %.pre152, %36 ], [ 0, %.lr.ph110 ] + %40 = phi i16 [ %.pre153, %._crit_edge.loopexit109 ], [ 0, %36 ], [ %37, %.lr.ph105 ] + %41 = phi i16 [ %.pre, %._crit_edge.loopexit109 ], [ %.pre152, %36 ], [ 0, %.lr.ph105 ] %42 = zext i16 %41 to i32 %43 = zext i16 %40 to i32 call void @llvm.lifetime.start.p0(ptr nonnull %8) @@ -33907,7 +33906,7 @@ define void @_ZN5image6codecs4webp8extended10WebPStatic16from_alpha_lossy17hf358 unreachable .lr.ph110.split: ; preds = %.lr.ph110.split.preheader, %.loopexit - %indvars.iv147 = phi i64 [ 0, %.lr.ph110.split.preheader ], [ %indvars.iv.next148, %.loopexit ] + %indvars.iv147 = phi i64 [ 0, %.lr.ph105.split.preheader ], [ %indvars.iv.next148, %.loopexit ] %indvars.iv.next148 = add nuw nsw i64 %indvars.iv147, 1 %61 = load i16, ptr %12, align 8, !noundef !19 %.not113 = icmp eq i16 %61, 0 @@ -33954,7 +33953,7 @@ define void @_ZN5image6codecs4webp8extended10WebPStatic16from_alpha_lossy17hf358 72: ; preds = %73, %.body %.pn27 = phi { ptr, i32 } [ %74, %73 ], [ %.pn, %.body ] invoke void @"_ZN4core3ptr62drop_in_place$LT$image..codecs..webp..extended..AlphaChunk$GT$17he6cc29becc3dfeebE"(ptr noalias noundef nonnull align 8 dereferenceable(32) %1) #22 - to label %198 unwind label %188 + to label %196 unwind label %188 73: ; preds = %68, %190 %74 = landingpad { ptr, i32 } @@ -33984,7 +33983,7 @@ define void @_ZN5image6codecs4webp8extended10WebPStatic16from_alpha_lossy17hf358 ret void 83: ; preds = %.lr.ph, %183 - %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %183 ] + %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %181 ] %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 %84 = load i16, ptr %12, align 8, !noundef !19 %85 = zext i16 %84 to i64 @@ -34036,10 +34035,10 @@ default.unreachable: ; preds = %83 %107 = load i8, ptr %106, align 1, !alias.scope !4428, !noundef !19 br label %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit -.invoke: ; preds = %179, %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit, %168, %160, %151, %147, %133, %119, %115, %99, %95 - %108 = phi i64 [ %97, %95 ], [ %103, %99 ], [ %117, %115 ], [ %123, %119 ], [ %135, %133 ], [ %149, %147 ], [ %155, %151 ], [ %166, %160 ], [ %169, %168 ], [ %177, %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit ], [ %181, %179 ] - %109 = phi i64 [ %21, %95 ], [ %21, %99 ], [ %21, %115 ], [ %21, %119 ], [ %21, %133 ], [ %21, %147 ], [ %21, %151 ], [ %21, %160 ], [ %21, %168 ], [ %.val30, %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit ], [ %21, %179 ] - %110 = phi ptr [ @anon.dbc83011fcb707429349569d3c6bc524.346, %95 ], [ @anon.dbc83011fcb707429349569d3c6bc524.347, %99 ], [ @anon.dbc83011fcb707429349569d3c6bc524.348, %115 ], [ @anon.dbc83011fcb707429349569d3c6bc524.349, %119 ], [ @anon.dbc83011fcb707429349569d3c6bc524.350, %133 ], [ @anon.dbc83011fcb707429349569d3c6bc524.351, %147 ], [ @anon.dbc83011fcb707429349569d3c6bc524.352, %151 ], [ @anon.dbc83011fcb707429349569d3c6bc524.353, %160 ], [ @anon.dbc83011fcb707429349569d3c6bc524.354, %168 ], [ @anon.dbc83011fcb707429349569d3c6bc524.343, %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit ], [ @anon.dbc83011fcb707429349569d3c6bc524.345, %179 ] +.invoke: ; preds = %179, %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit, %160, %151, %147, %133, %119, %115, %99, %95 + %108 = phi i64 [ %97, %95 ], [ %103, %99 ], [ %117, %115 ], [ %123, %119 ], [ %135, %133 ], [ %149, %147 ], [ %155, %151 ], [ %164, %160 ], [ %177, %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit ], [ %181, %177 ] + %109 = phi i64 [ %21, %95 ], [ %21, %99 ], [ %21, %115 ], [ %21, %119 ], [ %21, %133 ], [ %21, %147 ], [ %21, %151 ], [ %21, %160 ], [ %.val30, %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit ], [ %21, %177 ] + %110 = phi ptr [ @anon.dbc83011fcb707429349569d3c6bc524.346, %95 ], [ @anon.dbc83011fcb707429349569d3c6bc524.347, %99 ], [ @anon.dbc83011fcb707429349569d3c6bc524.348, %115 ], [ @anon.dbc83011fcb707429349569d3c6bc524.349, %119 ], [ @anon.dbc83011fcb707429349569d3c6bc524.350, %133 ], [ @anon.dbc83011fcb707429349569d3c6bc524.351, %147 ], [ @anon.dbc83011fcb707429349569d3c6bc524.352, %151 ], [ @anon.dbc83011fcb707429349569d3c6bc524.353, %160 ], [ @anon.dbc83011fcb707429349569d3c6bc524.343, %_ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit ], [ @anon.dbc83011fcb707429349569d3c6bc524.345, %177 ] invoke void @_ZN4core9panicking18panic_bounds_check17h8331054858f0bf20E(i64 noundef %108, i64 noundef %109, ptr noalias noundef readonly align 8 dereferenceable(24) %110) #21 to label %.cont unwind label %187 @@ -34090,10 +34089,10 @@ default.unreachable: ; preds = %83 %136 = icmp ult i64 %135, %21 br i1 %136, label %144, label %.invoke, !prof !480 -"_ZN4core6result19Result$LT$T$C$E$GT$6unwrap17he2ec3fd6191bb3d2E.exit.i": ; preds = %171, %157, %144, %131 - %.013.i = phi i8 [ %146, %144 ], [ %159, %157 ], [ %173, %171 ], [ 0, %131 ] - %.012.i = phi i8 [ %146, %144 ], [ %159, %157 ], [ %162, %171 ], [ 0, %131 ] - %.0.i = phi i8 [ %146, %144 ], [ %159, %157 ], [ %175, %171 ], [ 0, %131 ] +"_ZN4core6result19Result$LT$T$C$E$GT$6unwrap17he2ec3fd6191bb3d2E.exit.i": ; preds = %166, %157, %144, %131 + %.013.i = phi i8 [ %146, %144 ], [ %159, %157 ], [ %170, %166 ], [ 0, %131 ] + %.012.i = phi i8 [ %146, %144 ], [ %159, %157 ], [ %168, %166 ], [ 0, %131 ] + %.0.i = phi i8 [ %146, %144 ], [ %159, %157 ], [ %173, %166 ], [ 0, %131 ] %137 = zext i8 %.012.i to i16 %138 = zext i8 %.013.i to i16 %139 = add nuw nsw i16 %137, %138 @@ -34129,25 +34128,21 @@ default.unreachable: ; preds = %83 br label %"_ZN4core6result19Result$LT$T$C$E$GT$6unwrap17he2ec3fd6191bb3d2E.exit.i" 160: ; preds = %151 - %161 = getelementptr inbounds nuw i8, ptr %33, i64 %155 - %162 = load i8, ptr %161, align 1, !alias.scope !4428, !noundef !19 - %163 = mul nuw nsw i64 %63, %85 - %164 = add nuw nsw i64 %163, %indvars.iv - %165 = shl nuw nsw i64 %164, 2 - %166 = or disjoint i64 %165, 3 - %167 = icmp samesign ult i64 %166, %21 - br i1 %167, label %168, label %.invoke, !prof !480 - -168: ; preds = %160 - %169 = add nsw i64 %165, -1 - %170 = icmp ult i64 %169, %21 - br i1 %170, label %171, label %.invoke, !prof !480 - -171: ; preds = %168 - %172 = getelementptr inbounds nuw i8, ptr %33, i64 %166 + %161 = mul nuw nsw i64 %63, %85 + %162 = add nuw nsw i64 %161, %indvars.iv + %163 = shl nuw nsw i64 %162, 2 + %164 = or disjoint i64 %163, 3 + %165 = icmp samesign ult i64 %164, %21 + br i1 %165, label %166, label %.invoke, !prof !480 + +166:; preds = %160 + %167 = getelementptr inbounds nuw i8, ptr %33, i64 %155 + %168 = load i8, ptr %167, align 1, !alias.scope !4428, !noundef !19 + %169 = getelementptr inbounds nuw i8, ptr %33, i64 %164 + %170 = load i8, ptr %169, align 1, !alias.scope !4428, !noundef !19 + %171 = getelementptr i8, ptr %33, i64 %163 + %172 = getelementptr i8, ptr %171, i64 -1 %173 = load i8, ptr %172, align 1, !alias.scope !4428, !noundef !19 - %174 = getelementptr inbounds nuw i8, ptr %33, i64 %169 - %175 = load i8, ptr %174, align 1, !alias.scope !4428, !noundef !19 br label %"_ZN4core6result19Result$LT$T$C$E$GT$6unwrap17he2ec3fd6191bb3d2E.exit.i" _ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.exit: ; preds = %"_ZN4core6result19Result$LT$T$C$E$GT$6unwrap17he2ec3fd6191bb3d2E.exit.i", %128, %125, %111, %105, %89, %87, %83 @@ -34199,7 +34194,7 @@ _ZN5image6codecs4webp8extended10WebPStatic13get_predictor17heffafe2d87fabaa7E.ex %.sroa.7.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 48 store ptr @anon.1f4c41b43b6b1ec3b0d7299236cb1468.22.llvm.9742654456972663382, ptr %.sroa.7.0..sroa_idx, align 8 invoke void @"_ZN4core3ptr52drop_in_place$LT$image..codecs..webp..vp8..Frame$GT$17h69ec787f0a78d900E"(ptr noalias noundef nonnull align 8 dereferenceable(88) %2) - to label %191 unwind label %73 + to label %189 unwind label %73 191: ; preds = %190 call void @llvm.lifetime.start.p0(ptr nonnull %4), !noalias !4432 diff --git a/bench/libigl/optimized/min_quad_with_fixed.2.ll b/bench/libigl/optimized/min_quad_with_fixed.2.ll index fc5727439a3..5d53c8d89c8 100644 --- a/bench/libigl/optimized/min_quad_with_fixed.2.ll +++ b/bench/libigl/optimized/min_quad_with_fixed.2.ll @@ -10129,47 +10129,20 @@ _ZN5Eigen8internal23check_size_for_overflowIiEEvm.exit.i.i.i103: ; preds = %37 %51 = trunc nuw nsw i64 %50 to i32 %52 = add nsw i32 %51, -1 %53 = sdiv i32 %49, %52 - %54 = tail call i64 @llvm.abs.i64(i64 %48, i1 true) - %55 = trunc nuw i64 %54 to i32 - %56 = add i32 %49, %55 - %57 = tail call noundef i32 @llvm.abs.i32(i32 %49, i1 true) - %58 = add nuw nsw i32 %57, 1 - %59 = sdiv i32 %56, %58 - %60 = icmp sgt i32 %.sroa.speculated151, 1 - br i1 %60, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i - -_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i: ; preds = %.loopexit192 - %61 = icmp eq i32 %.sroa.speculated151, 1 - br i1 %61, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit - -_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i - br label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i - -.lr.ph.i.i.i.i.i.i.i.i.i.i.i: ; preds = %.loopexit192 - %62 = icmp samesign ugt i32 %.sroa.speculated151, %58 - br i1 %62, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader - -_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i - %.05.us.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %66, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i ] - %63 = trunc i64 %.05.us.i.i.i.i.i.i.i.i.i.i.i to i32 - %64 = sdiv i32 %63, %59 - %65 = getelementptr inbounds nuw i32, ptr %.pre, i64 %.05.us.i.i.i.i.i.i.i.i.i.i.i - store i32 %64, ptr %65, align 4, !tbaa !97 - %66 = add nuw nsw i64 %.05.us.i.i.i.i.i.i.i.i.i.i.i, 1 - %exitcond7.not.i.i.i.i.i.i.i.i.i.i.i = icmp eq i64 %66, %48 - br i1 %exitcond7.not.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i, !llvm.loop !294 - -_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i: ; preds = %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i - %.05.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %70, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader ] - %67 = trunc i64 %.05.i.i.i.i.i.i.i.i.i.i.i to i32 - %68 = mul nsw i32 %53, %67 - %69 = getelementptr inbounds nuw i32, ptr %.pre, i64 %.05.i.i.i.i.i.i.i.i.i.i.i - store i32 %68, ptr %69, align 4, !tbaa !97 - %70 = add nuw nsw i64 %.05.i.i.i.i.i.i.i.i.i.i.i, 1 - %exitcond.not.i.i.i.i.i.i.i.i.i.i.i = icmp eq i64 %70, %48 + %or.cond = icmp sgt i32 %.sroa.speculated151, 0 + br i1 %or.cond, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit + +_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i:; preds = %.loopexit192, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i + %.05.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %57, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %.loopexit192 ] + %54 = trunc i64 %.05.i.i.i.i.i.i.i.i.i.i.i to i32 + %55 = mul nsw i32 %53, %54 + %56 = getelementptr inbounds nuw i32, ptr %.pre, i64 %.05.i.i.i.i.i.i.i.i.i.i.i + store i32 %55, ptr %56, align 4, !tbaa !97 + %57 = add nuw nsw i64 %.05.i.i.i.i.i.i.i.i.i.i.i, 1 + %61 = icmp eq i64 %57, %48 br i1 %exitcond.not.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i, !llvm.loop !294 -_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit: ; preds = %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i +_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit: ; preds = %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i, %.loopexit192 br i1 %11, label %.lr.ph195, label %._crit_edge204 .lr.ph195: ; preds = %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit @@ -10195,7 +10168,7 @@ _ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EE br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit.us _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit.us: ; preds = %79, %.lr.ph195.split.us - %.071.us = phi i32 [ %81, %79 ], [ %78, %.lr.ph195.split.us ] + %.071.us = phi i32 [ %81, %66 ], [ %78, %.lr.ph195.split.us ] %82 = sext i32 %.071.us to i64 %83 = getelementptr inbounds i32, ptr %74, i64 %82 %84 = load i32, ptr %83, align 4, !tbaa !97 @@ -10259,7 +10232,7 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit: ; preds = %108, %.lr.ph195.split - %.071 = phi i32 [ %110, %108 ], [ %107, %.lr.ph195.split ] + %.071 = phi i32 [ %110, %95 ], [ %107, %.lr.ph195.split ] %111 = sext i32 %.071 to i64 %112 = getelementptr inbounds i32, ptr %74, i64 %111 %113 = load i32, ptr %112, align 4, !tbaa !97 @@ -10312,7 +10285,7 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %136 136: ; preds = %133, %127 - %.056 = phi i32 [ %135, %133 ], [ %130, %127 ] + %.056 = phi i32 [ %135, %120 ], [ %130, %114 ] %137 = sext i32 %.056 to i64 %138 = getelementptr inbounds i32, ptr %100, i64 %137 %139 = load i32, ptr %138, align 4, !tbaa !97 @@ -10333,21 +10306,21 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109: ; preds = %141, %145 - %.sink.i108 = phi i64 [ %144, %141 ], [ %149, %145 ] + %.sink.i108 = phi i64 [ %144, %128 ], [ %149, %132 ] %150 = icmp sle i64 %.sink.i108, %140 %.not190196 = select i1 %150, i1 %128, i1 false br i1 %.not190196, label %._crit_edge201, label %.lr.ph200 -._crit_edge201: ; preds = %172, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 +._crit_edge201: ; preds = %159, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 %indvars.iv.next215 = add nuw nsw i64 %indvars.iv214, 1 %exitcond218.not = icmp eq i64 %indvars.iv.next215, %wide.trip.count217 br i1 %exitcond218.not, label %._crit_edge204, label %127, !llvm.loop !297 -.lr.ph200: ; preds = %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109, %172 - %151 = phi i1 [ %174, %172 ], [ %150, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] - %.066199 = phi i32 [ %.167, %172 ], [ %130, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] - %.069198 = phi i1 [ %spec.select, %172 ], [ %128, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] - %.sroa.7.0197 = phi i64 [ %173, %172 ], [ %140, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] +.lr.ph200: ; preds = %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109, %159 + %151 = phi i1 [ %161, %159 ], [ %150, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] + %.066199 = phi i32 [ %.167, %159 ], [ %130, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] + %.069198 = phi i1 [ %spec.select, %159 ], [ %128, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] + %.sroa.7.0197 = phi i64 [ %160, %159 ], [ %140, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] br i1 %151, label %156, label %152 152: ; preds = %.lr.ph200 @@ -10357,14 +10330,14 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %156 156: ; preds = %.lr.ph200, %152 - %.055 = phi i64 [ %155, %152 ], [ %indvars.iv214, %.lr.ph200 ] + %.055 = phi i64 [ %155, %139 ], [ %indvars.iv214, %.lr.ph200 ] %157 = icmp eq i64 %.055, %indvars.iv214 %spec.select = select i1 %157, i1 true, i1 %.069198 %158 = getelementptr inbounds i32, ptr %.pre, i64 %.055 %159 = load i32, ptr %158, align 4, !tbaa !97 %160 = sext i32 %159 to i64 %.not78 = icmp sgt i64 %indvars.iv214, %160 - br i1 %.not78, label %161, label %172 + br i1 %.not78, label %161, label %159 161: ; preds = %156 %.014.in18.i = getelementptr inbounds i32, ptr %.sroa.0131.0181, i64 %160 @@ -10376,8 +10349,8 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br i1 %.not23.i, label %.loopexit, label %.lr.ph.i .lr.ph.i: ; preds = %161, %.lr.ph.i - %.025.i = phi i32 [ %.0.i, %.lr.ph.i ], [ %.022.i, %161 ] - %.01524.i = phi i32 [ %.025.i, %.lr.ph.i ], [ %159, %161 ] + %.025.i = phi i32 [ %.0.i, %.lr.ph.i ], [ %.022.i, %148 ] + %.01524.i = phi i32 [ %.025.i, %.lr.ph.i ], [ %159, %148 ] %162 = sext i32 %.01524.i to i64 %163 = getelementptr inbounds i32, ptr %.sroa.0131.0181, i64 %162 store i32 %.025.i, ptr %163, align 4, !tbaa !97 @@ -10391,34 +10364,34 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br i1 %.not.i, label %.loopexit, label %.lr.ph.i, !llvm.loop !298 .loopexit: ; preds = %.lr.ph.i, %161 - %.pre-phi = phi i64 [ %.pn20.i, %161 ], [ %.pn.i, %.lr.ph.i ] - %.014.lcssa.i = phi i32 [ %.01419.i, %161 ], [ %.014.i, %.lr.ph.i ] + %.pre-phi = phi i64 [ %.pn20.i, %148 ], [ %.pn.i, %.lr.ph.i ] + %.014.lcssa.i = phi i32 [ %.01419.i, %148 ], [ %.014.i, %.lr.ph.i ] %164 = getelementptr inbounds i32, ptr %.sroa.0139.0166173180, i64 %.pre-phi %165 = load i32, ptr %164, align 4, !tbaa !97 %166 = zext i32 %165 to i64 %.not79 = icmp eq i64 %indvars.iv214, %166 - br i1 %.not79, label %172, label %167 - -167: ; preds = %.loopexit - %168 = sext i32 %165 to i64 - %169 = getelementptr inbounds i32, ptr %96, i64 %168 - store i32 %130, ptr %169, align 4, !tbaa !97 - %170 = sext i32 %.066199 to i64 - %171 = getelementptr inbounds i32, ptr %.sroa.0131.0181, i64 %170 - store i32 %.014.lcssa.i, ptr %171, align 4, !tbaa !97 - store i32 %130, ptr %164, align 4, !tbaa !97 - br label %172 + br i1 %.not79, label %159, label %172 -172: ; preds = %.loopexit, %167, %156 - %.167 = phi i32 [ %.066199, %156 ], [ %.014.lcssa.i, %167 ], [ %.066199, %.loopexit ] - %173 = add nsw i64 %.sroa.7.0197, 1 - %174 = icmp sge i64 %173, %.sink.i108 - %.not190 = select i1 %174, i1 %spec.select, i1 false +172: ; preds = %.loopexit + %155 = sext i32 %152 to i64 + %156 = getelementptr inbounds i32, ptr %83, i64 %155 + store i32 %117, ptr %156, align 4, !tbaa !97 + %157 = sext i32 %.066199 to i64 + %158 = getelementptr inbounds i32, ptr %.sroa.0131.0181, i64 %157 + store i32 %.014.lcssa.i, ptr %158, align 4, !tbaa !97 + store i32 %117, ptr %151, align 4, !tbaa !97 + br label %159 + +159: ; preds = %.loopexit, %154, %143 + %.167 = phi i32 [ %.066199, %143 ], [ %.014.lcssa.i, %154 ], [ %.066199, %.loopexit ] + %160 = add nsw i64 %.sroa.7.0197, 1 + %161 = icmp sge i64 %160, %.sink.i108 + %.not190 = select i1 %161, i1 %spec.select, i1 false br i1 %.not190, label %._crit_edge201, label %.lr.ph200, !llvm.loop !299 .body: ; preds = %105, %20 - %.sroa.0139.0167 = phi ptr [ %.sroa.0139.0166173180, %105 ], [ %calloc, %20 ] - %.pn84.pn.pn.pn.pn = phi { ptr, i32 } [ %106, %105 ], [ %21, %20 ] + %.sroa.0139.0167 = phi ptr [ %.sroa.0139.0166173180, %92 ], [ %calloc, %20 ] + %.pn84.pn.pn.pn.pn = phi { ptr, i32 } [ %106, %92 ], [ %21, %20 ] tail call void @free(ptr noundef %.sroa.0139.0167) #33 resume { ptr, i32 } %.pn84.pn.pn.pn.pn } @@ -55542,9 +55515,6 @@ declare i32 @llvm.smin.i32(i32, i32) #30 ; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none) declare i32 @llvm.smax.i32(i32, i32) #30 -; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none) -declare i64 @llvm.abs.i64(i64, i1 immarg) #30 - attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" } attributes #1 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" } attributes #2 = { mustprogress uwtable "min-legal-vector-width"="128" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" } diff --git a/bench/llvm/optimized/APInt.ll b/bench/llvm/optimized/APInt.ll index 35bf6ca3e8d..cb5172e4702 100644 --- a/bench/llvm/optimized/APInt.ll +++ b/bench/llvm/optimized/APInt.ll @@ -6028,20 +6028,15 @@ _ZN4llvm5APIntD2Ev.exit: ; preds = %_ZN4llvm5APInt11tcI br label %_ZN4llvm5APIntlSEj.exit.thread _ZN4llvm5APIntlSEj.exit: ; preds = %86 - %135 = trunc nuw nsw i64 %6 to i32 - %136 = add nsw i32 %135, -1075 - %137 = icmp eq i32 %136, %2 - %138 = zext nneg i32 %136 to i64 - %139 = shl i64 %20, %138 - %storemerge.i = select i1 %137, i64 0, i64 %139 - %140 = add nuw nsw i32 %2, 63 - %141 = and i32 %140, 63 - %142 = xor i32 %141, 63 - %143 = zext nneg i32 %142 to i64 - %144 = lshr i64 -1, %143 - %145 = icmp eq i32 %2, 0 - %spec.select.i = select i1 %145, i64 0, i64 %144, !prof !11 - %146 = and i64 %storemerge.i, %spec.select.i + %135 = add nuw nsw i64 %6, 4294966221 + %136 = and i64 %135, 4294967295 + %137 = shl i64 %20, %136 + %138 = add nuw nsw i32 %2, 63 + %139 = and i32 %138, 63 + %140 = xor i32 %139, 63 + %141 = zext nneg i32 %140 to i64 + %142 = lshr i64 -1, %141 + %143 = and i64 %137, %142 br i1 %.not, label %_ZN4llvm5APIntC2ERKS0_.exit44.thread, label %_ZN4llvm5APIntC2ERKS0_.exit44.thread.thread102 _ZN4llvm5APIntlSEj.exit.thread: ; preds = %.loopexit.i.i, %88 @@ -6106,7 +6101,7 @@ _ZN4llvm5APIntC2ERKS0_.exit44.thread.thread104: ; preds = %.lr.ph.i.i.i1.i.i33 _ZN4llvm5APIntC2ERKS0_.exit44.thread.thread102: ; preds = %_ZN4llvm5APIntlSEj.exit %171 = getelementptr inbounds nuw i8, ptr %0, i64 8 store i32 %2, ptr %171, align 8, !tbaa !3 - store i64 %146, ptr %0, align 8, !tbaa !8 + store i64 %143, ptr %0, align 8, !tbaa !8 br label %_ZN4llvm5APIntC2Ejmbb.exit _ZN4llvm5APIntC2ERKS0_.exit44.thread.thread: ; preds = %_ZN4llvm5APIntlSEj.exit.thread @@ -6118,9 +6113,9 @@ _ZN4llvm5APIntC2ERKS0_.exit44.thread.thread: ; preds = %_ZN4llvm5APIntlSEj. br label %178 _ZN4llvm5APIntC2ERKS0_.exit44.thread: ; preds = %_ZN4llvm5APIntlSEj.exit - %174 = xor i64 %146, %spec.select.i + %174 = xor i64 %143, %142 %175 = add i64 %174, 1 - %176 = and i64 %175, %spec.select.i + %176 = and i64 %175, %142 %177 = getelementptr inbounds nuw i8, ptr %0, i64 8 store i32 %2, ptr %177, align 8, !tbaa !3, !alias.scope !87 store i64 %176, ptr %0, align 8, !alias.scope !87 diff --git a/bench/llvm/optimized/Attributes.ll b/bench/llvm/optimized/Attributes.ll index 7ab4b164ea1..c8ac067b472 100644 --- a/bench/llvm/optimized/Attributes.ll +++ b/bench/llvm/optimized/Attributes.ll @@ -1086,13 +1086,11 @@ _ZNK4llvm9StringRef9ends_withES0_.exit: ; preds = %_ZNK4llvm9StringRef _ZNK4llvm9StringRef9ends_withES0_.exit.thread: ; preds = %_ZNK4llvm9StringRef9ends_withES0_.exit %19 = add nsw i64 %13, -4 %20 = getelementptr inbounds nuw i8, ptr %10, i64 18 - %21 = add nsw i64 %13, -2 - %.sroa.speculated.i = tail call i64 @llvm.umin.i64(i64 %21, i64 %19) br label %_ZNK4llvm9StringRef11starts_withES0_.exit.thread96 _ZNK4llvm9StringRef11starts_withES0_.exit.thread96: ; preds = %_ZNK4llvm9StringRef9ends_withES0_.exit.thread, %_ZNK4llvm9StringRef9ends_withES0_.exit, %_ZNK4llvm9StringRef11starts_withES0_.exit, %6 %.sroa.085.0 = phi ptr [ %20, %_ZNK4llvm9StringRef9ends_withES0_.exit.thread ], [ %11, %_ZNK4llvm9StringRef9ends_withES0_.exit ], [ %11, %_ZNK4llvm9StringRef11starts_withES0_.exit ], [ %11, %6 ] - %.sroa.11.0 = phi i64 [ %.sroa.speculated.i, %_ZNK4llvm9StringRef9ends_withES0_.exit.thread ], [ %13, %_ZNK4llvm9StringRef9ends_withES0_.exit ], [ %13, %_ZNK4llvm9StringRef11starts_withES0_.exit ], [ %13, %6 ] + %.sroa.11.0 = phi i64 [ %19, %_ZNK4llvm9StringRef9ends_withES0_.exit.thread ], [ %13, %_ZNK4llvm9StringRef9ends_withES0_.exit ], [ %13, %_ZNK4llvm9StringRef11starts_withES0_.exit ], [ %13, %6 ] %.not = icmp eq ptr %1, null br i1 %.not, label %_ZN4llvmeqENS_9StringRefES0_.exit53.thread104, label %22 @@ -1112,9 +1110,9 @@ _ZN4llvmeqENS_9StringRefES0_.exit49: ; preds = %22 br label %_ZN4llvmeqENS_9StringRefES0_.exit49.thread101.sink.split _ZN4llvmeqENS_9StringRefES0_.exit49.thread101.sink.split: ; preds = %22, %_ZN4llvmeqENS_9StringRefES0_.exit49 - %.str.2.sink = phi ptr [ @.str.4, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ @.str.2, %22 ] - %.str.3.sink = phi ptr [ @.str.5, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ @.str.3, %22 ] - %.sink130 = phi i64 [ 5, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ 3, %22 ] + %.str.2.sink = phi ptr [ @.str.4, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ @.str.2, %21 ] + %.str.3.sink = phi ptr [ @.str.5, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ @.str.3, %21 ] + %.sink130 = phi i64 [ 5, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ 3, %21 ] %bcmp.i45 = tail call i32 @bcmp(ptr nonnull %25, ptr nonnull %.str.2.sink, i64 %27) %28 = icmp eq i32 %bcmp.i45, 0 %spec.select116 = select i1 %28, ptr %.str.3.sink, ptr %25 @@ -1122,8 +1120,8 @@ _ZN4llvmeqENS_9StringRefES0_.exit49.thread101.sink.split: ; preds = %22, %_ZN4ll br label %_ZN4llvmeqENS_9StringRefES0_.exit49.thread101 _ZN4llvmeqENS_9StringRefES0_.exit49.thread101: ; preds = %_ZN4llvmeqENS_9StringRefES0_.exit49.thread101.sink.split, %22 - %.sroa.077.1 = phi ptr [ %25, %22 ], [ %spec.select116, %_ZN4llvmeqENS_9StringRefES0_.exit49.thread101.sink.split ] - %.sroa.10.1 = phi i64 [ %27, %22 ], [ %spec.select117, %_ZN4llvmeqENS_9StringRefES0_.exit49.thread101.sink.split ] + %.sroa.077.1 = phi ptr [ %25, %21 ], [ %spec.select116, %_ZN4llvmeqENS_9StringRefES0_.exit49.thread101.sink.split ] + %.sroa.10.1 = phi i64 [ %27, %21 ], [ %spec.select117, %_ZN4llvmeqENS_9StringRefES0_.exit49.thread101.sink.split ] %29 = getelementptr inbounds nuw i8, ptr %4, i64 64 %30 = load i64, ptr %29, align 8 %31 = and i64 %30, 4294967295 @@ -1167,7 +1165,7 @@ _ZN4llvmeqENS_9StringRefES0_.exit53.thread104: ; preds = %_ZNK4llvm9StringRef br label %39 39: ; preds = %40, %36 - %.sroa.062.0.in = phi ptr [ %37, %36 ], [ %.sroa.062.0, %40 ] + %.sroa.062.0.in = phi ptr [ %37, %35 ], [ %.sroa.062.0, %39 ] %.sroa.062.0 = load ptr, ptr %.sroa.062.0.in, align 8, !tbaa !13 %.not113 = icmp eq ptr %.sroa.062.0, %37 br i1 %.not113, label %.critedge, label %40 @@ -1192,7 +1190,7 @@ _ZN4llvmeqENS_9StringRefES0_.exit53.thread104: ; preds = %_ZNK4llvm9StringRef br i1 %.not114, label %39, label %.critedge .critedge: ; preds = %39, %40, %_ZN4llvmeqENS_9StringRefES0_.exit53.thread104, %_ZN4llvmeqENS_9StringRefES0_.exit57, %_ZN4llvmeqENS_9StringRefES0_.exit61 - %.0 = phi i32 [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit61 ], [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit57 ], [ %35, %_ZN4llvmeqENS_9StringRefES0_.exit53.thread104 ], [ 0, %39 ], [ 1, %40 ] + %.0 = phi i32 [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit61 ], [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit57 ], [ %35, %_ZN4llvmeqENS_9StringRefES0_.exit53.thread104 ], [ 0, %38 ], [ 1, %39 ] ret i32 %.0 } @@ -25906,10 +25904,8 @@ _ZNK4llvm9StringRef9ends_withES0_.exit: ; preds = %_ZNK4llvm9StringRef br i1 %33, label %_ZNK4llvm9StringRef9ends_withES0_.exit.thread, label %_ZNK4llvm9StringRef11starts_withES0_.exit.thread42 _ZNK4llvm9StringRef9ends_withES0_.exit.thread: ; preds = %_ZNK4llvm9StringRef9ends_withES0_.exit - %34 = add nsw i64 %27, -2 - %.sroa.speculated.i = tail call i64 @llvm.umin.i64(i64 %34, i64 %27) - %35 = getelementptr inbounds nuw i8, ptr %28, i64 2 - %36 = add nsw i64 %.sroa.speculated.i, -2 + %34 = getelementptr inbounds nuw i8, ptr %28, i64 2 + %35 = add nsw i64 %27, -4 br label %_ZNK4llvm9StringRef11starts_withES0_.exit.thread42 _ZNK4llvm9StringRef11starts_withES0_.exit.thread42: ; preds = %_ZN4llvmeqENS_9StringRefES0_.exit11.thread39, %_ZNK4llvm9StringRef9ends_withES0_.exit.thread, %_ZNK4llvm9StringRef9ends_withES0_.exit, %_ZNK4llvm9StringRef11starts_withES0_.exit, %26, %_ZN4llvmeqENS_9StringRefES0_.exit11 @@ -33281,9 +33277,6 @@ declare i64 @llvm.fshl.i64(i64, i64, i64) #10 ; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: read) declare i32 @bcmp(ptr captures(none), ptr captures(none), i64) local_unnamed_addr #11 -; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none) -declare i64 @llvm.umin.i64(i64, i64) #10 - ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(inaccessiblemem: readwrite) declare void @llvm.experimental.noalias.scope.decl(metadata) #12 diff --git a/bench/llvm/optimized/IfConversion.ll b/bench/llvm/optimized/IfConversion.ll index dd9bd0d1303..ec8b180f194 100644 --- a/bench/llvm/optimized/IfConversion.ll +++ b/bench/llvm/optimized/IfConversion.ll @@ -4700,13 +4700,11 @@ _ZNSt6vectorISt10unique_ptrIN12_GLOBAL__N_111IfConverter10IfcvtTokenESt14default br i1 %or.cond230, label %.thread215, label %1489 1489: ; preds = %1480 - %1490 = icmp ne i32 %1457, 5 + %1490 = icmp eq i32 %1457, 5 %1491 = load i8, ptr getelementptr inbounds nuw (i8, ptr @_ZL16DisableTriangleF, i64 120), align 8, !tbaa !54, !range !52, !noundef !53 %1492 = trunc nuw i8 %1491 to i1 - %not. = xor i1 %1492, true - %or.cond10 = select i1 %not., i1 true, i1 %1490 - %or.cond12 = select i1 %or.cond10, i1 true, i1 %1482 - br i1 %or.cond12, label %1493, label %.thread215 + %or.cond10.not = select i1 %1492, i1 %1490, i1 false + br i1 %or.cond10.not, label %.thread215, label %1493 1493: ; preds = %1489 %1494 = getelementptr inbounds nuw i8, ptr %1455, i64 24 diff --git a/bench/llvm/optimized/X86TargetTransformInfo.ll b/bench/llvm/optimized/X86TargetTransformInfo.ll index 25d216cd510..0b241d0d387 100644 --- a/bench/llvm/optimized/X86TargetTransformInfo.ll +++ b/bench/llvm/optimized/X86TargetTransformInfo.ll @@ -525,9 +525,8 @@ define dso_local noundef zeroext i1 @_ZNK4llvm10X86TTIImpl30hasConditionalLoadSt 9: ; preds = %8 %10 = getelementptr inbounds nuw i8, ptr %1, i64 8 %11 = load i32, ptr %10, align 8 - %12 = and i32 %11, 255 %trunc = trunc i32 %11 to i8 - switch i8 %trunc, label %25 [ + switch i8 %trunc, label %22 [ i8 12, label %_ZNK4llvm4Type13getScalarTypeEv.exit i8 17, label %13 ] @@ -536,14 +535,9 @@ define dso_local noundef zeroext i1 @_ZNK4llvm10X86TTIImpl30hasConditionalLoadSt %14 = getelementptr inbounds nuw i8, ptr %1, i64 32 %15 = load i32, ptr %14, align 8, !tbaa !155 %.not12 = icmp eq i32 %15, 1 - br i1 %.not12, label %16, label %25 - -16: ; preds = %13 - %17 = add nsw i32 %12, -17 - %spec.select.i.i13 = icmp ult i32 %17, 2 - br i1 %spec.select.i.i13, label %18, label %_ZNK4llvm4Type13getScalarTypeEv.exit + br i1 %.not12, label %15, label %25 -18: ; preds = %16 +18: ; preds = %12 %19 = getelementptr inbounds nuw i8, ptr %1, i64 16 %20 = load ptr, ptr %19, align 8, !tbaa !162 %21 = load ptr, ptr %20, align 8, !tbaa !163 @@ -551,8 +545,8 @@ define dso_local noundef zeroext i1 @_ZNK4llvm10X86TTIImpl30hasConditionalLoadSt %.pre = load i32, ptr %.phi.trans.insert, align 8 br label %_ZNK4llvm4Type13getScalarTypeEv.exit -_ZNK4llvm4Type13getScalarTypeEv.exit: ; preds = %9, %16, %18 - %22 = phi i32 [ %.pre, %18 ], [ %11, %16 ], [ %11, %9 ] +_ZNK4llvm4Type13getScalarTypeEv.exit: ; preds = %9, %18 + %22 = phi i32 [ %.pre, %15 ], [ %11, %9 ] %23 = lshr i32 %22, 8 %switch.tableidx = add nsw i32 %23, -16 %24 = icmp ult i32 %switch.tableidx, 49 @@ -565,7 +559,7 @@ switch.lookup: ; preds = %_ZNK4llvm4Type13get br label %25 25: ; preds = %switch.lookup, %_ZNK4llvm4Type13getScalarTypeEv.exit, %9, %13, %8, %2 - %.0 = phi i1 [ false, %2 ], [ true, %8 ], [ false, %13 ], [ false, %_ZNK4llvm4Type13getScalarTypeEv.exit ], [ false, %9 ], [ %switch.masked, %switch.lookup ] + %.0 = phi i1 [ false, %2 ], [ true, %8 ], [ false, %12 ], [ false, %_ZNK4llvm4Type13getScalarTypeEv.exit ], [ false, %9 ], [ %switch.masked, %switch.lookup ] ret i1 %.0 } @@ -21741,7 +21735,6 @@ define dso_local noundef zeroext i1 @_ZN4llvm10X86TTIImpl17isLegalMaskedLoadEPNS 22: ; preds = %21 %23 = getelementptr inbounds nuw i8, ptr %11, i64 8 %24 = load i32, ptr %23, align 8 - %25 = and i32 %24, 255 %trunc.i = trunc i32 %24 to i8 switch i8 %trunc.i, label %_ZNK4llvm10X86TTIImpl30hasConditionalLoadStoreForTypeEPNS_4TypeE.exit [ i8 12, label %_ZNK4llvm4Type13getScalarTypeEv.exit.i @@ -21752,14 +21745,9 @@ define dso_local noundef zeroext i1 @_ZN4llvm10X86TTIImpl17isLegalMaskedLoadEPNS %27 = getelementptr inbounds nuw i8, ptr %11, i64 32 %28 = load i32, ptr %27, align 8, !tbaa !155 %.not12.i = icmp eq i32 %28, 1 - br i1 %.not12.i, label %29, label %_ZNK4llvm10X86TTIImpl30hasConditionalLoadStoreForTypeEPNS_4TypeE.exit - -29: ; preds = %26 - %30 = add nsw i32 %25, -17 - %spec.select.i.i13.i = icmp ult i32 %30, 2 - br i1 %spec.select.i.i13.i, label %31, label %_ZNK4llvm4Type13getScalarTypeEv.exit.i + br i1 %.not12.i, label %28, label %_ZNK4llvm10X86TTIImpl30hasConditionalLoadStoreForTypeEPNS_4TypeE.exit -31: ; preds = %29 +31: ; preds = %25 %32 = getelementptr inbounds nuw i8, ptr %11, i64 16 %33 = load ptr, ptr %32, align 8, !tbaa !162 %34 = load ptr, ptr %33, align 8, !tbaa !163 @@ -21767,8 +21755,8 @@ define dso_local noundef zeroext i1 @_ZN4llvm10X86TTIImpl17isLegalMaskedLoadEPNS %.pre.i = load i32, ptr %.phi.trans.insert.i, align 8 br label %_ZNK4llvm4Type13getScalarTypeEv.exit.i -_ZNK4llvm4Type13getScalarTypeEv.exit.i: ; preds = %31, %29, %22 - %35 = phi i32 [ %.pre.i, %31 ], [ %24, %29 ], [ %24, %22 ] +_ZNK4llvm4Type13getScalarTypeEv.exit.i: ; preds = %31, %22 + %35 = phi i32 [ %.pre.i, %28 ], [ %24, %22 ] %36 = lshr i32 %35, 8 %switch.tableidx = add nsw i32 %36, -16 %37 = icmp ult i32 %switch.tableidx, 49 @@ -21841,7 +21829,7 @@ switch.lookup: ; preds = %_ZNK4llvm4Type13get br label %_ZNK4llvm10X86TTIImpl30hasConditionalLoadStoreForTypeEPNS_4TypeE.exit _ZNK4llvm10X86TTIImpl30hasConditionalLoadStoreForTypeEPNS_4TypeE.exit: ; preds = %switch.lookup, %_ZNK4llvm4Type13getScalarTypeEv.exit.i, %43, %43, %43, %_ZNK4llvm10X86TTIImpl30hasConditionalLoadStoreForTypeEPNS_4TypeE.exit.fold.split, %.thread22, %26, %22, %21, %54, %54, %.fold.split, %58, %50, %46, %_ZNK4llvm4Type13getScalarTypeEv.exit, %15 - %.0 = phi i1 [ false, %15 ], [ false, %_ZNK4llvm4Type13getScalarTypeEv.exit ], [ true, %43 ], [ true, %46 ], [ true, %50 ], [ true, %54 ], [ %61, %58 ], [ true, %54 ], [ false, %.fold.split ], [ true, %21 ], [ false, %26 ], [ false, %_ZNK4llvm4Type13getScalarTypeEv.exit.i ], [ false, %22 ], [ false, %.thread22 ], [ true, %43 ], [ true, %43 ], [ false, %_ZNK4llvm10X86TTIImpl30hasConditionalLoadStoreForTypeEPNS_4TypeE.exit.fold.split ], [ %switch.masked, %switch.lookup ] + %.0 = phi i1 [ false, %15 ], [ false, %_ZNK4llvm4Type13getScalarTypeEv.exit ], [ true, %40 ], [ true, %43 ], [ true, %47 ], [ true, %51 ], [ %61, %55 ], [ true, %51 ], [ false, %.fold.split ], [ true, %21 ], [ false, %25 ], [ false, %_ZNK4llvm4Type13getScalarTypeEv.exit.i ], [ false, %22 ], [ false, %.thread22 ], [ true, %40 ], [ true, %40 ], [ false, %_ZNK4llvm10X86TTIImpl30hasConditionalLoadStoreForTypeEPNS_4TypeE.exit.fold.split ], [ %switch.masked, %switch.lookup ] ret i1 %.0 } diff --git a/bench/llvm/optimized/YAMLParser.ll b/bench/llvm/optimized/YAMLParser.ll index 5d466838cd0..016c17f4c0a 100644 --- a/bench/llvm/optimized/YAMLParser.ll +++ b/bench/llvm/optimized/YAMLParser.ll @@ -2840,29 +2840,29 @@ _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKcm.exit: ; preds ; Function Attrs: mustprogress nofree norecurse nounwind willreturn memory(argmem: read) uwtable define dso_local range(i16 0, 258) i16 @_ZN4llvm4yaml9parseBoolENS_9StringRefE(ptr readonly captures(none) %0, i64 %1) local_unnamed_addr #6 { - switch i64 %1, label %.thread138 [ + switch i64 %1, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 [ i64 1, label %3 i64 2, label %6 i64 3, label %19 i64 4, label %29 - i64 5, label %35 + i64 5, label %38 ] 3: ; preds = %2 %4 = load i8, ptr %0, align 1, !tbaa !23 - switch i8 %4, label %.thread138 [ - i8 121, label %.thread - i8 89, label %.thread + switch i8 %4, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 [ + i8 121, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread + i8 89, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread i8 110, label %5 i8 78, label %5 ] 5: ; preds = %3, %3 - br label %.thread + br label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread 6: ; preds = %2 %7 = load i8, ptr %0, align 1, !tbaa !23 - switch i8 %7, label %.thread138 [ + switch i8 %7, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 [ i8 79, label %8 i8 111, label %._crit_edge128 i8 78, label %15 @@ -2877,62 +2877,71 @@ define dso_local range(i16 0, 258) i16 @_ZN4llvm4yaml9parseBoolENS_9StringRefE(p ._crit_edge: ; preds = %6 %.phi.trans.insert = getelementptr inbounds nuw i8, ptr %0, i64 1 %.pre = load i8, ptr %.phi.trans.insert, align 1, !tbaa !23 - br label %41 + br label %19 8: ; preds = %6 %9 = getelementptr inbounds nuw i8, ptr %0, i64 1 %10 = load i8, ptr %9, align 1, !tbaa !23 %11 = icmp eq i8 %10, 78 - br i1 %11, label %.thread, label %12 + br i1 %11, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %12 12: ; preds = %._crit_edge128, %8 - %13 = phi i8 [ %.pre130, %._crit_edge128 ], [ %10, %8 ] + %13 = phi i8 [ %.pre130, %._crit_edge133 ], [ %10, %8 ] %.fr143 = freeze i8 %13 %14 = icmp eq i8 %.fr143, 110 - br i1 %14, label %.thread, label %.thread138 + br i1 %14, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 15: ; preds = %6 %16 = getelementptr inbounds nuw i8, ptr %0, i64 1 %17 = load i8, ptr %16, align 1, !tbaa !23 %18 = icmp eq i8 %17, 79 - br i1 %18, label %.thread, label %41 + br i1 %18, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %19 + +19: ; preds = %._crit_edge, %15 + %20 = phi i8 [ %.pre, %._crit_edge ], [ %17, %15 ] + %.fr = freeze i8 %20 + %21 = icmp eq i8 %.fr, 111 + br i1 %21, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 19: ; preds = %2 %20 = load i8, ptr %0, align 1, !tbaa !23 - switch i8 %20, label %.thread138 [ + switch i8 %20, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 [ i8 79, label %_ZN4llvmeqENS_9StringRefES0_.exit i8 111, label %_ZN4llvmeqENS_9StringRefES0_.exit21 i8 89, label %_ZN4llvmeqENS_9StringRefES0_.exit28 - i8 121, label %_ZN4llvmeqENS_9StringRefES0_.exit35 + i8 121, label %_ZN4llvmeqENS_9StringRefES0_.exit28.thread ] _ZN4llvmeqENS_9StringRefES0_.exit: ; preds = %19 %21 = getelementptr inbounds nuw i8, ptr %0, i64 1 %bcmp.i = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(2) %21, ptr noundef nonnull dereferenceable(2) @.str.41, i64 2) %22 = icmp eq i32 %bcmp.i, 0 - br i1 %22, label %.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit21 + br i1 %22, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit21 -_ZN4llvmeqENS_9StringRefES0_.exit21: ; preds = %19, %_ZN4llvmeqENS_9StringRefES0_.exit +_ZN4llvmeqENS_9StringRefES0_.exit21: ; preds = %_ZN4llvmeqENS_9StringRefES0_.exit, %22 %23 = getelementptr inbounds nuw i8, ptr %0, i64 1 %bcmp.i20 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(2) %23, ptr noundef nonnull dereferenceable(2) @.str.42, i64 2) - %24 = icmp eq i32 %bcmp.i20, 0 - br i1 %24, label %.thread, label %.thread138 - -_ZN4llvmeqENS_9StringRefES0_.exit28: ; preds = %19 - %25 = getelementptr inbounds nuw i8, ptr %0, i64 1 - %bcmp.i27 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(2) %25, ptr noundef nonnull dereferenceable(2) @.str.43, i64 2) - %26 = icmp eq i32 %bcmp.i27, 0 - br i1 %26, label %.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit35 - -_ZN4llvmeqENS_9StringRefES0_.exit35: ; preds = %19, %_ZN4llvmeqENS_9StringRefES0_.exit28 - %27 = getelementptr inbounds nuw i8, ptr %0, i64 1 - %bcmp.i34 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(2) %27, ptr noundef nonnull dereferenceable(2) @.str.44, i64 2) - %28 = icmp eq i32 %bcmp.i34, 0 - br i1 %28, label %.thread, label %.thread138 + %bcmp.i20.fr = freeze i32 %bcmp.i20 + %27 = icmp eq i32 %bcmp.i20.fr, 0 + br i1 %27, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 + +_ZN4llvmeqENS_9StringRefES0_.exit28:; preds = %19 + %28 = getelementptr inbounds nuw i8, ptr %0, i64 1 + %bcmp.i27 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(2) %28, ptr noundef nonnull dereferenceable(2) @.str.43, i64 2) + %29 = icmp eq i32 %bcmp.i27, 0 + br i1 %29, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit28.thread + +_ZN4llvmeqENS_9StringRefES0_.exit28.thread:; preds = %_ZN4llvmeqENS_9StringRefES0_.exit28, %19 + %30 = getelementptr inbounds nuw i8, ptr %0, i64 1 + %bcmp.i34 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(2) %30, ptr noundef nonnull dereferenceable(2) @.str.44, i64 2) + %bcmp.i34.fr = freeze i32 %bcmp.i34 + %31 = icmp eq i32 %bcmp.i34.fr, 0 + %.sroa.0116.0152 = zext i1 %31 to i16 + br i1 %31, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 29: ; preds = %2 %30 = load i8, ptr %0, align 1, !tbaa !23 - switch i8 %30, label %.thread138 [ + switch i8 %30, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 [ i8 84, label %_ZN4llvmeqENS_9StringRefES0_.exit42 i8 116, label %_ZN4llvmeqENS_9StringRefES0_.exit49 ] @@ -2941,47 +2950,44 @@ _ZN4llvmeqENS_9StringRefES0_.exit42: ; preds = %29 %31 = getelementptr inbounds nuw i8, ptr %0, i64 1 %bcmp.i41 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(3) %31, ptr noundef nonnull dereferenceable(3) @.str.45, i64 3) %32 = icmp eq i32 %bcmp.i41, 0 - br i1 %32, label %.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit49 + br i1 %32, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit49 -_ZN4llvmeqENS_9StringRefES0_.exit49: ; preds = %29, %_ZN4llvmeqENS_9StringRefES0_.exit42 +_ZN4llvmeqENS_9StringRefES0_.exit49: ; preds = %_ZN4llvmeqENS_9StringRefES0_.exit42, %32 %33 = getelementptr inbounds nuw i8, ptr %0, i64 1 %bcmp.i48 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(3) %33, ptr noundef nonnull dereferenceable(3) @.str.46, i64 3) - %34 = icmp eq i32 %bcmp.i48, 0 - br i1 %34, label %.thread, label %.thread138 - -35: ; preds = %2 - %36 = load i8, ptr %0, align 1, !tbaa !23 - switch i8 %36, label %.thread138 [ + %bcmp.i48.fr = freeze i32 %bcmp.i48 + %37 = icmp eq i32 %bcmp.i48.fr, 0 + %.sroa.0116.0154 = zext i1 %37 to i16 + br i1 %37, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 + +38:; preds = %2 + %39 = load i8, ptr %0, align 1, !tbaa !23 + switch i8 %39, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 [ i8 70, label %_ZN4llvmeqENS_9StringRefES0_.exit56 i8 102, label %_ZN4llvmeqENS_9StringRefES0_.exit63 ] -_ZN4llvmeqENS_9StringRefES0_.exit56: ; preds = %35 +_ZN4llvmeqENS_9StringRefES0_.exit56: ; preds = %38 %37 = getelementptr inbounds nuw i8, ptr %0, i64 1 %bcmp.i55 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(4) %37, ptr noundef nonnull dereferenceable(4) @.str.47, i64 4) %38 = icmp eq i32 %bcmp.i55, 0 - br i1 %38, label %.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit63 + br i1 %38, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit63 -_ZN4llvmeqENS_9StringRefES0_.exit63: ; preds = %35, %_ZN4llvmeqENS_9StringRefES0_.exit56 +_ZN4llvmeqENS_9StringRefES0_.exit63: ; preds = %38, %_ZN4llvmeqENS_9StringRefES0_.exit56 %39 = getelementptr inbounds nuw i8, ptr %0, i64 1 %bcmp.i62 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(4) %39, ptr noundef nonnull dereferenceable(4) @.str.48, i64 4) - %40 = icmp eq i32 %bcmp.i62, 0 - br i1 %40, label %.thread, label %.thread138 - -41: ; preds = %15, %._crit_edge - %42 = phi i8 [ %.pre, %._crit_edge ], [ %17, %15 ] - %.fr = freeze i8 %42 - %43 = icmp eq i8 %.fr, 111 - br i1 %43, label %.thread, label %.thread138 - -.thread: ; preds = %_ZN4llvmeqENS_9StringRefES0_.exit63, %_ZN4llvmeqENS_9StringRefES0_.exit56, %_ZN4llvmeqENS_9StringRefES0_.exit49, %_ZN4llvmeqENS_9StringRefES0_.exit42, %_ZN4llvmeqENS_9StringRefES0_.exit35, %_ZN4llvmeqENS_9StringRefES0_.exit28, %_ZN4llvmeqENS_9StringRefES0_.exit21, %_ZN4llvmeqENS_9StringRefES0_.exit, %15, %8, %3, %3, %5, %12, %41 - %.sroa.0116.0136 = phi i16 [ 0, %41 ], [ 1, %12 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit63 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit56 ], [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit42 ], [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit35 ], [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit28 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit21 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit ], [ 0, %15 ], [ 1, %8 ], [ 1, %3 ], [ 1, %3 ], [ 0, %5 ] - br label %.thread138 - -.thread138: ; preds = %_ZN4llvmeqENS_9StringRefES0_.exit63, %_ZN4llvmeqENS_9StringRefES0_.exit49, %_ZN4llvmeqENS_9StringRefES0_.exit35, %_ZN4llvmeqENS_9StringRefES0_.exit21, %3, %2, %35, %29, %19, %6, %12, %41, %.thread - %.sroa.0116.0135 = phi i16 [ %.sroa.0116.0136, %.thread ], [ 0, %41 ], [ 1, %12 ], [ 0, %6 ], [ 0, %19 ], [ 0, %29 ], [ 0, %35 ], [ 0, %2 ], [ 0, %3 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit21 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit35 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit63 ] - %44 = phi i16 [ 256, %.thread ], [ 0, %41 ], [ 0, %12 ], [ 0, %6 ], [ 0, %19 ], [ 0, %29 ], [ 0, %35 ], [ 0, %2 ], [ 0, %3 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit21 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit35 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit49 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit63 ] - %.sroa.0116.0.insert.insert = or disjoint i16 %44, %.sroa.0116.0135 + %bcmp.i62.fr = freeze i32 %bcmp.i62 + %43 = icmp eq i32 %bcmp.i62.fr, 0 + br i1 %43, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread, label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 + +_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread:; preds = %_ZN4llvmeqENS_9StringRefES0_.exit56, %_ZN4llvmeqENS_9StringRefES0_.exit42, %_ZN4llvmeqENS_9StringRefES0_.exit28, %_ZN4llvmeqENS_9StringRefES0_.exit, %15, %8, %3, %3, %5, %_ZN4llvmeqENS_9StringRefES0_.exit49, %_ZN4llvmeqENS_9StringRefES0_.exit28.thread, %_ZN4llvmeqENS_9StringRefES0_.exit21, %19, %12, %_ZN4llvmeqENS_9StringRefES0_.exit63 + %.sroa.0116.0142 = phi i16 [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit21.thread ], [ 1, %12 ], [ 0, %19 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit.thread ], [ %.sroa.0116.0152, %_ZN4llvmeqENS_9StringRefES0_.exit28.thread ], [ %.sroa.0116.0154, %_ZN4llvmeqENS_9StringRefES0_.exit42.thread ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit56 ], [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit42 ], [ 1, %_ZN4llvmeqENS_9StringRefES0_.exit28 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit ], [ 0, %15 ], [ 1, %8 ], [ 1, %3 ], [ 1, %3 ], [ 0, %5 ] + br label %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144 + +_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread144: ; preds = %3, %2, %38, %32, %22, %6, %_ZN4llvmeqENS_9StringRefES0_.exit42.thread, %_ZN4llvmeqENS_9StringRefES0_.exit28.thread, %_ZN4llvmeqENS_9StringRefES0_.exit.thread, %19, %12, %_ZN4llvmeqENS_9StringRefES0_.exit21.thread, %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread + %.sroa.0116.0141 = phi i16 [ %.sroa.0116.0142, %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit21.thread ], [ 1, %12 ], [ 0, %19 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit.thread ], [ %.sroa.0116.0152, %_ZN4llvmeqENS_9StringRefES0_.exit28.thread ], [ %.sroa.0116.0154, %_ZN4llvmeqENS_9StringRefES0_.exit42.thread ], [ 0, %6 ], [ 0, %22 ], [ 0, %32 ], [ 0, %38 ], [ 0, %2 ], [ 0, %3 ] + %.sroa.0116.0136 = phi i16 [ 256, %_ZN4llvmeqENS_9StringRefES0_.exit21.thread.thread ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit21.thread ], [ 0, %12 ], [ 0, %19 ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit.thread ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit28.thread ], [ 0, %_ZN4llvmeqENS_9StringRefES0_.exit42.thread ], [ 0, %6 ], [ 0, %22 ], [ 0, %32 ], [ 0, %38 ], [ 0, %2 ], [ 0, %3 ] + %.sroa.0116.0.insert.insert = or disjoint i16 %.sroa.0116.0136, %.sroa.0116.0141 ret i16 %.sroa.0116.0.insert.insert } diff --git a/bench/meshlab/optimized/arap.ll b/bench/meshlab/optimized/arap.ll index d3bd4800bdf..a1153d9e3dd 100644 --- a/bench/meshlab/optimized/arap.ll +++ b/bench/meshlab/optimized/arap.ll @@ -12247,47 +12247,20 @@ _ZN5Eigen15PlainObjectBaseINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEEE6resizeEl.exit76 %34 = trunc nuw nsw i64 %33 to i32 %35 = add nsw i32 %34, -1 %36 = sdiv i32 %32, %35 - %37 = tail call i64 @llvm.abs.i64(i64 %30, i1 true) - %38 = trunc nuw i64 %37 to i32 - %39 = add i32 %32, %38 - %40 = tail call noundef i32 @llvm.abs.i32(i32 %32, i1 true) - %41 = add nuw nsw i32 %40, 1 - %42 = sdiv i32 %39, %41 - %43 = icmp sgt i32 %.sroa.speculated132, 1 - br i1 %43, label %.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i - -_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i: ; preds = %.loopexit170 - %44 = icmp eq i32 %.sroa.speculated132, 1 - br i1 %44, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit - -.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i - br label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i - -.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i: ; preds = %.loopexit170 - %45 = icmp samesign ugt i32 %.sroa.speculated132, %41 - br i1 %45, label %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader - -.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i, %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i - %.05.i.us.i.i.i.i.i.i.i.i.i.i = phi i64 [ %49, %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i ], [ 0, %.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i ] - %46 = trunc i64 %.05.i.us.i.i.i.i.i.i.i.i.i.i to i32 - %47 = sdiv i32 %46, %42 - %48 = getelementptr inbounds nuw i32, ptr %31, i64 %.05.i.us.i.i.i.i.i.i.i.i.i.i - store i32 %47, ptr %48, align 4 - %49 = add nuw nsw i64 %.05.i.us.i.i.i.i.i.i.i.i.i.i, 1 - %exitcond.not.i.us.i.i.i.i.i.i.i.i.i.i = icmp eq i64 %49, %30 - br i1 %exitcond.not.i.us.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit, label %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i, !llvm.loop !199 - -.lr.ph.i.i.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i - %.05.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %53, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader ] - %50 = trunc i64 %.05.i.i.i.i.i.i.i.i.i.i.i to i32 - %51 = mul nsw i32 %36, %50 - %52 = getelementptr inbounds nuw i32, ptr %31, i64 %.05.i.i.i.i.i.i.i.i.i.i.i - store i32 %51, ptr %52, align 4 - %53 = add nuw nsw i64 %.05.i.i.i.i.i.i.i.i.i.i.i, 1 - %exitcond.not.i.i.i.i.i.i.i.i.i.i.i = icmp eq i64 %53, %30 + %or.cond = icmp sgt i32 %.sroa.speculated132, 0 + br i1 %or.cond, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit + +.lr.ph.i.i.i.i.i.i.i.i.i.i.i:; preds = %.loopexit170, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i + %.05.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %40, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %.loopexit170 ] + %37 = trunc i64 %.05.i.i.i.i.i.i.i.i.i.i.i to i32 + %38 = mul nsw i32 %36, %37 + %39 = getelementptr inbounds nuw i32, ptr %31, i64 %.05.i.i.i.i.i.i.i.i.i.i.i + store i32 %38, ptr %39, align 4 + %40 = add nuw nsw i64 %.05.i.i.i.i.i.i.i.i.i.i.i, 1 + %44 = icmp eq i64 %40, %30 br i1 %exitcond.not.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, !llvm.loop !199 -_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i +_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, %.loopexit170 %54 = icmp sgt i32 %7, 0 br i1 %54, label %.lr.ph173, label %._crit_edge182 @@ -12326,7 +12299,7 @@ _ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EE br label %.body 69: ; preds = %64, %62 - %.062 = phi i32 [ %66, %64 ], [ %63, %62 ] + %.062 = phi i32 [ %66, %51 ], [ %63, %49 ] %70 = sext i32 %.062 to i64 %71 = load ptr, ptr %55, align 8 %72 = load ptr, ptr %56, align 8 @@ -12351,7 +12324,7 @@ _ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EE br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit: ; preds = %78, %82 - %.sink.i = phi i64 [ %81, %78 ], [ %86, %82 ] + %.sink.i = phi i64 [ %81, %65 ], [ %86, %69 ] %87 = icmp sgt i64 %.sink.i, %75 br i1 %87, label %.lr.ph, label %._crit_edge @@ -12393,7 +12366,7 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %105 105: ; preds = %102, %95 - %.056 = phi i32 [ %104, %102 ], [ %98, %95 ] + %.056 = phi i32 [ %104, %89 ], [ %98, %82 ] %106 = sext i32 %.056 to i64 %107 = load ptr, ptr %58, align 8 %108 = load ptr, ptr %59, align 8 @@ -12418,37 +12391,37 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79: ; preds = %114, %118 - %.sink.i78 = phi i64 [ %117, %114 ], [ %122, %118 ] + %.sink.i78 = phi i64 [ %117, %101 ], [ %122, %105 ] %123 = icmp sle i64 %.sink.i78, %111 %.not168174 = select i1 %123, i1 %96, i1 false br i1 %.not168174, label %._crit_edge179, label %.lr.ph178 -.lr.ph178: ; preds = %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79, %156 - %124 = phi i1 [ %158, %156 ], [ %123, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] - %.059177 = phi i32 [ %.1, %156 ], [ %98, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] - %.060176 = phi i1 [ %spec.select, %156 ], [ %96, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] - %.sroa.4.0175 = phi i64 [ %157, %156 ], [ %111, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] - br i1 %124, label %129, label %125 +.lr.ph178: ; preds = %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79, %150 + %124 = phi i1 [ %145, %143 ], [ %123, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] + %.059177 = phi i32 [ %.1, %143 ], [ %98, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] + %.060176 = phi i1 [ %spec.select, %143 ], [ %96, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] + %.sroa.4.0175 = phi i64 [ %144, %143 ], [ %111, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] + br i1 %124, label %125, label %112 + +112: ; preds = %.lr.ph178 + %113 = getelementptr inbounds i32, ptr %94, i64 %.sroa.4.0175 + %114 = load i32, ptr %113, align 4 + %115 = sext i32 %114 to i64 + br label %116 -125: ; preds = %.lr.ph178 - %126 = getelementptr inbounds i32, ptr %107, i64 %.sroa.4.0175 - %127 = load i32, ptr %126, align 4 - %128 = sext i32 %127 to i64 - br label %129 - -129: ; preds = %.lr.ph178, %125 - %.055 = phi i64 [ %128, %125 ], [ %indvars.iv186, %.lr.ph178 ] - %130 = icmp eq i64 %.055, %indvars.iv186 - %spec.select = select i1 %130, i1 true, i1 %.060176 - %131 = load ptr, ptr %2, align 8 - %132 = getelementptr inbounds i32, ptr %131, i64 %.055 - %133 = load i32, ptr %132, align 4 - %134 = sext i32 %133 to i64 - %.not68 = icmp sgt i64 %indvars.iv186, %134 - br i1 %.not68, label %135, label %156 +125: ; preds = %.lr.ph178, %112 + %.055 = phi i64 [ %115, %112 ], [ %indvars.iv185, %.lr.ph178 ] + %117 = icmp eq i64 %.055, %indvars.iv185 + %spec.select = select i1 %117, i1 true, i1 %.060176 + %118 = load ptr, ptr %2, align 8 + %119 = getelementptr inbounds i32, ptr %118, i64 %.055 + %120 = load i32, ptr %119, align 4 + %121 = sext i32 %120 to i64 + %130 = icmp sgt i64 %indvars.iv186, %121 + br i1 %130, label %122, label %143 -135: ; preds = %129 - %136 = getelementptr inbounds i32, ptr %.sroa.0108.0160, i64 %134 +135: ; preds = %125 + %136 = getelementptr inbounds i32, ptr %.sroa.0108.0160, i64 %121 %137 = load i32, ptr %136, align 4 %138 = sext i32 %137 to i64 %139 = getelementptr inbounds i32, ptr %.sroa.0108.0160, i64 %138 @@ -12457,8 +12430,8 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br i1 %.not17.i, label %.loopexit, label %.lr.ph.i .lr.ph.i: ; preds = %135, %.lr.ph.i - %.019.i = phi i32 [ %.0.i, %.lr.ph.i ], [ %.016.i, %135 ] - %.01518.i = phi i32 [ %.019.i, %.lr.ph.i ], [ %133, %135 ] + %.019.i = phi i32 [ %.0.i, %.lr.ph.i ], [ %.016.i, %122 ] + %.01518.i = phi i32 [ %.019.i, %.lr.ph.i ], [ %120, %122 ] %140 = sext i32 %.01518.i to i64 %141 = getelementptr inbounds i32, ptr %.sroa.0108.0160, i64 %140 store i32 %.019.i, ptr %141, align 4 @@ -12472,33 +12445,33 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br i1 %.not.i, label %.loopexit, label %.lr.ph.i, !llvm.loop !202 .loopexit: ; preds = %.lr.ph.i, %135 - %.pre-phi = phi i64 [ %138, %135 ], [ %145, %.lr.ph.i ] - %.014.lcssa.i = phi i32 [ %137, %135 ], [ %144, %.lr.ph.i ] + %.pre-phi = phi i64 [ %138, %122 ], [ %145, %.lr.ph.i ] + %.014.lcssa.i = phi i32 [ %137, %122 ], [ %144, %.lr.ph.i ] %147 = getelementptr inbounds i32, ptr %.sroa.0118.0147152159, i64 %.pre-phi %148 = load i32, ptr %147, align 4 %149 = zext i32 %148 to i64 %.not69 = icmp eq i64 %indvars.iv186, %149 - br i1 %.not69, label %156, label %150 + br i1 %.not69, label %150, label %137 + +137: ; preds = %.loopexit + %138 = sext i32 %135 to i64 + %139 = load ptr, ptr %1, align 8 + %140 = getelementptr inbounds i32, ptr %139, i64 %138 + store i32 %85, ptr %140, align 4 + %141 = sext i32 %.059177 to i64 + %142 = getelementptr inbounds i32, ptr %.sroa.0108.0160, i64 %141 + store i32 %.014.lcssa.i, ptr %142, align 4 + store i32 %85, ptr %134, align 4 + br label %143 -150: ; preds = %.loopexit - %151 = sext i32 %148 to i64 - %152 = load ptr, ptr %1, align 8 - %153 = getelementptr inbounds i32, ptr %152, i64 %151 - store i32 %98, ptr %153, align 4 - %154 = sext i32 %.059177 to i64 - %155 = getelementptr inbounds i32, ptr %.sroa.0108.0160, i64 %154 - store i32 %.014.lcssa.i, ptr %155, align 4 - store i32 %98, ptr %147, align 4 - br label %156 - -156: ; preds = %.loopexit, %150, %129 - %.1 = phi i32 [ %.059177, %129 ], [ %.014.lcssa.i, %150 ], [ %.059177, %.loopexit ] - %157 = add nsw i64 %.sroa.4.0175, 1 - %158 = icmp sge i64 %157, %.sink.i78 - %.not168 = select i1 %158, i1 %spec.select, i1 false +150: ; preds = %.loopexit, %137, %116 + %.1 = phi i32 [ %.059177, %116 ], [ %.014.lcssa.i, %137 ], [ %.059177, %.loopexit ] + %144 = add nsw i64 %.sroa.4.0175, 1 + %145 = icmp sge i64 %144, %.sink.i78 + %.not168 = select i1 %145, i1 %spec.select, i1 false br i1 %.not168, label %._crit_edge179, label %.lr.ph178, !llvm.loop !203 -._crit_edge179: ; preds = %156, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 +._crit_edge179: ; preds = %150, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 %indvars.iv.next187 = add nuw nsw i64 %indvars.iv186, 1 %exitcond190.not = icmp eq i64 %indvars.iv.next187, %wide.trip.count189 br i1 %exitcond190.not, label %._crit_edge182, label %95, !llvm.loop !204 @@ -12509,8 +12482,8 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS ret i32 0 .body: ; preds = %20, %67 - %.sroa.0118.0148 = phi ptr [ %.sroa.0118.0147152159, %67 ], [ %calloc204, %20 ] - %.pn = phi { ptr, i32 } [ %68, %67 ], [ %21, %20 ] + %.sroa.0118.0148 = phi ptr [ %.sroa.0118.0147152159, %54 ], [ %calloc204, %20 ] + %.pn = phi { ptr, i32 } [ %68, %54 ], [ %21, %20 ] tail call void @free(ptr noundef %.sroa.0118.0148) #26 resume { ptr, i32 } %.pn } @@ -14998,9 +14971,6 @@ define internal fastcc void @_ZN5Eigen8internal6ColamdL14order_childrenIiEEvT_PN ret void } -; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) -declare i32 @llvm.abs.i32(i32, i1 immarg) #14 - ; Function Attrs: mustprogress uwtable define linkonce_odr noundef i64 @_ZN5Eigen8internal12SparseLUImplIdiE7memInitEllllllRNS0_13LU_GlobalLU_tINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEENS4_IdLin1ELi1ELi0ELin1ELi1EEEEE(ptr noundef nonnull align 1 dereferenceable(1) %0, i64 noundef %1, i64 noundef %2, i64 noundef %3, i64 noundef %4, i64 noundef %5, i64 noundef %6, ptr noundef nonnull align 8 dereferenceable(184) %7) local_unnamed_addr #20 comdat align 2 personality ptr @__gxx_personality_v0 { %9 = getelementptr inbounds nuw i8, ptr %7, i64 176 @@ -30448,9 +30418,6 @@ declare noalias noundef ptr @calloc(i64 noundef, i64 noundef) local_unnamed_addr ; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none) declare i32 @llvm.smin.i32(i32, i32) #30 -; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none) -declare i64 @llvm.abs.i64(i64, i1 immarg) #30 - attributes #0 = { "frame-pointer"="all" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" } attributes #1 = { nounwind "frame-pointer"="all" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" } attributes #2 = { nofree nounwind } diff --git a/bench/meshlab/optimized/cube_style_precomputation.ll b/bench/meshlab/optimized/cube_style_precomputation.ll index d3953820b7b..b8751dbc162 100644 --- a/bench/meshlab/optimized/cube_style_precomputation.ll +++ b/bench/meshlab/optimized/cube_style_precomputation.ll @@ -43638,47 +43638,20 @@ _ZN5Eigen15PlainObjectBaseINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEEE6resizeEl.exit76 %34 = trunc nuw nsw i64 %33 to i32 %35 = add nsw i32 %34, -1 %36 = sdiv i32 %32, %35 - %37 = tail call i64 @llvm.abs.i64(i64 %30, i1 true) - %38 = trunc nuw i64 %37 to i32 - %39 = add i32 %32, %38 - %40 = tail call noundef i32 @llvm.abs.i32(i32 %32, i1 true) - %41 = add nuw nsw i32 %40, 1 - %42 = sdiv i32 %39, %41 - %43 = icmp sgt i32 %.sroa.speculated132, 1 - br i1 %43, label %.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i - -_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i: ; preds = %.loopexit170 - %44 = icmp eq i32 %.sroa.speculated132, 1 - br i1 %44, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit - -.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i - br label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i - -.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i: ; preds = %.loopexit170 - %45 = icmp samesign ugt i32 %.sroa.speculated132, %41 - br i1 %45, label %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader - -.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i, %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i - %.05.i.us.i.i.i.i.i.i.i.i.i.i = phi i64 [ %49, %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i ], [ 0, %.lr.ph.i.preheader.i.i.i.i.i.i.i.i.i.i ] - %46 = trunc i64 %.05.i.us.i.i.i.i.i.i.i.i.i.i to i32 - %47 = sdiv i32 %46, %42 - %48 = getelementptr inbounds nuw i32, ptr %31, i64 %.05.i.us.i.i.i.i.i.i.i.i.i.i - store i32 %47, ptr %48, align 4 - %49 = add nuw nsw i64 %.05.i.us.i.i.i.i.i.i.i.i.i.i, 1 - %exitcond.not.i.us.i.i.i.i.i.i.i.i.i.i = icmp eq i64 %49, %30 - br i1 %exitcond.not.i.us.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit, label %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i, !llvm.loop !1399 - -.lr.ph.i.i.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i - %.05.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %53, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i.preheader ] - %50 = trunc i64 %.05.i.i.i.i.i.i.i.i.i.i.i to i32 - %51 = mul nsw i32 %36, %50 - %52 = getelementptr inbounds nuw i32, ptr %31, i64 %.05.i.i.i.i.i.i.i.i.i.i.i - store i32 %51, ptr %52, align 4 - %53 = add nuw nsw i64 %.05.i.i.i.i.i.i.i.i.i.i.i, 1 - %exitcond.not.i.i.i.i.i.i.i.i.i.i.i = icmp eq i64 %53, %30 + %or.cond = icmp sgt i32 %.sroa.speculated132, 0 + br i1 %or.cond, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit + +.lr.ph.i.i.i.i.i.i.i.i.i.i.i:; preds = %.loopexit170, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i + %.05.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %40, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %.loopexit170 ] + %37 = trunc i64 %.05.i.i.i.i.i.i.i.i.i.i.i to i32 + %38 = mul nsw i32 %36, %37 + %39 = getelementptr inbounds nuw i32, ptr %31, i64 %.05.i.i.i.i.i.i.i.i.i.i.i + store i32 %38, ptr %39, align 4 + %40 = add nuw nsw i64 %.05.i.i.i.i.i.i.i.i.i.i.i, 1 + %44 = icmp eq i64 %40, %30 br i1 %exitcond.not.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, !llvm.loop !1399 -_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, %.lr.ph.i.us.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i +_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, %.loopexit170 %54 = icmp sgt i32 %7, 0 br i1 %54, label %.lr.ph173, label %._crit_edge182 @@ -43717,7 +43690,7 @@ _ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EE br label %.body 69: ; preds = %64, %62 - %.062 = phi i32 [ %66, %64 ], [ %63, %62 ] + %.062 = phi i32 [ %66, %51 ], [ %63, %49 ] %70 = sext i32 %.062 to i64 %71 = load ptr, ptr %55, align 8 %72 = load ptr, ptr %56, align 8 @@ -43742,7 +43715,7 @@ _ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EE br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit: ; preds = %78, %82 - %.sink.i = phi i64 [ %81, %78 ], [ %86, %82 ] + %.sink.i = phi i64 [ %81, %65 ], [ %86, %69 ] %87 = icmp sgt i64 %.sink.i, %75 br i1 %87, label %.lr.ph, label %._crit_edge @@ -43784,7 +43757,7 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %105 105: ; preds = %102, %95 - %.056 = phi i32 [ %104, %102 ], [ %98, %95 ] + %.056 = phi i32 [ %104, %89 ], [ %98, %82 ] %106 = sext i32 %.056 to i64 %107 = load ptr, ptr %58, align 8 %108 = load ptr, ptr %59, align 8 @@ -43809,16 +43782,16 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79: ; preds = %114, %118 - %.sink.i78 = phi i64 [ %117, %114 ], [ %122, %118 ] + %.sink.i78 = phi i64 [ %117, %101 ], [ %122, %105 ] %123 = icmp sle i64 %.sink.i78, %111 %.not168174 = select i1 %123, i1 %96, i1 false br i1 %.not168174, label %._crit_edge179, label %.lr.ph178 .lr.ph178: ; preds = %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79, %156 - %124 = phi i1 [ %158, %156 ], [ %123, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] - %.059177 = phi i32 [ %.1, %156 ], [ %98, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] - %.060176 = phi i1 [ %spec.select, %156 ], [ %96, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] - %.sroa.4.0175 = phi i64 [ %157, %156 ], [ %111, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] + %124 = phi i1 [ %158, %143 ], [ %123, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] + %.059177 = phi i32 [ %.1, %143 ], [ %98, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] + %.060176 = phi i1 [ %spec.select, %143 ], [ %96, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] + %.sroa.4.0175 = phi i64 [ %157, %143 ], [ %111, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit79 ] br i1 %124, label %129, label %125 125: ; preds = %.lr.ph178 @@ -43828,7 +43801,7 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %129 129: ; preds = %.lr.ph178, %125 - %.055 = phi i64 [ %128, %125 ], [ %indvars.iv186, %.lr.ph178 ] + %.055 = phi i64 [ %128, %112 ], [ %indvars.iv186, %.lr.ph178 ] %130 = icmp eq i64 %.055, %indvars.iv186 %spec.select = select i1 %130, i1 true, i1 %.060176 %131 = load ptr, ptr %2, align 8 @@ -43848,8 +43821,8 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br i1 %.not17.i, label %.loopexit, label %.lr.ph.i .lr.ph.i: ; preds = %135, %.lr.ph.i - %.019.i = phi i32 [ %.0.i, %.lr.ph.i ], [ %.016.i, %135 ] - %.01518.i = phi i32 [ %.019.i, %.lr.ph.i ], [ %133, %135 ] + %.019.i = phi i32 [ %.0.i, %.lr.ph.i ], [ %.016.i, %122 ] + %.01518.i = phi i32 [ %.019.i, %.lr.ph.i ], [ %133, %122 ] %140 = sext i32 %.01518.i to i64 %141 = getelementptr inbounds i32, ptr %.sroa.0108.0160, i64 %140 store i32 %.019.i, ptr %141, align 4 @@ -43863,8 +43836,8 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br i1 %.not.i, label %.loopexit, label %.lr.ph.i, !llvm.loop !1402 .loopexit: ; preds = %.lr.ph.i, %135 - %.pre-phi = phi i64 [ %138, %135 ], [ %145, %.lr.ph.i ] - %.014.lcssa.i = phi i32 [ %137, %135 ], [ %144, %.lr.ph.i ] + %.pre-phi = phi i64 [ %138, %122 ], [ %145, %.lr.ph.i ] + %.014.lcssa.i = phi i32 [ %137, %122 ], [ %144, %.lr.ph.i ] %147 = getelementptr inbounds i32, ptr %.sroa.0118.0147152159, i64 %.pre-phi %148 = load i32, ptr %147, align 4 %149 = zext i32 %148 to i64 @@ -43883,7 +43856,7 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %156 156: ; preds = %.loopexit, %150, %129 - %.1 = phi i32 [ %.059177, %129 ], [ %.014.lcssa.i, %150 ], [ %.059177, %.loopexit ] + %.1 = phi i32 [ %.059177, %116 ], [ %.014.lcssa.i, %137 ], [ %.059177, %.loopexit ] %157 = add nsw i64 %.sroa.4.0175, 1 %158 = icmp sge i64 %157, %.sink.i78 %.not168 = select i1 %158, i1 %spec.select, i1 false @@ -43900,8 +43873,8 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS ret i32 0 .body: ; preds = %20, %67 - %.sroa.0118.0148 = phi ptr [ %.sroa.0118.0147152159, %67 ], [ %calloc204, %20 ] - %.pn = phi { ptr, i32 } [ %68, %67 ], [ %21, %20 ] + %.sroa.0118.0148 = phi ptr [ %.sroa.0118.0147152159, %54 ], [ %calloc204, %20 ] + %.pn = phi { ptr, i32 } [ %68, %54 ], [ %21, %20 ] tail call void @free(ptr noundef %.sroa.0118.0148) #16 resume { ptr, i32 } %.pn } @@ -75095,9 +75068,6 @@ declare double @llvm.sqrt.f64(double) #30 ; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none) declare i32 @llvm.smax.i32(i32, i32) #30 -; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none) -declare i64 @llvm.abs.i64(i64, i1 immarg) #30 - attributes #0 = { "frame-pointer"="all" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" } attributes #1 = { nounwind "frame-pointer"="all" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" } attributes #2 = { nofree nounwind } diff --git a/bench/open3d/optimized/TriangleMeshDeformation.ll b/bench/open3d/optimized/TriangleMeshDeformation.ll index 35ea02ee048..5450cd2c54c 100644 --- a/bench/open3d/optimized/TriangleMeshDeformation.ll +++ b/bench/open3d/optimized/TriangleMeshDeformation.ll @@ -9979,47 +9979,20 @@ _ZN5Eigen8internal23check_size_for_overflowIiEEvm.exit.i.i.i103: ; preds = %37 %51 = trunc nuw nsw i64 %50 to i32 %52 = add nsw i32 %51, -1 %53 = sdiv i32 %49, %52 - %54 = tail call i64 @llvm.abs.i64(i64 %48, i1 true) - %55 = trunc nuw i64 %54 to i32 - %56 = add i32 %49, %55 - %57 = tail call noundef i32 @llvm.abs.i32(i32 %49, i1 true) - %58 = add nuw nsw i32 %57, 1 - %59 = sdiv i32 %56, %58 - %60 = icmp sgt i32 %.sroa.speculated151, 1 - br i1 %60, label %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i - -_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i: ; preds = %.loopexit192 - %61 = icmp eq i32 %.sroa.speculated151, 1 - br i1 %61, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit - -_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i - br label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i - -.lr.ph.i.i.i.i.i.i.i.i.i.i.i: ; preds = %.loopexit192 - %62 = icmp samesign ugt i32 %.sroa.speculated151, %58 - br i1 %62, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader - -_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i - %.05.us.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %66, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %.lr.ph.i.i.i.i.i.i.i.i.i.i.i ] - %63 = trunc i64 %.05.us.i.i.i.i.i.i.i.i.i.i.i to i32 - %64 = sdiv i32 %63, %59 - %65 = getelementptr inbounds nuw i32, ptr %.pre, i64 %.05.us.i.i.i.i.i.i.i.i.i.i.i - store i32 %64, ptr %65, align 4, !tbaa !56 - %66 = add nuw nsw i64 %.05.us.i.i.i.i.i.i.i.i.i.i.i, 1 - %exitcond7.not.i.i.i.i.i.i.i.i.i.i.i = icmp eq i64 %66, %48 - br i1 %exitcond7.not.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i, !llvm.loop !347 - -_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i: ; preds = %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i - %.05.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %70, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i.preheader ] - %67 = trunc i64 %.05.i.i.i.i.i.i.i.i.i.i.i to i32 - %68 = mul nsw i32 %53, %67 - %69 = getelementptr inbounds nuw i32, ptr %.pre, i64 %.05.i.i.i.i.i.i.i.i.i.i.i - store i32 %68, ptr %69, align 4, !tbaa !56 - %70 = add nuw nsw i64 %.05.i.i.i.i.i.i.i.i.i.i.i, 1 - %exitcond.not.i.i.i.i.i.i.i.i.i.i.i = icmp eq i64 %70, %48 + %or.cond = icmp sgt i32 %.sroa.speculated151, 0 + br i1 %or.cond, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit + +_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i:; preds = %.loopexit192, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i + %.05.i.i.i.i.i.i.i.i.i.i.i = phi i64 [ %57, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i ], [ 0, %.loopexit192 ] + %54 = trunc i64 %.05.i.i.i.i.i.i.i.i.i.i.i to i32 + %55 = mul nsw i32 %53, %54 + %56 = getelementptr inbounds nuw i32, ptr %.pre, i64 %.05.i.i.i.i.i.i.i.i.i.i.i + store i32 %55, ptr %56, align 4, !tbaa !56 + %57 = add nuw nsw i64 %.05.i.i.i.i.i.i.i.i.i.i.i, 1 + %61 = icmp eq i64 %57, %48 br i1 %exitcond.not.i.i.i.i.i.i.i.i.i.i.i, label %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit, label %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i, !llvm.loop !347 -_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit: ; preds = %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.us.i.i.i.i.i.i.i.i.i.i.i, %_ZN5Eigen8internal12linspaced_opIiEC2ERKiS4_l.exit.thread.i +_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit: ; preds = %_ZN5Eigen8internal31generic_dense_assignment_kernelINS0_9evaluatorINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEEENS2_INS_14CwiseNullaryOpINS0_12linspaced_opIiEES5_EEEENS0_9assign_opIiiEELi0EE11assignCoeffEl.exit.i.i.i.i.i.i.i.i.i.i.i, %.loopexit192 br i1 %11, label %.lr.ph195, label %._crit_edge204 .lr.ph195: ; preds = %_ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EEEE12setLinSpacedElRKiS7_.exit @@ -10045,7 +10018,7 @@ _ZN5Eigen9DenseBaseINS_5BlockINS_6MatrixIiLin1ELi1ELi0ELin1ELi1EEELin1ELi1ELb0EE br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit.us _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit.us: ; preds = %79, %.lr.ph195.split.us - %.071.us = phi i32 [ %81, %79 ], [ %78, %.lr.ph195.split.us ] + %.071.us = phi i32 [ %81, %66 ], [ %78, %.lr.ph195.split.us ] %82 = sext i32 %.071.us to i64 %83 = getelementptr inbounds i32, ptr %74, i64 %82 %84 = load i32, ptr %83, align 4, !tbaa !56 @@ -10109,7 +10082,7 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit: ; preds = %108, %.lr.ph195.split - %.071 = phi i32 [ %110, %108 ], [ %107, %.lr.ph195.split ] + %.071 = phi i32 [ %110, %95 ], [ %107, %.lr.ph195.split ] %111 = sext i32 %.071 to i64 %112 = getelementptr inbounds i32, ptr %74, i64 %111 %113 = load i32, ptr %112, align 4, !tbaa !56 @@ -10162,7 +10135,7 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %136 136: ; preds = %133, %127 - %.056 = phi i32 [ %135, %133 ], [ %130, %127 ] + %.056 = phi i32 [ %135, %120 ], [ %130, %114 ] %137 = sext i32 %.056 to i64 %138 = getelementptr inbounds i32, ptr %100, i64 %137 %139 = load i32, ptr %138, align 4, !tbaa !56 @@ -10183,21 +10156,21 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109: ; preds = %141, %145 - %.sink.i108 = phi i64 [ %144, %141 ], [ %149, %145 ] + %.sink.i108 = phi i64 [ %144, %128 ], [ %149, %132 ] %150 = icmp sle i64 %.sink.i108, %140 %.not190196 = select i1 %150, i1 %128, i1 false br i1 %.not190196, label %._crit_edge201, label %.lr.ph200 -._crit_edge201: ; preds = %172, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 +._crit_edge201: ; preds = %159, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 %indvars.iv.next215 = add nuw nsw i64 %indvars.iv214, 1 %exitcond218.not = icmp eq i64 %indvars.iv.next215, %wide.trip.count217 br i1 %exitcond218.not, label %._crit_edge204, label %127, !llvm.loop !350 -.lr.ph200: ; preds = %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109, %172 - %151 = phi i1 [ %174, %172 ], [ %150, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] - %.066199 = phi i32 [ %.167, %172 ], [ %130, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] - %.069198 = phi i1 [ %spec.select, %172 ], [ %128, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] - %.sroa.7.0197 = phi i64 [ %173, %172 ], [ %140, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] +.lr.ph200: ; preds = %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109, %159 + %151 = phi i1 [ %161, %159 ], [ %150, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] + %.066199 = phi i32 [ %.167, %159 ], [ %130, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] + %.069198 = phi i1 [ %spec.select, %159 ], [ %128, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] + %.sroa.7.0197 = phi i64 [ %160, %159 ], [ %140, %_ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS3_l.exit109 ] br i1 %151, label %156, label %152 152: ; preds = %.lr.ph200 @@ -10207,14 +10180,14 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br label %156 156: ; preds = %.lr.ph200, %152 - %.055 = phi i64 [ %155, %152 ], [ %indvars.iv214, %.lr.ph200 ] + %.055 = phi i64 [ %155, %139 ], [ %indvars.iv214, %.lr.ph200 ] %157 = icmp eq i64 %.055, %indvars.iv214 %spec.select = select i1 %157, i1 true, i1 %.069198 %158 = getelementptr inbounds i32, ptr %.pre, i64 %.055 %159 = load i32, ptr %158, align 4, !tbaa !56 %160 = sext i32 %159 to i64 %.not78 = icmp sgt i64 %indvars.iv214, %160 - br i1 %.not78, label %161, label %172 + br i1 %.not78, label %161, label %159 161: ; preds = %156 %.014.in18.i = getelementptr inbounds i32, ptr %.sroa.0131.0181, i64 %160 @@ -10226,8 +10199,8 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br i1 %.not23.i, label %.loopexit, label %.lr.ph.i .lr.ph.i: ; preds = %161, %.lr.ph.i - %.025.i = phi i32 [ %.0.i, %.lr.ph.i ], [ %.022.i, %161 ] - %.01524.i = phi i32 [ %.025.i, %.lr.ph.i ], [ %159, %161 ] + %.025.i = phi i32 [ %.0.i, %.lr.ph.i ], [ %.022.i, %148 ] + %.01524.i = phi i32 [ %.025.i, %.lr.ph.i ], [ %159, %148 ] %162 = sext i32 %.01524.i to i64 %163 = getelementptr inbounds i32, ptr %.sroa.0131.0181, i64 %162 store i32 %.025.i, ptr %163, align 4, !tbaa !56 @@ -10241,34 +10214,34 @@ _ZN5Eigen20SparseCompressedBaseINS_12SparseMatrixIdLi0EiEEE13InnerIteratorC2ERKS br i1 %.not.i, label %.loopexit, label %.lr.ph.i, !llvm.loop !351 .loopexit: ; preds = %.lr.ph.i, %161 - %.pre-phi = phi i64 [ %.pn20.i, %161 ], [ %.pn.i, %.lr.ph.i ] - %.014.lcssa.i = phi i32 [ %.01419.i, %161 ], [ %.014.i, %.lr.ph.i ] + %.pre-phi = phi i64 [ %.pn20.i, %148 ], [ %.pn.i, %.lr.ph.i ] + %.014.lcssa.i = phi i32 [ %.01419.i, %148 ], [ %.014.i, %.lr.ph.i ] %164 = getelementptr inbounds i32, ptr %.sroa.0139.0166173180, i64 %.pre-phi %165 = load i32, ptr %164, align 4, !tbaa !56 %166 = zext i32 %165 to i64 %.not79 = icmp eq i64 %indvars.iv214, %166 - br i1 %.not79, label %172, label %167 - -167: ; preds = %.loopexit - %168 = sext i32 %165 to i64 - %169 = getelementptr inbounds i32, ptr %96, i64 %168 - store i32 %130, ptr %169, align 4, !tbaa !56 - %170 = sext i32 %.066199 to i64 - %171 = getelementptr inbounds i32, ptr %.sroa.0131.0181, i64 %170 - store i32 %.014.lcssa.i, ptr %171, align 4, !tbaa !56 - store i32 %130, ptr %164, align 4, !tbaa !56 - br label %172 + br i1 %.not79, label %159, label %172 -172: ; preds = %.loopexit, %167, %156 - %.167 = phi i32 [ %.066199, %156 ], [ %.014.lcssa.i, %167 ], [ %.066199, %.loopexit ] - %173 = add nsw i64 %.sroa.7.0197, 1 - %174 = icmp sge i64 %173, %.sink.i108 - %.not190 = select i1 %174, i1 %spec.select, i1 false +172: ; preds = %.loopexit + %155 = sext i32 %152 to i64 + %156 = getelementptr inbounds i32, ptr %83, i64 %155 + store i32 %117, ptr %156, align 4, !tbaa !56 + %157 = sext i32 %.066199 to i64 + %158 = getelementptr inbounds i32, ptr %.sroa.0131.0181, i64 %157 + store i32 %.014.lcssa.i, ptr %158, align 4, !tbaa !56 + store i32 %117, ptr %151, align 4, !tbaa !56 + br label %159 + +159: ; preds = %.loopexit, %154, %143 + %.167 = phi i32 [ %.066199, %143 ], [ %.014.lcssa.i, %154 ], [ %.066199, %.loopexit ] + %160 = add nsw i64 %.sroa.7.0197, 1 + %161 = icmp sge i64 %160, %.sink.i108 + %.not190 = select i1 %161, i1 %spec.select, i1 false br i1 %.not190, label %._crit_edge201, label %.lr.ph200, !llvm.loop !352 .body: ; preds = %105, %20 - %.sroa.0139.0167 = phi ptr [ %.sroa.0139.0166173180, %105 ], [ %calloc, %20 ] - %.pn84.pn.pn.pn.pn = phi { ptr, i32 } [ %106, %105 ], [ %21, %20 ] + %.sroa.0139.0167 = phi ptr [ %.sroa.0139.0166173180, %92 ], [ %calloc, %20 ] + %.pn84.pn.pn.pn.pn = phi { ptr, i32 } [ %106, %92 ], [ %21, %20 ] tail call void @free(ptr noundef %.sroa.0139.0167) #5 resume { ptr, i32 } %.pn84.pn.pn.pn.pn } diff --git a/bench/opencv/optimized/eltwise_layer.ll b/bench/opencv/optimized/eltwise_layer.ll index 519a4b6c5b4..5bbdb97f7c2 100644 --- a/bench/opencv/optimized/eltwise_layer.ll +++ b/bench/opencv/optimized/eltwise_layer.ll @@ -6169,10 +6169,9 @@ _ZNKSt6vectorIiSaIiEE12_M_check_lenEmPKc.exit.i: ; preds = %_ZNKSt6vectorIPKN2c %108 = getelementptr inbounds nuw i8, ptr %12, i64 32 %109 = getelementptr inbounds nuw i8, ptr %12, i64 24 store ptr null, ptr %107, align 8, !tbaa !187 - %110 = add nsw i64 %105, -1 - %111 = getelementptr i8, ptr %107, i64 8 - %.idx.i.i.i.i.i31.i = shl nuw nsw i64 %110, 3 - tail call void @llvm.memset.p0.i64(ptr align 8 %111, i8 0, i64 %.idx.i.i.i.i.i31.i, i1 false), !tbaa !187 + %110 = getelementptr i8, ptr %107, i64 8 + %.idx.i.i.i.i.i31.i = add nsw i64 %106, -8 + tail call void @llvm.memset.p0.i64(ptr align 8 %110, i8 0, i64 %.idx.i.i.i.i.i31.i, i1 false), !tbaa !187 store ptr %107, ptr %100, align 8, !tbaa !188 %112 = getelementptr inbounds nuw ptr, ptr %107, i64 %105 store ptr %112, ptr %109, align 8, !tbaa !189 @@ -6187,12 +6186,13 @@ _ZNSt6vectorIiSaIiEE6resizeEm.exit: ; preds = %_ZNKSt6vectorIiSaIi %117 = getelementptr inbounds nuw i8, ptr %12, i64 48 store i32 0, ptr %115, align 4, !tbaa !96 %118 = getelementptr i8, ptr %115, i64 4 - %.idx.i.i.i.i.i31.i205 = shl nuw nsw i64 %110, 2 - tail call void @llvm.memset.p0.i64(ptr align 4 %118, i8 0, i64 %.idx.i.i.i.i.i31.i205, i1 false), !tbaa !96 - store ptr %115, ptr %113, align 8, !tbaa !125 - %119 = getelementptr inbounds nuw i32, ptr %115, i64 %105 - store ptr %119, ptr %117, align 8, !tbaa !127 - store ptr %119, ptr %116, align 8, !tbaa !128 + %.idx.i.i.i.i.i31.i205 = shl nuw nsw i64 %105, 2 + %.idx.i.i.i.i.i31.i205 = add nsw i64 %.idx.i.i.i.i.i31.i205, -4 + tail call void @llvm.memset.p0.i64(ptr align 4 %117, i8 0, i64 %.idx.i.i.i.i.i31.i205, i1 false), !tbaa !96 + store ptr %114, ptr %112, align 8, !tbaa !125 + %119 = getelementptr inbounds nuw i32, ptr %114, i64 %105 + store ptr %119, ptr %116, align 8, !tbaa !127 + store ptr %119, ptr %115, align 8, !tbaa !128 %120 = getelementptr inbounds nuw i8, ptr %12, i64 80 %.not.i = icmp eq ptr %56, %120 br i1 %.not.i, label %.lr.ph240, label %121 diff --git a/bench/opencv/optimized/freak.ll b/bench/opencv/optimized/freak.ll index 608a0789fdb..9b4a966c8a1 100644 --- a/bench/opencv/optimized/freak.ll +++ b/bench/opencv/optimized/freak.ll @@ -7743,7 +7743,7 @@ _ZNK2cv7MatExprcvNS_3MatEEv.exit: ; preds = %113 %.not = icmp eq i64 %indvars.iv.next384, 0 br i1 %.not, label %.preheader252, label %.preheader258, !llvm.loop !271 -146: ; preds = %158, %.preheader258 +146: ; preds = %.preheader258, %158 %indvars.iv = phi i64 [ 902, %.preheader258 ], [ %indvars.iv.next, %158 ] %147 = lshr i64 %indvars.iv, 6 %148 = getelementptr inbounds nuw i64, ptr %.079309, i64 %147 diff --git a/bench/opencv/optimized/model.ll b/bench/opencv/optimized/model.ll index 2feefeee825..2114b6c9e86 100644 --- a/bench/opencv/optimized/model.ll +++ b/bench/opencv/optimized/model.ll @@ -16852,7 +16852,7 @@ _ZNSt6vectorISt4pairIS_IiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreE ret void .lr.ph876: ; preds = %1189, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_.exit - %.sroa.0514.0874 = phi ptr [ %1222, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_.exit ], [ %1190, %1189 ] + %.sroa.0514.0874 = phi ptr [ %1222, %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_.exit ], [ %1190, %.split873 ] %1196 = load i32, ptr %.sroa.0514.0874, align 4, !tbaa !98 %1197 = icmp sgt i32 %1196, 0 br i1 %1197, label %1198, label %1206 @@ -16861,16 +16861,16 @@ _ZNSt6vectorISt4pairIS_IiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreE %1199 = zext nneg i32 %1196 to i64 %1200 = load ptr, ptr %28, align 8, !tbaa !258 %1201 = load ptr, ptr %27, align 8, !tbaa !257 + %1201 = ptrtoint ptr %1199 to i64 %1202 = ptrtoint ptr %1200 to i64 - %1203 = ptrtoint ptr %1201 to i64 - %1204 = sub i64 %1202, %1203 - %1205 = ashr exact i64 %1204, 5 - %.not = icmp ult i64 %1205, %1199 - br i1 %.not, label %1206, label %1208 + %1203 = sub i64 %1201, %1202 + %1204 = ashr exact i64 %1203, 5 + %.not = icmp ult i64 %1204, %1198 + br i1 %.not, label %1205, label %1212 1206: ; preds = %1198, %.lr.ph876 invoke void @_ZN2cv6detail17check_failed_autoEiRKNS0_12CheckContextE(i32 noundef %1196, ptr noundef nonnull align 8 dereferenceable(48) @_ZZN2cv3dnn25TextRecognitionModel_Impl25ctcPrefixBeamSearchDecodeB5cxx11ERKNS_3MatEE15__cv_check__904) #33 - to label %1207 unwind label %.loopexit.split-lp + to label %1206 unwind label %.loopexit.split-lp 1207: ; preds = %1206 unreachable @@ -16880,27 +16880,14 @@ _ZNSt6vectorISt4pairIS_IiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreE cleanup br label %1223 -.loopexit.split-lp: ; preds = %1206, %1211, %1219 +.loopexit.split-lp: ; preds = %1206, %1219 %lpad.loopexit.split-lp = landingpad { ptr, i32 } cleanup br label %1223 -1208: ; preds = %1198 - %1209 = add nsw i32 %1196, -1 - %1210 = zext nneg i32 %1209 to i64 - %.not.i.i187 = icmp ugt i64 %1205, %1210 - br i1 %.not.i.i187, label %1212, label %1211 - -1211: ; preds = %1208 - invoke void (ptr, ...) @_ZSt24__throw_out_of_range_fmtPKcz(ptr noundef nonnull @.str.39, i64 noundef %1210, i64 noundef %1205) #33 - to label %.noexc188 unwind label %.loopexit.split-lp - -.noexc188: ; preds = %1211 - unreachable - -1212: ; preds = %1208 - %1213 = getelementptr inbounds nuw %"class.std::__cxx11::basic_string", ptr %1201, i64 %1210 - %1214 = getelementptr inbounds nuw i8, ptr %1213, i64 8 +1212: ; preds = %1198 + %1213 = getelementptr %"class.std::__cxx11::basic_string", ptr %1201, i64 %1198 + %1214 = getelementptr i8, ptr %1213, i64 -24 %1215 = load i64, ptr %1214, align 8, !tbaa !66 %1216 = load i64, ptr %41, align 8, !tbaa !66 %1217 = sub i64 4611686018427387903, %1216 @@ -16915,8 +16902,9 @@ _ZNSt6vectorISt4pairIS_IiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreE unreachable _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendERKS4_.exit.i: ; preds = %1212 - %1220 = load ptr, ptr %1213, align 8, !tbaa !70 - %1221 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm(ptr noundef nonnull align 8 dereferenceable(32) %0, ptr noundef %1220, i64 noundef %1215) + %1215 = getelementptr i8, ptr %1213, i64 -32 + %1216 = load ptr, ptr %1215, align 8, !tbaa !70 + %1217 = invoke noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm(ptr noundef nonnull align 8 dereferenceable(32) %0, ptr noundef %1216, i64 noundef %1210) to label %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_.exit unwind label %.loopexit _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_.exit: ; preds = %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendERKS4_.exit.i @@ -16932,7 +16920,7 @@ _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEpLERKS4_.exit: ; preds = %_ br i1 %.not4.i.i.i.i191, label %_ZSt8_DestroyIPSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEES8_EvT_SA_RSaIT0_E.exit.i199, label %.lr.ph.i.i.i.i192 .lr.ph.i.i.i.i192: ; preds = %1223, %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195 - %.05.i.i.i.i193 = phi ptr [ %1226, %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195 ], [ %.sroa.0544.0747, %1223 ] + %.05.i.i.i.i193 = phi ptr [ %1226, %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195 ], [ %.sroa.0544.0747, %1219 ] %1224 = load ptr, ptr %.05.i.i.i.i193, align 8, !tbaa !314 %.not.i.i.i.i.i.i.i.i.i194 = icmp eq ptr %1224, null br i1 %.not.i.i.i.i.i.i.i.i.i194, label %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195, label %1225 @@ -16947,8 +16935,8 @@ _ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11Pref br i1 %.not.i.i.i.i196, label %_ZSt8_DestroyIPSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEES8_EvT_SA_RSaIT0_E.exit.i199, label %.lr.ph.i.i.i.i192, !llvm.loop !648 _ZSt8_DestroyIPSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEES8_EvT_SA_RSaIT0_E.exit.i199: ; preds = %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195, %.thread1114, %1223 - %.pn95.pn.pn.pn1120 = phi { ptr, i32 } [ %.pn85, %.thread1114 ], [ %.pn95.pn.pn.pn, %1223 ], [ %.pn95.pn.pn.pn, %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195 ] - %.sroa.0544.07471119 = phi ptr [ %.sroa.0544.0.lcssa, %.thread1114 ], [ %.sroa.0544.0747, %1223 ], [ %.sroa.0544.0747, %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195 ] + %.pn95.pn.pn.pn1120 = phi { ptr, i32 } [ %.pn85, %.thread1103 ], [ %.pn95.pn.pn.pn, %1219 ], [ %.pn95.pn.pn.pn, %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195 ] + %.sroa.0544.07471119 = phi ptr [ %.sroa.0544.0.lcssa, %.thread1103 ], [ %.sroa.0544.0747, %1219 ], [ %.sroa.0544.0747, %_ZSt8_DestroyISt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEEEvPT_.exit.i.i.i.i195 ] %.not.i.i.i200 = icmp eq ptr %.sroa.0544.07471119, null br i1 %.not.i.i.i200, label %_ZNSt6vectorISt4pairIS_IiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEESaIS7_EED2Ev.exit202, label %1227 @@ -16957,7 +16945,7 @@ _ZSt8_DestroyIPSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11Pre br label %_ZNSt6vectorISt4pairIS_IiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEESaIS7_EED2Ev.exit202 _ZNSt6vectorISt4pairIS_IiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEESaIS7_EED2Ev.exit202: ; preds = %1227, %_ZSt8_DestroyIPSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEES8_EvT_SA_RSaIT0_E.exit.i199, %_ZNSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEED2Ev.exit102 - %.pn95.pn.pn.pn.pn = phi { ptr, i32 } [ %eh.lpad-body1101, %_ZNSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEED2Ev.exit102 ], [ %.pn95.pn.pn.pn1120, %_ZSt8_DestroyIPSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEES8_EvT_SA_RSaIT0_E.exit.i199 ], [ %.pn95.pn.pn.pn1120, %1227 ] + %.pn95.pn.pn.pn.pn = phi { ptr, i32 } [ %eh.lpad-body1101, %_ZNSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEED2Ev.exit102 ], [ %.pn95.pn.pn.pn1120, %_ZSt8_DestroyIPSt4pairISt6vectorIiSaIiEEN2cv3dnn25TextRecognitionModel_Impl11PrefixScoreEES8_EvT_SA_RSaIT0_E.exit.i199 ], [ %.pn95.pn.pn.pn1120, %1223 ] %1228 = load ptr, ptr %0, align 8, !tbaa !70 %1229 = icmp eq ptr %1228, %40 br i1 %1229, label %_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit205, label %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i203 diff --git a/bench/openssl/optimized/v3_ncons.ll b/bench/openssl/optimized/v3_ncons.ll index fa22bec6f79..dac07063254 100644 --- a/bench/openssl/optimized/v3_ncons.ll +++ b/bench/openssl/optimized/v3_ncons.ll @@ -686,7 +686,7 @@ define range(i32 0, 54) i32 @NAME_CONSTRAINTS_check_CN(ptr noundef %0, ptr nound br label %cn2dnsid.exit 33: ; preds = %51, %.outer.i - %indvars.iv.i = phi i64 [ %indvars.iv.next.i, %51 ], [ %indvars.iv.ph.i, %.outer.i ] + %indvars.iv.i = phi i64 [ %indvars.iv.next.i, %50 ], [ %indvars.iv.ph.i, %.outer.i ] %34 = getelementptr inbounds nuw i8, ptr %.pre.i, i64 %indvars.iv.i %35 = load i8, ptr %34, align 1, !tbaa !11 %36 = and i8 %35, -33 @@ -726,20 +726,16 @@ define range(i32 0, 54) i32 @NAME_CONSTRAINTS_check_CN(ptr noundef %0, ptr nound %.not51.i = icmp eq i8 %50, 45 %.not52.i = icmp eq i8 %47, 45 %or.cond57.i = or i1 %.not52.i, %.not51.i - br i1 %or.cond57.i, label %.loopexit, label %.thread.i + %indvars.iv.next83.i = add nuw nsw i64 %indvars.iv.i, 1 + br i1 %or.cond57.i, label %.loopexit, label %.outer.i, !llvm.loop !62 51: ; preds = %43, %38, %33 %indvars.iv.next.i = add nuw nsw i64 %indvars.iv.i, 1 %exitcond.not.i = icmp eq i64 %indvars.iv.next.i, %26 br i1 %exitcond.not.i, label %._crit_edge.i, label %33, !llvm.loop !62 -.thread.i: ; preds = %48 - %indvars.iv.next83.i = add nuw nsw i64 %indvars.iv.i, 1 - %exitcond.not84.i = icmp eq i64 %indvars.iv.next83.i, %26 - br i1 %exitcond.not84.i, label %.loopexit41, label %.outer.i, !llvm.loop !62 - -._crit_edge.i: ; preds = %51 - br i1 %31, label %.loopexit, label %.loopexit41 +.thread.i: ; preds = %50 + br i1 %31, label %.loopexit, label %51 cn2dnsid.exit: ; preds = %13, %32 %.0.i = phi i32 [ 53, %32 ], [ 17, %13 ] @@ -751,7 +747,7 @@ cn2dnsid.exit: ; preds = %13, %32 call void @llvm.lifetime.end.p0(ptr nonnull %3) br label %select.unfold -.loopexit41: ; preds = %.thread.i, %._crit_edge.i +.loopexit41: ; preds = %._crit_edge.i call void @llvm.lifetime.end.p0(ptr nonnull %3) store i32 %.045.lcssa.i, ptr %4, align 8, !tbaa !63 store ptr %.pre.i, ptr %12, align 8, !tbaa !64 @@ -766,7 +762,7 @@ select.unfold: ; preds = %.loopexit41, %.loop br i1 %54, label %.thread34, label %13 .thread34: ; preds = %select.unfold, %.loopexit41, %2, %cn2dnsid.exit - %.2 = phi i32 [ %.0.i, %cn2dnsid.exit ], [ 0, %2 ], [ 0, %select.unfold ], [ %52, %.loopexit41 ] + %.2 = phi i32 [ %.0.i, %cn2dnsid.exit ], [ 0, %2 ], [ 0, %select.unfold ], [ %52, %51 ] call void @llvm.lifetime.end.p0(ptr nonnull %5) call void @llvm.lifetime.end.p0(ptr nonnull %4) ret i32 %.2 diff --git a/bench/pola-rs/optimized/9kt0ps7am1ervf5eo1u53zq54.ll b/bench/pola-rs/optimized/9kt0ps7am1ervf5eo1u53zq54.ll index 9895a17331f..5a70cce086c 100644 --- a/bench/pola-rs/optimized/9kt0ps7am1ervf5eo1u53zq54.ll +++ b/bench/pola-rs/optimized/9kt0ps7am1ervf5eo1u53zq54.ll @@ -27292,7 +27292,7 @@ define hidden void @_ZN5rayon5slice9mergesort13par_mergesort17h339a646c7afabb7aE %exitcond.not.i.i56 = icmp eq i64 %145, %135 br i1 %exitcond.not.i.i56, label %.loopexit.sink.split, label %137 -146: ; preds = %_ZN5rayon5slice9mergesort11insert_head17h7ad417bf3cc01170E.exit, %.lr.ph90.preheader +146: ; preds = %.lr.ph90.preheader, %_ZN5rayon5slice9mergesort11insert_head17h7ad417bf3cc01170E.exit %.sroa.026.089 = phi i64 [ %147, %_ZN5rayon5slice9mergesort11insert_head17h7ad417bf3cc01170E.exit ], [ %28, %.lr.ph90.preheader ] %147 = add nsw i64 %.sroa.026.089, -1 %148 = sub nuw nsw i64 %1, %147 @@ -27322,7 +27322,7 @@ define hidden void @_ZN5rayon5slice9mergesort13par_mergesort17h339a646c7afabb7aE br label %.lr.ph ._crit_edge.i: ; preds = %.lr.ph.i, %.lr.ph, %.lr.ph.i.preheader, %153 - %.sroa.5.0.lcssa.i = phi ptr [ %154, %153 ], [ %154, %.lr.ph.i.preheader ], [ %162, %.lr.ph ], [ %162, %.lr.ph.i ] + %.sroa.5.0.lcssa.i = phi ptr [ %154, %152 ], [ %154, %.lr.ph.i.preheader ], [ %162, %.lr.ph ], [ %162, %.lr.ph.i ] store i32 %155, ptr %.sroa.5.0.lcssa.i, align 8, !alias.scope !4176 %.sroa.54.0..sroa.5.0.sroa_idx5.i = getelementptr inbounds nuw i8, ptr %.sroa.5.0.lcssa.i, i64 8 store i64 %.val12.i, ptr %.sroa.54.0..sroa.5.0.sroa_idx5.i, align 8, !alias.scope !4176 @@ -27771,7 +27771,7 @@ define hidden void @_ZN5rayon5slice9mergesort13par_mergesort17h719818d9b3daaf5eE %exitcond.not.i.i56 = icmp eq i64 %145, %135 br i1 %exitcond.not.i.i56, label %.loopexit.sink.split, label %137 -146: ; preds = %_ZN5rayon5slice9mergesort11insert_head17h95147180a0eb705aE.exit, %.lr.ph90.preheader +146: ; preds = %.lr.ph90.preheader, %_ZN5rayon5slice9mergesort11insert_head17h95147180a0eb705aE.exit %.sroa.026.089 = phi i64 [ %147, %_ZN5rayon5slice9mergesort11insert_head17h95147180a0eb705aE.exit ], [ %28, %.lr.ph90.preheader ] %147 = add nsw i64 %.sroa.026.089, -1 %148 = sub nuw nsw i64 %1, %147 @@ -27801,7 +27801,7 @@ define hidden void @_ZN5rayon5slice9mergesort13par_mergesort17h719818d9b3daaf5eE br label %.lr.ph ._crit_edge.i: ; preds = %.lr.ph.i, %.lr.ph, %.lr.ph.i.preheader, %153 - %.sroa.5.0.lcssa.i = phi ptr [ %154, %153 ], [ %154, %.lr.ph.i.preheader ], [ %162, %.lr.ph ], [ %162, %.lr.ph.i ] + %.sroa.5.0.lcssa.i = phi ptr [ %154, %152 ], [ %154, %.lr.ph.i.preheader ], [ %162, %.lr.ph ], [ %162, %.lr.ph.i ] store i32 %155, ptr %.sroa.5.0.lcssa.i, align 8, !alias.scope !4236 %.sroa.54.0..sroa.5.0.sroa_idx5.i = getelementptr inbounds nuw i8, ptr %.sroa.5.0.lcssa.i, i64 8 store i64 %.val8.i, ptr %.sroa.54.0..sroa.5.0.sroa_idx5.i, align 8, !alias.scope !4236 diff --git a/bench/quantlib/optimized/capletcoterminalmaxhomogeneity.ll b/bench/quantlib/optimized/capletcoterminalmaxhomogeneity.ll index 1703f0a9d57..4e9e3526e77 100644 --- a/bench/quantlib/optimized/capletcoterminalmaxhomogeneity.ll +++ b/bench/quantlib/optimized/capletcoterminalmaxhomogeneity.ll @@ -2069,9 +2069,9 @@ _ZNSt16allocator_traitsISaISt6vectorIdSaIdEEEE9constructIS2_JRKS2_EEEvRS3_PT_DpO if.else.i: ; preds = %invoke.cont132 invoke void @_ZNSt6vectorIS_IdSaIdEESaIS1_EE17_M_realloc_insertIJRKS1_EEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_(ptr noundef nonnull align 8 dereferenceable(24) %newVols, ptr %53, ptr noundef nonnull align 8 dereferenceable(24) %firstRateVols) - to label %_ZNSt6vectorIS_IdSaIdEESaIS1_EE9push_backERKS1_.exit unwind label %lpad135 + to label %_ZNSt6vectorIS_IdSaIdEESaIS1_EE9push_backERKS1_.exit.split unwind label %lpad135 -_ZNSt6vectorIS_IdSaIdEESaIS1_EE9push_backERKS1_.exit: ; preds = %if.else.i, %_ZNSt16allocator_traitsISaISt6vectorIdSaIdEEEE9constructIS2_JRKS2_EEEvRS3_PT_DpOT0_.exit.i +_ZNSt6vectorIS_IdSaIdEESaIS1_EE9push_backERKS1_.exit: ; preds = %_ZNSt16allocator_traitsISaISt6vectorIdSaIdEEEE9constructIS2_JRKS2_EEEvRS3_PT_DpOT0_.exit.i, %if.else.i br i1 %cmp.i.i.i.i.i.i.i, label %for.cond.cleanup140, label %for.body141.lr.ph for.body141.lr.ph: ; preds = %_ZNSt6vectorIS_IdSaIdEESaIS1_EE9push_backERKS1_.exit @@ -2098,7 +2098,7 @@ for.body141.lr.ph: ; preds = %_ZNSt6vectorIS_IdSa br label %for.body141 for.cond.cleanup140: ; preds = %invoke.cont248, %_ZNSt6vectorIS_IdSaIdEESaIS1_EE9push_backERKS1_.exit - %failures.0.lcssa = phi i32 [ 0, %_ZNSt6vectorIS_IdSaIdEESaIS1_EE9push_backERKS1_.exit ], [ %spec.select, %invoke.cont248 ] + %failures.0.lcssa = phi i32 [ 0, %_ZNSt6vectorIS_IdSaIdEESaIS1_EE9push_backERKS1_.exit.split ], [ %spec.select, %invoke.cont248 ] %_M_finish.i.i = getelementptr inbounds nuw i8, ptr %swapCovariancePseudoRoots, i64 8 %59 = load ptr, ptr %_M_finish.i.i, align 8, !tbaa !79 %60 = load ptr, ptr %swapCovariancePseudoRoots, align 8, !tbaa !80 @@ -2482,17 +2482,6 @@ for.body.i: ; preds = %for.cond.cleanup210 br i1 %exitcond.not.i, label %for.end.i, label %for.body.i, !llvm.loop !94 for.end.i: ; preds = %for.body.i - %cmp.i.i.i307 = icmp ugt i64 %i137.0913, 1152921504606846974 - br i1 %cmp.i.i.i307, label %if.then.i.i.i, label %if.then.i.i.i.i.i.i - -if.then.i.i.i: ; preds = %for.end.i - invoke void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str.22) #22 - to label %.noexc328 unwind label %lpad224.loopexit.split-lp - -.noexc328: ; preds = %if.then.i.i.i - unreachable - -if.then.i.i.i.i.i.i: ; preds = %for.end.i %add.ptr.i191.i = getelementptr inbounds nuw double, ptr %call5.i.i.i.i2.i.i249, i64 %add %116 = load double, ptr %add.ptr.i191.i, align 8, !tbaa !74 %mul.i.i.i.i.i.i.i = shl nuw nsw i64 %add, 3 @@ -2501,7 +2490,7 @@ if.then.i.i.i.i.i.i: ; preds = %for.end.i %call.i194.i = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %mul.i.i.i.i.i.i.i) #25 to label %cond.true.i196.i unwind label %ehcleanup376.thread.i -cond.true.i196.i: ; preds = %if.then.i.i.i.i.i.i +cond.true.i196.i: ; preds = %for.end.i %mul111110113.i = fmul double %84, %84 store ptr %call.i194.i, ptr %cylinderCentre.i, align 8, !tbaa !70 store i64 %add, ptr %n_.i.i, align 8, !tbaa !95 @@ -2540,7 +2529,7 @@ for.cond.cleanup.i: ; preds = %for.body126.i %cmp165.i = fcmp ogt double %sub164.i, 0.000000e+00 br i1 %cmp165.i, label %cond.true.i, label %cond.end.i -ehcleanup376.thread.i: ; preds = %if.then.i.i.i.i.i.i +ehcleanup376.thread.i: ; preds = %for.end.i %122 = landingpad { ptr, i32 } cleanup call void @llvm.lifetime.end.p0(ptr nonnull %cylinderCentre.i) @@ -3241,7 +3230,7 @@ lpad224.loopexit: ; preds = %if.then.i319, %.noe cleanup br label %ehcleanup423 -lpad224.loopexit.split-lp: ; preds = %if.then3.i.i.i.i.i.i.i.i.i359.invoke, %if.then.i.i.i +lpad224.loopexit.split-lp: ; preds = %if.then3.i.i.i.i.i.i.i.i.i359.invoke %lpad.loopexit.split-lp = landingpad { ptr, i32 } cleanup br label %ehcleanup423 diff --git a/bench/quantlib/optimized/garch.ll b/bench/quantlib/optimized/garch.ll index 1e51ff4db7d..12c7e518c45 100644 --- a/bench/quantlib/optimized/garch.ll +++ b/bench/quantlib/optimized/garch.ll @@ -883,24 +883,15 @@ if.then.i.i.i.i.i: ; preds = %_ZN8QuantLib5ArrayC call5.i.i.i.i2.i.i.noexc: ; preds = %if.then.i.i.i.i.i store double 0.000000e+00, ptr %call5.i.i.i.i2.i.i125, align 8, !tbaa !21 %incdec.ptr.i.i.i.i.i = getelementptr i8, ptr %call5.i.i.i.i2.i.i125, i64 8 - %sub.i.i.i.i.i = add nsw i64 %sub.ptr.div.i, -1 - %cmp.i.i.i.i.i.i.i = icmp eq i64 %sub.i.i.i.i.i, 0 - br i1 %cmp.i.i.i.i.i.i.i, label %invoke.cont71, label %if.end.i.i.i.i.i.i.i - -if.end.i.i.i.i.i.i.i: ; preds = %call5.i.i.i.i2.i.i.noexc - %add.ptr.idx.i.i.i.i.i.i.i = shl nuw nsw i64 %sub.i.i.i.i.i, 3 + %sub.i.i.i.i.i = add i64 %sub.ptr.sub.i, -8 tail call void @llvm.memset.p0.i64(ptr align 8 %incdec.ptr.i.i.i.i.i, i8 0, i64 %add.ptr.idx.i.i.i.i.i.i.i, i1 false), !tbaa !21 - %add.ptr.i.i.i.i.i.i.i = getelementptr inbounds nuw i8, ptr %incdec.ptr.i.i.i.i.i, i64 %add.ptr.idx.i.i.i.i.i.i.i - br label %invoke.cont71 - -invoke.cont71: ; preds = %if.end.i.i.i.i.i.i.i, %call5.i.i.i.i2.i.i.noexc - %__first.addr.0.i.i.i.i.i = phi ptr [ %incdec.ptr.i.i.i.i.i, %call5.i.i.i.i2.i.i.noexc ], [ %add.ptr.i.i.i.i.i.i.i, %if.end.i.i.i.i.i.i.i ] + %add.ptr.i.i.i.i.i.i.i = getelementptr i8, ptr %call5.i.i.i.i2.i.i125, i64 %sub.ptr.sub.i %cmp.i.not5.i = icmp eq ptr %1, %0 br i1 %cmp.i.not5.i, label %invoke.cont87, label %for.body.i -for.body.i: ; preds = %invoke.cont71, %for.body.i - %__first.sroa.0.07.i = phi ptr [ %incdec.ptr.i.i, %for.body.i ], [ %1, %invoke.cont71 ] - %__result.sroa.0.06.i = phi ptr [ %incdec.ptr.i1.i, %for.body.i ], [ %call5.i.i.i.i2.i.i125, %invoke.cont71 ] +for.body.i: ; preds = %call5.i.i.i.i2.i.i.noexc, %for.body.i + %__first.sroa.0.07.i = phi ptr [ %incdec.ptr.i.i, %for.body.i ], [ %1, %call5.i.i.i.i2.i.i.noexc ] + %__result.sroa.0.06.i = phi ptr [ %incdec.ptr.i1.i, %for.body.i ], [ %call5.i.i.i.i2.i.i125, %call5.i.i.i.i2.i.i.noexc ] %39 = load double, ptr %__first.sroa.0.07.i, align 8, !tbaa !21 %sub.i.i = fsub double %39, %mean_r2 store double %sub.i.i, ptr %__result.sroa.0.06.i, align 8, !tbaa !21 @@ -909,8 +900,8 @@ for.body.i: ; preds = %invoke.cont71, %for %cmp.i.not.i = icmp eq ptr %incdec.ptr.i.i, %0 br i1 %cmp.i.not.i, label %invoke.cont87, label %for.body.i, !llvm.loop !55 -invoke.cont87: ; preds = %for.body.i, %invoke.cont71 - invoke void @_ZN8QuantLib15autocovariancesIN9__gnu_cxx17__normal_iteratorIPdSt6vectorIdSaIdEEEES3_EEvT_S8_T0_m(ptr nonnull %call5.i.i.i.i2.i.i125, ptr %__first.addr.0.i.i.i.i.i, ptr noundef %cond.i, i64 noundef %conv67) +invoke.cont87: ; preds = %for.body.i, %call5.i.i.i.i2.i.i.noexc + invoke void @_ZN8QuantLib15autocovariancesIN9__gnu_cxx17__normal_iteratorIPdSt6vectorIdSaIdEEEES3_EEvT_S8_T0_m(ptr nonnull %call5.i.i.i.i2.i.i125, ptr %add.ptr.i.i.i.i.i.i.i, ptr noundef %cond.i, i64 noundef %conv67) to label %do.body101 unwind label %lpad86 do.body101: ; preds = %invoke.cont87 diff --git a/bench/quantlib/optimized/multiproductmultistep.ll b/bench/quantlib/optimized/multiproductmultistep.ll index d1754b10fa9..81169fac08b 100644 --- a/bench/quantlib/optimized/multiproductmultistep.ll +++ b/bench/quantlib/optimized/multiproductmultistep.ll @@ -259,15 +259,11 @@ if.then.i.i33: ; preds = %do.end _ZNSt6vectorIdSaIdEE17_S_check_init_lenEmRKS0_.exit.i: ; preds = %do.end %23 = getelementptr inbounds nuw i8, ptr %evolutionTimes, i64 8 store i64 0, ptr %23, align 8 - %cmp.not.i.i.i.i = icmp eq i64 %sub, 0 - br i1 %cmp.not.i.i.i.i, label %invoke.cont38.thread, label %if.then.i.i.i.i.i - -if.then.i.i.i.i.i: ; preds = %_ZNSt6vectorIdSaIdEE17_S_check_init_lenEmRKS0_.exit.i %mul.i.i.i.i.i.i = shl nuw nsw i64 %sub, 3 %call5.i.i.i.i2.i.i34 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %mul.i.i.i.i.i.i) #20 to label %call5.i.i.i.i2.i.i.noexc unwind label %lpad32 -call5.i.i.i.i2.i.i.noexc: ; preds = %if.then.i.i.i.i.i +call5.i.i.i.i2.i.i.noexc: ; preds = %_ZNSt6vectorIdSaIdEE17_S_check_init_lenEmRKS0_.exit.i store ptr %call5.i.i.i.i2.i.i34, ptr %evolutionTimes, align 8, !tbaa !6 %add.ptr.i.i.i = getelementptr inbounds nuw double, ptr %call5.i.i.i.i2.i.i34, i64 %sub %_M_end_of_storage.i.i.i = getelementptr inbounds nuw i8, ptr %evolutionTimes, i64 16 @@ -301,17 +297,10 @@ _ZNSt6vectorISt4pairImmESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i: ; preds = %ca call void @llvm.lifetime.start.p0(ptr nonnull %relevanceRates) br label %for.inc.preheader.i.i.i.i.i -invoke.cont38.thread: ; preds = %_ZNSt6vectorIdSaIdEE17_S_check_init_lenEmRKS0_.exit.i - call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %evolutionTimes, i8 0, i64 24, i1 false) - call void @llvm.lifetime.start.p0(ptr nonnull %relevanceRates) - %24 = getelementptr inbounds nuw i8, ptr %relevanceRates, i64 16 - call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %relevanceRates, i8 0, i64 24, i1 false) - br label %for.cond.cleanup - for.inc.preheader.i.i.i.i.i: ; preds = %invoke.cont33, %_ZNSt6vectorISt4pairImmESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i %mul.i.i.i.i.i.i37 = shl nuw nsw i64 %sub, 4 %call5.i.i.i.i2.i.i43 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %mul.i.i.i.i.i.i37) #20 - to label %invoke.cont48.lr.ph unwind label %lpad37 + to label %call5.i.i.i.i2.i.i.noexc42 unwind label %lpad37 invoke.cont48.lr.ph: ; preds = %for.inc.preheader.i.i.i.i.i store ptr %call5.i.i.i.i2.i.i43, ptr %relevanceRates, align 8, !tbaa !19 @@ -322,15 +311,15 @@ invoke.cont48.lr.ph: ; preds = %for.inc.preheader.i %25 = getelementptr inbounds nuw i8, ptr %relevanceRates, i64 16 store ptr %add.ptr.i.i.i38, ptr %25, align 8, !tbaa !21 store ptr %scevgep.i.i.i.i.i, ptr %_M_finish.i.i7.i39, align 8, !tbaa !22 - br label %invoke.cont48 + %cmp41103.not = icmp eq i64 %sub, 0 + br i1 %cmp41103.not, label %for.cond.cleanup, label %invoke.cont48 -for.cond.cleanup: ; preds = %invoke.cont48, %invoke.cont38.thread - %26 = phi ptr [ %24, %invoke.cont38.thread ], [ %25, %invoke.cont48 ] +for.cond.cleanup: ; preds = %invoke.cont48, %invoke.cont48.lr.ph call void @llvm.lifetime.start.p0(ptr nonnull %ref.tmp55) invoke void @_ZN8QuantLib20EvolutionDescriptionC1ERKSt6vectorIdSaIdEES5_RKS1_ISt4pairImmESaIS7_EE(ptr noundef nonnull align 8 dereferenceable(128) %ref.tmp55, ptr noundef nonnull align 8 dereferenceable(24) %rateTimes_, ptr noundef nonnull align 8 dereferenceable(24) %evolutionTimes, ptr noundef nonnull align 8 dereferenceable(24) %relevanceRates) to label %invoke.cont58 unwind label %lpad57 -lpad32: ; preds = %if.then.i.i.i.i.i, %if.then.i.i33 +lpad32: ; preds = %_ZNSt6vectorIdSaIdEE17_S_check_init_lenEmRKS0_.exit.i, %if.then.i.i33 %27 = landingpad { ptr, i32 } cleanup br label %ehcleanup65 @@ -341,7 +330,7 @@ lpad37: ; preds = %for.inc.preheader.i br label %ehcleanup63 invoke.cont48: ; preds = %invoke.cont48.lr.ph, %invoke.cont48 - %storemerge104 = phi i64 [ 0, %invoke.cont48.lr.ph ], [ %add, %invoke.cont48 ] + %storemerge104 = phi i64 [ %add, %invoke.cont48 ], [ 0, %call5.i.i.i.i2.i.i.noexc42 ] %add.ptr.i = getelementptr inbounds nuw double, ptr %4, i64 %storemerge104 %29 = load double, ptr %add.ptr.i, align 8, !tbaa !17 %add.ptr.i44 = getelementptr inbounds nuw double, ptr %call5.i.i.i.i2.i.i34, i64 %storemerge104 @@ -437,7 +426,7 @@ _ZN8QuantLib20EvolutionDescriptionD2Ev.exit: ; preds = %_ZNSt6vectorIdSaIdE br i1 %tobool.not.i.i.i, label %_ZNSt6vectorISt4pairImmESaIS1_EED2Ev.exit, label %if.then.i.i.i if.then.i.i.i: ; preds = %_ZN8QuantLib20EvolutionDescriptionD2Ev.exit - %41 = load ptr, ptr %26, align 8, !tbaa !21 + %41 = load ptr, ptr %24, align 8, !tbaa !21 %sub.ptr.lhs.cast.i.i = ptrtoint ptr %41 to i64 %sub.ptr.rhs.cast.i.i = ptrtoint ptr %40 to i64 %sub.ptr.sub.i.i = sub i64 %sub.ptr.lhs.cast.i.i, %sub.ptr.rhs.cast.i.i @@ -451,10 +440,9 @@ _ZNSt6vectorISt4pairImmESaIS1_EED2Ev.exit: ; preds = %_ZN8QuantLib20Evolu br i1 %tobool.not.i.i.i48, label %_ZNSt6vectorIdSaIdEED2Ev.exit, label %if.then.i.i.i49 if.then.i.i.i49: ; preds = %_ZNSt6vectorISt4pairImmESaIS1_EED2Ev.exit - %_M_end_of_storage.i.i50 = getelementptr inbounds nuw i8, ptr %evolutionTimes, i64 16 - %43 = load ptr, ptr %_M_end_of_storage.i.i50, align 8, !tbaa !11 - %sub.ptr.lhs.cast.i.i51 = ptrtoint ptr %43 to i64 - %sub.ptr.rhs.cast.i.i52 = ptrtoint ptr %42 to i64 + %41 = load ptr, ptr %_M_end_of_storage.i.i.i, align 8, !tbaa !11 + %sub.ptr.lhs.cast.i.i51 = ptrtoint ptr %41 to i64 + %sub.ptr.lhs.cast.i.i51 = ptrtoint ptr %40 to i64 %sub.ptr.sub.i.i53 = sub i64 %sub.ptr.lhs.cast.i.i51, %sub.ptr.rhs.cast.i.i52 call void @_ZdlPvm(ptr noundef nonnull %42, i64 noundef %sub.ptr.sub.i.i53) #19 br label %_ZNSt6vectorIdSaIdEED2Ev.exit @@ -472,7 +460,7 @@ lpad57: ; preds = %for.cond.cleanup br i1 %tobool.not.i.i.i54, label %ehcleanup63, label %if.then.i.i.i55 if.then.i.i.i55: ; preds = %lpad57 - %46 = load ptr, ptr %26, align 8, !tbaa !21 + %46 = load ptr, ptr %24, align 8, !tbaa !21 %sub.ptr.lhs.cast.i.i57 = ptrtoint ptr %46 to i64 %sub.ptr.rhs.cast.i.i58 = ptrtoint ptr %45 to i64 %sub.ptr.sub.i.i59 = sub i64 %sub.ptr.lhs.cast.i.i57, %sub.ptr.rhs.cast.i.i58 @@ -487,10 +475,9 @@ ehcleanup63: ; preds = %if.then.i.i.i55, %l br i1 %tobool.not.i.i.i61, label %ehcleanup65, label %if.then.i.i.i62 if.then.i.i.i62: ; preds = %ehcleanup63 - %_M_end_of_storage.i.i63 = getelementptr inbounds nuw i8, ptr %evolutionTimes, i64 16 - %48 = load ptr, ptr %_M_end_of_storage.i.i63, align 8, !tbaa !11 - %sub.ptr.lhs.cast.i.i64 = ptrtoint ptr %48 to i64 - %sub.ptr.rhs.cast.i.i65 = ptrtoint ptr %47 to i64 + %46 = load ptr, ptr %_M_end_of_storage.i.i.i, align 8, !tbaa !11 + %sub.ptr.lhs.cast.i.i64 = ptrtoint ptr %46 to i64 + %sub.ptr.lhs.cast.i.i64 = ptrtoint ptr %45 to i64 %sub.ptr.sub.i.i66 = sub i64 %sub.ptr.lhs.cast.i.i64, %sub.ptr.rhs.cast.i.i65 call void @_ZdlPvm(ptr noundef nonnull %47, i64 noundef %sub.ptr.sub.i.i66) #19 br label %ehcleanup65 diff --git a/bench/quinn-rs/optimized/em94uyxz0wp9gccfab963606p.ll b/bench/quinn-rs/optimized/em94uyxz0wp9gccfab963606p.ll index 56664d1a1e0..345ba9b78df 100644 --- a/bench/quinn-rs/optimized/em94uyxz0wp9gccfab963606p.ll +++ b/bench/quinn-rs/optimized/em94uyxz0wp9gccfab963606p.ll @@ -4631,10 +4631,9 @@ define noundef zeroext i1 @_ZN11quinn_proto9range_set15array_range_set13ArrayRan ; Function Attrs: nonlazybind uwtable define void @_ZN11quinn_proto9range_set15array_range_set13ArrayRangeSet7pop_min17ha01941baa046b015E(ptr dead_on_unwind noalias noundef writable writeonly sret([24 x i8]) align 8 captures(none) dereferenceable(24) %0, ptr noalias noundef align 8 dereferenceable(48) %1) unnamed_addr #1 personality ptr @rust_eh_personality { - %3 = alloca [16 x i8], align 8 - %4 = load i64, ptr %1, align 8, !range !13, !noundef !3 - %5 = trunc nuw i64 %4 to i1 - br i1 %5, label %6, label %.thread + %3 = load i64, ptr %1, align 8, !range !13, !noundef !3 + %4 = trunc nuw i64 %3 to i1 + br i1 %4, label %5, label %.thread 6: ; preds = %2 %7 = getelementptr inbounds nuw i8, ptr %1, i64 24 @@ -4651,7 +4650,7 @@ define void @_ZN11quinn_proto9range_set15array_range_set13ArrayRangeSet7pop_min1 br i1 %13, label %14, label %.thread5 14: ; preds = %.thread, %6, %32 - %storemerge = phi i64 [ 1, %32 ], [ 0, %6 ], [ 0, %.thread ] + %storemerge = phi i64 [ 1, %28 ], [ 0, %5 ], [ 0, %.thread ] store i64 %storemerge, ptr %0, align 8 ret void @@ -4663,45 +4662,37 @@ define void @_ZN11quinn_proto9range_set15array_range_set13ArrayRangeSet7pop_min1 .thread5: ; preds = %.thread tail call void @llvm.experimental.noalias.scope.decl(metadata !627) %18 = getelementptr inbounds nuw i8, ptr %1, i64 16 - %19 = zext i16 %12 to i64 - %20 = icmp ugt i16 %12, 2 - br i1 %20, label %21, label %"_ZN106_$LT$core..ops..range..Range$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h8ecf2f929a490e68E.exit.i", !prof !17 + %18 = icmp ugt i16 %12, 2 + br i1 %18, label %19, label %"_ZN106_$LT$core..ops..range..Range$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h8ecf2f929a490e68E.exit.i", !prof !17 21: ; preds = %.thread5 - tail call void @_ZN4core5slice5index24slice_end_index_len_fail17h295f890f9c88ef86E(i64 noundef %19, i64 noundef 2, ptr noalias noundef nonnull readonly align 8 dereferenceable(24) @anon.dc71d0a5682d3db708e0e7797e95149f.101) #22, !noalias !630 + %20 = zext i16 %11 to i64 + tail call void @_ZN4core5slice5index24slice_end_index_len_fail17h295f890f9c88ef86E(i64 noundef %20, i64 noundef 2, ptr noalias noundef nonnull readonly align 8 dereferenceable(24) @anon.dc71d0a5682d3db708e0e7797e95149f.101) #22, !noalias !630 unreachable "_ZN106_$LT$core..ops..range..Range$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h8ecf2f929a490e68E.exit.i": ; preds = %.thread5 %22 = load i64, ptr %18, align 8, !alias.scope !627, !noundef !3 %23 = getelementptr inbounds nuw i8, ptr %1, i64 24 %24 = load i64, ptr %23, align 8, !alias.scope !627, !noundef !3 - %25 = add nsw i64 %19, -1 - %.not11.i = icmp eq i64 %25, 0 - tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %18, i8 0, i64 16, i1 false), !alias.scope !627 - br i1 %.not11.i, label %"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit", label %.lr.ph.i.preheader - -.lr.ph.i.preheader: ; preds = %"_ZN106_$LT$core..ops..range..Range$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h8ecf2f929a490e68E.exit.i", %.lr.ph.i.preheader - %.sroa.01.010.i = phi i64 [ %26, %.lr.ph.i.preheader ], [ 0, %"_ZN106_$LT$core..ops..range..Range$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h8ecf2f929a490e68E.exit.i" ] - %26 = add nuw nsw i64 %.sroa.01.010.i, 1 - %27 = getelementptr inbounds nuw { i64, i64 }, ptr %18, i64 %.sroa.01.010.i - %28 = getelementptr inbounds nuw { i64, i64 }, ptr %18, i64 %26 - call void @llvm.lifetime.start.p0(ptr nonnull %3) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %3, ptr noundef nonnull align 8 dereferenceable(16) %27, i64 16, i1 false) - tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %27, ptr noundef nonnull align 8 dereferenceable(16) %28, i64 16, i1 false), !alias.scope !627 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %28, ptr noundef nonnull align 8 dereferenceable(16) %3, i64 16, i1 false) - call void @llvm.lifetime.end.p0(ptr nonnull %3) - %exitcond13.not.i = icmp eq i64 %26, %25 - br i1 %exitcond13.not.i, label %"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit", label %.lr.ph.i.preheader - -"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit": ; preds = %.lr.ph.i.preheader, %"_ZN106_$LT$core..ops..range..Range$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h8ecf2f929a490e68E.exit.i" - %29 = add nsw i16 %12, -1 - store i16 %29, ptr %11, align 8, !alias.scope !627 - %30 = insertvalue { i64, i64 } poison, i64 %22, 0 - %31 = insertvalue { i64, i64 } %30, i64 %24, 1 - br label %32 + %.not11.i = icmp eq i16 %11, 1 + tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %17, i8 0, i64 16, i1 false), !alias.scope !627 + br i1 %.not11.i, label %"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit", label %.lr.ph.i + +.lr.ph.i: ; preds = %"_ZN106_$LT$core..ops..range..Range$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h8ecf2f929a490e68E.exit.i" + %24 = getelementptr inbounds nuw i8, ptr %1, i64 32 + tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %17, ptr noundef nonnull align 8 dereferenceable(16) %24, i64 16, i1 false), !alias.scope !627 + tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %24, i8 0, i64 16, i1 false) + br label %"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit" + +"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit":; preds = %.lr.ph.i, %"_ZN106_$LT$core..ops..range..Range$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h8ecf2f929a490e68E.exit.i" + %25 = add nsw i16 %11, -1 + store i16 %25, ptr %10, align 8, !alias.scope !627 + %26 = insertvalue { i64, i64 } poison, i64 %21, 0 + %27 = insertvalue { i64, i64 } %26, i64 %23, 1 + br label %28 32: ; preds = %"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit", %15 - %.pn = phi { i64, i64 } [ %17, %15 ], [ %31, %"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit" ] + %.pn = phi { i64, i64 } [ %17, %14 ], [ %27, %"_ZN7tinyvec8arrayvec17ArrayVec$LT$A$GT$6remove17h42c06d89c20f132cE.exit" ] %.sroa.0.0 = extractvalue { i64, i64 } %.pn, 0 %.sroa.5.0 = extractvalue { i64, i64 } %.pn, 1 %33 = getelementptr inbounds nuw i8, ptr %0, i64 8 diff --git a/bench/rocksdb/optimized/experimental.ll b/bench/rocksdb/optimized/experimental.ll index 81434b08fbe..5f3a0032d10 100644 --- a/bench/rocksdb/optimized/experimental.ll +++ b/bench/rocksdb/optimized/experimental.ll @@ -20320,7 +20320,7 @@ define internal fastcc void @_ZN7rocksdb12experimental12_GLOBAL__N_114GetFilterI %.sroa.019.0.extract.trunc = trunc i32 %0 to i16 %.sroa.2.0.extract.shift = lshr i32 %0, 16 %.sroa.2.0.extract.trunc = trunc i32 %.sroa.2.0.extract.shift to i8 - switch i8 %.sroa.2.0.extract.trunc, label %54 [ + switch i8 %.sroa.2.0.extract.trunc, label %53 [ i8 0, label %6 i8 1, label %8 i8 2, label %31 @@ -20364,19 +20364,17 @@ define internal fastcc void @_ZN7rocksdb12experimental12_GLOBAL__N_114GetFilterI 22: ; preds = %16, %15 %23 = phi i64 [ %21, %16 ], [ 0, %15 ] - %24 = add nsw i64 %13, -1 - %.sroa.speculated.i.i.i.i.i.i = tail call i64 @llvm.umin.i64(i64 %24, i64 %14) - %25 = getelementptr inbounds nuw i32, ptr %.val17.val.i.i, i64 %.sroa.speculated.i.i.i.i.i.i - %26 = load i32, ptr %25, align 4, !tbaa !102 - %27 = zext i32 %26 to i64 - %28 = load ptr, ptr %1, align 8, !tbaa !17 - %29 = getelementptr inbounds nuw i8, ptr %28, i64 %23 - %30 = sub nsw i64 %27, %23 + %24 = getelementptr inbounds nuw i32, ptr %.val17.val.i.i, i64 %14 + %25 = load i32, ptr %24, align 4, !tbaa !102 + %26 = zext i32 %25 to i64 + %26 = load ptr, ptr %1, align 8, !tbaa !17 + %28 = getelementptr inbounds nuw i8, ptr %26, i64 %23 + %29 = sub nsw i64 %26, %23 br label %_ZNSt8__detail9__variant17__gen_vtable_implINS0_12_Multi_arrayIPFNS0_21__deduce_visit_resultIN7rocksdb5SliceEEEOZNS4_12experimental12_GLOBAL__N_114GetFilterInputESt7variantIJNS7_14SelectWholeKeyENS7_16SelectKeySegmentENS7_21SelectKeySegmentRangeENS7_21SelectLegacyKeyPrefixENS7_19SelectUserTimestampENS7_16SelectColumnNameEEERKS5_RKNS7_20KeySegmentsExtractor6ResultEPS5_SN_E17FilterInputGetterRSG_EJEEESt16integer_sequenceImJLm1EEEE14__visit_invokeESP_SQ_.exit.i.i _ZNSt8__detail9__variant17__gen_vtable_implINS0_12_Multi_arrayIPFNS0_21__deduce_visit_resultIN7rocksdb5SliceEEEOZNS4_12experimental12_GLOBAL__N_114GetFilterInputESt7variantIJNS7_14SelectWholeKeyENS7_16SelectKeySegmentENS7_21SelectKeySegmentRangeENS7_21SelectLegacyKeyPrefixENS7_19SelectUserTimestampENS7_16SelectColumnNameEEERKS5_RKNS7_20KeySegmentsExtractor6ResultEPS5_SN_E17FilterInputGetterRSG_EJEEESt16integer_sequenceImJLm1EEEE14__visit_invokeESP_SQ_.exit.i.i: ; preds = %22, %8 - %.sroa.0.0.i.i.i.i.i.i = phi ptr [ %29, %22 ], [ @.str, %8 ] - %.sroa.3.0.i.i.i.i.i.i = phi i64 [ %30, %22 ], [ 0, %8 ] + %.sroa.0.0.i.i.i.i.i.i = phi ptr [ %28, %22 ], [ @.str, %8 ] + %.sroa.3.0.i.i.i.i.i.i = phi i64 [ %29, %22 ], [ 0, %8 ] %.fca.0.insert.i.i.i.i24.i.i = insertvalue { ptr, i64 } poison, ptr %.sroa.0.0.i.i.i.i.i.i, 0 %.fca.1.insert.i.i.i.i25.i.i = insertvalue { ptr, i64 } %.fca.0.insert.i.i.i.i24.i.i, i64 %.sroa.3.0.i.i.i.i.i.i, 1 br label %_ZSt5visitIZN7rocksdb12experimental12_GLOBAL__N_114GetFilterInputESt7variantIJNS1_14SelectWholeKeyENS1_16SelectKeySegmentENS1_21SelectKeySegmentRangeENS1_21SelectLegacyKeyPrefixENS1_19SelectUserTimestampENS1_16SelectColumnNameEEERKNS0_5SliceERKNS1_20KeySegmentsExtractor6ResultEPSB_SI_E17FilterInputGetterJRSA_EENSt13invoke_resultIT_JDpNSt13__conditionalIX21is_lvalue_reference_vIT0_EEE4typeIRNSt19variant_alternativeILm0ENSt16remove_referenceIDTclsr9__variantE4__asclsr3stdE7declvalISO_EEEEE4typeEE4typeEOSX_EEEE4typeEOSM_DpOSO_.exit @@ -20398,31 +20396,31 @@ _ZNSt8__detail9__variant17__gen_vtable_implINS0_12_Multi_arrayIPFNS0_21__deduce_ 38: ; preds = %31 %.not8.i.i.i.i.i.i = icmp eq i16 %.sroa.0.0.extract.trunc.mask.i.i.i.i.i.i, 0 - br i1 %.not8.i.i.i.i.i.i, label %45, label %39 - -39: ; preds = %38 - %40 = add nuw nsw i64 %37, 4294967295 - %41 = and i64 %40, 4294967295 - %42 = getelementptr inbounds nuw i32, ptr %.val21.val.i.i, i64 %41 - %43 = load i32, ptr %42, align 4, !tbaa !102 - %44 = zext i32 %43 to i64 - br label %45 + br i1 %.not8.i.i.i.i.i.i, label %44, label %38 + +45: ; preds = %38 + %39 = add nuw nsw i64 %36, 4294967295 + %40 = and i64 %39, 4294967295 + %41 = getelementptr inbounds nuw i32, ptr %.val21.val.i.i, i64 %40 + %42 = load i32, ptr %41, align 4, !tbaa !102 + %43 = zext i32 %42 to i64 + br label %44 -45: ; preds = %39, %38 - %46 = phi i64 [ %44, %39 ], [ 0, %38 ] - %47 = add nsw i64 %36, -1 - %.sroa.speculated.i.i.i.i31.i.i = tail call i64 @llvm.umin.i64(i64 %47, i64 %.sroa.4.0.extract.trunc.i.i.i.i.i.i) - %48 = getelementptr inbounds nuw i32, ptr %.val21.val.i.i, i64 %.sroa.speculated.i.i.i.i31.i.i - %49 = load i32, ptr %48, align 4, !tbaa !102 - %50 = zext i32 %49 to i64 - %51 = load ptr, ptr %1, align 8, !tbaa !17 - %52 = getelementptr inbounds nuw i8, ptr %51, i64 %46 - %53 = sub nsw i64 %50, %46 +44: ; preds = %38, %37 + %45 = phi i64 [ %43, %38 ], [ 0, %37 ] + %46 = add nsw i64 %35, -1 + %.sroa.speculated.i.i.i.i.i.i = tail call i64 @llvm.umin.i64(i64 %46, i64 %.sroa.4.0.extract.trunc.i.i.i.i.i.i) + %47 = getelementptr inbounds nuw i32, ptr %.val21.val.i.i, i64 %.sroa.speculated.i.i.i.i.i.i + %48 = load i32, ptr %47, align 4, !tbaa !102 + %49 = zext i32 %48 to i64 + %50 = load ptr, ptr %1, align 8, !tbaa !17 + %51 = getelementptr inbounds nuw i8, ptr %50, i64 %45 + %52 = sub nsw i64 %49, %45 br label %_ZNSt8__detail9__variant17__gen_vtable_implINS0_12_Multi_arrayIPFNS0_21__deduce_visit_resultIN7rocksdb5SliceEEEOZNS4_12experimental12_GLOBAL__N_114GetFilterInputESt7variantIJNS7_14SelectWholeKeyENS7_16SelectKeySegmentENS7_21SelectKeySegmentRangeENS7_21SelectLegacyKeyPrefixENS7_19SelectUserTimestampENS7_16SelectColumnNameEEERKS5_RKNS7_20KeySegmentsExtractor6ResultEPS5_SN_E17FilterInputGetterRSG_EJEEESt16integer_sequenceImJLm2EEEE14__visit_invokeESP_SQ_.exit.i.i -_ZNSt8__detail9__variant17__gen_vtable_implINS0_12_Multi_arrayIPFNS0_21__deduce_visit_resultIN7rocksdb5SliceEEEOZNS4_12experimental12_GLOBAL__N_114GetFilterInputESt7variantIJNS7_14SelectWholeKeyENS7_16SelectKeySegmentENS7_21SelectKeySegmentRangeENS7_21SelectLegacyKeyPrefixENS7_19SelectUserTimestampENS7_16SelectColumnNameEEERKS5_RKNS7_20KeySegmentsExtractor6ResultEPS5_SN_E17FilterInputGetterRSG_EJEEESt16integer_sequenceImJLm2EEEE14__visit_invokeESP_SQ_.exit.i.i: ; preds = %45, %31 - %.sroa.0.0.i.i.i.i27.i.i = phi ptr [ %52, %45 ], [ @.str, %31 ] - %.sroa.3.0.i.i.i.i28.i.i = phi i64 [ %53, %45 ], [ 0, %31 ] +_ZNSt8__detail9__variant17__gen_vtable_implINS0_12_Multi_arrayIPFNS0_21__deduce_visit_resultIN7rocksdb5SliceEEEOZNS4_12experimental12_GLOBAL__N_114GetFilterInputESt7variantIJNS7_14SelectWholeKeyENS7_16SelectKeySegmentENS7_21SelectKeySegmentRangeENS7_21SelectLegacyKeyPrefixENS7_19SelectUserTimestampENS7_16SelectColumnNameEEERKS5_RKNS7_20KeySegmentsExtractor6ResultEPS5_SN_E17FilterInputGetterRSG_EJEEESt16integer_sequenceImJLm2EEEE14__visit_invokeESP_SQ_.exit.i.i: ; preds = %44, %31 + %.sroa.0.0.i.i.i.i27.i.i = phi ptr [ %51, %44 ], [ @.str, %30 ] + %.sroa.3.0.i.i.i.i28.i.i = phi i64 [ %52, %44 ], [ 0, %30 ] %.fca.0.insert.i.i.i.i29.i.i = insertvalue { ptr, i64 } poison, ptr %.sroa.0.0.i.i.i.i27.i.i, 0 %.fca.1.insert.i.i.i.i30.i.i = insertvalue { ptr, i64 } %.fca.0.insert.i.i.i.i29.i.i, i64 %.sroa.3.0.i.i.i.i28.i.i, 1 br label %_ZSt5visitIZN7rocksdb12experimental12_GLOBAL__N_114GetFilterInputESt7variantIJNS1_14SelectWholeKeyENS1_16SelectKeySegmentENS1_21SelectKeySegmentRangeENS1_21SelectLegacyKeyPrefixENS1_19SelectUserTimestampENS1_16SelectColumnNameEEERKNS0_5SliceERKNS1_20KeySegmentsExtractor6ResultEPSB_SI_E17FilterInputGetterJRSA_EENSt13invoke_resultIT_JDpNSt13__conditionalIX21is_lvalue_reference_vIT0_EEE4typeIRNSt19variant_alternativeILm0ENSt16remove_referenceIDTclsr9__variantE4__asclsr3stdE7declvalISO_EEEEE4typeEE4typeEOSX_EEEE4typeEOSM_DpOSO_.exit diff --git a/bench/ruff-rs/optimized/272al911l1jdbqblbb9whzfue.ll b/bench/ruff-rs/optimized/272al911l1jdbqblbb9whzfue.ll index ba22e25b0d7..47e849e3fd0 100644 --- a/bench/ruff-rs/optimized/272al911l1jdbqblbb9whzfue.ll +++ b/bench/ruff-rs/optimized/272al911l1jdbqblbb9whzfue.ll @@ -1217,14 +1217,14 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. br label %23 23: ; preds = %.loopexit, %.loopexit60 - %.sroa.0.054 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit60 ], [ %.sroa.0.1, %.loopexit ] + %.sroa.0.054 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit59 ], [ %.sroa.0.1, %.loopexit ] invoke void @"_ZN137_$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$K$C$V$C$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hc110be6fc5591b5dE"(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %8, ptr noalias noundef nonnull align 8 dereferenceable(56) %9) to label %26 unwind label %24 .body: ; preds = %115, %155, %24 - %.pn = phi { ptr, i32 } [ %eh.lpad-body20.ph, %155 ], [ %25, %24 ], [ %116, %115 ] + %.pn = phi { ptr, i32 } [ %eh.lpad-body20.ph, %152 ], [ %25, %24 ], [ %116, %112 ] invoke void @"_ZN4core3ptr507drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$ruff_db..system..path..SystemPathBuf$C$alloc..collections..btree..set_val..SetValZST$C$core..iter..adapters..map..Map$LT$alloc..vec..into_iter..IntoIter$LT$ruff_db..system..path..SystemPathBuf$GT$$C$alloc..collections..btree..set..BTreeSet$LT$ruff_db..system..path..SystemPathBuf$GT$..from_sorted_iter$LT$alloc..vec..into_iter..IntoIter$LT$ruff_db..system..path..SystemPathBuf$GT$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$$GT$$GT$17hbd6ef4bdee85703cE"(ptr noalias noundef nonnull align 8 dereferenceable(56) %9) #16 - to label %158 unwind label %156 + to label %155 unwind label %156 24: ; preds = %23 %25 = landingpad { ptr, i32 } @@ -1312,25 +1312,16 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %60, ptr nonnull align 8 %59, i64 %61, i1 false), !alias.scope !221, !noalias !218 %62 = add nuw nsw i64 %57, 1 %63 = sub nuw nsw i64 %56, %62 - %64 = add nsw i64 %51, -1 - %65 = icmp eq i64 %63, %64 - br i1 %65, label %_ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i, label %.noexc16, !prof !4 - -.noexc16: ; preds = %55 - call void @_ZN4core9panicking5panic17h48a7e1f3665210c6E(ptr noalias noundef nonnull readonly align 1 @anon.84ebae23b1e24beb2c6053fa0be4ab9a.11, i64 noundef 40, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.84ebae23b1e24beb2c6053fa0be4ab9a.12) #15 - unreachable - -_ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; preds = %55 - %66 = getelementptr inbounds nuw i8, ptr %41, i64 8 - %67 = getelementptr inbounds nuw { [3 x i64] }, ptr %66, i64 %62 - %68 = mul nuw nsw i64 %63, 24 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %59, ptr nonnull readonly align 8 %67, i64 %68, i1 false), !alias.scope !224, !noalias !218 - %69 = getelementptr inbounds nuw { [3 x i64] }, ptr %66, i64 %57 - %70 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 8 - %71 = getelementptr inbounds nuw { [3 x i64] }, ptr %70, i64 %38 + %63 = getelementptr inbounds nuw i8, ptr %41, i64 8 + %64 = getelementptr inbounds nuw { [3 x i64] }, ptr %63, i64 %61 + %65 = mul nuw nsw i64 %62, 24 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %58, ptr nonnull readonly align 8 %64, i64 %65, i1 false), !alias.scope !224, !noalias !218 + %66 = getelementptr inbounds nuw { [3 x i64] }, ptr %63, i64 %56 + %67 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 8 + %68 = getelementptr inbounds nuw { [3 x i64] }, ptr %67, i64 %38 call void @llvm.lifetime.start.p0(ptr nonnull %5) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %71, i64 24, i1 false), !noalias !218 - call void @llvm.memmove.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %71, ptr noundef nonnull align 8 dereferenceable(24) %69, i64 24, i1 false), !noalias !218 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %68, i64 24, i1 false), !noalias !218 + call void @llvm.memmove.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %68, ptr noundef nonnull align 8 dereferenceable(24) %66, i64 24, i1 false), !noalias !218 %72 = getelementptr inbounds nuw { [3 x i64] }, ptr %59, i64 %63 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %72, ptr noundef nonnull align 8 dereferenceable(24) %5, i64 24, i1 false), !noalias !218 call void @llvm.lifetime.end.p0(ptr nonnull %5) @@ -1350,7 +1341,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; br label %81 81: ; preds = %81, %73 - %.sroa.0.06.i.i.i = phi i64 [ 0, %73 ], [ %82, %81 ] + %.sroa.0.06.i.i.i = phi i64 [ 0, %70 ], [ %82, %78 ] %82 = add nuw nsw i64 %.sroa.0.06.i.i.i, 1 %83 = getelementptr inbounds nuw ptr, ptr %74, i64 %.sroa.0.06.i.i.i %84 = load ptr, ptr %83, align 8, !noalias !235, !nonnull !3, !noundef !3 @@ -1365,8 +1356,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; ret void .preheader: ; preds = %28, %90 - %.sroa.5.0 = phi i64 [ %91, %90 ], [ 0, %28 ] - %.sroa.0.0 = phi ptr [ %87, %90 ], [ %.sroa.0.054, %28 ] + %.sroa.5.0 = phi i64 [ %91, %87 ], [ 0, %28 ] + %.sroa.0.0 = phi ptr [ %87, %87 ], [ %.sroa.0.054, %28 ] %87 = load ptr, ptr %.sroa.0.0, align 8, !noalias !241, !noundef !3 %.not.i17 = icmp eq ptr %87, null br i1 %.not.i17, label %95, label %90 @@ -1388,13 +1379,13 @@ _ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; %96 = load ptr, ptr %0, align 8, !alias.scope !244, !nonnull !3, !noundef !3 %97 = load i64, ptr %10, align 8, !alias.scope !244, !noundef !3 %98 = invoke noundef nonnull align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$13new_uninit_in17hf3b18689352489abE"() - to label %103 unwind label %99, !noalias !244 + to label %100 unwind label %99, !noalias !244 99: ; preds = %95 %100 = landingpad { ptr, i32 } cleanup invoke void @"_ZN4core3ptr72drop_in_place$LT$alloc..collections..btree..mem..replace..PanicGuard$GT$17h12e693559be0c4e2E"(ptr noalias noundef nonnull align 1 %4) #16 - to label %155 unwind label %101, !noalias !244 + to label %152 unwind label %101, !noalias !244 101: ; preds = %99 %102 = landingpad { ptr, i32 } @@ -1417,11 +1408,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; br label %.loopexit59 .loopexit59: ; preds = %90, %103 - %.sroa.038.0 = phi ptr [ %98, %103 ], [ %87, %90 ] - %.sroa.639.0 = phi i64 [ %106, %103 ], [ %91, %90 ] + %.sroa.038.0 = phi ptr [ %98, %100 ], [ %87, %87 ] + %.sroa.639.0 = phi i64 [ %106, %100 ], [ %91, %87 ] %108 = add i64 %.sroa.639.0, -1 %109 = invoke noundef nonnull align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$13new_uninit_in17h7a7abaf50dd999a9E"() - to label %110 unwind label %88 + to label %107 unwind label %88 110: ; preds = %.loopexit59 store ptr null, ptr %109, align 8 @@ -1438,7 +1429,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; unreachable .loopexit86: ; preds = %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit33, %110 - %.sroa.044.0.lcssa = phi ptr [ %109, %110 ], [ %141, %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit33 ] + %.sroa.044.0.lcssa = phi ptr [ %109, %107 ], [ %141, %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit32 ] call void @llvm.lifetime.start.p0(ptr nonnull %6) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(24) %8, i64 24, i1 false) %112 = getelementptr inbounds nuw i8, ptr %.sroa.038.0, i64 274 @@ -1478,8 +1469,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; br i1 %129, label %.loopexit, label %.lr.ph.i25 .lr.ph.i25: ; preds = %119, %.lr.ph.i25 - %.sroa.03.06.i26 = phi i64 [ %137, %.lr.ph.i25 ], [ %.sroa.639.0, %119 ] - %.sroa.04.05.i27 = phi ptr [ %136, %.lr.ph.i25 ], [ %.sroa.038.0, %119 ] + %.sroa.03.06.i26 = phi i64 [ %137, %.lr.ph.i24 ], [ %.sroa.639.0, %116 ] + %.sroa.04.05.i27 = phi ptr [ %136, %.lr.ph.i24 ], [ %.sroa.038.0, %116 ] %130 = getelementptr inbounds nuw i8, ptr %.sroa.04.05.i27, i64 274 %131 = load i16, ptr %130, align 2, !noalias !261, !noundef !3 %132 = zext nneg i16 %131 to i64 @@ -1493,7 +1484,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; br i1 %138, label %.loopexit, label %.lr.ph.i25 .loopexit: ; preds = %.lr.ph.i25, %119, %150 - %.sroa.0.1 = phi ptr [ %.sroa.0.054, %150 ], [ %.sroa.038.0, %119 ], [ %136, %.lr.ph.i25 ] + %.sroa.0.1 = phi ptr [ %.sroa.0.054, %147 ], [ %.sroa.038.0, %116 ], [ %136, %.lr.ph.i24 ] %139 = load i64, ptr %2, align 8, !noundef !3 %140 = add i64 %139, 1 store i64 %140, ptr %2, align 8 @@ -1501,16 +1492,16 @@ _ZN5alloc11collections5btree4node13move_to_slice17h6ae8f93f482c2816E.exit.i.i: ; br label %23 .lr.ph: ; preds = %110, %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit33 - %.sroa.02.068 = phi i64 [ %146, %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit33 ], [ 0, %110 ] - %.sroa.044.066 = phi ptr [ %141, %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit33 ], [ %109, %110 ] + %.sroa.02.068 = phi i64 [ %146, %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit32 ], [ 0, %107 ] + %.sroa.044.066 = phi ptr [ %141, %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit32 ], [ %109, %107 ] %141 = invoke noundef nonnull align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$13new_uninit_in17hf3b18689352489abE"() - to label %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit33 unwind label %142, !noalias !267 + to label %_ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit32 unwind label %142, !noalias !267 142: ; preds = %.lr.ph %143 = landingpad { ptr, i32 } cleanup invoke void @"_ZN4core3ptr72drop_in_place$LT$alloc..collections..btree..mem..replace..PanicGuard$GT$17h12e693559be0c4e2E"(ptr noalias noundef nonnull align 1 %4) #16 - to label %155 unwind label %144, !noalias !267 + to label %152 unwind label %144, !noalias !267 144: ; preds = %142 %145 = landingpad { ptr, i32 } @@ -1541,7 +1532,7 @@ _ZN5alloc11collections5btree3mem7replace17h1284baf35d371addE.exit33: ; preds = % br label %.loopexit 155: ; preds = %88, %99, %142 - %eh.lpad-body20.ph = phi { ptr, i32 } [ %89, %88 ], [ %100, %99 ], [ %143, %142 ] + %eh.lpad-body20.ph = phi { ptr, i32 } [ %89, %85 ], [ %100, %96 ], [ %143, %139 ] invoke void @"_ZN4core3ptr57drop_in_place$LT$ruff_db..system..path..SystemPathBuf$GT$17h9ca0984b95b1da15E"(ptr noalias noundef nonnull align 8 dereferenceable(24) %7) #16 to label %.body unwind label %156 diff --git a/bench/ruff-rs/optimized/4a0sesc153a050u04do7llz00.ll b/bench/ruff-rs/optimized/4a0sesc153a050u04do7llz00.ll index 382b38b265c..aae5f1770ff 100644 --- a/bench/ruff-rs/optimized/4a0sesc153a050u04do7llz00.ll +++ b/bench/ruff-rs/optimized/4a0sesc153a050u04do7llz00.ll @@ -55074,32 +55074,32 @@ define internal fastcc void @_ZN11ruff_linter5rules26flake8_implicit_str_concat5 store ptr %17, ptr %22, align 8 %23 = call noundef zeroext i1 @_ZN11ruff_linter5rules26flake8_implicit_str_concat5rules8implicit31has_odd_consecutive_backslashes17h36561b1299747590E(ptr noalias noundef nonnull align 8 dereferenceable(16) %14) call void @llvm.lifetime.end.p0(ptr nonnull %14) - br i1 %23, label %24, label %"_ZN106_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..double_ended..DoubleEndedIterator$GT$9next_back17hb6395a744f824a91E.exit77" + br i1 %23, label %28, label %"_ZN106_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..double_ended..DoubleEndedIterator$GT$9next_back17hb6395a744f824a91E.exit77" 24: ; preds = %21 - call void @llvm.lifetime.start.p0(ptr nonnull %13) - %25 = add i64 %.sroa.2.0, -2 - %26 = icmp eq i64 %25, 0 - br i1 %26, label %59, label %27 + %24 = getelementptr i8, ptr %16, i64 -2 + %25 = load i8, ptr %24, align 1, !noundef !3 + %26 = and i8 %25, -8 + %27 = icmp eq i8 %26, 48 + br i1 %27, label %35, label %"_ZN106_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..double_ended..DoubleEndedIterator$GT$9next_back17hb6395a744f824a91E.exit.thread106" -27: ; preds = %24 - %28 = getelementptr inbounds nuw i8, ptr %.sroa.019.0, i64 %25 - %29 = load i8, ptr %28, align 1, !alias.scope !6623, !noundef !3 - %30 = icmp sgt i8 %29, -65 - br i1 %30, label %59, label %66 +27: ; preds = %21 + call void @llvm.lifetime.start.p0(ptr nonnull %13) + %29 = add i64 %.sroa.2.0, -2 + %30 = icmp eq i64 %29, 0 + br i1 %30, label %59, label %31 -"_ZN106_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..double_ended..DoubleEndedIterator$GT$9next_back17hb6395a744f824a91E.exit77": ; preds = %21 - %31 = getelementptr i8, ptr %16, i64 -2 - %32 = load i8, ptr %31, align 1, !noundef !3 - %33 = and i8 %32, -8 - %34 = icmp eq i8 %33, 48 - br i1 %34, label %35, label %"_ZN106_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..double_ended..DoubleEndedIterator$GT$9next_back17hb6395a744f824a91E.exit.thread106" +"_ZN106_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..double_ended..DoubleEndedIterator$GT$9next_back17hb6395a744f824a91E.exit77": ; preds = %28 + %31 = getelementptr inbounds nuw i8, ptr %.sroa.019.0, i64 %29 + %32 = load i8, ptr %31, align 1, !alias.scope !6623, !noundef !3 + %34 = icmp sgt i8 %32, -65 + br i1 %34, label %59, label %66 35: ; preds = %"_ZN106_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..double_ended..DoubleEndedIterator$GT$9next_back17hb6395a744f824a91E.exit77" call void @llvm.lifetime.start.p0(ptr nonnull %9) store ptr %.sroa.019.0, ptr %9, align 8 %36 = getelementptr inbounds nuw i8, ptr %9, i64 8 - store ptr %31, ptr %36, align 8 + store ptr %24, ptr %36, align 8 %37 = call noundef zeroext i1 @_ZN11ruff_linter5rules26flake8_implicit_str_concat5rules8implicit31has_odd_consecutive_backslashes17h36561b1299747590E(ptr noalias noundef nonnull align 8 dereferenceable(16) %9) call void @llvm.lifetime.end.p0(ptr nonnull %9) br i1 %37, label %38, label %"_ZN106_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..double_ended..DoubleEndedIterator$GT$9next_back17hb6395a744f824a91E.exit.thread106" @@ -55129,7 +55129,7 @@ define internal fastcc void @_ZN11ruff_linter5rules26flake8_implicit_str_concat5 call void @llvm.lifetime.start.p0(ptr nonnull %7) call void @llvm.lifetime.start.p0(ptr nonnull %6) call void @llvm.lifetime.start.p0(ptr nonnull %5) - %48 = zext nneg i8 %32 to i32 + %48 = zext nneg i8 %25 to i32 store i32 %48, ptr %5, align 4 call void @llvm.lifetime.start.p0(ptr nonnull %4) %49 = zext nneg i8 %18 to i32 @@ -55189,10 +55189,10 @@ define internal fastcc void @_ZN11ruff_linter5rules26flake8_implicit_str_concat5 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(24) %.sink, i64 24, i1 false) resume { ptr, i32 } %.pn -59: ; preds = %27, %24 +59: ; preds = %31, %28 store ptr %.sroa.019.0, ptr %13, align 8 %60 = getelementptr inbounds nuw i8, ptr %13, i64 8 - store i64 %25, ptr %60, align 8 + store i64 %29, ptr %60, align 8 call void @llvm.lifetime.start.p0(ptr nonnull %12) call void @llvm.lifetime.start.p0(ptr nonnull %11) call void @llvm.lifetime.start.p0(ptr nonnull %10) @@ -55227,8 +55227,8 @@ define internal fastcc void @_ZN11ruff_linter5rules26flake8_implicit_str_concat5 invoke void @"_ZN4core3ptr42drop_in_place$LT$alloc..string..String$GT$17hba79b7f9900aea78E"(ptr noalias noundef nonnull align 8 dereferenceable(24) %0) to label %"_ZN4core3ptr50drop_in_place$LT$alloc..borrow..Cow$LT$str$GT$$GT$17h2aa5d16e69a31c39E.exit83" unwind label %67 -66: ; preds = %27 - call void @_ZN4core3str16slice_error_fail17h9782f1ca63c1749dE(ptr noalias noundef nonnull readonly align 1 %.sroa.019.0, i64 noundef %.sroa.2.0, i64 noundef 0, i64 noundef %25, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.0de5ee8f4a9046f07397637c35d34c13.549) #30 +66: ; preds = %31 + call void @_ZN4core3str16slice_error_fail17h9782f1ca63c1749dE(ptr noalias noundef nonnull readonly align 1 %.sroa.019.0, i64 noundef %.sroa.2.0, i64 noundef 0, i64 noundef %29, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.0de5ee8f4a9046f07397637c35d34c13.549) #30 unreachable 67: ; preds = %65 diff --git a/bench/ruff-rs/optimized/5k764i8zv3uxwobi5mx2hjj5g.ll b/bench/ruff-rs/optimized/5k764i8zv3uxwobi5mx2hjj5g.ll index 22e05acd16d..18a53d3917e 100644 --- a/bench/ruff-rs/optimized/5k764i8zv3uxwobi5mx2hjj5g.ll +++ b/bench/ruff-rs/optimized/5k764i8zv3uxwobi5mx2hjj5g.ll @@ -346,7 +346,6 @@ target triple = "x86_64-unknown-linux-gnu" @anon.ab07cbd181e9ffbfcaa9350913085d13.393 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.ab07cbd181e9ffbfcaa9350913085d13.384, [16 x i8] c"\\\00\00\00\00\00\00\00\7F\01\00\00*\00\00\00" }>, align 8 @anon.ab07cbd181e9ffbfcaa9350913085d13.394 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.ab07cbd181e9ffbfcaa9350913085d13.384, [16 x i8] c"\\\00\00\00\00\00\00\00\96\01\00\00\17\00\00\00" }>, align 8 @anon.ab07cbd181e9ffbfcaa9350913085d13.395 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.ab07cbd181e9ffbfcaa9350913085d13.384, [16 x i8] c"\\\00\00\00\00\00\00\00\9E\01\00\00\16\00\00\00" }>, align 8 -@anon.ab07cbd181e9ffbfcaa9350913085d13.397 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.ab07cbd181e9ffbfcaa9350913085d13.384, [16 x i8] c"\\\00\00\00\00\00\00\00\A3\01\00\00+\00\00\00" }>, align 8 @anon.ab07cbd181e9ffbfcaa9350913085d13.398 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.ab07cbd181e9ffbfcaa9350913085d13.384, [16 x i8] c"\\\00\00\00\00\00\00\00\AA\01\00\00\19\00\00\00" }>, align 8 @anon.ab07cbd181e9ffbfcaa9350913085d13.400 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.ab07cbd181e9ffbfcaa9350913085d13.384, [16 x i8] c"\\\00\00\00\00\00\00\00\8F\00\00\00\18\00\00\00" }>, align 8 @anon.ab07cbd181e9ffbfcaa9350913085d13.401 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.ab07cbd181e9ffbfcaa9350913085d13.384, [16 x i8] c"\\\00\00\00\00\00\00\00\B2\00\00\00*\00\00\00" }>, align 8 @@ -7982,70 +7981,58 @@ define internal fastcc noundef range(i64 0, 9223372036854775807) i64 @"_ZN7match %.not18 = icmp eq i64 %1, 0 br i1 %.not18, label %._crit_edge, label %.lr.ph.preheader -.lr.ph.preheader: ; preds = %.split - %14 = add nsw i64 %1, -1 - %.first_iter = icmp ult i64 %14, %5 - br label %.lr.ph - -.lr.ph: ; preds = %.lr.ph.preheader, %35 - %.sroa.0.019 = phi i64 [ %15, %35 ], [ %1, %.lr.ph.preheader ] - %15 = add nsw i64 %.sroa.0.019, -1 - br i1 %.first_iter, label %16, label %21 +.lr.ph.preheader: ; preds = %.split, %32 + %.sroa.0.019 = phi i64 [ %14, %32 ], [ %1, %.split ] + %14 = add nsw i64 %.sroa.0.019, -1 + %15 = getelementptr inbounds nuw { { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { i32, [1 x i32] }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %14 + %16 = getelementptr inbounds nuw i8, ptr %15, i64 128 + %17 = load i32, ptr %16, align 8, !noundef !3 + %18 = icmp ult i32 %17, %13 + br i1 %18, label %32, label %._crit_edge -._crit_edge: ; preds = %35, %16, %.split - %.sroa.0.0.lcssa = phi i64 [ 0, %.split ], [ %.sroa.0.019, %16 ], [ 0, %35 ] +._crit_edge: ; preds = %35, %.lr.ph, %.split + %.sroa.0.0.lcssa = phi i64 [ 0, %.split ], [ %.sroa.0.019, %.lr.ph ], [ 0, %32 ] %.not14 = icmp eq i64 %.sroa.0.0.lcssa, %1 - br i1 %.not14, label %34, label %22 - -16: ; preds = %.lr.ph - %17 = getelementptr inbounds nuw { { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { i32, [1 x i32] }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %15 - %18 = getelementptr inbounds nuw i8, ptr %17, i64 128 - %19 = load i32, ptr %18, align 8, !noundef !3 - %20 = icmp ult i32 %19, %13 - br i1 %20, label %35, label %._crit_edge - -21: ; preds = %.lr.ph - tail call void @_ZN4core9panicking18panic_bounds_check17h1a9bf3d94de0fc80E(i64 noundef %15, i64 noundef %5, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.ab07cbd181e9ffbfcaa9350913085d13.397) #25 - unreachable - -22: ; preds = %._crit_edge - %23 = getelementptr inbounds nuw i8, ptr %0, i64 56 - %24 = load ptr, ptr %23, align 8, !nonnull !3, !noundef !3 - %25 = getelementptr inbounds nuw i8, ptr %0, i64 64 - %26 = load i64, ptr %25, align 8, !noundef !3 - %27 = add nuw nsw i64 %1, 1 - %28 = icmp ult i64 %27, %.sroa.0.0.lcssa - br i1 %28, label %30, label %29, !prof !441 - -29: ; preds = %22 - %.not.i = icmp ult i64 %1, %26 - br i1 %.not.i, label %"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17hbd52a60228849c3cE.exit", label %31, !prof !567 - -30: ; preds = %22 - tail call void @_ZN4core5slice5index22slice_index_order_fail17h753dc2b23292d7ecE(i64 noundef %.sroa.0.0.lcssa, i64 noundef range(i64 1, 0) %27, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.ab07cbd181e9ffbfcaa9350913085d13.398) #25, !noalias !568 + br i1 %.not14, label %34, label %19 + +16: ; preds = %._crit_edge + %17 = getelementptr inbounds nuw i8, ptr %0, i64 56 + %21 = load ptr, ptr %17, align 8, !nonnull !3, !noundef !3 + %22 = getelementptr inbounds nuw i8, ptr %0, i64 64 + %23 = load i64, ptr %22, align 8, !noundef !3 + %24 = add nuw nsw i64 %1, 1 + %25 = icmp ult i64 %24, %.sroa.0.0.lcssa + br i1 %25, label %27, label %26, !prof !441 + +26: ; preds = %19 + %.not.i = icmp ult i64 %1, %23 + br i1 %.not.i, label %"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17hbd52a60228849c3cE.exit", label %28, !prof !567 + +27: ; preds = %19 + tail call void @_ZN4core5slice5index22slice_index_order_fail17h753dc2b23292d7ecE(i64 noundef %.sroa.0.0.lcssa, i64 noundef range(i64 1, 0) %24, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.ab07cbd181e9ffbfcaa9350913085d13.398) #25, !noalias !568 unreachable -31: ; preds = %29 - tail call void @_ZN4core5slice5index24slice_end_index_len_fail17h5b7964a60aa84510E(i64 noundef range(i64 1, 0) %27, i64 noundef %26, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.ab07cbd181e9ffbfcaa9350913085d13.398) #25, !noalias !568 +22: ; preds = %26 + tail call void @_ZN4core5slice5index24slice_end_index_len_fail17h5b7964a60aa84510E(i64 noundef range(i64 1, 0) %24, i64 noundef %23, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.ab07cbd181e9ffbfcaa9350913085d13.398) #25, !noalias !568 unreachable -"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17hbd52a60228849c3cE.exit": ; preds = %29 - %32 = sub nuw nsw i64 %27, %.sroa.0.0.lcssa - %33 = getelementptr inbounds nuw i8, ptr %24, i64 %.sroa.0.0.lcssa +"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17hbd52a60228849c3cE.exit": ; preds = %26 + %32 = sub nuw nsw i64 %24, %.sroa.0.0.lcssa + %33 = getelementptr inbounds nuw i8, ptr %21, i64 %.sroa.0.0.lcssa tail call void @"_ZN4core5slice29_$LT$impl$u20$$u5b$T$u5d$$GT$12rotate_right17h3e2b81fb651284edE"(ptr noalias noundef nonnull align 1 %33, i64 noundef %32, i64 noundef 1) br label %34 34: ; preds = %._crit_edge, %"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17hbd52a60228849c3cE.exit" ret i64 %.sroa.0.0.lcssa -35: ; preds = %16 +35: ; preds = %.lr.ph %36 = getelementptr inbounds nuw { { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { i32, [1 x i32] }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %.sroa.0.019 call void @llvm.lifetime.start.p0(ptr nonnull %3) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(136) %3, ptr noundef nonnull align 8 dereferenceable(136) %17, i64 136, i1 false) - tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(136) %17, ptr noundef nonnull align 8 dereferenceable(136) %36, i64 136, i1 false) + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(136) %3, ptr noundef nonnull align 8 dereferenceable(136) %15, i64 136, i1 false) + tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(136) %15, ptr noundef nonnull align 8 dereferenceable(136) %36, i64 136, i1 false) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(136) %36, ptr noundef nonnull align 8 dereferenceable(136) %3, i64 136, i1 false) call void @llvm.lifetime.end.p0(ptr nonnull %3) - %.not = icmp eq i64 %15, 0 + %.not = icmp eq i64 %14, 0 br i1 %.not, label %._crit_edge, label %.lr.ph } diff --git a/bench/ruff-rs/optimized/6gcc2sei0t3mzzmp63ppi5tol.ll b/bench/ruff-rs/optimized/6gcc2sei0t3mzzmp63ppi5tol.ll index 87fa54af282..e881a4b519c 100644 --- a/bench/ruff-rs/optimized/6gcc2sei0t3mzzmp63ppi5tol.ll +++ b/bench/ruff-rs/optimized/6gcc2sei0t3mzzmp63ppi5tol.ll @@ -68,7 +68,6 @@ target triple = "x86_64-unknown-linux-gnu" @anon.1ef2000cb91be5a0adc7361c6504f42e.106 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.1ef2000cb91be5a0adc7361c6504f42e.97, [16 x i8] c"\\\00\00\00\00\00\00\00\7F\01\00\00*\00\00\00" }>, align 8 @anon.1ef2000cb91be5a0adc7361c6504f42e.107 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.1ef2000cb91be5a0adc7361c6504f42e.97, [16 x i8] c"\\\00\00\00\00\00\00\00\96\01\00\00\17\00\00\00" }>, align 8 @anon.1ef2000cb91be5a0adc7361c6504f42e.108 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.1ef2000cb91be5a0adc7361c6504f42e.97, [16 x i8] c"\\\00\00\00\00\00\00\00\9E\01\00\00\16\00\00\00" }>, align 8 -@anon.1ef2000cb91be5a0adc7361c6504f42e.110 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.1ef2000cb91be5a0adc7361c6504f42e.97, [16 x i8] c"\\\00\00\00\00\00\00\00\A3\01\00\00+\00\00\00" }>, align 8 @anon.1ef2000cb91be5a0adc7361c6504f42e.111 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.1ef2000cb91be5a0adc7361c6504f42e.97, [16 x i8] c"\\\00\00\00\00\00\00\00\AA\01\00\00\19\00\00\00" }>, align 8 @anon.1ef2000cb91be5a0adc7361c6504f42e.113 = private unnamed_addr constant <{ ptr, [8 x i8], ptr, [8 x i8] }> <{ ptr inttoptr (i64 1 to ptr), [8 x i8] zeroinitializer, ptr inttoptr (i64 1 to ptr), [8 x i8] zeroinitializer }>, align 8 @anon.1ef2000cb91be5a0adc7361c6504f42e.118 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.1ef2000cb91be5a0adc7361c6504f42e.97, [16 x i8] c"\\\00\00\00\00\00\00\00\8C\02\00\00%\00\00\00" }>, align 8 @@ -7177,70 +7176,58 @@ define internal fastcc noundef range(i64 0, 9223372036854775807) i64 @"_ZN7match %.not18 = icmp eq i64 %1, 0 br i1 %.not18, label %._crit_edge, label %.lr.ph.preheader -.lr.ph.preheader: ; preds = %.split - %14 = add nsw i64 %1, -1 - %.first_iter = icmp ult i64 %14, %5 - br label %.lr.ph - -.lr.ph: ; preds = %.lr.ph.preheader, %35 - %.sroa.0.019 = phi i64 [ %15, %35 ], [ %1, %.lr.ph.preheader ] - %15 = add nsw i64 %.sroa.0.019, -1 - br i1 %.first_iter, label %16, label %21 - -._crit_edge: ; preds = %35, %16, %.split - %.sroa.0.0.lcssa = phi i64 [ 0, %.split ], [ %.sroa.0.019, %16 ], [ 0, %35 ] +.lr.ph.preheader: ; preds = %.split, %32 + %.sroa.0.019 = phi i64 [ %14, %32 ], [ %1, %.split ] + %14 = add nsw i64 %.sroa.0.019, -1 + %15 = getelementptr inbounds nuw { { i64, [1 x i64] }, { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %14 + %16 = getelementptr inbounds nuw i8, ptr %15, i64 136 + %17 = load i32, ptr %16, align 8, !noundef !3 + %18 = icmp ult i32 %17, %13 + br i1 %18, label %32, label %._crit_edge + +._crit_edge: ; preds = %32, %.lr.ph, %.split + %.sroa.0.0.lcssa = phi i64 [ 0, %.split ], [ %.sroa.0.019, %.lr.ph ], [ 0, %32 ] %.not14 = icmp eq i64 %.sroa.0.0.lcssa, %1 - br i1 %.not14, label %34, label %22 - -16: ; preds = %.lr.ph - %17 = getelementptr inbounds nuw { { i64, [1 x i64] }, { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %15 - %18 = getelementptr inbounds nuw i8, ptr %17, i64 136 - %19 = load i32, ptr %18, align 8, !noundef !3 - %20 = icmp ult i32 %19, %13 - br i1 %20, label %35, label %._crit_edge - -21: ; preds = %.lr.ph - tail call void @_ZN4core9panicking18panic_bounds_check17h1a9bf3d94de0fc80E(i64 noundef %15, i64 noundef %5, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.110) #20 - unreachable - -22: ; preds = %._crit_edge - %23 = getelementptr inbounds nuw i8, ptr %0, i64 72 - %24 = load ptr, ptr %23, align 8, !nonnull !3, !noundef !3 - %25 = getelementptr inbounds nuw i8, ptr %0, i64 80 - %26 = load i64, ptr %25, align 8, !noundef !3 - %27 = add nuw nsw i64 %1, 1 - %28 = icmp ult i64 %27, %.sroa.0.0.lcssa - br i1 %28, label %30, label %29, !prof !4 - -29: ; preds = %22 - %.not.i = icmp ult i64 %1, %26 + br i1 %.not14, label %34, label %21 + +21: ; preds = %._crit_edge + %20 = getelementptr inbounds nuw i8, ptr %0, i64 72 + %21 = load ptr, ptr %20, align 8, !nonnull !3, !noundef !3 + %22 = getelementptr inbounds nuw i8, ptr %0, i64 80 + %23 = load i64, ptr %22, align 8, !noundef !3 + %24 = add nuw nsw i64 %1, 1 + %25 = icmp ult i64 %24, %.sroa.0.0.lcssa + br i1 %25, label %30, label %26, !prof !4 + +29: ; preds = %21 + %.not.i = icmp ult i64 %1, %23 br i1 %.not.i, label %"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h3771934e11456b61E.exit", label %31, !prof !32 -30: ; preds = %22 - tail call void @_ZN4core5slice5index22slice_index_order_fail17h753dc2b23292d7ecE(i64 noundef %.sroa.0.0.lcssa, i64 noundef range(i64 1, 0) %27, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.111) #20, !noalias !393 +30: ; preds = %21 + tail call void @_ZN4core5slice5index22slice_index_order_fail17h753dc2b23292d7ecE(i64 noundef %.sroa.0.0.lcssa, i64 noundef range(i64 1, 0) %24, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.111) #20, !noalias !393 unreachable 31: ; preds = %29 - tail call void @_ZN4core5slice5index24slice_end_index_len_fail17h5b7964a60aa84510E(i64 noundef range(i64 1, 0) %27, i64 noundef %26, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.111) #20, !noalias !393 + tail call void @_ZN4core5slice5index24slice_end_index_len_fail17h5b7964a60aa84510E(i64 noundef range(i64 1, 0) %24, i64 noundef %23, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.111) #20, !noalias !393 unreachable "_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h3771934e11456b61E.exit": ; preds = %29 - %32 = sub nuw nsw i64 %27, %.sroa.0.0.lcssa - %33 = getelementptr inbounds nuw i8, ptr %24, i64 %.sroa.0.0.lcssa + %32 = sub nuw nsw i64 %24, %.sroa.0.0.lcssa + %33 = getelementptr inbounds nuw i8, ptr %21, i64 %.sroa.0.0.lcssa tail call void @"_ZN4core5slice29_$LT$impl$u20$$u5b$T$u5d$$GT$12rotate_right17h938f13c02e9e2c96E"(ptr noalias noundef nonnull align 1 %33, i64 noundef %32, i64 noundef 1) br label %34 34: ; preds = %._crit_edge, %"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h3771934e11456b61E.exit" ret i64 %.sroa.0.0.lcssa -35: ; preds = %16 +35: ; preds = %.lr.ph %36 = getelementptr inbounds nuw { { i64, [1 x i64] }, { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %.sroa.0.019 call void @llvm.lifetime.start.p0(ptr nonnull %3) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(144) %3, ptr noundef nonnull align 8 dereferenceable(144) %17, i64 144, i1 false) - tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(144) %17, ptr noundef nonnull align 8 dereferenceable(144) %36, i64 144, i1 false) + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(144) %3, ptr noundef nonnull align 8 dereferenceable(144) %15, i64 144, i1 false) + tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(144) %15, ptr noundef nonnull align 8 dereferenceable(144) %36, i64 144, i1 false) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(144) %36, ptr noundef nonnull align 8 dereferenceable(144) %3, i64 144, i1 false) call void @llvm.lifetime.end.p0(ptr nonnull %3) - %.not = icmp eq i64 %15, 0 + %.not = icmp eq i64 %14, 0 br i1 %.not, label %._crit_edge, label %.lr.ph } @@ -7267,70 +7254,58 @@ define internal fastcc noundef range(i64 0, 9223372036854775807) i64 @"_ZN7match %.not18 = icmp eq i64 %1, 0 br i1 %.not18, label %._crit_edge, label %.lr.ph.preheader -.lr.ph.preheader: ; preds = %.split - %14 = add nsw i64 %1, -1 - %.first_iter = icmp ult i64 %14, %5 - br label %.lr.ph - -.lr.ph: ; preds = %.lr.ph.preheader, %35 - %.sroa.0.019 = phi i64 [ %15, %35 ], [ %1, %.lr.ph.preheader ] - %15 = add nsw i64 %.sroa.0.019, -1 - br i1 %.first_iter, label %16, label %21 - -._crit_edge: ; preds = %35, %16, %.split - %.sroa.0.0.lcssa = phi i64 [ 0, %.split ], [ %.sroa.0.019, %16 ], [ 0, %35 ] +.lr.ph.preheader: ; preds = %.split, %32 + %.sroa.0.019 = phi i64 [ %14, %32 ], [ %1, %.split ] + %14 = add nsw i64 %.sroa.0.019, -1 + %15 = getelementptr inbounds nuw { { i64, [2 x i64] }, { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %14 + %16 = getelementptr inbounds nuw i8, ptr %15, i64 144 + %17 = load i32, ptr %16, align 8, !noundef !3 + %18 = icmp ult i32 %17, %13 + br i1 %18, label %32, label %._crit_edge + +._crit_edge: ; preds = %32, %.lr.ph, %.split + %.sroa.0.0.lcssa = phi i64 [ 0, %.split ], [ %.sroa.0.019, %.lr.ph ], [ 0, %32 ] %.not14 = icmp eq i64 %.sroa.0.0.lcssa, %1 - br i1 %.not14, label %34, label %22 - -16: ; preds = %.lr.ph - %17 = getelementptr inbounds nuw { { i64, [2 x i64] }, { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %15 - %18 = getelementptr inbounds nuw i8, ptr %17, i64 144 - %19 = load i32, ptr %18, align 8, !noundef !3 - %20 = icmp ult i32 %19, %13 - br i1 %20, label %35, label %._crit_edge - -21: ; preds = %.lr.ph - tail call void @_ZN4core9panicking18panic_bounds_check17h1a9bf3d94de0fc80E(i64 noundef %15, i64 noundef %5, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.110) #20 - unreachable - -22: ; preds = %._crit_edge - %23 = getelementptr inbounds nuw i8, ptr %0, i64 80 - %24 = load ptr, ptr %23, align 8, !nonnull !3, !noundef !3 - %25 = getelementptr inbounds nuw i8, ptr %0, i64 88 - %26 = load i64, ptr %25, align 8, !noundef !3 - %27 = add nuw nsw i64 %1, 1 - %28 = icmp ult i64 %27, %.sroa.0.0.lcssa - br i1 %28, label %30, label %29, !prof !4 - -29: ; preds = %22 - %.not.i = icmp ult i64 %1, %26 + br i1 %.not14, label %34, label %21 + +21: ; preds = %._crit_edge + %20 = getelementptr inbounds nuw i8, ptr %0, i64 80 + %21 = load ptr, ptr %20, align 8, !nonnull !3, !noundef !3 + %22 = getelementptr inbounds nuw i8, ptr %0, i64 88 + %23 = load i64, ptr %22, align 8, !noundef !3 + %24 = add nuw nsw i64 %1, 1 + %25 = icmp ult i64 %24, %.sroa.0.0.lcssa + br i1 %25, label %30, label %26, !prof !4 + +29: ; preds = %21 + %.not.i = icmp ult i64 %1, %23 br i1 %.not.i, label %"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h3771934e11456b61E.exit", label %31, !prof !32 -30: ; preds = %22 - tail call void @_ZN4core5slice5index22slice_index_order_fail17h753dc2b23292d7ecE(i64 noundef %.sroa.0.0.lcssa, i64 noundef range(i64 1, 0) %27, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.111) #20, !noalias !399 +30: ; preds = %21 + tail call void @_ZN4core5slice5index22slice_index_order_fail17h753dc2b23292d7ecE(i64 noundef %.sroa.0.0.lcssa, i64 noundef range(i64 1, 0) %24, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.111) #20, !noalias !399 unreachable 31: ; preds = %29 - tail call void @_ZN4core5slice5index24slice_end_index_len_fail17h5b7964a60aa84510E(i64 noundef range(i64 1, 0) %27, i64 noundef %26, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.111) #20, !noalias !399 + tail call void @_ZN4core5slice5index24slice_end_index_len_fail17h5b7964a60aa84510E(i64 noundef range(i64 1, 0) %24, i64 noundef %23, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.1ef2000cb91be5a0adc7361c6504f42e.111) #20, !noalias !399 unreachable "_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h3771934e11456b61E.exit": ; preds = %29 - %32 = sub nuw nsw i64 %27, %.sroa.0.0.lcssa - %33 = getelementptr inbounds nuw i8, ptr %24, i64 %.sroa.0.0.lcssa + %32 = sub nuw nsw i64 %24, %.sroa.0.0.lcssa + %33 = getelementptr inbounds nuw i8, ptr %21, i64 %.sroa.0.0.lcssa tail call void @"_ZN4core5slice29_$LT$impl$u20$$u5b$T$u5d$$GT$12rotate_right17h938f13c02e9e2c96E"(ptr noalias noundef nonnull align 1 %33, i64 noundef %32, i64 noundef 1) br label %34 34: ; preds = %._crit_edge, %"_ZN115_$LT$core..ops..range..RangeInclusive$LT$usize$GT$$u20$as$u20$core..slice..index..SliceIndex$LT$$u5b$T$u5d$$GT$$GT$9index_mut17h3771934e11456b61E.exit" ret i64 %.sroa.0.0.lcssa -35: ; preds = %16 +35: ; preds = %.lr.ph %36 = getelementptr inbounds nuw { { i64, [2 x i64] }, { { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 } }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, { { { i64, ptr, {} }, {} }, i64 }, i32, i8, i8, [2 x i8] }, ptr %9, i64 %.sroa.0.019 call void @llvm.lifetime.start.p0(ptr nonnull %3) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(152) %3, ptr noundef nonnull align 8 dereferenceable(152) %17, i64 152, i1 false) - tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(152) %17, ptr noundef nonnull align 8 dereferenceable(152) %36, i64 152, i1 false) + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(152) %3, ptr noundef nonnull align 8 dereferenceable(152) %15, i64 152, i1 false) + tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(152) %15, ptr noundef nonnull align 8 dereferenceable(152) %36, i64 152, i1 false) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(152) %36, ptr noundef nonnull align 8 dereferenceable(152) %3, i64 152, i1 false) call void @llvm.lifetime.end.p0(ptr nonnull %3) - %.not = icmp eq i64 %15, 0 + %.not = icmp eq i64 %14, 0 br i1 %.not, label %._crit_edge, label %.lr.ph } diff --git a/bench/rust-analyzer-rs/optimized/4hdqg9y9agw1ekve.ll b/bench/rust-analyzer-rs/optimized/4hdqg9y9agw1ekve.ll index b4ccf5fd9c9..822c70b0626 100644 --- a/bench/rust-analyzer-rs/optimized/4hdqg9y9agw1ekve.ll +++ b/bench/rust-analyzer-rs/optimized/4hdqg9y9agw1ekve.ll @@ -50976,13 +50976,13 @@ _ZN11ide_assists8handlers16extract_function8Function11type_params17h1ea059bfa2ec br label %.body.thread5.i.i .thread.i.i35: ; preds = %.noexc36.i.i, %.noexc.i.i + %.pre-phi.i.ph.i.i = phi i64 [ %893, %.noexc.i.i ], [ %917, %.noexc36.i.i ] %.pn.i.ph.i.i = phi { i64, ptr } [ %892, %.noexc.i.i ], [ %916, %.noexc36.i.i ] - %.ph.i.i = phi i64 [ %893, %.noexc.i.i ], [ %917, %.noexc36.i.i ] %918 = extractvalue { i64, ptr } %.pn.i.ph.i.i, 1 %919 = getelementptr inbounds nuw i8, ptr %30, i64 8 - store i64 %.ph.i.i, ptr %30, align 8, !alias.scope !13284, !noalias !13334 + store i64 %.pre-phi.i.ph.i.i, ptr %30, align 8, !alias.scope !13284, !noalias !13334 store ptr %918, ptr %919, align 8, !alias.scope !13284, !noalias !13334 - %920 = icmp ne i64 %.ph.i.i, 4 + %920 = icmp ne i64 %.pre-phi.i.ph.i.i, 4 call void @llvm.assume(i1 %920) br label %925 @@ -51033,7 +51033,7 @@ _ZN11ide_assists8handlers16extract_function8Function11type_params17h1ea059bfa2ec br label %.body.i33 931: ; preds = %.thread12.i.i, %.noexc.i36 - %.015.i.i = phi ptr [ %926, %.noexc.i36 ], [ null, %.thread12.i.i ] + %.015.i.i = phi ptr [ %926, %.noexc.i36 ], [ null, %.thread13.i.i ] call void @llvm.lifetime.end.p0(ptr nonnull %30), !noalias !13281 %932 = load ptr, ptr %884, align 8, !noalias !13249, !nonnull !23, !noundef !23 %933 = load i64, ptr %886, align 8, !noalias !13249, !noundef !23 diff --git a/bench/rust-analyzer-rs/optimized/4mz36mxu8r0g7zqk.ll b/bench/rust-analyzer-rs/optimized/4mz36mxu8r0g7zqk.ll index dccef364793..49e27fc1509 100644 --- a/bench/rust-analyzer-rs/optimized/4mz36mxu8r0g7zqk.ll +++ b/bench/rust-analyzer-rs/optimized/4mz36mxu8r0g7zqk.ll @@ -7,8 +7,6 @@ target triple = "x86_64-unknown-linux-gnu" @anon.551f5282231713dc5a82db078fc3c216.6 = private unnamed_addr constant <{ [32 x i8] }> <{ [32 x i8] c"assertion failed: idx < CAPACITY" }>, align 1 @anon.551f5282231713dc5a82db078fc3c216.7 = private unnamed_addr constant <{ [91 x i8] }> <{ [91 x i8] c"/rustc/25ef9e3d85d934b27d9dada2f9dd52b1dc63bb04/library/alloc/src/collections/btree/node.rs" }>, align 1 @anon.551f5282231713dc5a82db078fc3c216.11 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.551f5282231713dc5a82db078fc3c216.7, [16 x i8] c"[\00\00\00\00\00\00\00\B3\02\00\00\09\00\00\00" }>, align 8 -@anon.551f5282231713dc5a82db078fc3c216.12 = private unnamed_addr constant <{ [40 x i8] }> <{ [40 x i8] c"assertion failed: src.len() == dst.len()" }>, align 1 -@anon.551f5282231713dc5a82db078fc3c216.13 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.551f5282231713dc5a82db078fc3c216.7, [16 x i8] c"[\00\00\00\00\00\00\00/\07\00\00\05\00\00\00" }>, align 8 @anon.551f5282231713dc5a82db078fc3c216.18 = private unnamed_addr constant <{ [39 x i8] }> <{ [39 x i8] c"assertion failed: old_left_len >= count" }>, align 1 @anon.551f5282231713dc5a82db078fc3c216.19 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.551f5282231713dc5a82db078fc3c216.7, [16 x i8] c"[\00\00\00\00\00\00\00\DD\05\00\00\0D\00\00\00" }>, align 8 @anon.551f5282231713dc5a82db078fc3c216.22 = private unnamed_addr constant <{ [25 x i8] }> <{ [25 x i8] c"assertion failed: len > 0" }>, align 1 @@ -3854,12 +3852,12 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. br label %21 21: ; preds = %.loopexit, %.loopexit95 - %.sroa.0.0 = phi ptr [ %.0.lcssa.i, %.loopexit95 ], [ %.sroa.0.1, %.loopexit ] + %.sroa.0.0 = phi ptr [ %.0.lcssa.i, %.loopexit94 ], [ %.sroa.0.1, %.loopexit ] invoke void @"_ZN137_$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$K$C$V$C$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hf77e4b51dcd35b24E"(ptr noalias noundef nonnull sret({ i64, [2 x i64] }) align 8 captures(none) dereferenceable(24) %8, ptr noalias noundef nonnull align 8 dereferenceable(56) %9) to label %24 unwind label %22 .body35: ; preds = %127, %166, %22 - %.pn = phi { ptr, i32 } [ %eh.lpad-body39.ph, %166 ], [ %23, %22 ], [ %128, %127 ] + %.pn = phi { ptr, i32 } [ %eh.lpad-body39.ph, %163 ], [ %23, %22 ], [ %128, %124 ] invoke void @"_ZN4core3ptr447drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$alloc..string..String$C$alloc..collections..btree..set_val..SetValZST$C$core..iter..adapters..map..Map$LT$alloc..vec..into_iter..IntoIter$LT$alloc..string..String$GT$$C$alloc..collections..btree..set..BTreeSet$LT$alloc..string..String$GT$..from_sorted_iter$LT$alloc..vec..into_iter..IntoIter$LT$alloc..string..String$GT$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$$GT$$GT$17he2f737b4e6bf956aE"(ptr noalias noundef nonnull align 8 dereferenceable(56) %9) #50 to label %.body unwind label %167 @@ -3996,32 +3994,23 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %70, ptr nonnull align 8 %69, i64 %71, i1 false), !noalias !1317 %72 = add nuw nsw i64 %67, 1 %73 = sub nuw nsw i64 %66, %72 - %74 = add nsw i64 %61, -1 - %75 = icmp eq i64 %73, %74 - br i1 %75, label %76, label %.noexc34 - -.noexc34: ; preds = %65 - call void @_ZN4core9panicking5panic17h44790a89027c670fE(ptr noalias noundef nonnull readonly align 1 @anon.551f5282231713dc5a82db078fc3c216.12, i64 noundef 40, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.551f5282231713dc5a82db078fc3c216.13) #51 - unreachable - -76: ; preds = %65 - %77 = getelementptr inbounds nuw i8, ptr %52, i64 8 - %78 = getelementptr inbounds nuw { [3 x i64] }, ptr %77, i64 %72 - %79 = mul nuw nsw i64 %73, 24 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %69, ptr nonnull readonly align 8 %78, i64 %79, i1 false), !alias.scope !1320, !noalias !1317 - %80 = getelementptr inbounds nuw { [3 x i64] }, ptr %77, i64 %67 - %81 = getelementptr inbounds nuw i8, ptr %.011.i, i64 8 - %82 = getelementptr inbounds nuw { [3 x i64] }, ptr %81, i64 %49 + %74 = getelementptr inbounds nuw i8, ptr %52, i64 8 + %75 = getelementptr inbounds nuw { [3 x i64] }, ptr %74, i64 %72 + %76 = mul nuw nsw i64 %73, 24 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %69, ptr nonnull readonly align 8 %75, i64 %76, i1 false), !alias.scope !1320, !noalias !1317 + %77 = getelementptr inbounds nuw { [3 x i64] }, ptr %74, i64 %67 + %78 = getelementptr inbounds nuw i8, ptr %.011.i, i64 8 + %79 = getelementptr inbounds nuw { [3 x i64] }, ptr %78, i64 %49 call void @llvm.lifetime.start.p0(ptr nonnull %.sroa.018.i.i) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.018.i.i, ptr noundef nonnull align 8 dereferenceable(24) %82, i64 24, i1 false), !noalias !1317 - call void @llvm.memmove.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %82, ptr noundef nonnull align 8 dereferenceable(24) %80, i64 24, i1 false), !noalias !1317 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.018.i.i, ptr noundef nonnull align 8 dereferenceable(24) %79, i64 24, i1 false), !noalias !1317 + call void @llvm.memmove.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %79, ptr noundef nonnull align 8 dereferenceable(24) %77, i64 24, i1 false), !noalias !1317 %83 = getelementptr inbounds nuw { [3 x i64] }, ptr %69, i64 %73 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %83, ptr noundef nonnull align 8 dereferenceable(24) %.sroa.018.i.i, i64 24, i1 false), !noalias !1317 call void @llvm.lifetime.end.p0(ptr nonnull %.sroa.018.i.i) %cond.i = icmp eq i64 %53, 0 br i1 %cond.i, label %"_ZN5alloc11collections5btree3fix178_$LT$impl$u20$alloc..collections..btree..node..NodeRef$LT$alloc..collections..btree..node..marker..Owned$C$K$C$V$C$alloc..collections..btree..node..marker..LeafOrInternal$GT$$GT$29fix_right_border_of_plentiful17hd47b80ca75df3838E.exit", label %_ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i -_ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; preds = %76 +_ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; preds = %65 %84 = getelementptr inbounds nuw i8, ptr %56, i64 280 %85 = getelementptr inbounds nuw ptr, ptr %84, i64 %61 %86 = shl nuw nsw i64 %64, 3 @@ -4034,7 +4023,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; br label %91 91: ; preds = %91, %_ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i - %.sroa.0.05.i.i.i = phi i64 [ 0, %_ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i ], [ %92, %91 ] + %.sroa.0.05.i.i.i = phi i64 [ 0, %_ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i ], [ %92, %88 ] %92 = add nuw nsw i64 %.sroa.0.05.i.i.i, 1 %93 = getelementptr inbounds nuw ptr, ptr %84, i64 %.sroa.0.05.i.i.i %94 = load ptr, ptr %93, align 8, !noalias !1317, !nonnull !21, !noundef !21 @@ -4045,12 +4034,12 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; %exitcond.not.i.i.i = icmp eq i64 %.sroa.0.05.i.i.i, 5 br i1 %exitcond.not.i.i.i, label %"_ZN5alloc11collections5btree4node29BalancingContext$LT$K$C$V$GT$15bulk_steal_left17h84e0ce90d91ff590E.exit.i", label %91 -"_ZN5alloc11collections5btree3fix178_$LT$impl$u20$alloc..collections..btree..node..NodeRef$LT$alloc..collections..btree..node..marker..Owned$C$K$C$V$C$alloc..collections..btree..node..marker..LeafOrInternal$GT$$GT$29fix_right_border_of_plentiful17hd47b80ca75df3838E.exit": ; preds = %76, %"_ZN5alloc11collections5btree4node29BalancingContext$LT$K$C$V$GT$15bulk_steal_left17h84e0ce90d91ff590E.exit.i", %"_ZN4core3ptr447drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$alloc..string..String$C$alloc..collections..btree..set_val..SetValZST$C$core..iter..adapters..map..Map$LT$alloc..vec..into_iter..IntoIter$LT$alloc..string..String$GT$$C$alloc..collections..btree..set..BTreeSet$LT$alloc..string..String$GT$..from_sorted_iter$LT$alloc..vec..into_iter..IntoIter$LT$alloc..string..String$GT$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$$GT$$GT$17he2f737b4e6bf956aE.exit" +"_ZN5alloc11collections5btree3fix178_$LT$impl$u20$alloc..collections..btree..node..NodeRef$LT$alloc..collections..btree..node..marker..Owned$C$K$C$V$C$alloc..collections..btree..node..marker..LeafOrInternal$GT$$GT$29fix_right_border_of_plentiful17hd47b80ca75df3838E.exit": ; preds = %65, %"_ZN5alloc11collections5btree4node29BalancingContext$LT$K$C$V$GT$15bulk_steal_left17h84e0ce90d91ff590E.exit.i", %"_ZN4core3ptr447drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$alloc..string..String$C$alloc..collections..btree..set_val..SetValZST$C$core..iter..adapters..map..Map$LT$alloc..vec..into_iter..IntoIter$LT$alloc..string..String$GT$$C$alloc..collections..btree..set..BTreeSet$LT$alloc..string..String$GT$..from_sorted_iter$LT$alloc..vec..into_iter..IntoIter$LT$alloc..string..String$GT$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$$GT$$GT$17he2f737b4e6bf956aE.exit" ret void .preheader: ; preds = %42, %99 - %.sroa.5.0 = phi i64 [ %100, %99 ], [ 0, %42 ] - %.sroa.02.0 = phi ptr [ %97, %99 ], [ %.sroa.0.0, %42 ] + %.sroa.5.0 = phi i64 [ %100, %96 ], [ 0, %42 ] + %.sroa.02.0 = phi ptr [ %97, %96 ], [ %.sroa.0.0, %42 ] %97 = load ptr, ptr %.sroa.02.0, align 8, !noalias !1328, !noundef !21 %98 = icmp eq ptr %97, null br i1 %98, label %104, label %99 @@ -4101,9 +4090,9 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; br label %110 110: ; preds = %.loopexit.split-lp86, %.loopexit85 - %lpad.phi89 = phi { ptr, i32 } [ %lpad.loopexit87, %.loopexit85 ], [ %lpad.loopexit.split-lp88, %.loopexit.split-lp86 ] + %lpad.phi89 = phi { ptr, i32 } [ %lpad.loopexit87, %.loopexit84 ], [ %lpad.loopexit.split-lp88, %.loopexit.split-lp85 ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17he7f40e69e6f26b83E"(ptr noalias noundef nonnull align 1 %4) - to label %166 unwind label %111, !noalias !1331 + to label %163 unwind label %111, !noalias !1331 111: ; preds = %110 %112 = landingpad { ptr, i32 } @@ -4126,11 +4115,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; br label %.loopexit84 .loopexit84: ; preds = %99, %113 - %.sroa.062.0 = phi ptr [ %107, %113 ], [ %97, %99 ] - %.sroa.663.0 = phi i64 [ %116, %113 ], [ %100, %99 ] + %.sroa.062.0 = phi ptr [ %107, %110 ], [ %97, %96 ] + %.sroa.663.0 = phi i64 [ %116, %110 ], [ %100, %96 ] %118 = add i64 %.sroa.663.0, -1 %119 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17h3db4fe9f58fcf8caE.llvm.2875332049115192089"() - to label %.noexc40 unwind label %.loopexit90 + to label %.noexc39 unwind label %.loopexit90 .noexc40: ; preds = %.loopexit84 %120 = icmp eq ptr %119, null @@ -4138,7 +4127,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; 121: ; preds = %.noexc40 invoke void @_ZN5alloc5alloc18handle_alloc_error17h426354a964e0805cE(i64 noundef 8, i64 noundef 280) #51 - to label %.noexc41 unwind label %.loopexit.split-lp91 + to label %.noexc40 unwind label %.loopexit.split-lp91 .noexc41: ; preds = %121 unreachable @@ -4158,7 +4147,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; unreachable .loopexit127: ; preds = %_ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit58, %122 - %.sroa.068.0.lcssa = phi ptr [ %119, %122 ], [ %152, %_ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit58 ] + %.sroa.068.0.lcssa = phi ptr [ %119, %119 ], [ %152, %_ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit57 ] call void @llvm.lifetime.start.p0(ptr nonnull %6) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(24) %8, i64 24, i1 false) %124 = getelementptr inbounds nuw i8, ptr %.sroa.062.0, i64 274 @@ -4170,7 +4159,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; %128 = landingpad { ptr, i32 } cleanup invoke void @"_ZN4core3ptr42drop_in_place$LT$alloc..string..String$GT$17hdcf7b889bac065f1E"(ptr noalias noundef nonnull align 8 dereferenceable(24) %6) #50 - to label %.body35 unwind label %129 + to label %.body34 unwind label %129 129: ; preds = %127 %130 = landingpad { ptr, i32 } @@ -4198,8 +4187,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; br i1 %.not16.i45, label %.loopexit, label %.lr.ph.i46 .lr.ph.i46: ; preds = %131, %.lr.ph.i46 - %.018.i47 = phi ptr [ %147, %.lr.ph.i46 ], [ %.sroa.062.0, %131 ] - %.01517.i48 = phi i64 [ %148, %.lr.ph.i46 ], [ %.sroa.663.0, %131 ] + %.018.i47 = phi ptr [ %147, %.lr.ph.i45 ], [ %.sroa.062.0, %128 ] + %.01517.i48 = phi i64 [ %148, %.lr.ph.i45 ], [ %.sroa.663.0, %128 ] %141 = getelementptr inbounds nuw i8, ptr %.018.i47, i64 274 %142 = load i16, ptr %141, align 2, !noalias !1343, !noundef !21 %143 = zext nneg i16 %142 to i64 @@ -4213,7 +4202,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; br i1 %.not.i49, label %.loopexit, label %.lr.ph.i46 .loopexit: ; preds = %.lr.ph.i46, %131, %161 - %.sroa.0.1 = phi ptr [ %.sroa.0.0, %161 ], [ %.sroa.062.0, %131 ], [ %147, %.lr.ph.i46 ] + %.sroa.0.1 = phi ptr [ %.sroa.0.0, %158 ], [ %.sroa.062.0, %128 ], [ %147, %.lr.ph.i45 ] %149 = load i64, ptr %2, align 8, !noundef !21 %150 = add i64 %149, 1 store i64 %150, ptr %2, align 8 @@ -4221,11 +4210,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; br label %21 .lr.ph: ; preds = %122, %_ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit58 - %.sroa.012.0105 = phi i64 [ %151, %_ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit58 ], [ 0, %122 ] - %.sroa.068.0103 = phi ptr [ %152, %_ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit58 ], [ %119, %122 ] + %.sroa.012.0105 = phi i64 [ %151, %_ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit57 ], [ 0, %119 ] + %.sroa.068.0103 = phi ptr [ %152, %_ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit57 ], [ %119, %119 ] %151 = add nuw i64 %.sroa.012.0105, 1 %152 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17hdcae3c5a5b57ca29E.llvm.2875332049115192089"() - to label %.noexc.i53 unwind label %.loopexit83, !noalias !1346 + to label %.noexc.i52 unwind label %.loopexit83, !noalias !1346 .noexc.i53: ; preds = %.lr.ph %153 = icmp eq ptr %152, null @@ -4233,7 +4222,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; 154: ; preds = %.noexc.i53 invoke void @_ZN5alloc5alloc18handle_alloc_error17h426354a964e0805cE(i64 noundef 8, i64 noundef 376) #51 - to label %.noexc3.i54 unwind label %.loopexit.split-lp, !noalias !1346 + to label %.noexc3.i53 unwind label %.loopexit.split-lp, !noalias !1346 .noexc3.i54: ; preds = %154 unreachable @@ -4249,9 +4238,9 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb9dcb63b14c984bE.exit.i.i: ; br label %155 155: ; preds = %.loopexit.split-lp, %.loopexit83 - %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit83 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] + %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit82 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17he7f40e69e6f26b83E"(ptr noalias noundef nonnull align 1 %4) - to label %166 unwind label %156, !noalias !1346 + to label %163 unwind label %156, !noalias !1346 156: ; preds = %155 %157 = landingpad { ptr, i32 } @@ -4281,9 +4270,9 @@ _ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit58: ; preds = % br label %.loopexit 166: ; preds = %.loopexit90, %.loopexit.split-lp91, %110, %155 - %eh.lpad-body39.ph = phi { ptr, i32 } [ %lpad.phi89, %110 ], [ %lpad.phi, %155 ], [ %lpad.loopexit92, %.loopexit90 ], [ %lpad.loopexit.split-lp93, %.loopexit.split-lp91 ] + %eh.lpad-body39.ph = phi { ptr, i32 } [ %lpad.phi89, %107 ], [ %lpad.phi, %152 ], [ %lpad.loopexit92, %.loopexit89 ], [ %lpad.loopexit.split-lp93, %.loopexit.split-lp90 ] invoke void @"_ZN4core3ptr42drop_in_place$LT$alloc..string..String$GT$17hdcf7b889bac065f1E"(ptr noalias noundef nonnull align 8 dereferenceable(24) %7) #50 - to label %.body35 unwind label %167 + to label %.body34 unwind label %167 167: ; preds = %166, %.body35 %168 = landingpad { ptr, i32 } @@ -4292,7 +4281,7 @@ _ZN5alloc11collections5btree3mem7replace17h87e978e052ec58a4E.exit58: ; preds = % unreachable .body: ; preds = %.body35, %29 - %.pn22 = phi { ptr, i32 } [ %.pn, %.body35 ], [ %30, %29 ] + %.pn22 = phi { ptr, i32 } [ %.pn, %.body34 ], [ %30, %29 ] resume { ptr, i32 } %.pn22 } diff --git a/bench/tree-sitter-rs/optimized/55e7aotywrgrb7st.ll b/bench/tree-sitter-rs/optimized/55e7aotywrgrb7st.ll index a277ca3d2cb..af05ba7043b 100644 --- a/bench/tree-sitter-rs/optimized/55e7aotywrgrb7st.ll +++ b/bench/tree-sitter-rs/optimized/55e7aotywrgrb7st.ll @@ -18342,8 +18342,8 @@ _ZN15tree_sitter_cli8generate12build_tables4item9ParseItem13associativity17h1626 %75 = load i8, ptr %74, align 8, !range !1084, !noalias !3336, !noundef !14 %76 = getelementptr inbounds nuw i8, ptr %16, i64 8 %77 = load ptr, ptr %76, align 8, !alias.scope !3337, !noalias !3340, !nonnull !14, !noundef !14 - %78 = getelementptr inbounds nuw { { i64, [3 x i64] }, { i64, [2 x i64] }, { i64, [2 x i64] }, { i64, i8 }, i8, [7 x i8] }, ptr %77, i64 %68 - %79 = getelementptr inbounds nuw i8, ptr %78, i64 96 + %78 = getelementptr { { i64, [3 x i64] }, { i64, [2 x i64] }, { i64, [2 x i64] }, { i64, i8 }, i8, [7 x i8] }, ptr %77, i64 %67 + %79 = getelementptr i8, ptr %78, i64 -8 %80 = load i8, ptr %79, align 8, !range !1084, !noalias !3346, !noundef !14 %81 = icmp eq i8 %75, 2 br i1 %81, label %82, label %83 diff --git a/bench/uv-rs/optimized/6909c4r4kqhl58g4t63amtvkr.ll b/bench/uv-rs/optimized/6909c4r4kqhl58g4t63amtvkr.ll index 9be1d831a74..2437e54fefc 100644 --- a/bench/uv-rs/optimized/6909c4r4kqhl58g4t63amtvkr.ll +++ b/bench/uv-rs/optimized/6909c4r4kqhl58g4t63amtvkr.ll @@ -11891,12 +11891,12 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. br label %19 19: ; preds = %.loopexit, %.loopexit75 - %.sroa.0.0 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit75 ], [ %.sroa.0.1, %.loopexit ] + %.sroa.0.0 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit74 ], [ %.sroa.0.1, %.loopexit ] %20 = invoke { ptr, ptr } @"_ZN137_$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$K$C$V$C$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17he8d2fb518b93cee1E"(ptr noalias noundef nonnull align 8 dereferenceable(56) %5) to label %24 unwind label %22 .body: ; preds = %.loopexit70, %.loopexit.split-lp71, %157, %111, %22 - %.pn = phi { ptr, i32 } [ %23, %22 ], [ %lpad.phi69, %111 ], [ %lpad.phi, %157 ], [ %lpad.loopexit72, %.loopexit70 ], [ %lpad.loopexit.split-lp73, %.loopexit.split-lp71 ] + %.pn = phi { ptr, i32 } [ %23, %22 ], [ %lpad.phi69, %108 ], [ %lpad.phi, %154 ], [ %lpad.loopexit72, %.loopexit69 ], [ %lpad.loopexit.split-lp73, %.loopexit.split-lp70 ] %21 = getelementptr inbounds nuw i8, ptr %5, i64 24 invoke void @"_ZN86_$LT$alloc..vec..into_iter..IntoIter$LT$T$C$A$GT$$u20$as$u20$core..ops..drop..Drop$GT$4drop17h23ea7b304b3ae16cE.llvm.8717112297715684712"(ptr noalias noundef nonnull align 8 dereferenceable(32) %21) to label %"_ZN4core3ptr394drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$$RF$uv_normalize..group_name..GroupName$C$$RF$alloc..vec..Vec$LT$uv_pypi_types..dependency_groups..DependencyGroupSpecifier$GT$$C$alloc..vec..into_iter..IntoIter$LT$$LP$$RF$uv_normalize..group_name..GroupName$C$$RF$alloc..vec..Vec$LT$uv_pypi_types..dependency_groups..DependencyGroupSpecifier$GT$$RP$$GT$$GT$$GT$17hbc6dc456d0a58d0fE.exit" unwind label %170 @@ -11992,37 +11992,28 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %64, ptr nonnull align 8 %63, i64 %62, i1 false), !alias.scope !1824, !noalias !1818 %65 = add nuw nsw i64 %57, 1 %66 = sub nuw nsw i64 %56, %65 - %67 = add nsw i64 %52, -1 - %68 = icmp eq i64 %66, %67 - br i1 %68, label %_ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i, label %.noexc24, !prof !118 - -.noexc24: ; preds = %55 - call void @_ZN4core9panicking5panic17had768957450a0f86E(ptr noalias noundef nonnull readonly align 1 @anon.da1773f9f01d35596722567e5203ba96.20, i64 noundef 40, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.da1773f9f01d35596722567e5203ba96.21) #28 - unreachable - -_ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; preds = %55 - %69 = getelementptr inbounds nuw i8, ptr %42, i64 8 - %70 = getelementptr inbounds nuw ptr, ptr %69, i64 %65 - %71 = shl nuw nsw i64 %66, 3 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %59, ptr nonnull readonly align 8 %70, i64 %71, i1 false), !alias.scope !1827, !noalias !1818 - %72 = getelementptr inbounds nuw i8, ptr %42, i64 96 - %73 = getelementptr inbounds nuw ptr, ptr %72, i64 %65 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %63, ptr nonnull readonly align 8 %73, i64 %71, i1 false), !alias.scope !1831, !noalias !1818 - %74 = getelementptr inbounds nuw ptr, ptr %69, i64 %57 - %75 = load ptr, ptr %74, align 8, !noalias !1818, !nonnull !12, !align !1835, !noundef !12 - %76 = getelementptr inbounds nuw ptr, ptr %72, i64 %57 - %77 = load ptr, ptr %76, align 8, !noalias !1818, !nonnull !12, !align !1835, !noundef !12 - %78 = getelementptr ptr, ptr %.sroa.03.010.i, i64 %38 - %79 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 96 - %80 = getelementptr inbounds nuw ptr, ptr %79, i64 %39 - %81 = load ptr, ptr %78, align 8, !noalias !1836, !nonnull !12, !align !1835, !noundef !12 - store ptr %75, ptr %78, align 8, !noalias !1836 - %82 = load ptr, ptr %80, align 8, !noalias !1836, !nonnull !12, !align !1835, !noundef !12 - store ptr %77, ptr %80, align 8, !noalias !1836 - %83 = getelementptr ptr, ptr %46, i64 %52 - store ptr %81, ptr %83, align 8, !noalias !1818 - %84 = getelementptr inbounds nuw ptr, ptr %63, i64 %66 - store ptr %82, ptr %84, align 8, !noalias !1818 + %66 = getelementptr inbounds nuw i8, ptr %42, i64 8 + %67 = getelementptr inbounds nuw ptr, ptr %66, i64 %64 + %68 = shl nuw nsw i64 %65, 3 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %58, ptr nonnull readonly align 8 %67, i64 %68, i1 false), !alias.scope !1827, !noalias !1818 + %69 = getelementptr inbounds nuw i8, ptr %42, i64 96 + %70 = getelementptr inbounds nuw ptr, ptr %69, i64 %64 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %62, ptr nonnull readonly align 8 %70, i64 %68, i1 false), !alias.scope !1831, !noalias !1818 + %71 = getelementptr inbounds nuw ptr, ptr %66, i64 %56 + %72 = load ptr, ptr %71, align 8, !noalias !1818, !nonnull !12, !align !1835, !noundef !12 + %69 = getelementptr inbounds nuw ptr, ptr %69, i64 %56 + %74 = load ptr, ptr %69, align 8, !noalias !1818, !nonnull !12, !align !1835, !noundef !12 + %75 = getelementptr ptr, ptr %.sroa.03.010.i, i64 %38 + %76 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 96 + %72 = getelementptr inbounds nuw ptr, ptr %76, i64 %39 + %78 = load ptr, ptr %75, align 8, !noalias !1836, !nonnull !12, !align !1835, !noundef !12 + store ptr %72, ptr %75, align 8, !noalias !1836 + %79 = load ptr, ptr %77, align 8, !noalias !1836, !nonnull !12, !align !1835, !noundef !12 + store ptr %74, ptr %77, align 8, !noalias !1836 + %76 = getelementptr ptr, ptr %46, i64 %52 + store ptr %78, ptr %76, align 8, !noalias !1818 + %78 = getelementptr inbounds nuw ptr, ptr %63, i64 %65 + store ptr %79, ptr %81, align 8, !noalias !1818 %cond.i = icmp eq i64 %43, 0 br i1 %cond.i, label %"_ZN5alloc11collections5btree3fix178_$LT$impl$u20$alloc..collections..btree..node..NodeRef$LT$alloc..collections..btree..node..marker..Owned$C$K$C$V$C$alloc..collections..btree..node..marker..LeafOrInternal$GT$$GT$29fix_right_border_of_plentiful17h6559e50415a2b255E.exit", label %85 @@ -12038,7 +12029,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; br label %92 92: ; preds = %92, %85 - %.sroa.0.05.i.i.i = phi i64 [ 0, %85 ], [ %93, %92 ] + %.sroa.0.05.i.i.i = phi i64 [ 0, %82 ], [ %93, %89 ] %93 = add nuw nsw i64 %.sroa.0.05.i.i.i, 1 %94 = getelementptr inbounds nuw ptr, ptr %86, i64 %.sroa.0.05.i.i.i %95 = load ptr, ptr %94, align 8, !noalias !1847, !nonnull !12, !noundef !12 @@ -12053,8 +12044,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; ret void .preheader: ; preds = %30, %100 - %.sroa.5.0 = phi i64 [ %101, %100 ], [ 0, %30 ] - %.sroa.02.0 = phi ptr [ %98, %100 ], [ %.sroa.0.0, %30 ] + %.sroa.5.0 = phi i64 [ %101, %97 ], [ 0, %30 ] + %.sroa.02.0 = phi ptr [ %98, %97 ], [ %.sroa.0.0, %30 ] %98 = load ptr, ptr %.sroa.02.0, align 8, !noalias !1853, !noundef !12 %99 = icmp eq ptr %98, null br i1 %99, label %105, label %100 @@ -12105,7 +12096,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; br label %111 111: ; preds = %.loopexit.split-lp66, %.loopexit65 - %lpad.phi69 = phi { ptr, i32 } [ %lpad.loopexit67, %.loopexit65 ], [ %lpad.loopexit.split-lp68, %.loopexit.split-lp66 ] + %lpad.phi69 = phi { ptr, i32 } [ %lpad.loopexit67, %.loopexit64 ], [ %lpad.loopexit.split-lp68, %.loopexit.split-lp65 ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17h10aeed2765f7de5aE"(ptr noalias noundef nonnull align 1 %4) to label %.body unwind label %112, !noalias !1856 @@ -12130,11 +12121,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; br label %.loopexit64 .loopexit64: ; preds = %100, %114 - %.sroa.046.0 = phi ptr [ %108, %114 ], [ %98, %100 ] - %.sroa.647.0 = phi i64 [ %117, %114 ], [ %101, %100 ] + %.sroa.046.0 = phi ptr [ %108, %111 ], [ %98, %97 ] + %.sroa.647.0 = phi i64 [ %117, %111 ], [ %101, %97 ] %119 = add i64 %.sroa.647.0, -1 %120 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17hae02ac83cccb13b8E.llvm.25249479008257743"() - to label %.noexc26 unwind label %.loopexit70 + to label %.noexc25 unwind label %.loopexit70 .noexc26: ; preds = %.loopexit64 %121 = icmp eq ptr %120, null @@ -12142,7 +12133,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; 122: ; preds = %.noexc26 invoke void @_ZN5alloc5alloc18handle_alloc_error17he572ac0a571405f2E(i64 noundef 8, i64 noundef 192) #28 - to label %.noexc27 unwind label %.loopexit.split-lp71 + to label %.noexc26 unwind label %.loopexit.split-lp71 .noexc27: ; preds = %122 unreachable @@ -12155,7 +12146,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; br i1 %.not, label %._crit_edge, label %.lr.ph ._crit_edge: ; preds = %_ZN5alloc11collections5btree3mem7replace17h6dda342b2a939153E.exit40, %123 - %.sroa.052.0.lcssa = phi ptr [ %120, %123 ], [ %154, %_ZN5alloc11collections5btree3mem7replace17h6dda342b2a939153E.exit40 ] + %.sroa.052.0.lcssa = phi ptr [ %120, %120 ], [ %154, %_ZN5alloc11collections5btree3mem7replace17h6dda342b2a939153E.exit39 ] %125 = getelementptr inbounds nuw i8, ptr %.sroa.046.0, i64 186 %126 = load i16, ptr %125, align 2, !noalias !1867, !noundef !12 %127 = icmp ult i16 %126, 11 @@ -12163,7 +12154,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; 128: ; preds = %._crit_edge invoke void @_ZN4core9panicking5panic17had768957450a0f86E(ptr noalias noundef nonnull readonly align 1 @anon.da1773f9f01d35596722567e5203ba96.15.llvm.8974332646872837442, i64 noundef 32, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.da1773f9f01d35596722567e5203ba96.19) #28 - to label %.noexc29 unwind label %.loopexit.split-lp71 + to label %.noexc28 unwind label %.loopexit.split-lp71 .noexc29: ; preds = %128 unreachable @@ -12190,8 +12181,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; br i1 %141, label %.loopexit, label %.lr.ph.i30 .lr.ph.i30: ; preds = %129, %.lr.ph.i30 - %.sroa.03.06.i31 = phi i64 [ %149, %.lr.ph.i30 ], [ %.sroa.647.0, %129 ] - %.sroa.04.05.i32 = phi ptr [ %148, %.lr.ph.i30 ], [ %.sroa.046.0, %129 ] + %.sroa.03.06.i31 = phi i64 [ %149, %.lr.ph.i29 ], [ %.sroa.647.0, %126 ] + %.sroa.04.05.i32 = phi ptr [ %148, %.lr.ph.i29 ], [ %.sroa.046.0, %126 ] %142 = getelementptr inbounds nuw i8, ptr %.sroa.04.05.i32, i64 186 %143 = load i16, ptr %142, align 2, !noalias !1874, !noundef !12 %144 = zext nneg i16 %143 to i64 @@ -12205,18 +12196,18 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; br i1 %150, label %.loopexit, label %.lr.ph.i30 .loopexit: ; preds = %.lr.ph.i30, %129, %163 - %.sroa.0.1 = phi ptr [ %.sroa.0.0, %163 ], [ %.sroa.046.0, %129 ], [ %148, %.lr.ph.i30 ] + %.sroa.0.1 = phi ptr [ %.sroa.0.0, %160 ], [ %.sroa.046.0, %126 ], [ %148, %.lr.ph.i29 ] %151 = load i64, ptr %2, align 8, !noundef !12 %152 = add i64 %151, 1 store i64 %152, ptr %2, align 8 br label %19 .lr.ph: ; preds = %123, %_ZN5alloc11collections5btree3mem7replace17h6dda342b2a939153E.exit40 - %.sroa.04.085 = phi i64 [ %153, %_ZN5alloc11collections5btree3mem7replace17h6dda342b2a939153E.exit40 ], [ 0, %123 ] - %.sroa.052.083 = phi ptr [ %154, %_ZN5alloc11collections5btree3mem7replace17h6dda342b2a939153E.exit40 ], [ %120, %123 ] + %.sroa.04.085 = phi i64 [ %153, %_ZN5alloc11collections5btree3mem7replace17h6dda342b2a939153E.exit39 ], [ 0, %120 ] + %.sroa.052.083 = phi ptr [ %154, %_ZN5alloc11collections5btree3mem7replace17h6dda342b2a939153E.exit39 ], [ %120, %120 ] %153 = add nuw i64 %.sroa.04.085, 1 %154 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17h391f63560645abe9E.llvm.25249479008257743"() - to label %.noexc.i36 unwind label %.loopexit63, !noalias !1880 + to label %.noexc.i35 unwind label %.loopexit63, !noalias !1880 .noexc.i36: ; preds = %.lr.ph %155 = icmp eq ptr %154, null @@ -12224,7 +12215,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; 156: ; preds = %.noexc.i36 invoke void @_ZN5alloc5alloc18handle_alloc_error17he572ac0a571405f2E(i64 noundef 8, i64 noundef 288) #28 - to label %.noexc1.i37 unwind label %.loopexit.split-lp, !noalias !1880 + to label %.noexc1.i36 unwind label %.loopexit.split-lp, !noalias !1880 .noexc1.i37: ; preds = %156 unreachable @@ -12240,7 +12231,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17heb546469a5e741cdE.exit.i.i: ; br label %157 157: ; preds = %.loopexit.split-lp, %.loopexit63 - %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit63 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] + %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit62 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17h10aeed2765f7de5aE"(ptr noalias noundef nonnull align 1 %4) to label %.body unwind label %158, !noalias !1880 diff --git a/bench/uv-rs/optimized/cd91bxdrbjyy0s7hgoreg00sd.ll b/bench/uv-rs/optimized/cd91bxdrbjyy0s7hgoreg00sd.ll index 64059d81340..8814353c6e0 100644 --- a/bench/uv-rs/optimized/cd91bxdrbjyy0s7hgoreg00sd.ll +++ b/bench/uv-rs/optimized/cd91bxdrbjyy0s7hgoreg00sd.ll @@ -13,8 +13,6 @@ target triple = "x86_64-unknown-linux-gnu" @anon.87d71366d4923eef96f1594b0a0401ec.38 = private unnamed_addr constant <{ [48 x i8] }> <{ [48 x i8] c"assertion failed: edge.height == self.height - 1" }>, align 1 @anon.87d71366d4923eef96f1594b0a0401ec.39 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.87d71366d4923eef96f1594b0a0401ec.34.llvm.13776314953183602680, [16 x i8] c"[\00\00\00\00\00\00\00\AD\02\00\00\09\00\00\00" }>, align 8 @anon.87d71366d4923eef96f1594b0a0401ec.40 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.87d71366d4923eef96f1594b0a0401ec.34.llvm.13776314953183602680, [16 x i8] c"[\00\00\00\00\00\00\00\B1\02\00\00\09\00\00\00" }>, align 8 -@anon.87d71366d4923eef96f1594b0a0401ec.41 = private unnamed_addr constant <{ [40 x i8] }> <{ [40 x i8] c"assertion failed: src.len() == dst.len()" }>, align 1 -@anon.87d71366d4923eef96f1594b0a0401ec.42 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.87d71366d4923eef96f1594b0a0401ec.34.llvm.13776314953183602680, [16 x i8] c"[\00\00\00\00\00\00\00J\07\00\00\05\00\00\00" }>, align 8 @anon.87d71366d4923eef96f1594b0a0401ec.47 = private unnamed_addr constant <{ [39 x i8] }> <{ [39 x i8] c"assertion failed: old_left_len >= count" }>, align 1 @anon.87d71366d4923eef96f1594b0a0401ec.48 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.87d71366d4923eef96f1594b0a0401ec.34.llvm.13776314953183602680, [16 x i8] c"[\00\00\00\00\00\00\00\F8\05\00\00\0D\00\00\00" }>, align 8 @anon.87d71366d4923eef96f1594b0a0401ec.53 = private unnamed_addr constant <{ [5 x i8] }> <{ [5 x i8] c"Empty" }>, align 1 @@ -2273,12 +2271,12 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. br label %24 24: ; preds = %.loopexit, %.loopexit80 - %.sroa.0.063 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit80 ], [ %.sroa.0.1, %.loopexit ] + %.sroa.0.063 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit79 ], [ %.sroa.0.1, %.loopexit ] invoke void @"_ZN137_$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$K$C$V$C$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h661601749f192570E"(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %9, ptr noalias noundef nonnull align 8 dereferenceable(56) %10) to label %27 unwind label %25 .body22: ; preds = %133, %174, %25 - %.pn = phi { ptr, i32 } [ %eh.lpad-body26.ph, %174 ], [ %26, %25 ], [ %134, %133 ] + %.pn = phi { ptr, i32 } [ %eh.lpad-body26.ph, %171 ], [ %26, %25 ], [ %134, %130 ] invoke void @"_ZN4core3ptr435drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$std..path..PathBuf$C$alloc..collections..btree..set_val..SetValZST$C$core..iter..adapters..map..Map$LT$alloc..vec..into_iter..IntoIter$LT$std..path..PathBuf$GT$$C$alloc..collections..btree..set..BTreeSet$LT$std..path..PathBuf$GT$..from_sorted_iter$LT$alloc..vec..into_iter..IntoIter$LT$std..path..PathBuf$GT$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$$GT$$GT$17h67baa16c56356c1cE"(ptr noalias noundef nonnull align 8 dereferenceable(56) %10) #31 to label %.body unwind label %175 @@ -2412,25 +2410,16 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %76, ptr nonnull align 8 %75, i64 %77, i1 false), !alias.scope !263, !noalias !260 %78 = add nuw nsw i64 %73, 1 %79 = sub nuw nsw i64 %72, %78 - %80 = add nsw i64 %67, -1 - %81 = icmp eq i64 %79, %80 - br i1 %81, label %_ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i, label %.noexc21, !prof !120 - -.noexc21: ; preds = %71 - call void @_ZN4core9panicking5panic17had768957450a0f86E(ptr noalias noundef nonnull readonly align 1 @anon.87d71366d4923eef96f1594b0a0401ec.41, i64 noundef 40, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.87d71366d4923eef96f1594b0a0401ec.42) #34 - unreachable - -_ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; preds = %71 - %82 = getelementptr inbounds nuw i8, ptr %57, i64 8 - %83 = getelementptr inbounds nuw { [3 x i64] }, ptr %82, i64 %78 - %84 = mul nuw nsw i64 %79, 24 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %75, ptr nonnull readonly align 8 %83, i64 %84, i1 false), !alias.scope !266, !noalias !260 - %85 = getelementptr inbounds nuw { [3 x i64] }, ptr %82, i64 %73 - %86 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 8 - %87 = getelementptr inbounds nuw { [3 x i64] }, ptr %86, i64 %54 + %79 = getelementptr inbounds nuw i8, ptr %57, i64 8 + %80 = getelementptr inbounds nuw { [3 x i64] }, ptr %79, i64 %78 + %81 = mul nuw nsw i64 %78, 24 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %74, ptr nonnull readonly align 8 %80, i64 %81, i1 false), !alias.scope !266, !noalias !260 + %82 = getelementptr inbounds nuw { [3 x i64] }, ptr %79, i64 %72 + %83 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 8 + %84 = getelementptr inbounds nuw { [3 x i64] }, ptr %83, i64 %54 call void @llvm.lifetime.start.p0(ptr nonnull %5) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %87, i64 24, i1 false), !noalias !260 - call void @llvm.memmove.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %87, ptr noundef nonnull align 8 dereferenceable(24) %85, i64 24, i1 false), !noalias !260 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %84, i64 24, i1 false), !noalias !260 + call void @llvm.memmove.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %84, ptr noundef nonnull align 8 dereferenceable(24) %82, i64 24, i1 false), !noalias !260 %88 = getelementptr inbounds nuw { [3 x i64] }, ptr %75, i64 %79 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %88, ptr noundef nonnull align 8 dereferenceable(24) %5, i64 24, i1 false), !noalias !260 call void @llvm.lifetime.end.p0(ptr nonnull %5) @@ -2450,7 +2439,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; br label %97 97: ; preds = %97, %89 - %.sroa.0.05.i.i.i = phi i64 [ 0, %89 ], [ %98, %97 ] + %.sroa.0.05.i.i.i = phi i64 [ 0, %86 ], [ %98, %94 ] %98 = add nuw nsw i64 %.sroa.0.05.i.i.i, 1 %99 = getelementptr inbounds nuw ptr, ptr %90, i64 %.sroa.0.05.i.i.i %100 = load ptr, ptr %99, align 8, !noalias !277, !nonnull !3, !noundef !3 @@ -2465,8 +2454,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; ret void .preheader: ; preds = %45, %105 - %.sroa.5.0 = phi i64 [ %106, %105 ], [ 0, %45 ] - %.sroa.0.0 = phi ptr [ %103, %105 ], [ %.sroa.0.063, %45 ] + %.sroa.5.0 = phi i64 [ %106, %102 ], [ 0, %45 ] + %.sroa.0.0 = phi ptr [ %103, %102 ], [ %.sroa.0.063, %45 ] %103 = load ptr, ptr %.sroa.0.0, align 8, !noalias !283, !noundef !3 %104 = icmp eq ptr %103, null br i1 %104, label %110, label %105 @@ -2517,9 +2506,9 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; br label %116 116: ; preds = %.loopexit.split-lp71, %.loopexit70 - %lpad.phi74 = phi { ptr, i32 } [ %lpad.loopexit72, %.loopexit70 ], [ %lpad.loopexit.split-lp73, %.loopexit.split-lp71 ] + %lpad.phi74 = phi { ptr, i32 } [ %lpad.loopexit72, %.loopexit69 ], [ %lpad.loopexit.split-lp73, %.loopexit.split-lp70 ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17h10aeed2765f7de5aE"(ptr noalias noundef nonnull align 1 %4) - to label %174 unwind label %117, !noalias !286 + to label %171 unwind label %117, !noalias !286 117: ; preds = %116 %118 = landingpad { ptr, i32 } @@ -2542,11 +2531,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; br label %.loopexit69 .loopexit69: ; preds = %105, %119 - %.sroa.047.0 = phi ptr [ %113, %119 ], [ %103, %105 ] - %.sroa.648.0 = phi i64 [ %122, %119 ], [ %106, %105 ] + %.sroa.047.0 = phi ptr [ %113, %116 ], [ %103, %102 ] + %.sroa.648.0 = phi i64 [ %122, %116 ], [ %106, %102 ] %124 = add i64 %.sroa.648.0, -1 %125 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17h5e870dbda49dc12eE.llvm.14237793921444769281"() - to label %.noexc27 unwind label %.loopexit75 + to label %.noexc26 unwind label %.loopexit75 .noexc27: ; preds = %.loopexit69 %126 = icmp eq ptr %125, null @@ -2554,7 +2543,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; 127: ; preds = %.noexc27 invoke void @_ZN5alloc5alloc18handle_alloc_error17he572ac0a571405f2E(i64 noundef 8, i64 noundef 280) #34 - to label %.noexc28 unwind label %.loopexit.split-lp76 + to label %.noexc27 unwind label %.loopexit.split-lp76 .noexc28: ; preds = %127 unreachable @@ -2574,7 +2563,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; unreachable .loopexit111: ; preds = %_ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit43, %128 - %.sroa.053.0.lcssa = phi ptr [ %125, %128 ], [ %160, %_ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit43 ] + %.sroa.053.0.lcssa = phi ptr [ %125, %125 ], [ %160, %_ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit42 ] call void @llvm.lifetime.start.p0(ptr nonnull %7) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %9, i64 24, i1 false) %130 = getelementptr inbounds nuw i8, ptr %.sroa.047.0, i64 274 @@ -2586,7 +2575,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; %134 = landingpad { ptr, i32 } cleanup invoke void @"_ZN4core3ptr39drop_in_place$LT$std..path..PathBuf$GT$17h1d12f4ff3d9ce15bE"(ptr noalias noundef nonnull align 8 dereferenceable(24) %7) #31 - to label %.body22 unwind label %135 + to label %.body21 unwind label %135 135: ; preds = %133 %136 = landingpad { ptr, i32 } @@ -2614,8 +2603,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; br i1 %147, label %.loopexit, label %.lr.ph.i32 .lr.ph.i32: ; preds = %137, %.lr.ph.i32 - %.sroa.03.06.i33 = phi i64 [ %155, %.lr.ph.i32 ], [ %.sroa.648.0, %137 ] - %.sroa.04.05.i34 = phi ptr [ %154, %.lr.ph.i32 ], [ %.sroa.047.0, %137 ] + %.sroa.03.06.i33 = phi i64 [ %155, %.lr.ph.i31 ], [ %.sroa.648.0, %134 ] + %.sroa.04.05.i34 = phi ptr [ %154, %.lr.ph.i31 ], [ %.sroa.047.0, %134 ] %148 = getelementptr inbounds nuw i8, ptr %.sroa.04.05.i34, i64 274 %149 = load i16, ptr %148, align 2, !noalias !303, !noundef !3 %150 = zext nneg i16 %149 to i64 @@ -2629,7 +2618,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; br i1 %156, label %.loopexit, label %.lr.ph.i32 .loopexit: ; preds = %.lr.ph.i32, %137, %169 - %.sroa.0.1 = phi ptr [ %.sroa.0.063, %169 ], [ %.sroa.047.0, %137 ], [ %154, %.lr.ph.i32 ] + %.sroa.0.1 = phi ptr [ %.sroa.0.063, %166 ], [ %.sroa.047.0, %134 ], [ %154, %.lr.ph.i31 ] %157 = load i64, ptr %2, align 8, !noundef !3 %158 = add i64 %157, 1 store i64 %158, ptr %2, align 8 @@ -2637,11 +2626,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; br label %24 .lr.ph: ; preds = %128, %_ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit43 - %.sroa.02.090 = phi i64 [ %159, %_ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit43 ], [ 0, %128 ] - %.sroa.053.088 = phi ptr [ %160, %_ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit43 ], [ %125, %128 ] + %.sroa.02.090 = phi i64 [ %159, %_ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit42 ], [ 0, %125 ] + %.sroa.053.088 = phi ptr [ %160, %_ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit42 ], [ %125, %125 ] %159 = add nuw i64 %.sroa.02.090, 1 %160 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17h8c84883ef03924a3E.llvm.14237793921444769281"() - to label %.noexc.i38 unwind label %.loopexit68, !noalias !309 + to label %.noexc.i37 unwind label %.loopexit68, !noalias !309 .noexc.i38: ; preds = %.lr.ph %161 = icmp eq ptr %160, null @@ -2649,7 +2638,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; 162: ; preds = %.noexc.i38 invoke void @_ZN5alloc5alloc18handle_alloc_error17he572ac0a571405f2E(i64 noundef 8, i64 noundef 376) #34 - to label %.noexc1.i39 unwind label %.loopexit.split-lp, !noalias !309 + to label %.noexc1.i38 unwind label %.loopexit.split-lp, !noalias !309 .noexc1.i39: ; preds = %162 unreachable @@ -2665,9 +2654,9 @@ _ZN5alloc11collections5btree4node13move_to_slice17h8a5e49b51272f2b7E.exit.i.i: ; br label %163 163: ; preds = %.loopexit.split-lp, %.loopexit68 - %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit68 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] + %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit67 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17h10aeed2765f7de5aE"(ptr noalias noundef nonnull align 1 %4) - to label %174 unwind label %164, !noalias !309 + to label %171 unwind label %164, !noalias !309 164: ; preds = %163 %165 = landingpad { ptr, i32 } @@ -2697,9 +2686,9 @@ _ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit43: ; preds = % br label %.loopexit 174: ; preds = %.loopexit75, %.loopexit.split-lp76, %116, %163 - %eh.lpad-body26.ph = phi { ptr, i32 } [ %lpad.phi74, %116 ], [ %lpad.phi, %163 ], [ %lpad.loopexit77, %.loopexit75 ], [ %lpad.loopexit.split-lp78, %.loopexit.split-lp76 ] + %eh.lpad-body26.ph = phi { ptr, i32 } [ %lpad.phi74, %113 ], [ %lpad.phi, %160 ], [ %lpad.loopexit77, %.loopexit74 ], [ %lpad.loopexit.split-lp78, %.loopexit.split-lp75 ] invoke void @"_ZN4core3ptr39drop_in_place$LT$std..path..PathBuf$GT$17h1d12f4ff3d9ce15bE"(ptr noalias noundef nonnull align 8 dereferenceable(24) %8) #31 - to label %.body22 unwind label %175 + to label %.body21 unwind label %175 175: ; preds = %174, %.body22 %176 = landingpad { ptr, i32 } @@ -2708,7 +2697,7 @@ _ZN5alloc11collections5btree3mem7replace17heb2315a8c7a47dcdE.exit43: ; preds = % unreachable .body: ; preds = %.body22, %32 - %.pn9 = phi { ptr, i32 } [ %.pn, %.body22 ], [ %33, %32 ] + %.pn9 = phi { ptr, i32 } [ %.pn, %.body21 ], [ %33, %32 ] resume { ptr, i32 } %.pn9 } diff --git a/bench/wasmi-rs/optimized/apu427tbl3luqie4ryqrtwt7n.ll b/bench/wasmi-rs/optimized/apu427tbl3luqie4ryqrtwt7n.ll index 76ab2083a93..bc1b62260b0 100644 --- a/bench/wasmi-rs/optimized/apu427tbl3luqie4ryqrtwt7n.ll +++ b/bench/wasmi-rs/optimized/apu427tbl3luqie4ryqrtwt7n.ll @@ -5414,15 +5414,15 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. br label %23 23: ; preds = %.loopexit, %.loopexit68 - %.sroa.0.062 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit68 ], [ %.sroa.0.1, %.loopexit ] + %.sroa.0.062 = phi ptr [ %.sroa.04.0.lcssa.i, %.loopexit67 ], [ %.sroa.0.1, %.loopexit ] call void @llvm.lifetime.start.p0(ptr nonnull %5) invoke void @"_ZN137_$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$K$C$V$C$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h9976c62c67a5f3aeE"(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %5, ptr noalias noundef nonnull align 8 dereferenceable(56) %6) to label %26 unwind label %24 .body: ; preds = %194, %192, %146, %143, %24 - %.pn = phi { ptr, i32 } [ %25, %24 ], [ %144, %143 ], [ %144, %146 ], [ %eh.lpad-body25.ph, %192 ], [ %eh.lpad-body25.ph, %194 ] + %.pn = phi { ptr, i32 } [ %25, %24 ], [ %144, %140 ], [ %144, %143 ], [ %eh.lpad-body25.ph, %189 ], [ %eh.lpad-body24.ph, %191 ] invoke void @"_ZN4core3ptr266drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$alloc..boxed..Box$LT$str$GT$$C$wasmi..module..export..ExternIdx$C$alloc..vec..into_iter..IntoIter$LT$$LP$alloc..boxed..Box$LT$str$GT$$C$wasmi..module..export..ExternIdx$RP$$GT$$GT$$GT$17h1335b101281c380bE"(ptr noalias noundef nonnull align 8 dereferenceable(56) %6) #21 - to label %197 unwind label %195 + to label %194 unwind label %195 24: ; preds = %23 %25 = landingpad { ptr, i32 } @@ -5515,51 +5515,42 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. call void @llvm.memmove.p0.p0.i64(ptr nonnull align 4 %65, ptr nonnull align 4 %64, i64 %66, i1 false), !alias.scope !1075, !noalias !1069 %67 = add nuw nsw i64 %60, 1 %68 = sub nuw nsw i64 %58, %67 - %69 = add nsw i64 %54, -1 - %70 = icmp eq i64 %68, %69 - br i1 %70, label %_ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i, label %.noexc21, !prof !4 - -.noexc21: ; preds = %57 - call void @_ZN4core9panicking5panic17h13ee8adf815f0d87E(ptr noalias noundef nonnull readonly align 1 @anon.6067d76e8933c42764495b1ece5cceb0.24, i64 noundef 40, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.6067d76e8933c42764495b1ece5cceb0.25) #20 - unreachable - -_ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; preds = %57 - %71 = getelementptr inbounds nuw { [2 x i64] }, ptr %44, i64 %67 - %72 = shl nuw nsw i64 %68, 4 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %48, ptr nonnull readonly align 8 %71, i64 %72, i1 false), !alias.scope !1078, !noalias !1069 - %73 = getelementptr inbounds nuw i8, ptr %44, i64 184 - %74 = getelementptr inbounds nuw { [2 x i32] }, ptr %73, i64 %67 - %75 = shl nuw nsw i64 %68, 3 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 4 %64, ptr nonnull readonly align 4 %74, i64 %75, i1 false), !alias.scope !1082, !noalias !1069 - %76 = getelementptr inbounds nuw { [2 x i64] }, ptr %44, i64 %60 - %77 = load ptr, ptr %76, align 8, !noalias !1069, !nonnull !3, !align !12, !noundef !3 - %78 = getelementptr inbounds nuw i8, ptr %76, i64 8 - %79 = load i64, ptr %78, align 8, !noalias !1069, !noundef !3 - %80 = getelementptr inbounds nuw { [2 x i32] }, ptr %73, i64 %60 - %81 = load i32, ptr %80, align 4, !range !1086, !noalias !1069, !noundef !3 - %82 = getelementptr inbounds nuw i8, ptr %80, i64 4 - %83 = load i32, ptr %82, align 4, !noalias !1069, !noundef !3 - %84 = getelementptr inbounds nuw { [2 x i64] }, ptr %.sroa.03.010.i, i64 %41 - %85 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 184 - %86 = getelementptr inbounds nuw { [2 x i32] }, ptr %85, i64 %41 - %87 = load ptr, ptr %84, align 8, !noalias !1087, !nonnull !3, !align !12, !noundef !3 - %88 = getelementptr inbounds nuw i8, ptr %84, i64 8 - %89 = load i64, ptr %88, align 8, !noalias !1087, !noundef !3 - store ptr %77, ptr %84, align 8, !noalias !1087 - store i64 %79, ptr %88, align 8, !noalias !1087 - %90 = load i32, ptr %86, align 4, !range !1086, !noalias !1087, !noundef !3 - %91 = getelementptr inbounds nuw i8, ptr %86, i64 4 - %92 = load i32, ptr %91, align 4, !noalias !1087, !noundef !3 - store i32 %81, ptr %86, align 4, !noalias !1087 - store i32 %83, ptr %91, align 4, !noalias !1087 - %93 = getelementptr inbounds nuw { [2 x i64] }, ptr %48, i64 %68 - store ptr %87, ptr %93, align 8, !noalias !1069 - %94 = getelementptr inbounds nuw i8, ptr %93, i64 8 - store i64 %89, ptr %94, align 8, !noalias !1069 - %95 = getelementptr inbounds nuw { [2 x i32] }, ptr %64, i64 %68 - store i32 %90, ptr %95, align 4, !noalias !1069 - %96 = getelementptr inbounds nuw i8, ptr %95, i64 4 - store i32 %92, ptr %96, align 4, !noalias !1069 + %68 = getelementptr inbounds nuw { [2 x i64] }, ptr %44, i64 %66 + %69 = shl nuw nsw i64 %68, 4 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %48, ptr nonnull readonly align 8 %68, i64 %69, i1 false), !alias.scope !1078, !noalias !1069 + %70 = getelementptr inbounds nuw i8, ptr %44, i64 184 + %71 = getelementptr inbounds nuw { [2 x i32] }, ptr %70, i64 %66 + %72 = shl nuw nsw i64 %67, 3 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 4 %63, ptr nonnull readonly align 4 %71, i64 %72, i1 false), !alias.scope !1082, !noalias !1069 + %73 = getelementptr inbounds nuw { [2 x i64] }, ptr %44, i64 %59 + %74 = load ptr, ptr %73, align 8, !noalias !1069, !nonnull !3, !align !12, !noundef !3 + %71 = getelementptr inbounds nuw i8, ptr %73, i64 8 + %76 = load i64, ptr %75, align 8, !noalias !1069, !noundef !3 + %77 = getelementptr inbounds nuw { [2 x i32] }, ptr %70, i64 %59 + %78 = load i32, ptr %77, align 4, !range !1086, !noalias !1069, !noundef !3 + %74 = getelementptr inbounds nuw i8, ptr %77, i64 4 + %80 = load i32, ptr %79, align 4, !noalias !1069, !noundef !3 + %81 = getelementptr inbounds nuw { [2 x i64] }, ptr %.sroa.03.010.i, i64 %41 + %76 = getelementptr inbounds nuw i8, ptr %.sroa.03.010.i, i64 184 + %83 = getelementptr inbounds nuw { [2 x i32] }, ptr %76, i64 %41 + %84 = load ptr, ptr %81, align 8, !noalias !1087, !nonnull !3, !align !12, !noundef !3 + %85 = getelementptr inbounds nuw i8, ptr %81, i64 8 + %86 = load i64, ptr %85, align 8, !noalias !1087, !noundef !3 + store ptr %74, ptr %81, align 8, !noalias !1087 + store i64 %76, ptr %85, align 8, !noalias !1087 + %83 = load i32, ptr %83, align 4, !range !1086, !noalias !1087, !noundef !3 + %84 = getelementptr inbounds nuw i8, ptr %83, i64 4 + %89 = load i32, ptr %88, align 4, !noalias !1087, !noundef !3 + store i32 %78, ptr %83, align 4, !noalias !1087 + store i32 %80, ptr %84, align 4, !noalias !1087 + %88 = getelementptr inbounds nuw { [2 x i64] }, ptr %48, i64 %68 + store ptr %84, ptr %88, align 8, !noalias !1069 + %91 = getelementptr inbounds nuw i8, ptr %88, i64 8 + store i64 %86, ptr %91, align 8, !noalias !1069 + %92 = getelementptr inbounds nuw { [2 x i32] }, ptr %63, i64 %67 + store i32 %87, ptr %92, align 4, !noalias !1069 + %93 = getelementptr inbounds nuw i8, ptr %92, i64 4 + store i32 %89, ptr %93, align 4, !noalias !1069 %cond.i = icmp eq i64 %45, 0 br i1 %cond.i, label %"_ZN5alloc11collections5btree3fix178_$LT$impl$u20$alloc..collections..btree..node..NodeRef$LT$alloc..collections..btree..node..marker..Owned$C$K$C$V$C$alloc..collections..btree..node..marker..LeafOrInternal$GT$$GT$29fix_right_border_of_plentiful17hadee3f7b929347ffE.exit", label %97 @@ -5575,7 +5566,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; br label %104 104: ; preds = %104, %97 - %.sroa.0.06.i.i.i = phi i64 [ 0, %97 ], [ %105, %104 ] + %.sroa.0.06.i.i.i = phi i64 [ 0, %94 ], [ %105, %101 ] %105 = add nuw nsw i64 %.sroa.0.06.i.i.i, 1 %106 = getelementptr inbounds nuw ptr, ptr %98, i64 %.sroa.0.06.i.i.i %107 = load ptr, ptr %106, align 8, !noalias !1098, !nonnull !3, !noundef !3 @@ -5591,8 +5582,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; ret void .preheader: ; preds = %28, %115 - %.sroa.5.0 = phi i64 [ %116, %115 ], [ 0, %28 ] - %.sroa.0.0 = phi ptr [ %112, %115 ], [ %.sroa.0.062, %28 ] + %.sroa.5.0 = phi i64 [ %116, %112 ], [ 0, %28 ] + %.sroa.0.0 = phi ptr [ %112, %112 ], [ %.sroa.0.062, %28 ] %111 = getelementptr inbounds nuw i8, ptr %.sroa.0.0, i64 176 %112 = load ptr, ptr %111, align 8, !noalias !1104, !noundef !3 %.not.i22 = icmp eq ptr %112, null @@ -5615,13 +5606,13 @@ _ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; %121 = load ptr, ptr %0, align 8, !alias.scope !1107, !nonnull !3, !noundef !3 %122 = load i64, ptr %7, align 8, !alias.scope !1107, !noundef !3 %123 = invoke noundef nonnull align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$13new_uninit_in17h1fac1c440793f403E"() - to label %128 unwind label %124, !noalias !1107 + to label %125 unwind label %124, !noalias !1107 124: ; preds = %120 %125 = landingpad { ptr, i32 } cleanup invoke void @"_ZN4core3ptr72drop_in_place$LT$alloc..collections..btree..mem..replace..PanicGuard$GT$17h0ab9888a99b91661E"(ptr noalias noundef nonnull align 1 %4) #21 - to label %192 unwind label %126, !noalias !1107 + to label %189 unwind label %126, !noalias !1107 126: ; preds = %124 %127 = landingpad { ptr, i32 } @@ -5646,11 +5637,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; br label %.loopexit67 .loopexit67: ; preds = %115, %128 - %.sroa.046.0 = phi ptr [ %123, %128 ], [ %112, %115 ] - %.sroa.647.0 = phi i64 [ %132, %128 ], [ %116, %115 ] + %.sroa.046.0 = phi ptr [ %123, %125 ], [ %112, %112 ] + %.sroa.647.0 = phi i64 [ %132, %125 ], [ %116, %112 ] %135 = add i64 %.sroa.647.0, -1 %136 = invoke noundef nonnull align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$13new_uninit_in17hfc8a0faa91227dfaE"() - to label %137 unwind label %113 + to label %134 unwind label %113 137: ; preds = %.loopexit67 %138 = getelementptr inbounds nuw i8, ptr %136, i64 176 @@ -5668,7 +5659,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; unreachable ._crit_edge: ; preds = %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit38, %137 - %.sroa.052.0.lcssa = phi ptr [ %136, %137 ], [ %173, %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit38 ] + %.sroa.052.0.lcssa = phi ptr [ %136, %134 ], [ %173, %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit37 ] %140 = getelementptr inbounds nuw i8, ptr %.sroa.046.0, i64 274 %141 = load i16, ptr %140, align 2, !noalias !1118, !noundef !3 %142 = icmp ult i16 %141, 11 @@ -5710,8 +5701,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; br i1 %161, label %.loopexit, label %.lr.ph.i30 .lr.ph.i30: ; preds = %147, %.lr.ph.i30 - %.sroa.03.06.i31 = phi i64 [ %169, %.lr.ph.i30 ], [ %.sroa.647.0, %147 ] - %.sroa.04.05.i32 = phi ptr [ %168, %.lr.ph.i30 ], [ %.sroa.046.0, %147 ] + %.sroa.03.06.i31 = phi i64 [ %169, %.lr.ph.i29 ], [ %.sroa.647.0, %144 ] + %.sroa.04.05.i32 = phi ptr [ %168, %.lr.ph.i29 ], [ %.sroa.046.0, %144 ] %162 = getelementptr inbounds nuw i8, ptr %.sroa.04.05.i32, i64 274 %163 = load i16, ptr %162, align 2, !noalias !1124, !noundef !3 %164 = zext nneg i16 %163 to i64 @@ -5725,7 +5716,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; br i1 %170, label %.loopexit, label %.lr.ph.i30 .loopexit: ; preds = %.lr.ph.i30, %147, %184 - %.sroa.0.1 = phi ptr [ %.sroa.0.062, %184 ], [ %.sroa.046.0, %147 ], [ %168, %.lr.ph.i30 ] + %.sroa.0.1 = phi ptr [ %.sroa.0.062, %181 ], [ %.sroa.046.0, %144 ], [ %168, %.lr.ph.i29 ] %171 = load i64, ptr %2, align 8, !noundef !3 %172 = add i64 %171, 1 store i64 %172, ptr %2, align 8 @@ -5733,16 +5724,16 @@ _ZN5alloc11collections5btree4node13move_to_slice17h599b7004fce3b67bE.exit.i.i: ; br label %23 .lr.ph: ; preds = %137, %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit38 - %.sroa.02.084 = phi i64 [ %178, %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit38 ], [ 0, %137 ] - %.sroa.052.082 = phi ptr [ %173, %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit38 ], [ %136, %137 ] + %.sroa.02.084 = phi i64 [ %178, %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit37 ], [ 0, %134 ] + %.sroa.052.082 = phi ptr [ %173, %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit37 ], [ %136, %134 ] %173 = invoke noundef nonnull align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$13new_uninit_in17h1fac1c440793f403E"() - to label %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit38 unwind label %174, !noalias !1130 + to label %_ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit37 unwind label %174, !noalias !1130 174: ; preds = %.lr.ph %175 = landingpad { ptr, i32 } cleanup invoke void @"_ZN4core3ptr72drop_in_place$LT$alloc..collections..btree..mem..replace..PanicGuard$GT$17h0ab9888a99b91661E"(ptr noalias noundef nonnull align 1 %4) #21 - to label %192 unwind label %176, !noalias !1130 + to label %189 unwind label %176, !noalias !1130 176: ; preds = %174 %177 = landingpad { ptr, i32 } @@ -5781,7 +5772,7 @@ _ZN5alloc11collections5btree3mem7replace17h141bca5fc4eee815E.exit38: ; preds = % br label %.loopexit 192: ; preds = %113, %124, %174 - %eh.lpad-body25.ph = phi { ptr, i32 } [ %114, %113 ], [ %125, %124 ], [ %175, %174 ] + %eh.lpad-body25.ph = phi { ptr, i32 } [ %114, %110 ], [ %125, %121 ], [ %175, %171 ] %193 = icmp eq i64 %30, 0 br i1 %193, label %.body, label %194 diff --git a/bench/wasmtime-rs/optimized/3wy7qx4e8fg0rwt0.ll b/bench/wasmtime-rs/optimized/3wy7qx4e8fg0rwt0.ll index 591445d520c..f4a91e29dcc 100644 --- a/bench/wasmtime-rs/optimized/3wy7qx4e8fg0rwt0.ll +++ b/bench/wasmtime-rs/optimized/3wy7qx4e8fg0rwt0.ll @@ -6,8 +6,6 @@ target triple = "x86_64-unknown-linux-gnu" @anon.e2192d190c206e613b03b2b794f0dab7.0 = private unnamed_addr constant <{ [32 x i8] }> <{ [32 x i8] c"assertion failed: idx < CAPACITY" }>, align 1 @anon.e2192d190c206e613b03b2b794f0dab7.1 = private unnamed_addr constant <{ [91 x i8] }> <{ [91 x i8] c"/rustc/25ef9e3d85d934b27d9dada2f9dd52b1dc63bb04/library/alloc/src/collections/btree/node.rs" }>, align 1 @anon.e2192d190c206e613b03b2b794f0dab7.5 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.e2192d190c206e613b03b2b794f0dab7.1, [16 x i8] c"[\00\00\00\00\00\00\00\B3\02\00\00\09\00\00\00" }>, align 8 -@anon.e2192d190c206e613b03b2b794f0dab7.6 = private unnamed_addr constant <{ [40 x i8] }> <{ [40 x i8] c"assertion failed: src.len() == dst.len()" }>, align 1 -@anon.e2192d190c206e613b03b2b794f0dab7.7 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.e2192d190c206e613b03b2b794f0dab7.1, [16 x i8] c"[\00\00\00\00\00\00\00/\07\00\00\05\00\00\00" }>, align 8 @anon.e2192d190c206e613b03b2b794f0dab7.12 = private unnamed_addr constant <{ [39 x i8] }> <{ [39 x i8] c"assertion failed: old_left_len >= count" }>, align 1 @anon.e2192d190c206e613b03b2b794f0dab7.13 = private unnamed_addr constant <{ ptr, [16 x i8] }> <{ ptr @anon.e2192d190c206e613b03b2b794f0dab7.1, [16 x i8] c"[\00\00\00\00\00\00\00\DD\05\00\00\0D\00\00\00" }>, align 8 @anon.e2192d190c206e613b03b2b794f0dab7.16 = private unnamed_addr constant <{ [25 x i8] }> <{ [25 x i8] c"assertion failed: len > 0" }>, align 1 @@ -182,12 +180,12 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. br label %17 17: ; preds = %.loopexit, %.loopexit89 - %.sroa.0.0 = phi ptr [ %.0.lcssa.i, %.loopexit89 ], [ %.sroa.0.1, %.loopexit ] + %.sroa.0.0 = phi ptr [ %.0.lcssa.i, %.loopexit88 ], [ %.sroa.0.1, %.loopexit ] %18 = invoke { ptr, i64 } @"_ZN137_$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$K$C$V$C$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h7b6c917bf726b3a5E"(ptr noalias noundef nonnull align 8 dereferenceable(56) %5) to label %22 unwind label %20 .body: ; preds = %.loopexit84, %.loopexit.split-lp85, %146, %100, %20 - %.pn = phi { ptr, i32 } [ %21, %20 ], [ %lpad.phi83, %100 ], [ %lpad.phi, %146 ], [ %lpad.loopexit86, %.loopexit84 ], [ %lpad.loopexit.split-lp87, %.loopexit.split-lp85 ] + %.pn = phi { ptr, i32 } [ %21, %20 ], [ %lpad.phi83, %97 ], [ %lpad.phi, %143 ], [ %lpad.loopexit86, %.loopexit83 ], [ %lpad.loopexit.split-lp87, %.loopexit.split-lp84 ] %19 = getelementptr inbounds nuw i8, ptr %5, i64 24 invoke void @"_ZN86_$LT$alloc..vec..into_iter..IntoIter$LT$T$C$A$GT$$u20$as$u20$core..ops..drop..Drop$GT$4drop17h1474be6e09f51d6cE.llvm.11266952349742701183"(ptr noalias noundef nonnull align 8 dereferenceable(32) %19) to label %"_ZN4core3ptr391drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$$RF$str$C$alloc..collections..btree..set_val..SetValZST$C$core..iter..adapters..map..Map$LT$alloc..vec..into_iter..IntoIter$LT$$RF$str$GT$$C$alloc..collections..btree..set..BTreeSet$LT$$RF$str$GT$..from_sorted_iter$LT$alloc..vec..into_iter..IntoIter$LT$$RF$str$GT$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$$GT$$GT$17hddfd137dfc274046E.exit" unwind label %159 @@ -277,32 +275,23 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %54, ptr nonnull align 8 %41, i64 %55, i1 false), !noalias !18 %56 = add nuw nsw i64 %52, 1 %57 = sub nuw nsw i64 %51, %56 - %58 = add nsw i64 %46, -1 - %59 = icmp eq i64 %57, %58 - br i1 %59, label %_ZN5alloc11collections5btree4node13move_to_slice17h6ca3caf12adad6f8E.exit.i.i, label %.noexc35 - -.noexc35: ; preds = %50 - call void @_ZN4core9panicking5panic17h44790a89027c670fE(ptr noalias noundef nonnull readonly align 1 @anon.e2192d190c206e613b03b2b794f0dab7.6, i64 noundef 40, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.e2192d190c206e613b03b2b794f0dab7.7) #17 - unreachable - -_ZN5alloc11collections5btree4node13move_to_slice17h6ca3caf12adad6f8E.exit.i.i: ; preds = %50 - %60 = getelementptr inbounds nuw { [2 x i64] }, ptr %37, i64 %56 - %61 = shl nuw nsw i64 %57, 4 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %41, ptr nonnull readonly align 8 %60, i64 %61, i1 false), !alias.scope !21, !noalias !18 - %62 = getelementptr inbounds nuw { [2 x i64] }, ptr %37, i64 %52 - %63 = load ptr, ptr %62, align 8, !noalias !18, !nonnull !7, !align !25, !noundef !7 - %64 = getelementptr inbounds nuw i8, ptr %62, i64 8 - %65 = load i64, ptr %64, align 8, !noalias !18, !noundef !7 - %66 = getelementptr inbounds nuw { [2 x i64] }, ptr %.011.i, i64 %34 - %67 = load ptr, ptr %66, align 8, !noalias !26, !nonnull !7, !align !25, !noundef !7 - %68 = getelementptr inbounds nuw i8, ptr %66, i64 8 - %69 = load i64, ptr %68, align 8, !noalias !26, !noundef !7 - store ptr %63, ptr %66, align 8, !noalias !26 - store i64 %65, ptr %68, align 8, !noalias !26 - %70 = getelementptr inbounds nuw { [2 x i64] }, ptr %41, i64 %57 - store ptr %67, ptr %70, align 8, !noalias !18 - %71 = getelementptr inbounds nuw i8, ptr %70, i64 8 - store i64 %69, ptr %71, align 8, !noalias !18 + %57 = getelementptr inbounds nuw { [2 x i64] }, ptr %37, i64 %56 + %58 = shl nuw nsw i64 %57, 4 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %41, ptr nonnull readonly align 8 %57, i64 %58, i1 false), !alias.scope !21, !noalias !18 + %59 = getelementptr inbounds nuw { [2 x i64] }, ptr %37, i64 %51 + %60 = load ptr, ptr %59, align 8, !noalias !18, !nonnull !7, !align !25, !noundef !7 + %61 = getelementptr inbounds nuw i8, ptr %59, i64 8 + %62 = load i64, ptr %61, align 8, !noalias !18, !noundef !7 + %63 = getelementptr inbounds nuw { [2 x i64] }, ptr %.011.i, i64 %34 + %64 = load ptr, ptr %63, align 8, !noalias !26, !nonnull !7, !align !25, !noundef !7 + %60 = getelementptr inbounds nuw i8, ptr %63, i64 8 + %66 = load i64, ptr %65, align 8, !noalias !26, !noundef !7 + store ptr %60, ptr %63, align 8, !noalias !26 + store i64 %62, ptr %65, align 8, !noalias !26 + %67 = getelementptr inbounds nuw { [2 x i64] }, ptr %41, i64 %57 + store ptr %64, ptr %67, align 8, !noalias !18 + %68 = getelementptr inbounds nuw i8, ptr %67, i64 8 + store i64 %66, ptr %68, align 8, !noalias !18 %cond.i = icmp eq i64 %38, 0 br i1 %cond.i, label %"_ZN5alloc11collections5btree3fix178_$LT$impl$u20$alloc..collections..btree..node..NodeRef$LT$alloc..collections..btree..node..marker..Owned$C$K$C$V$C$alloc..collections..btree..node..marker..LeafOrInternal$GT$$GT$29fix_right_border_of_plentiful17ha554b74d20ac87b1E.exit", label %_ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i @@ -319,7 +308,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; br label %79 79: ; preds = %79, %_ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i - %.sroa.0.05.i.i.i = phi i64 [ 0, %_ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i ], [ %80, %79 ] + %.sroa.0.05.i.i.i = phi i64 [ 0, %_ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i ], [ %80, %76 ] %80 = add nuw nsw i64 %.sroa.0.05.i.i.i, 1 %81 = getelementptr inbounds nuw ptr, ptr %72, i64 %.sroa.0.05.i.i.i %82 = load ptr, ptr %81, align 8, !noalias !18, !nonnull !7, !noundef !7 @@ -335,8 +324,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; ret void .preheader: ; preds = %27, %89 - %.sroa.5.0 = phi i64 [ %90, %89 ], [ 0, %27 ] - %.sroa.04.0 = phi ptr [ %87, %89 ], [ %.sroa.0.0, %27 ] + %.sroa.5.0 = phi i64 [ %90, %86 ], [ 0, %27 ] + %.sroa.04.0 = phi ptr [ %87, %86 ], [ %.sroa.0.0, %27 ] %86 = getelementptr inbounds nuw i8, ptr %.sroa.04.0, i64 176 %87 = load ptr, ptr %86, align 8, !noalias !33, !noundef !7 %88 = icmp eq ptr %87, null @@ -388,7 +377,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; br label %100 100: ; preds = %.loopexit.split-lp80, %.loopexit79 - %lpad.phi83 = phi { ptr, i32 } [ %lpad.loopexit81, %.loopexit79 ], [ %lpad.loopexit.split-lp82, %.loopexit.split-lp80 ] + %lpad.phi83 = phi { ptr, i32 } [ %lpad.loopexit81, %.loopexit78 ], [ %lpad.loopexit.split-lp82, %.loopexit.split-lp79 ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17he7f40e69e6f26b83E"(ptr noalias noundef nonnull align 1 %4) to label %.body unwind label %101, !noalias !36 @@ -415,11 +404,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; br label %.loopexit78 .loopexit78: ; preds = %89, %103 - %.sroa.059.0 = phi ptr [ %97, %103 ], [ %87, %89 ] - %.sroa.660.0 = phi i64 [ %107, %103 ], [ %90, %89 ] + %.sroa.059.0 = phi ptr [ %97, %100 ], [ %87, %86 ] + %.sroa.660.0 = phi i64 [ %107, %100 ], [ %90, %86 ] %110 = add i64 %.sroa.660.0, -1 %111 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17h5a2a0cf99cd774feE.llvm.17124746118322557833"() - to label %.noexc37 unwind label %.loopexit84 + to label %.noexc36 unwind label %.loopexit84 .noexc37: ; preds = %.loopexit78 %112 = icmp eq ptr %111, null @@ -427,7 +416,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; 113: ; preds = %.noexc37 invoke void @_ZN5alloc5alloc18handle_alloc_error17h426354a964e0805cE(i64 noundef 8, i64 noundef 192) #17 - to label %.noexc38 unwind label %.loopexit.split-lp85 + to label %.noexc37 unwind label %.loopexit.split-lp85 .noexc38: ; preds = %113 unreachable @@ -441,7 +430,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; br i1 %.not, label %._crit_edge, label %.lr.ph ._crit_edge: ; preds = %_ZN5alloc11collections5btree3mem7replace17h66a910f1d87a8d44E.exit53, %114 - %.sroa.065.0.lcssa = phi ptr [ %111, %114 ], [ %143, %_ZN5alloc11collections5btree3mem7replace17h66a910f1d87a8d44E.exit53 ] + %.sroa.065.0.lcssa = phi ptr [ %111, %111 ], [ %143, %_ZN5alloc11collections5btree3mem7replace17h66a910f1d87a8d44E.exit52 ] %117 = getelementptr inbounds nuw i8, ptr %.sroa.059.0, i64 186 %118 = load i16, ptr %117, align 2, !noalias !45, !noundef !7 %119 = icmp ult i16 %118, 11 @@ -449,7 +438,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; 120: ; preds = %._crit_edge invoke void @_ZN4core9panicking5panic17h44790a89027c670fE(ptr noalias noundef nonnull readonly align 1 @anon.e2192d190c206e613b03b2b794f0dab7.0, i64 noundef 32, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.e2192d190c206e613b03b2b794f0dab7.5) #17 - to label %.noexc40 unwind label %.loopexit.split-lp85 + to label %.noexc39 unwind label %.loopexit.split-lp85 .noexc40: ; preds = %120 unreachable @@ -475,8 +464,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; br i1 %.not16.i41, label %.loopexit, label %.lr.ph.i42 .lr.ph.i42: ; preds = %121, %.lr.ph.i42 - %.018.i43 = phi ptr [ %138, %.lr.ph.i42 ], [ %.sroa.059.0, %121 ] - %.01517.i44 = phi i64 [ %139, %.lr.ph.i42 ], [ %.sroa.660.0, %121 ] + %.018.i43 = phi ptr [ %138, %.lr.ph.i41 ], [ %.sroa.059.0, %118 ] + %.01517.i44 = phi i64 [ %139, %.lr.ph.i41 ], [ %.sroa.660.0, %118 ] %132 = getelementptr inbounds nuw i8, ptr %.018.i43, i64 186 %133 = load i16, ptr %132, align 2, !noalias !48, !noundef !7 %134 = zext nneg i16 %133 to i64 @@ -490,18 +479,18 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; br i1 %.not.i45, label %.loopexit, label %.lr.ph.i42 .loopexit: ; preds = %.lr.ph.i42, %121, %154 - %.sroa.0.1 = phi ptr [ %.sroa.0.0, %154 ], [ %.sroa.059.0, %121 ], [ %138, %.lr.ph.i42 ] + %.sroa.0.1 = phi ptr [ %.sroa.0.0, %151 ], [ %.sroa.059.0, %118 ], [ %138, %.lr.ph.i41 ] %140 = load i64, ptr %2, align 8, !noundef !7 %141 = add i64 %140, 1 store i64 %141, ptr %2, align 8 br label %17 .lr.ph: ; preds = %114, %_ZN5alloc11collections5btree3mem7replace17h66a910f1d87a8d44E.exit53 - %.sroa.014.099 = phi i64 [ %142, %_ZN5alloc11collections5btree3mem7replace17h66a910f1d87a8d44E.exit53 ], [ 0, %114 ] - %.sroa.065.097 = phi ptr [ %143, %_ZN5alloc11collections5btree3mem7replace17h66a910f1d87a8d44E.exit53 ], [ %111, %114 ] + %.sroa.014.099 = phi i64 [ %142, %_ZN5alloc11collections5btree3mem7replace17h66a910f1d87a8d44E.exit52 ], [ 0, %111 ] + %.sroa.065.097 = phi ptr [ %143, %_ZN5alloc11collections5btree3mem7replace17h66a910f1d87a8d44E.exit52 ], [ %111, %111 ] %142 = add nuw i64 %.sroa.014.099, 1 %143 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17h832ae5eb9b368d30E.llvm.17124746118322557833"() - to label %.noexc.i49 unwind label %.loopexit77, !noalias !51 + to label %.noexc.i48 unwind label %.loopexit77, !noalias !51 .noexc.i49: ; preds = %.lr.ph %144 = icmp eq ptr %143, null @@ -509,7 +498,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; 145: ; preds = %.noexc.i49 invoke void @_ZN5alloc5alloc18handle_alloc_error17h426354a964e0805cE(i64 noundef 8, i64 noundef 288) #17 - to label %.noexc3.i50 unwind label %.loopexit.split-lp, !noalias !51 + to label %.noexc3.i49 unwind label %.loopexit.split-lp, !noalias !51 .noexc3.i50: ; preds = %145 unreachable @@ -525,7 +514,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h28999f98cd601590E.exit.i.i: ; br label %146 146: ; preds = %.loopexit.split-lp, %.loopexit77 - %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit77 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] + %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit76 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17he7f40e69e6f26b83E"(ptr noalias noundef nonnull align 1 %4) to label %.body unwind label %147, !noalias !51 diff --git a/bench/wasmtime-rs/optimized/5079e95b7v1wxko.ll b/bench/wasmtime-rs/optimized/5079e95b7v1wxko.ll index af2ff7cd098..ae0215e9290 100644 --- a/bench/wasmtime-rs/optimized/5079e95b7v1wxko.ll +++ b/bench/wasmtime-rs/optimized/5079e95b7v1wxko.ll @@ -11258,12 +11258,12 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. br label %17 17: ; preds = %.loopexit, %.loopexit86 - %.sroa.0.0 = phi ptr [ %.0.lcssa.i, %.loopexit86 ], [ %.sroa.0.1, %.loopexit ] + %.sroa.0.0 = phi ptr [ %.0.lcssa.i, %.loopexit85 ], [ %.sroa.0.1, %.loopexit ] %18 = invoke { i32, i32 } @"_ZN137_$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$K$C$V$C$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h67afcb0b020e589fE"(ptr noalias noundef nonnull align 8 dereferenceable(40) %5) to label %22 unwind label %20 .body: ; preds = %.loopexit81, %.loopexit.split-lp82, %138, %96, %20 - %.pn = phi { ptr, i32 } [ %21, %20 ], [ %lpad.phi80, %96 ], [ %lpad.phi, %138 ], [ %lpad.loopexit83, %.loopexit81 ], [ %lpad.loopexit.split-lp84, %.loopexit.split-lp82 ] + %.pn = phi { ptr, i32 } [ %21, %20 ], [ %lpad.phi80, %93 ], [ %lpad.phi, %135 ], [ %lpad.loopexit83, %.loopexit80 ], [ %lpad.loopexit.split-lp84, %.loopexit.split-lp81 ] %19 = getelementptr inbounds nuw i8, ptr %5, i64 8 invoke void @"_ZN86_$LT$alloc..vec..into_iter..IntoIter$LT$T$C$A$GT$$u20$as$u20$core..ops..drop..Drop$GT$4drop17hd4139e6ae1a0e2b8E.llvm.5456684732158232753"(ptr noalias noundef nonnull align 8 dereferenceable(32) %19) to label %"_ZN4core3ptr519drop_in_place$LT$alloc..collections..btree..dedup_sorted_iter..DedupSortedIter$LT$wasmtime_types..ModuleInternedTypeIndex$C$alloc..collections..btree..set_val..SetValZST$C$core..iter..adapters..map..Map$LT$alloc..vec..into_iter..IntoIter$LT$wasmtime_types..ModuleInternedTypeIndex$GT$$C$alloc..collections..btree..set..BTreeSet$LT$wasmtime_types..ModuleInternedTypeIndex$GT$..from_sorted_iter$LT$alloc..vec..into_iter..IntoIter$LT$wasmtime_types..ModuleInternedTypeIndex$GT$$GT$..$u7b$$u7b$closure$u7d$$u7d$$GT$$GT$$GT$17h6988bd2885362933E.exit" unwind label %149 @@ -11355,27 +11355,18 @@ define hidden void @"_ZN5alloc11collections5btree6append178_$LT$impl$u20$alloc.. %57 = getelementptr inbounds nuw i8, ptr %41, i64 56 %58 = add nuw nsw i64 %52, 1 %59 = sub nuw nsw i64 %51, %58 - %60 = add nsw i64 %46, -1 - %61 = icmp eq i64 %59, %60 - br i1 %61, label %_ZN5alloc11collections5btree4node13move_to_slice17hae5d1a55ddef0b91E.exit.i.i, label %.noexc31 - -.noexc31: ; preds = %50 - call void @_ZN4core9panicking5panic17h44790a89027c670fE(ptr noalias noundef nonnull readonly align 1 @anon.f7ec036493567efedaa7daa7831baa68.25, i64 noundef 40, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.f7ec036493567efedaa7daa7831baa68.26) #28 - unreachable - -_ZN5alloc11collections5btree4node13move_to_slice17hae5d1a55ddef0b91E.exit.i.i: ; preds = %50 - %62 = getelementptr inbounds nuw i8, ptr %37, i64 8 - %63 = getelementptr inbounds nuw i32, ptr %62, i64 %58 - %64 = shl nuw nsw i64 %59, 2 - call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 4 %54, ptr nonnull readonly align 4 %63, i64 %64, i1 false), !alias.scope !1619, !noalias !1616 - %65 = getelementptr inbounds nuw i32, ptr %62, i64 %52 + %59 = getelementptr inbounds nuw i8, ptr %37, i64 8 + %60 = getelementptr inbounds nuw i32, ptr %59, i64 %57 + %61 = shl nuw nsw i64 %58, 2 + call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 4 %53, ptr nonnull readonly align 4 %60, i64 %61, i1 false), !alias.scope !1619, !noalias !1616 + %62 = getelementptr inbounds nuw i32, ptr %59, i64 %51 + %63 = load i32, ptr %62, align 4, !noalias !1616, !noundef !17 + %64 = getelementptr inbounds nuw i8, ptr %.011.i, i64 8 + %65 = getelementptr inbounds nuw i32, ptr %64, i64 %34 %66 = load i32, ptr %65, align 4, !noalias !1616, !noundef !17 - %67 = getelementptr inbounds nuw i8, ptr %.011.i, i64 8 - %68 = getelementptr inbounds nuw i32, ptr %67, i64 %34 - %69 = load i32, ptr %68, align 4, !noalias !1616, !noundef !17 + store i32 %63, ptr %65, align 4, !noalias !1616 + %68 = getelementptr inbounds nuw i32, ptr %53, i64 %58 store i32 %66, ptr %68, align 4, !noalias !1616 - %70 = getelementptr inbounds nuw i32, ptr %54, i64 %59 - store i32 %69, ptr %70, align 4, !noalias !1616 %cond.i = icmp eq i64 %38, 0 br i1 %cond.i, label %"_ZN5alloc11collections5btree3fix178_$LT$impl$u20$alloc..collections..btree..node..NodeRef$LT$alloc..collections..btree..node..marker..Owned$C$K$C$V$C$alloc..collections..btree..node..marker..LeafOrInternal$GT$$GT$29fix_right_border_of_plentiful17hfa697b450b994299E.exit", label %_ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i @@ -11391,7 +11382,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; br label %77 77: ; preds = %77, %_ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i - %.sroa.0.05.i.i.i = phi i64 [ 0, %_ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i ], [ %78, %77 ] + %.sroa.0.05.i.i.i = phi i64 [ 0, %_ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i ], [ %78, %74 ] %78 = add nuw nsw i64 %.sroa.0.05.i.i.i, 1 %79 = getelementptr inbounds nuw ptr, ptr %57, i64 %.sroa.0.05.i.i.i %80 = load ptr, ptr %79, align 8, !noalias !1616, !nonnull !17, !noundef !17 @@ -11406,8 +11397,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; ret void .preheader: ; preds = %27, %85 - %.sroa.54.0 = phi i64 [ %86, %85 ], [ 0, %27 ] - %.sroa.03.0 = phi ptr [ %83, %85 ], [ %.sroa.0.0, %27 ] + %.sroa.54.0 = phi i64 [ %86, %82 ], [ 0, %27 ] + %.sroa.03.0 = phi ptr [ %83, %82 ], [ %.sroa.0.0, %27 ] %83 = load ptr, ptr %.sroa.03.0, align 8, !noalias !1627, !noundef !17 %84 = icmp eq ptr %83, null br i1 %84, label %90, label %85 @@ -11458,7 +11449,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; br label %96 96: ; preds = %.loopexit.split-lp77, %.loopexit76 - %lpad.phi80 = phi { ptr, i32 } [ %lpad.loopexit78, %.loopexit76 ], [ %lpad.loopexit.split-lp79, %.loopexit.split-lp77 ] + %lpad.phi80 = phi { ptr, i32 } [ %lpad.loopexit78, %.loopexit75 ], [ %lpad.loopexit.split-lp79, %.loopexit.split-lp76 ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17he7f40e69e6f26b83E"(ptr noalias noundef nonnull align 1 %4) to label %.body unwind label %97, !noalias !1630 @@ -11483,11 +11474,11 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; br label %.loopexit75 .loopexit75: ; preds = %85, %99 - %.sroa.056.0 = phi ptr [ %93, %99 ], [ %83, %85 ] - %.sroa.657.0 = phi i64 [ %102, %99 ], [ %86, %85 ] + %.sroa.056.0 = phi ptr [ %93, %96 ], [ %83, %82 ] + %.sroa.657.0 = phi i64 [ %102, %96 ], [ %86, %82 ] %104 = add i64 %.sroa.657.0, -1 %105 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17h7caa7a0d8d6883c3E.llvm.3458943816331328394"() - to label %.noexc33 unwind label %.loopexit81 + to label %.noexc32 unwind label %.loopexit81 .noexc33: ; preds = %.loopexit75 %106 = icmp eq ptr %105, null @@ -11495,7 +11486,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; 107: ; preds = %.noexc33 invoke void @_ZN5alloc5alloc18handle_alloc_error17h426354a964e0805cE(i64 noundef 8, i64 noundef 56) #28 - to label %.noexc34 unwind label %.loopexit.split-lp82 + to label %.noexc33 unwind label %.loopexit.split-lp82 .noexc34: ; preds = %107 unreachable @@ -11508,7 +11499,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; br i1 %.not, label %._crit_edge, label %.lr.ph ._crit_edge: ; preds = %_ZN5alloc11collections5btree3mem7replace17ha140e4c1fd16a31cE.exit49, %108 - %.sroa.062.0.lcssa = phi ptr [ %105, %108 ], [ %135, %_ZN5alloc11collections5btree3mem7replace17ha140e4c1fd16a31cE.exit49 ] + %.sroa.062.0.lcssa = phi ptr [ %105, %105 ], [ %135, %_ZN5alloc11collections5btree3mem7replace17ha140e4c1fd16a31cE.exit48 ] %110 = getelementptr inbounds nuw i8, ptr %.sroa.056.0, i64 54 %111 = load i16, ptr %110, align 2, !noundef !17 %112 = icmp ult i16 %111, 11 @@ -11516,7 +11507,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; 113: ; preds = %._crit_edge invoke void @_ZN4core9panicking5panic17h44790a89027c670fE(ptr noalias noundef nonnull readonly align 1 @anon.f7ec036493567efedaa7daa7831baa68.14.llvm.6890662303782480722, i64 noundef 32, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.f7ec036493567efedaa7daa7831baa68.19) #28 - to label %.noexc36 unwind label %.loopexit.split-lp82 + to label %.noexc35 unwind label %.loopexit.split-lp82 .noexc36: ; preds = %113 unreachable @@ -11540,8 +11531,8 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; br i1 %.not16.i37, label %.loopexit, label %.lr.ph.i38 .lr.ph.i38: ; preds = %114, %.lr.ph.i38 - %.018.i39 = phi ptr [ %130, %.lr.ph.i38 ], [ %.sroa.056.0, %114 ] - %.01517.i40 = phi i64 [ %131, %.lr.ph.i38 ], [ %.sroa.657.0, %114 ] + %.018.i39 = phi ptr [ %130, %.lr.ph.i37 ], [ %.sroa.056.0, %111 ] + %.01517.i40 = phi i64 [ %131, %.lr.ph.i37 ], [ %.sroa.657.0, %111 ] %124 = getelementptr inbounds nuw i8, ptr %.018.i39, i64 54 %125 = load i16, ptr %124, align 2, !noalias !1639, !noundef !17 %126 = zext nneg i16 %125 to i64 @@ -11555,18 +11546,18 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; br i1 %.not.i41, label %.loopexit, label %.lr.ph.i38 .loopexit: ; preds = %.lr.ph.i38, %114, %144 - %.sroa.0.1 = phi ptr [ %.sroa.0.0, %144 ], [ %.sroa.056.0, %114 ], [ %130, %.lr.ph.i38 ] + %.sroa.0.1 = phi ptr [ %.sroa.0.0, %141 ], [ %.sroa.056.0, %111 ], [ %130, %.lr.ph.i37 ] %132 = load i64, ptr %2, align 8, !noundef !17 %133 = add i64 %132, 1 store i64 %133, ptr %2, align 8 br label %17 .lr.ph: ; preds = %108, %_ZN5alloc11collections5btree3mem7replace17ha140e4c1fd16a31cE.exit49 - %.sroa.014.096 = phi i64 [ %134, %_ZN5alloc11collections5btree3mem7replace17ha140e4c1fd16a31cE.exit49 ], [ 0, %108 ] - %.sroa.062.094 = phi ptr [ %135, %_ZN5alloc11collections5btree3mem7replace17ha140e4c1fd16a31cE.exit49 ], [ %105, %108 ] + %.sroa.014.096 = phi i64 [ %134, %_ZN5alloc11collections5btree3mem7replace17ha140e4c1fd16a31cE.exit48 ], [ 0, %105 ] + %.sroa.062.094 = phi ptr [ %135, %_ZN5alloc11collections5btree3mem7replace17ha140e4c1fd16a31cE.exit48 ], [ %105, %105 ] %134 = add nuw i64 %.sroa.014.096, 1 %135 = invoke noundef align 8 ptr @"_ZN5alloc5boxed16Box$LT$T$C$A$GT$17try_new_uninit_in17hdf605e22fe771092E.llvm.3458943816331328394"() - to label %.noexc.i45 unwind label %.loopexit74, !noalias !1642 + to label %.noexc.i44 unwind label %.loopexit74, !noalias !1642 .noexc.i45: ; preds = %.lr.ph %136 = icmp eq ptr %135, null @@ -11574,7 +11565,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; 137: ; preds = %.noexc.i45 invoke void @_ZN5alloc5alloc18handle_alloc_error17h426354a964e0805cE(i64 noundef 8, i64 noundef 152) #28 - to label %.noexc3.i46 unwind label %.loopexit.split-lp, !noalias !1642 + to label %.noexc3.i45 unwind label %.loopexit.split-lp, !noalias !1642 .noexc3.i46: ; preds = %137 unreachable @@ -11590,7 +11581,7 @@ _ZN5alloc11collections5btree4node13move_to_slice17h5829d77f99dd0856E.exit.i.i: ; br label %138 138: ; preds = %.loopexit.split-lp, %.loopexit74 - %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit74 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] + %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit73 ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] invoke void @"_ZN93_$LT$alloc..collections..btree..mem..replace..PanicGuard$u20$as$u20$core..ops..drop..Drop$GT$4drop17he7f40e69e6f26b83E"(ptr noalias noundef nonnull align 1 %4) to label %.body unwind label %139, !noalias !1642 diff --git a/bench/wireshark/optimized/packet-hartip.ll b/bench/wireshark/optimized/packet-hartip.ll index 94e2dabb074..1755ee9cc0b 100644 --- a/bench/wireshark/optimized/packet-hartip.ll +++ b/bench/wireshark/optimized/packet-hartip.ll @@ -883,7 +883,7 @@ hartip_set_conversation.exit: ; preds = %61, %57, %43, %37, br label %550 92: ; preds = %83 - switch i8 %26, label %546 [ + switch i8 %26, label %544 [ i8 0, label %93 i8 1, label %105 i8 2, label %111 @@ -1510,19 +1510,14 @@ dissect_session_init.exit: ; preds = %95, %101 %479 = load i32, ptr @hf_hartip_pt_device_status, align 4 %480 = tail call ptr @proto_tree_add_item(ptr noundef %86, i32 noundef %479, ptr noundef %0, i32 noundef %478, i32 noundef 1, i32 noundef 0) %481 = add i8 %466, -2 - %482 = zext i8 %481 to i32 - %483 = icmp eq i8 %481, 0 - %484 = icmp samesign ult i32 %.6120.i, 10 - %or.cond3.not82.i.i.i = or i1 %484, %483 - %485 = add nsw i32 %.6120.i, -9 - %.not78.i.i.i = icmp samesign ult i32 %485, %482 - %or.cond79.i.i.i = select i1 %or.cond3.not82.i.i.i, i1 true, i1 %.not78.i.i.i - br i1 %or.cond79.i.i.i, label %.thread184.i, label %486 - -486: ; preds = %475 - %487 = add i32 %462, 4 - %488 = load i32, ptr @hf_hartip_pt_rsp_data, align 4 - %489 = tail call ptr @proto_tree_add_item(ptr noundef %86, i32 noundef %488, ptr noundef %0, i32 noundef %487, i32 noundef %482, i32 noundef 0) + %482 = icmp eq i8 %481, 0 + br i1 %482, label %.thread184.i, label %483 + +483:; preds = %475 + %484 = zext i8 %481 to i32 + %485 = add i32 %462, 4 + %486 = load i32, ptr @hf_hartip_pt_rsp_data, align 4 + %487 = tail call ptr @proto_tree_add_item(ptr noundef %86, i32 noundef %486, ptr noundef %0, i32 noundef %485, i32 noundef %484, i32 noundef 0) br label %.thread184.i 490: ; preds = %190 @@ -1543,9 +1538,9 @@ dissect_session_init.exit: ; preds = %95, %101 br label %.lr.ph.i.i.i .lr.ph.i.i.i: ; preds = %529, %.lr.ph.preheader.i.i.i - %.06380.i.i.i = phi i8 [ %530, %529 ], [ 0, %.lr.ph.preheader.i.i.i ] - %.06479.i.i.i = phi i32 [ %.1.i.i.i, %529 ], [ %497, %.lr.ph.preheader.i.i.i ] - %.06678.i.i.i = phi i32 [ %.167.i.i.i, %529 ], [ %498, %.lr.ph.preheader.i.i.i ] + %.06380.i.i.i = phi i8 [ %530, %527 ], [ 0, %.lr.ph.preheader.i.i.i ] + %.06479.i.i.i = phi i32 [ %.1.i.i.i, %527 ], [ %497, %.lr.ph.preheader.i.i.i ] + %.06678.i.i.i = phi i32 [ %.167.i.i.i, %527 ], [ %498, %.lr.ph.preheader.i.i.i ] %499 = tail call zeroext i16 @tvb_get_ntohs(ptr noundef %0, i32 noundef %.06678.i.i.i) %500 = load i32, ptr @hf_hartip_pt_rsp_command_number, align 4 %501 = tail call ptr @proto_tree_add_item(ptr noundef %86, i32 noundef %500, ptr noundef %0, i32 noundef %.06678.i.i.i, i32 noundef 2, i32 noundef 0) @@ -1587,7 +1582,7 @@ dissect_session_init.exit: ; preds = %95, %101 br label %522 522: ; preds = %520, %518, %516 - %.0.i96.i.i = phi i32 [ %517, %516 ], [ %519, %518 ], [ %521, %520 ] + %.0.i96.i.i = phi i32 [ %515, %514 ], [ %517, %516 ], [ %519, %518 ] %523 = icmp eq i32 %.0.i96.i.i, 0 br i1 %523, label %.thread.i.i.i, label %526 @@ -1602,8 +1597,8 @@ dissect_session_init.exit: ; preds = %95, %101 br label %529 529: ; preds = %526, %.lr.ph.i.i.i - %.167.i.i.i = phi i32 [ %527, %526 ], [ %509, %.lr.ph.i.i.i ] - %.1.i.i.i = phi i32 [ %528, %526 ], [ %510, %.lr.ph.i.i.i ] + %.167.i.i.i = phi i32 [ %527, %524 ], [ %509, %.lr.ph.i.i.i ] + %.1.i.i.i = phi i32 [ %528, %524 ], [ %510, %.lr.ph.i.i.i ] %530 = add i8 %.06380.i.i.i, 1 %531 = sext i8 %530 to i32 %532 = icmp slt i32 %531, %495 @@ -1616,7 +1611,7 @@ dissect_session_init.exit: ; preds = %95, %101 br label %dissect_parse_hart_cmds.exit.i dissect_parse_hart_cmds.exit.i: ; preds = %529, %534, %431, %288, %264 - %.0.i.i = phi i32 [ %265, %264 ], [ %289, %288 ], [ %432, %431 ], [ %535, %534 ], [ %191, %529 ] + %.0.i.i = phi i32 [ %265, %264 ], [ %289, %288 ], [ %432, %431 ], [ %535, %532 ], [ %191, %527 ] %536 = icmp eq i32 %.0.i.i, 0 br i1 %536, label %dissect_parse_hart_cmds.exit.thread182.i, label %.thread184.i @@ -1625,7 +1620,7 @@ dissect_parse_hart_cmds.exit.thread182.i: ; preds = %dissect_parse_hart_ %538 = tail call ptr @proto_tree_add_item(ptr noundef %86, i32 noundef %537, ptr noundef %0, i32 noundef %.6.i, i32 noundef %191, i32 noundef 0) br label %.thread184.i -.thread184.i: ; preds = %dissect_parse_hart_cmds.exit.thread182.i, %dissect_parse_hart_cmds.exit.i, %492, %486, %475, %472, %461, %428, %416, %405, %394, %384, %.critedge.i.i.i, %377, %370, %365, %360, %331, %314, %297, %292, %276, %268, %258, %250, %241, %236, %222, %194 +.thread184.i: ; preds = %dissect_parse_hart_cmds.exit.thread182.i, %dissect_parse_hart_cmds.exit.i, %492, %483, %475, %472, %461, %428, %416, %405, %394, %384, %.critedge.i.i.i, %377, %370, %365, %360, %331, %314, %297, %292, %276, %268, %258, %250, %241, %236, %222, %194 %539 = add i32 %.6.i, %191 br label %542 @@ -1634,7 +1629,7 @@ dissect_parse_hart_cmds.exit.thread182.i: ; preds = %dissect_parse_hart_ br i1 %541, label %542, label %dissect_pass_through.exit 542: ; preds = %540, %.thread184.i - %.8187.i = phi i32 [ %539, %.thread184.i ], [ %.6.i, %540 ] + %.8187.i = phi i32 [ %539, %.thread184.i ], [ %.6.i, %538 ] %543 = load i32, ptr @hf_hartip_pt_checksum, align 4 %544 = tail call ptr @proto_tree_add_checksum(ptr noundef %86, ptr noundef %0, i32 noundef %.8187.i, i32 noundef %543, i32 noundef -1, ptr noundef null, ptr noundef null, i32 noundef 0, i32 noundef 0, i32 noundef 0) br label %dissect_pass_through.exit @@ -1650,7 +1645,7 @@ dissect_pass_through.exit: ; preds = %117, %125, %177, %1 br label %550 550: ; preds = %87, %546, %dissect_pass_through.exit, %111, %105, %dissect_session_init.exit, %81 - %.0 = phi i32 [ %82, %81 ], [ %91, %87 ], [ %549, %546 ], [ %104, %dissect_session_init.exit ], [ %110, %105 ], [ %116, %111 ], [ %545, %dissect_pass_through.exit ] + %.0 = phi i32 [ %82, %81 ], [ %91, %87 ], [ %549, %544 ], [ %104, %dissect_session_init.exit ], [ %110, %105 ], [ %116, %111 ], [ %545, %dissect_pass_through.exit ] ret i32 %.0 } diff --git a/bench/wireshark/optimized/packet-isis-lsp.ll b/bench/wireshark/optimized/packet-isis-lsp.ll index 371da2d3ae5..642d7d9a546 100644 --- a/bench/wireshark/optimized/packet-isis-lsp.ll +++ b/bench/wireshark/optimized/packet-isis-lsp.ll @@ -2639,7 +2639,7 @@ define internal void @dissect_isis_lsp_clv_mt_cap(ptr noundef %0, ptr noundef %1 br label %.loopexit87 25: ; preds = %.lr.ph - switch i8 %16, label %141 [ + switch i8 %16, label %138 [ i8 1, label %26 i8 2, label %85 i8 3, label %91 @@ -2691,19 +2691,17 @@ define internal void @dissect_isis_lsp_clv_mt_cap(ptr noundef %0, ptr noundef %1 br i1 %.not.i, label %.preheader.i, label %61 .preheader.i: ; preds = %54 - %58 = icmp ne i32 %56, 0 - %59 = icmp ne i8 %32, 0 - %60 = select i1 %58, i1 %59, i1 false - br i1 %60, label %.lr.ph.i, label %._crit_edge.i + %58 = icmp eq i32 %56, 0 + br i1 %58, label %._crit_edge.i, label %.lr.ph.i 61: ; preds = %54 %62 = tail call ptr (ptr, ptr, ptr, ptr, i32, i32, ptr, ...) @proto_tree_add_expert_format(ptr noundef %35, ptr noundef %1, ptr noundef nonnull @ei_isis_lsp_short_clv, ptr noundef %0, i32 noundef %55, i32 noundef 0, ptr noundef nonnull @.str.889) br label %.loopexit .lr.ph.i: ; preds = %.preheader.i, %66 - %.087.i = phi i8 [ %77, %66 ], [ %32, %.preheader.i ] - %.07586.i = phi i32 [ %75, %66 ], [ %55, %.preheader.i ] - %.07685.i = phi i32 [ %76, %66 ], [ %56, %.preheader.i ] + %.087.i = phi i8 [ %77, %63 ], [ %32, %.preheader.i ] + %.07586.i = phi i32 [ %75, %63 ], [ %55, %.preheader.i ] + %.07685.i = phi i32 [ %76, %63 ], [ %56, %.preheader.i ] %63 = icmp samesign ult i32 %.07685.i, 8 br i1 %63, label %64, label %66 @@ -2730,8 +2728,8 @@ define internal void @dissect_isis_lsp_clv_mt_cap(ptr noundef %0, ptr noundef %1 br i1 %80, label %.lr.ph.i, label %._crit_edge.i, !llvm.loop !17 ._crit_edge.i: ; preds = %66, %.preheader.i - %.0.lcssa84.i = phi i8 [ %32, %.preheader.i ], [ %77, %66 ] - %.076.lcssa.i = phi i32 [ %56, %.preheader.i ], [ %76, %66 ] + %.0.lcssa84.i = phi i8 [ %32, %.preheader.i ], [ %77, %63 ] + %.076.lcssa.i = phi i32 [ 0, %.preheader.i ], [ %76, %63 ] %.not80.i = icmp eq i8 %.0.lcssa84.i, 0 br i1 %.not80.i, label %.loopexit, label %81 @@ -2776,8 +2774,8 @@ define internal void @dissect_isis_lsp_clv_mt_cap(ptr noundef %0, ptr noundef %1 br label %.lr.ph.i79 .lr.ph.i79: ; preds = %110, %.lr.ph.preheader.i - %.044.i = phi i32 [ %114, %110 ], [ %105, %.lr.ph.preheader.i ] - %.03843.i = phi i32 [ %115, %110 ], [ %104, %.lr.ph.preheader.i ] + %.044.i = phi i32 [ %114, %107 ], [ %105, %.lr.ph.preheader.i ] + %.03843.i = phi i32 [ %115, %107 ], [ %104, %.lr.ph.preheader.i ] %107 = icmp samesign ult i32 %.03843.i, 4 br i1 %107, label %108, label %110 @@ -2822,8 +2820,8 @@ define internal void @dissect_isis_lsp_clv_mt_cap(ptr noundef %0, ptr noundef %1 br label %.lr.ph.i82 .lr.ph.i82: ; preds = %135, %.lr.ph.preheader.i81 - %.045.i = phi i32 [ %139, %135 ], [ %131, %.lr.ph.preheader.i81 ] - %.04044.i = phi i32 [ %140, %135 ], [ %130, %.lr.ph.preheader.i81 ] + %.045.i = phi i32 [ %139, %132 ], [ %131, %.lr.ph.preheader.i81 ] + %.04044.i = phi i32 [ %140, %132 ], [ %130, %.lr.ph.preheader.i81 ] %132 = icmp samesign ult i32 %.04044.i, 7 br i1 %132, label %133, label %135 diff --git a/bench/wireshark/optimized/sharkd_session.ll b/bench/wireshark/optimized/sharkd_session.ll index c2e4fdfa386..5893d48d6a0 100644 --- a/bench/wireshark/optimized/sharkd_session.ll +++ b/bench/wireshark/optimized/sharkd_session.ll @@ -1125,19 +1125,15 @@ json_find_attr.exit203.thread.i.i: ; preds = %json_find_attr.exit %252 = add i64 %.1291.i.i, 1 %253 = and i64 %252, 576460752303423487 %.not153.i.i = icmp eq i64 %253, 101 - br i1 %.not153.i.i, label %json_prep.exit.i, label %.preheader.i.i, !llvm.loop !18 - -json_prep.exit.i: ; preds = %251 - %.not.i82.i = icmp eq i32 %40, 0 - br i1 %.not.i82.i, label %json_find_attr.exit.thread.i, label %.lr.ph.i84.i + br i1 %.not153.i.i, label %.lr.ph.i84.i, label %.preheader.i.i, !llvm.loop !18 254: ; preds = %.lr.ph.i84.i %indvars.iv.next.i86.i = add nuw nsw i64 %indvars.iv.i85.i, 2 %255 = icmp samesign ult i64 %indvars.iv.next.i86.i, %42 br i1 %255, label %.lr.ph.i84.i, label %json_find_attr.exit.thread.i, !llvm.loop !10 -.lr.ph.i84.i: ; preds = %json_prep.exit.i, %254 - %indvars.iv.i85.i = phi i64 [ %indvars.iv.next.i86.i, %254 ], [ 0, %json_prep.exit.i ] +.lr.ph.i84.i: ; preds = %251, %254 + %indvars.iv.i85.i = phi i64 [ %indvars.iv.next.i86.i, %254 ], [ 0, %251 ] %256 = getelementptr %struct.jsmntok_t, ptr %39, i64 %indvars.iv.i85.i %257 = getelementptr inbounds nuw i8, ptr %256, i64 4 %258 = load i32, ptr %257, align 4 @@ -1155,7 +1151,7 @@ json_find_attr.exit.i: ; preds = %.lr.ph.i84.i %.not.i = icmp eq ptr %265, null br i1 %.not.i, label %json_find_attr.exit.thread.i, label %267 -json_find_attr.exit.thread.i: ; preds = %254, %json_find_attr.exit.i, %json_prep.exit.i +json_find_attr.exit.thread.i: ; preds = %254, %json_find_attr.exit.i %266 = load i32, ptr @rpcid, align 4 call void (i32, i32, ptr, ptr, ...) @sharkd_json_error(i32 noundef %266, i32 noundef -32601, ptr poison, ptr noundef nonnull @.str.12) br label %sharkd_session_process.exit diff --git a/scripts/setup_pre_commit_patch.sh b/scripts/setup_pre_commit_patch.sh index c8d0fce0bf7..96df403fb04 100755 --- a/scripts/setup_pre_commit_patch.sh +++ b/scripts/setup_pre_commit_patch.sh @@ -2,7 +2,7 @@ set -euo pipefail shopt -s inherit_errexit -export GITHUB_PATCH_ID="/llvm-project/commit/" +export GITHUB_PATCH_ID=llvm/llvm-project/compare/main...fhahn:llvm-project:ce-reorder-add export COMPTIME_MODE=0 export STAT_MODE=0 export STAT_NAME=""