diff --git a/bench/abc/optimized/acecRe.ll b/bench/abc/optimized/acecRe.ll index 38674e50d00..5b135ebb0e3 100644 --- a/bench/abc/optimized/acecRe.ll +++ b/bench/abc/optimized/acecRe.ll @@ -3025,10 +3025,10 @@ define void @Ree_ManRemoveTrivial(ptr noundef %0, ptr noundef captures(none) %1) br label %11 11: ; preds = %.lr.ph, %48 - %.val3343 = phi i32 [ %.val3339, %.lr.ph ], [ %.val33, %48 ] - %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %48 ] - %12 = phi i64 [ 0, %.lr.ph ], [ %49, %48 ] - %.041 = phi i32 [ 0, %.lr.ph ], [ %.1, %48 ] + %.val3343 = phi i32 [ %.val3339, %.lr.ph ], [ %.val33, %45 ] + %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %45 ] + %12 = phi i64 [ 0, %.lr.ph ], [ %49, %45 ] + %.041 = phi i32 [ 0, %.lr.ph ], [ %.1, %45 ] %.val36 = load ptr, ptr %9, align 8, !tbaa !23 %13 = and i64 %12, 4294967294 %14 = getelementptr inbounds nuw i32, ptr %.val36, i64 %13 @@ -3042,24 +3042,25 @@ define void @Ree_ManRemoveTrivial(ptr noundef %0, ptr noundef captures(none) %1) %20 = load i32, ptr %19, align 4, !tbaa !16 %.val32 = load ptr, ptr %10, align 8, !tbaa !30 %21 = sext i32 %20 to i64 - %22 = getelementptr inbounds %struct.Gia_Obj_t_, ptr %.val32, i64 %21 + %.idx39 = mul nsw i64 %21, 12 + %22 = getelementptr inbounds i8, ptr %.val32, i64 %.idx39 %23 = getelementptr inbounds nuw i8, ptr %14, i64 16 %24 = load i32, ptr %23, align 4, !tbaa !16 %25 = sext i32 %24 to i64 - %26 = getelementptr inbounds %struct.Gia_Obj_t_, ptr %.val32, i64 %25 + %.idx = mul nsw i64 %25, 12 %27 = load i64, ptr %22, align 4 %28 = and i64 %27, 536870911 - %29 = sub nsw i64 0, %28 - %30 = getelementptr inbounds %struct.Gia_Obj_t_, ptr %22, i64 %29 - %31 = icmp eq ptr %26, %30 + %.idx40 = mul nsw i64 %28, -12 + %28 = add nsw i64 %.idx40, %.idx39 + %31 = icmp eq i64 %.idx, %28 br i1 %31, label %38, label %32 32: ; preds = %18 %33 = lshr i64 %27, 32 %34 = and i64 %33, 536870911 - %35 = sub nsw i64 0, %34 - %36 = getelementptr inbounds %struct.Gia_Obj_t_, ptr %22, i64 %35 - %37 = icmp eq ptr %26, %36 + %.idx41 = mul nsw i64 %34, -12 + %33 = add nsw i64 %.idx41, %.idx39 + %37 = icmp eq i64 %.idx, %33 br i1 %37, label %38, label %43 38: ; preds = %32, %18 @@ -3080,8 +3081,8 @@ define void @Ree_ManRemoveTrivial(ptr noundef %0, ptr noundef captures(none) %1) br label %48 48: ; preds = %38, %43 - %.val33 = phi i32 [ %.val3343, %38 ], [ %.val33.pre, %43 ] - %.1 = phi i32 [ %.041, %38 ], [ %44, %43 ] + %.val33 = phi i32 [ %.val3343, %35 ], [ %.val33.pre, %40 ] + %.1 = phi i32 [ %.041, %35 ], [ %44, %40 ] %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 %49 = mul nuw nsw i64 %indvars.iv.next, 6 %50 = trunc nuw i64 %49 to i32 diff --git a/bench/abc/optimized/giaIso2.ll b/bench/abc/optimized/giaIso2.ll index 1b1489e76ba..841a58de573 100644 --- a/bench/abc/optimized/giaIso2.ll +++ b/bench/abc/optimized/giaIso2.ll @@ -322,7 +322,8 @@ define void @Gia_Iso2ManPropagate(ptr noundef readonly captures(none) %0) local_ %11 = getelementptr i8, ptr %.val53, i64 8 %.val55.val = load ptr, ptr %11, align 8, !tbaa !32 %.not38 = icmp eq ptr %.val54, null - br i1 %.not38, label %.critedge2, label %.lr.ph62.split + %invariant.gep = getelementptr i8, ptr %.val54, i64 8 + br i1 %.not38, label %.critedge2, label %.lr.ph64.split .lr.ph62.split: ; preds = %.lr.ph62 %12 = getelementptr i8, ptr %0, i64 64 @@ -410,31 +411,32 @@ define void @Gia_Iso2ManPropagate(ptr noundef readonly captures(none) %0) local_ br i1 %exitcond.not, label %.critedge.preheader, label %15, !llvm.loop !42 64: ; preds = %.lr.ph62.split, %.critedge - %indvars.iv66 = phi i64 [ 0, %.lr.ph62.split ], [ %indvars.iv.next67, %.critedge ] + %indvars.iv66 = phi i64 [ 0, %.lr.ph64.split ], [ %indvars.iv.next67, %.critedge ] %65 = trunc nuw nsw i64 %indvars.iv66 to i32 %.reass = add i32 %invariant.op, %65 %66 = sext i32 %.reass to i64 %67 = getelementptr inbounds i32, ptr %.val55.val, i64 %66 %68 = load i32, ptr %67, align 4, !tbaa !34 %69 = sext i32 %68 to i64 - %70 = getelementptr inbounds %struct.Gia_Obj_t_, ptr %.val54, i64 %69 - %.reass64 = add i32 %invariant.op63, %65 - %71 = sext i32 %.reass64 to i64 + %.idx60 = mul nsw i64 %69, 12 + %70 = getelementptr inbounds i8, ptr %.val54, i64 %.idx60 + %.reass66 = add i32 %invariant.op65, %65 + %71 = sext i32 %.reass66 to i64 %72 = getelementptr inbounds i32, ptr %.val57.val, i64 %71 %73 = load i32, ptr %72, align 4, !tbaa !34 %74 = sext i32 %73 to i64 - %75 = getelementptr inbounds %struct.Gia_Obj_t_, ptr %.val54, i64 %74 + %.idx = mul nsw i64 %74, 12 %76 = getelementptr inbounds nuw i8, ptr %70, i64 8 %77 = load i32, ptr %76, align 4, !tbaa !37 - %78 = getelementptr inbounds nuw i8, ptr %75, i64 8 + %78 = getelementptr i8, ptr %invariant.gep, i64 %.idx %79 = load i32, ptr %78, align 4, !tbaa !37 %80 = add i32 %79, %77 store i32 %80, ptr %78, align 4, !tbaa !37 %81 = load i64, ptr %70, align 4 %82 = and i64 %81, 536870911 - %83 = sub nsw i64 0, %82 - %84 = getelementptr inbounds %struct.Gia_Obj_t_, ptr %70, i64 %83 - %85 = icmp eq ptr %75, %84 + %.idx61 = mul nsw i64 %80, -12 + %81 = add nsw i64 %.idx61, %.idx60 + %85 = icmp eq i64 %.idx, %81 br i1 %85, label %86, label %.critedge 86: ; preds = %64 diff --git a/bench/abc/optimized/mvcUtils.ll b/bench/abc/optimized/mvcUtils.ll index a6c322061cc..23e62c9b0cd 100644 --- a/bench/abc/optimized/mvcUtils.ll +++ b/bench/abc/optimized/mvcUtils.ll @@ -882,17 +882,13 @@ define noundef i32 @Mvc_CoverSetCubeSizes(ptr noundef readonly captures(none) %0 7: ; preds = %.lr.ph22, %._crit_edge %.01420 = phi ptr [ %.01418, %.lr.ph22 ], [ %.014, %._crit_edge ] - %8 = getelementptr i8, ptr %.01420, i64 %5 - %.ptr24 = getelementptr i8, ptr %8, i64 16 - br i1 %6, label %.lr.ph.preheader, label %._crit_edge - -.lr.ph.preheader: ; preds = %7 - %.ptr = getelementptr inbounds nuw i8, ptr %.01420, i64 16 - br label %.lr.ph + %8 = getelementptr inbounds nuw i8, ptr %.01420, i64 16 + %.ptr24 = getelementptr inbounds i8, ptr %8, i64 %5 + br i1 %6, label %.lr.ph, label %._crit_edge -.lr.ph: ; preds = %.lr.ph.preheader, %.lr.ph - %.017 = phi i32 [ %13, %.lr.ph ], [ 0, %.lr.ph.preheader ] - %.01516 = phi ptr [ %14, %.lr.ph ], [ %.ptr, %.lr.ph.preheader ] +.lr.ph: ; preds = %7, %.lr.ph + %.017 = phi i32 [ %13, %.lr.ph ], [ 0, %7 ] + %.01516 = phi ptr [ %14, %.lr.ph ], [ %8, %7 ] %9 = load i8, ptr %.01516, align 1, !tbaa !35 %10 = zext i8 %9 to i64 %11 = getelementptr inbounds nuw [256 x i32], ptr @bit_count, i64 0, i64 %10 @@ -929,8 +925,7 @@ define noundef i32 @Mvc_CoverCountCubePairDiffs(ptr noundef %0, ptr noundef writ %7 = getelementptr inbounds nuw i8, ptr %3, i64 16 %8 = getelementptr inbounds nuw i8, ptr %3, i64 20 %9 = sext i32 %6 to i64 - %10 = getelementptr i8, ptr %3, i64 %9 - %.ptr63 = getelementptr i8, ptr %10, i64 16 + %10 = getelementptr inbounds i8, ptr %7, i64 %9 %11 = icmp sgt i32 %6, 0 br i1 %11, label %.preheader48.us, label %.preheader48 @@ -997,7 +992,7 @@ define noundef i32 @Mvc_CoverCountCubePairDiffs(ptr noundef %0, ptr noundef writ %36 = load i32, ptr %35, align 4, !tbaa !3 %37 = add nsw i32 %36, %.04252.us.us %38 = getelementptr inbounds nuw i8, ptr %.04551.us.us, i64 1 - %39 = icmp ult ptr %38, %.ptr63 + %39 = icmp ult ptr %38, %.ptr24 br i1 %39, label %.lr.ph.us.us, label %._crit_edge.us.us, !llvm.loop !40 40: ; preds = %.preheader.us.us, %40 diff --git a/bench/abseil-cpp/optimized/exception_safety_testing_test.ll b/bench/abseil-cpp/optimized/exception_safety_testing_test.ll index 0285dab586f..1b212c2b32e 100644 --- a/bench/abseil-cpp/optimized/exception_safety_testing_test.ll +++ b/bench/abseil-cpp/optimized/exception_safety_testing_test.ll @@ -29336,14 +29336,14 @@ _ZN7testing8internal14TrueWithStringD2Ev.exit42.i: ; preds = %_ZNKSt7__cxx1112ba br label %182 182: ; preds = %183, %.noexc15.i.i33 - %.idx.i.i.i.i = phi i64 [ 8, %.noexc15.i.i33 ], [ %.add.i.i.i.i, %183 ] + %.idx.i.i.i.i = phi i64 [ %.add.i.i.i.i, %183 ], [ 8, %.noexc15.i.i33 ] %.ptr.ptr.i.i.i.i = getelementptr inbounds nuw i8, ptr %181, i64 %.idx.i.i.i.i invoke void @_ZN7testing13ThrowingValueILNS_8TypeSpecE0EEC2Ev(ptr noundef nonnull align 4 dereferenceable(4) %.ptr.ptr.i.i.i.i) to label %183 unwind label %185, !noalias !243 183: ; preds = %182 %.add.i.i.i.i = add nuw nsw i64 %.idx.i.i.i.i, 4 - %184 = icmp samesign eq i64 %.add.i.i.i.i, 16 + %184 = icmp eq i64 %.idx.i.i.i.i, 12 br i1 %184, label %192, label %182 185: ; preds = %182 @@ -29560,14 +29560,14 @@ _ZN7testing7MessageD2Ev.exit22.i.i: ; preds = %_ZNKSt14default_del br label %250 250: ; preds = %251, %.noexc32.i31 - %.idx.i.i.i = phi i64 [ 8, %.noexc32.i31 ], [ %.add.i.i.i, %251 ] + %.idx.i.i.i = phi i64 [ %.add.i.i.i, %251 ], [ 8, %.noexc32.i31 ] %.ptr.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %249, i64 %.idx.i.i.i invoke void @_ZN7testing13ThrowingValueILNS_8TypeSpecE0EEC2Ev(ptr noundef nonnull align 4 dereferenceable(4) %.ptr.ptr.i.i.i) to label %251 unwind label %253, !noalias !248 251: ; preds = %250 %.add.i.i.i = add nuw nsw i64 %.idx.i.i.i, 4 - %252 = icmp samesign eq i64 %.add.i.i.i, 16 + %252 = icmp eq i64 %.idx.i.i.i, 12 br i1 %252, label %260, label %250 253: ; preds = %250 diff --git a/bench/actix-rs/optimized/19s5ghr2x6s6bmh4.ll b/bench/actix-rs/optimized/19s5ghr2x6s6bmh4.ll index edd7a6f96eb..ef3cc360573 100644 --- a/bench/actix-rs/optimized/19s5ghr2x6s6bmh4.ll +++ b/bench/actix-rs/optimized/19s5ghr2x6s6bmh4.ll @@ -1422,16 +1422,15 @@ define hidden void @"_ZN68_$LT$sha1..Sha1Core$u20$as$u20$digest..core_api..Fixed call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(20) %9, ptr noundef nonnull align 8 dereferenceable(20) %18, i64 20, i1 false) %19 = tail call i64 @llvm.bswap.i64(i64 %17) tail call void @llvm.experimental.noalias.scope.decl(metadata !191) - %20 = getelementptr inbounds nuw [0 x i8], ptr %1, i64 0, i64 %12 + %20 = getelementptr [0 x i8], ptr %1, i64 0, i64 %12 store i8 -128, ptr %20, align 1, !alias.scope !191, !noalias !194 %21 = icmp eq i8 %11, 63 br i1 %21, label %._crit_edge.thread, label %._crit_edge ._crit_edge: ; preds = %3 - %22 = getelementptr i8, ptr %1, i64 %12 - %scevgep = getelementptr i8, ptr %22, i64 1 + %22 = getelementptr i8, ptr %20, i64 1 %23 = xor i64 %12, 63 - tail call void @llvm.memset.p0.i64(ptr align 1 %scevgep, i8 0, i64 %23, i1 false), !noalias !197 + tail call void @llvm.memset.p0.i64(ptr align 1 %22, i8 0, i64 %23, i1 false), !noalias !197 %24 = xor i64 %12, 56 %25 = icmp samesign ult i64 %24, 8 br i1 %25, label %._crit_edge.thread, label %34 diff --git a/bench/arrow/optimized/coo_converter.ll b/bench/arrow/optimized/coo_converter.ll index 0823b657665..d60cd76e50f 100644 --- a/bench/arrow/optimized/coo_converter.ll +++ b/bench/arrow/optimized/coo_converter.ll @@ -7287,7 +7287,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i58, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !190 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %74, %.0.i.i.i.i.i55104.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i55104.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -7783,7 +7783,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i56, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !196 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %74, %.0.i.i.i.i.i53101.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i53101.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -8280,7 +8280,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i56, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !202 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %74, %.0.i.i.i.i.i53101.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i53101.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -8762,7 +8762,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i56, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !208 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %71, %.0.i.i.i.i.i53101.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i53101.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIhmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -9262,7 +9262,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i56, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIthEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !219 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIthEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIthEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i53101.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i53101.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIthEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIthEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -9763,7 +9763,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i61, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIttEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !225 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIttEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIttEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i58107.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i58107.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIttEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIttEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -10265,7 +10265,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i57, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !231 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i54102.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i54102.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -10752,7 +10752,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i57, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !237 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %73, %.0.i.i.i.i.i54102.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i54102.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorItmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -11253,7 +11253,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i56, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !248 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i53101.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i53101.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -11754,7 +11754,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i57, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !254 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i54102.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i54102.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjtEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -12256,7 +12256,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i61, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !260 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i58107.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i58107.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjjEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -12743,7 +12743,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i57, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !266 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %73, %.0.i.i.i.i.i54102.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i54102.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIjmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -13244,7 +13244,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i60, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !272 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i55106.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i55106.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlhEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -13744,7 +13744,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i61, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIltEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !278 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIltEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIltEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i56107.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i56107.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIltEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIltEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -14245,7 +14245,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i61, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIljEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !284 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIljEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIljEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %76, %.0.i.i.i.i.i56107.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i56107.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIljEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIljEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i @@ -14731,7 +14731,7 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIl br i1 %.not.i.i.i.i61, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, label %.lr.ph.i.i.i.i.i.i, !llvm.loop !290 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.i.i.i.i - %.not9.i.i.i.i = icmp eq ptr %73, %.0.i.i.i.i.i56107.ptr + %.not9.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i56107.idx, 120 br i1 %.not9.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.lr.ph.i.us.i.i.i.i .lr.ph.i.i.lr.ph.i.us.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SG_SI_.exit.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops14_Val_comp_iterIZN5arrow8internal12_GLOBAL__N_124ConvertColumnMajorTensorIlmEEvRKNS9_6TensorEPT_PT0_lEUlllE_EEEvSG_SI_.exit.loopexit.us.i.i.i.i diff --git a/bench/assimp/optimized/BlenderCustomData.ll b/bench/assimp/optimized/BlenderCustomData.ll index 4104f167bee..05672266af6 100644 --- a/bench/assimp/optimized/BlenderCustomData.ll +++ b/bench/assimp/optimized/BlenderCustomData.ll @@ -496,7 +496,7 @@ declare i32 @__gxx_personality_v0(...) declare void @llvm.lifetime.end.p0(i64 immarg, ptr captures(none)) #1 ; Function Attrs: mustprogress uwtable -define hidden noundef nonnull ptr @_ZN6Assimp7Blender11createMVertEm(i64 noundef %0) #0 personality ptr @__gxx_personality_v0 { +define hidden noalias noundef nonnull ptr @_ZN6Assimp7Blender11createMVertEm(i64 noundef %0) #0 personality ptr @__gxx_personality_v0 { %2 = tail call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %0, i64 56) %3 = extractvalue { i64, i1 } %2, 1 %4 = extractvalue { i64, i1 } %2, 0 @@ -507,16 +507,11 @@ define hidden noundef nonnull ptr @_ZN6Assimp7Blender11createMVertEm(i64 noundef %9 = select i1 %7, i64 -1, i64 %8 %10 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %9) #25 store i64 %0, ptr %10, align 16 - %.ptr5 = getelementptr inbounds nuw i8, ptr %10, i64 8 %11 = icmp eq i64 %0, 0 - br i1 %11, label %.loopexit, label %12 - -12: ; preds = %1 - %13 = getelementptr inbounds %"struct.Assimp::Blender::MVert", ptr %.ptr5, i64 %0 - br label %14 + br i1 %11, label %.loopexit, label %14 -14: ; preds = %12, %14 - %.idx = phi i64 [ 8, %12 ], [ %.add, %14 ] +14: ; preds = %1, %14 + %.idx = phi i64 [ %.add, %.preheader ], [ 8, %1 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %10, i64 %.idx %15 = getelementptr inbounds nuw i8, ptr %.ptr.ptr, i64 8 store ptr null, ptr %15, align 8 @@ -528,11 +523,12 @@ define hidden noundef nonnull ptr @_ZN6Assimp7Blender11createMVertEm(i64 noundef %18 = getelementptr inbounds nuw i8, ptr %.ptr.ptr, i64 48 store i32 0, ptr %18, align 8 %.add = add nuw nsw i64 %.idx, 56 - %.ptr4 = getelementptr inbounds nuw i8, ptr %10, i64 %.add - %19 = icmp eq ptr %.ptr4, %13 + %16 = add nuw nsw i64 %.idx, 48 + %19 = icmp eq i64 %16, %4 br i1 %19, label %.loopexit, label %14 .loopexit: ; preds = %14, %1 + %.ptr5 = getelementptr inbounds nuw i8, ptr %10, i64 8 ret ptr %.ptr5 } diff --git a/bench/assimp/optimized/BlenderLoader.ll b/bench/assimp/optimized/BlenderLoader.ll index 08302a66295..f069fc1a85e 100644 --- a/bench/assimp/optimized/BlenderLoader.ll +++ b/bench/assimp/optimized/BlenderLoader.ll @@ -8610,72 +8610,77 @@ _ZNSt6vectorIP9aiTextureSaIS1_EE9push_backEOS1_.exit: ; preds = %48, %_ZNSt6vect %.add = add i64 %73, 1064 %.ptr59 = getelementptr inbounds i8, ptr %4, i64 %.add %.not74 = icmp slt i64 %73, 0 - br i1 %.not74, label %.critedge, label %.lr.ph.preheader + br i1 %.not74, label %.critedge.thread, label %.lr.ph.preheader .lr.ph.preheader: ; preds = %_ZNSt6vectorIP9aiTextureSaIS1_EE9push_backEOS1_.exit %smin = tail call i64 @llvm.smin.i64(i64 %.add, i64 1064) - %74 = getelementptr i8, ptr %4, i64 %smin - %scevgep = getelementptr i8, ptr %74, i64 -1 + %74 = add i64 %smin, -1 + %scevgep = getelementptr i8, ptr %4, i64 %74 br label %.lr.ph -75: ; preds = %.lr.ph - %.0.add = add nsw i64 %.0.idx75, -1 +75: ; preds = %.lr.ph.preheader, %76 + %.0.ptr77 = phi ptr [ %.0.ptr, %76 ], [ %.ptr59, %.lr.ph.preheader ] + %.0.idx76 = phi i64 [ %.0.add, %76 ], [ %.add, %.lr.ph.preheader ] + %75 = load i8, ptr %.0.ptr77, align 1 + %.not60 = icmp eq i8 %75, 46 + br i1 %.not60, label %.critedge, label %76 + +76: ; preds = %.lr.ph + %.0.add = add nsw i64 %.0.idx76, -1 %.0.ptr = getelementptr inbounds i8, ptr %4, i64 %.0.add - %.not = icmp slt i64 %.0.idx75, 1065 + %.not = icmp slt i64 %.0.idx76, 1065 br i1 %.not, label %.critedge, label %.lr.ph, !llvm.loop !68 -.lr.ph: ; preds = %.lr.ph.preheader, %75 - %.0.ptr76 = phi ptr [ %.0.ptr, %75 ], [ %.ptr59, %.lr.ph.preheader ] - %.0.idx75 = phi i64 [ %.0.add, %75 ], [ %.add, %.lr.ph.preheader ] - %76 = load i8, ptr %.0.ptr76, align 1 - %.not60 = icmp eq i8 %76, 46 - br i1 %.not60, label %.critedge, label %75 - -.critedge: ; preds = %.lr.ph, %75, %_ZNSt6vectorIP9aiTextureSaIS1_EE9push_backEOS1_.exit - %.0.ptr.lcssa = phi ptr [ %.ptr59, %_ZNSt6vectorIP9aiTextureSaIS1_EE9push_backEOS1_.exit ], [ %scevgep, %75 ], [ %.0.ptr76, %.lr.ph ] - %77 = getelementptr inbounds nuw i8, ptr %.0.ptr.lcssa, i64 1 - %78 = icmp ugt ptr %77, %.ptr59 - br i1 %78, label %84, label %79 - -79: ; preds = %.critedge - %80 = load i8, ptr %77, align 1 - %81 = zext i8 %80 to i32 - %82 = tail call i32 @tolower(i32 noundef %81) #31 - %83 = trunc i32 %82 to i8 - br label %84 - -84: ; preds = %.critedge, %79 - %85 = phi i8 [ %83, %79 ], [ 0, %.critedge ] - %86 = getelementptr inbounds nuw i8, ptr %72, i64 8 - store i8 %85, ptr %86, align 8 - %87 = getelementptr inbounds nuw i8, ptr %.0.ptr.lcssa, i64 2 - %88 = icmp ugt ptr %87, %.ptr59 - br i1 %88, label %94, label %89 - -89: ; preds = %84 - %90 = load i8, ptr %87, align 1 - %91 = zext i8 %90 to i32 - %92 = tail call i32 @tolower(i32 noundef %91) #31 - %93 = trunc i32 %92 to i8 - br label %94 - -94: ; preds = %84, %89 - %95 = phi i8 [ %93, %89 ], [ 0, %84 ] - %96 = getelementptr inbounds nuw i8, ptr %72, i64 9 - store i8 %95, ptr %96, align 1 - %97 = getelementptr inbounds nuw i8, ptr %.0.ptr.lcssa, i64 3 - %98 = icmp ugt ptr %97, %.ptr59 - br i1 %98, label %104, label %99 - -99: ; preds = %94 - %100 = load i8, ptr %97, align 1 +.lr.ph: ; preds = %.lr.ph, %76 + %.0.ptr76 = phi i64 [ %.0.idx76, %.lr.ph ], [ %74, %76 ] + %.0.idx75 = phi ptr [ %.0.ptr77, %.lr.ph ], [ %scevgep, %76 ] + %.not61 = icmp slt i64 %.0.ptr76, %.add + br i1 %.not61, label %77, label %.critedge.thread + +77: ; preds = %.critedge + %78 = getelementptr inbounds nuw i8, ptr %.0.idx75, i64 1 + %79 = load i8, ptr %78, align 1 + %80 = zext i8 %79 to i32 + %81 = tail call i32 @tolower(i32 noundef %80) #31 + %82 = trunc i32 %81 to i8 + br label %.critedge.thread + +.critedge.thread:; preds = %_ZNSt6vectorIP9aiTextureSaIS1_EE9push_backEOS1_.exit, %.lr.ph, %77 + %.0.ptr.lcssa86 = phi ptr [ %.0.idx75, %77 ], [ %.0.idx75, %.critedge ], [ %.ptr59, %_ZNSt6vectorIP9aiTextureSaIS1_EE9push_backEOS1_.exit ] + %.0.idx.lcssa85 = phi i64 [ %.0.ptr76, %77 ], [ %.0.ptr76, %.critedge ], [ %.add, %_ZNSt6vectorIP9aiTextureSaIS1_EE9push_backEOS1_.exit ] + %83 = phi i8 [ %82, %77 ], [ 0, %.critedge ], [ 0, %_ZNSt6vectorIP9aiTextureSaIS1_EE9push_backEOS1_.exit ] + %84 = getelementptr inbounds nuw i8, ptr %72, i64 8 + store i8 %83, ptr %84, align 8 + %85 = add nsw i64 %73, 1062 + %86 = icmp sgt i64 %.0.idx.lcssa85, %85 + br i1 %86, label %93, label %87 + +87: ; preds = %.critedge.thread + %88 = getelementptr inbounds nuw i8, ptr %.0.ptr.lcssa86, i64 2 + %89 = load i8, ptr %88, align 1 + %90 = zext i8 %89 to i32 + %91 = tail call i32 @tolower(i32 noundef %90) #31 + %92 = trunc i32 %91 to i8 + br label %93 + +93:; preds = %.critedge.thread, %87 + %94 = phi i8 [ %92, %87 ], [ 0, %.critedge.thread ] + %95 = getelementptr inbounds nuw i8, ptr %72, i64 9 + store i8 %94, ptr %95, align 1 + %96 = add nsw i64 %73, 1061 + %97 = icmp sgt i64 %.0.idx.lcssa85, %96 + br i1 %97, label %104, label %98 + +98:; preds = %93 + %99 = getelementptr inbounds nuw i8, ptr %.0.ptr.lcssa86, i64 3 + %100 = load i8, ptr %99, align 1 %101 = zext i8 %100 to i32 %102 = tail call i32 @tolower(i32 noundef %101) #31 %103 = trunc i32 %102 to i8 br label %104 -104: ; preds = %94, %99 - %105 = phi i8 [ %103, %99 ], [ 0, %94 ] +104: ; preds = %93, %98 + %105 = phi i8 [ %103, %98 ], [ 0, %93 ] %106 = getelementptr inbounds nuw i8, ptr %72, i64 10 store i8 %105, ptr %106, align 2 %107 = getelementptr inbounds nuw i8, ptr %72, i64 11 diff --git a/bench/assimp/optimized/MMDPmxParser.ll b/bench/assimp/optimized/MMDPmxParser.ll index 431606d164a..4464f117b7a 100644 --- a/bench/assimp/optimized/MMDPmxParser.ll +++ b/bench/assimp/optimized/MMDPmxParser.ll @@ -5159,7 +5159,7 @@ define hidden void @_ZN3pmx8PmxModel4ReadEPSi(ptr noundef nonnull align 8 derefe 39: ; preds = %38 invoke void @__cxa_throw(ptr nonnull %36, ptr nonnull @_ZTI17DeadlyImportError, ptr nonnull @_ZNSt13runtime_errorD2Ev) #21 - to label %736 unwind label %41 + to label %734 unwind label %41 _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev.exit.thread: ; preds = %35 %40 = landingpad { ptr, i32 } @@ -6598,16 +6598,11 @@ _ZNSt10unique_ptrIA_N3pmx12PmxRigidBodyESt14default_deleteIS2_EED2Ev.exit: ; pre %683 = select i1 %680, i64 -1, i64 %682 %684 = call noalias noundef nonnull ptr @_Znam(i64 noundef %683) #22, !noalias !82 store i64 %678, ptr %684, align 16, !noalias !82 - %.ptr5.i = getelementptr inbounds nuw i8, ptr %684, i64 8 %685 = icmp eq i32 %677, 0 - br i1 %685, label %_ZN3mmd11make_uniqueIA_N3pmx8PmxJointEEENS_10_Unique_ifIT_E14_Unknown_boundEm.exit, label %686 + br i1 %685, label %_ZN3mmd11make_uniqueIA_N3pmx8PmxJointEEENS_10_Unique_ifIT_E14_Unknown_boundEm.exit, label %688 -686: ; preds = %._crit_edge261 - %687 = getelementptr inbounds %"class.pmx::PmxJoint", ptr %.ptr5.i, i64 %678 - br label %688 - -688: ; preds = %688, %686 - %.idx.i = phi i64 [ 8, %686 ], [ %.add.i, %688 ] +688: ; preds = %._crit_edge261, %688 + %.idx.i = phi i64 [ %.add.i, %.preheader ], [ 8, %._crit_edge261 ] %.ptr.ptr.i = getelementptr inbounds nuw i8, ptr %684, i64 %.idx.i %689 = getelementptr inbounds nuw i8, ptr %.ptr.ptr.i, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(160) %689, i8 0, i64 160, i1 false), !noalias !82 @@ -6620,30 +6615,31 @@ _ZNSt10unique_ptrIA_N3pmx12PmxRigidBodyESt14default_deleteIS2_EED2Ev.exit: ; pre %693 = getelementptr inbounds nuw i8, ptr %.ptr.ptr.i, i64 68 call void @llvm.memset.p0.i64(ptr noundef nonnull align 4 dereferenceable(104) %693, i8 0, i64 104, i1 false), !noalias !82 %.add.i = add nuw nsw i64 %.idx.i, 176 - %.ptr4.i = getelementptr inbounds nuw i8, ptr %684, i64 %.add.i - %694 = icmp eq ptr %.ptr4.i, %687 + %691 = add nuw nsw i64 %.idx.i, 168 + %694 = icmp eq i64 %691, %681 br i1 %694, label %_ZN3mmd11make_uniqueIA_N3pmx8PmxJointEEENS_10_Unique_ifIT_E14_Unknown_boundEm.exit, label %688 _ZN3mmd11make_uniqueIA_N3pmx8PmxJointEEENS_10_Unique_ifIT_E14_Unknown_boundEm.exit: ; preds = %688, %._crit_edge261 - %695 = getelementptr inbounds nuw i8, ptr %0, i64 280 - %696 = load ptr, ptr %695, align 8 - store ptr %.ptr5.i, ptr %695, align 8 - %.not.i.i.i.i192 = icmp eq ptr %696, null - br i1 %.not.i.i.i.i192, label %_ZNSt10unique_ptrIA_N3pmx8PmxJointESt14default_deleteIS2_EED2Ev.exit, label %697 - -697: ; preds = %_ZN3mmd11make_uniqueIA_N3pmx8PmxJointEEENS_10_Unique_ifIT_E14_Unknown_boundEm.exit - %698 = getelementptr inbounds i8, ptr %696, i64 -8 - %699 = load i64, ptr %698, align 8 - %.idx.i.i.i.i.i193 = mul i64 %699, 176 - %700 = icmp eq i64 %699, 0 - br i1 %700, label %_ZNKSt14default_deleteIA_N3pmx8PmxJointEEclIS1_EENSt9enable_ifIXsr14is_convertibleIPA_T_PS2_EE5valueEvE4typeEPS6_.exit.i.i.i.i, label %.preheader.preheader.i.i.i.i.i194 - -.preheader.preheader.i.i.i.i.i194: ; preds = %697 - %701 = getelementptr inbounds i8, ptr %696, i64 %.idx.i.i.i.i.i193 + %695 = getelementptr inbounds nuw i8, ptr %684, i64 8 + %693 = getelementptr inbounds nuw i8, ptr %0, i64 280 + %694 = load ptr, ptr %693, align 8 + store ptr %.ptr5.i, ptr %693, align 8 + %.not.i.i.i.i192 = icmp eq ptr %694, null + br i1 %.not.i.i.i.i192, label %_ZNSt10unique_ptrIA_N3pmx8PmxJointESt14default_deleteIS2_EED2Ev.exit, label %695 + +695:; preds = %_ZN3mmd11make_uniqueIA_N3pmx8PmxJointEEENS_10_Unique_ifIT_E14_Unknown_boundEm.exit + %696 = getelementptr inbounds i8, ptr %694, i64 -8 + %697 = load i64, ptr %696, align 8 + %.idx.i.i.i.i.i193 = mul i64 %697, 176 + %698 = icmp eq i64 %697, 0 + br i1 %698, label %_ZNKSt14default_deleteIA_N3pmx8PmxJointEEclIS1_EENSt9enable_ifIXsr14is_convertibleIPA_T_PS2_EE5valueEvE4typeEPS6_.exit.i.i.i.i, label %.preheader.preheader.i.i.i.i.i194 + +.preheader.preheader.i.i.i.i.i194:; preds = %695 + %699 = getelementptr inbounds i8, ptr %694, i64 %.idx.i.i.i.i.i193 br label %.preheader.i.i.i.i.i195 .preheader.i.i.i.i.i195: ; preds = %_ZN3pmx8PmxJointD2Ev.exit.i.i.i.i.i, %.preheader.preheader.i.i.i.i.i194 - %702 = phi ptr [ %703, %_ZN3pmx8PmxJointD2Ev.exit.i.i.i.i.i ], [ %701, %.preheader.preheader.i.i.i.i.i194 ] + %702 = phi ptr [ %703, %_ZN3pmx8PmxJointD2Ev.exit.i.i.i.i.i ], [ %699, %.preheader.preheader.i.i.i.i.i194 ] %703 = getelementptr inbounds i8, ptr %702, i64 -176 %704 = getelementptr inbounds i8, ptr %702, i64 -144 %705 = load ptr, ptr %704, align 8 @@ -6684,12 +6680,12 @@ _ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i1. br label %_ZN3pmx8PmxJointD2Ev.exit.i.i.i.i.i _ZN3pmx8PmxJointD2Ev.exit.i.i.i.i.i: ; preds = %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.i.i1.i.i.i.i.i.i198, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i2.i.i.i.i.i.i199 - %721 = icmp eq ptr %703, %696 + %721 = icmp eq ptr %703, %694 br i1 %721, label %_ZNKSt14default_deleteIA_N3pmx8PmxJointEEclIS1_EENSt9enable_ifIXsr14is_convertibleIPA_T_PS2_EE5valueEvE4typeEPS6_.exit.i.i.i.i, label %.preheader.i.i.i.i.i195 -_ZNKSt14default_deleteIA_N3pmx8PmxJointEEclIS1_EENSt9enable_ifIXsr14is_convertibleIPA_T_PS2_EE5valueEvE4typeEPS6_.exit.i.i.i.i: ; preds = %_ZN3pmx8PmxJointD2Ev.exit.i.i.i.i.i, %697 +_ZNKSt14default_deleteIA_N3pmx8PmxJointEEclIS1_EENSt9enable_ifIXsr14is_convertibleIPA_T_PS2_EE5valueEvE4typeEPS6_.exit.i.i.i.i: ; preds = %_ZN3pmx8PmxJointD2Ev.exit.i.i.i.i.i, %695 %722 = or disjoint i64 %.idx.i.i.i.i.i193, 8 - call void @_ZdaPvm(ptr noundef nonnull %698, i64 noundef %722) #23 + call void @_ZdaPvm(ptr noundef nonnull %696, i64 noundef %722) #23 %.pre296 = load i32, ptr %675, align 8 br label %_ZNSt10unique_ptrIA_N3pmx8PmxJointESt14default_deleteIS2_EED2Ev.exit @@ -6715,7 +6711,7 @@ _ZNSt10unique_ptrIA_N3pmx8PmxJointESt14default_deleteIS2_EED2Ev.exit: ; preds = .lr.ph263: ; preds = %_ZNSt10unique_ptrIA_N3pmx8PmxJointESt14default_deleteIS2_EED2Ev.exit, %.lr.ph263 %indvars.iv287 = phi i64 [ %indvars.iv.next288, %.lr.ph263 ], [ 0, %_ZNSt10unique_ptrIA_N3pmx8PmxJointESt14default_deleteIS2_EED2Ev.exit ] - %730 = load ptr, ptr %695, align 8 + %730 = load ptr, ptr %693, align 8 %731 = getelementptr inbounds nuw %"class.pmx::PmxJoint", ptr %730, i64 %indvars.iv287 call void @_ZN3pmx8PmxJoint4ReadEPSiPNS_10PmxSettingE(ptr noundef nonnull align 8 dereferenceable(172) %731, ptr noundef nonnull %1, ptr noundef nonnull %52) %indvars.iv.next288 = add nuw nsw i64 %indvars.iv287, 1 diff --git a/bench/boost/optimized/area_geo.ll b/bench/boost/optimized/area_geo.ll index 5439a3c84db..725a681cdc7 100644 --- a/bench/boost/optimized/area_geo.ll +++ b/bench/boost/optimized/area_geo.ll @@ -148227,8 +148227,9 @@ define linkonce_odr hidden noundef double @_ZN5boost12lexical_castIdNSt7__cxx111 24: ; preds = %23 %25 = getelementptr inbounds nuw i8, ptr %.037.i.i, i64 3 - %.not.i.i = icmp eq ptr %8, %25 - br i1 %.not.i.i, label %33, label %26 + %26 = select i1 %or.cond.i.i, i64 4, i64 3 + %.not.i.i = icmp samesign eq i64 %7, %26 + br i1 %.not.i.i, label %34, label %27 26: ; preds = %24 %.neg = select i1 %or.cond.i.i, i64 -4, i64 -3 @@ -148258,7 +148259,7 @@ _ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit.i.i: ; preds = %20 ] .lr.ph.i46.i.i: ; preds = %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit.i.i, %41 - %indvars.iv.i47.i.i = phi i64 [ %indvars.iv.next.i51.i.i, %41 ], [ 0, %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit.i.i ] + %indvars.iv.i47.i.i = phi i64 [ %indvars.iv.next.i51.i.i, %42 ], [ 0, %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit.i.i ] %34 = getelementptr inbounds nuw i8, ptr %.037.i.i, i64 %indvars.iv.i47.i.i %35 = load i8, ptr %34, align 1, !tbaa !24 %36 = getelementptr inbounds nuw i8, ptr @.str.818, i64 %indvars.iv.i47.i.i @@ -148278,7 +148279,7 @@ _ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit.i.i: ; preds = %20 br i1 %exitcond.not.i52.i.i, label %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit53.thread.i.i, label %.lr.ph.i46.i.i, !llvm.loop !2577 .lr.ph.i54.i.i: ; preds = %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit.i.i, %49 - %indvars.iv.i55.i.i = phi i64 [ %indvars.iv.next.i59.i.i, %49 ], [ 0, %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit.i.i ] + %indvars.iv.i55.i.i = phi i64 [ %indvars.iv.next.i59.i.i, %50 ], [ 0, %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit.i.i ] %42 = getelementptr inbounds nuw i8, ptr %.037.i.i, i64 %indvars.iv.i55.i.i %43 = load i8, ptr %42, align 1, !tbaa !24 %44 = getelementptr inbounds nuw i8, ptr @.str.818, i64 %indvars.iv.i55.i.i @@ -148302,7 +148303,7 @@ _ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit53.thread.i.i: ; preds = %49, %41 br label %_ZN5boost10conversion6detail19try_lexical_convertIdNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEbRKT0_RT_.exit.thread _ZN5boost10conversion6detail19try_lexical_convertIdNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEbRKT0_RT_.exit.thread: ; preds = %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit53.thread.i.i, %33 - %storemerge45.sink.i.i = phi double [ %storemerge45.i.i, %33 ], [ %storemerge.i.i, %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit53.thread.i.i ] + %storemerge45.sink.i.i = phi double [ %storemerge45.i.i, %34 ], [ %storemerge.i.i, %_ZN5boost6detail9lc_iequalIcEEbPKT_S4_S4_j.exit53.thread.i.i ] call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #57 br label %60 @@ -148335,7 +148336,7 @@ _ZN5boost10conversion6detail19try_lexical_convertIdNSt7__cxx1112basic_stringIcSt %56 = getelementptr inbounds nuw i8, ptr %2, i64 16 store ptr @_ZTId, ptr %56, align 8, !tbaa !2582 invoke void @_ZN5boost15throw_exceptionINS_16bad_lexical_castEEEvRKT_(ptr noundef nonnull align 8 dereferenceable(24) %2) #56 - to label %57 unwind label %58 + to label %58 unwind label %58 57: ; preds = %_ZN5boost10conversion6detail19try_lexical_convertIdNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEbRKT0_RT_.exit.thread3 unreachable diff --git a/bench/cmake/optimized/archive_read_support_format_7zip.ll b/bench/cmake/optimized/archive_read_support_format_7zip.ll index 2f4259c3f3b..b344973f183 100644 --- a/bench/cmake/optimized/archive_read_support_format_7zip.ll +++ b/bench/cmake/optimized/archive_read_support_format_7zip.ll @@ -165,9 +165,9 @@ define internal range(i32 -1, 49) i32 @archive_read_format_7zip_bid(ptr noundef br label %20 20: ; preds = %19, %56 - %21 = phi i64 [ 163840, %19 ], [ %57, %56 ] - %.03061 = phi i64 [ 4096, %19 ], [ %.131, %56 ] - %.03260 = phi i64 [ 159744, %19 ], [ %.133, %56 ] + %21 = phi i64 [ 163840, %19 ], [ %57, %55 ] + %.03061 = phi i64 [ 4096, %19 ], [ %.131, %55 ] + %.03260 = phi i64 [ 159744, %19 ], [ %.133, %55 ] %22 = call ptr @__archive_read_ahead(ptr noundef %0, i64 noundef %21, ptr noundef nonnull %3) #17 %23 = icmp eq ptr %22, null br i1 %23, label %24, label %27 @@ -179,24 +179,23 @@ define internal range(i32 -1, 49) i32 @archive_read_format_7zip_bid(ptr noundef 27: ; preds = %20 %28 = getelementptr inbounds i8, ptr %22, i64 %.03260 - %29 = getelementptr inbounds nuw i8, ptr %28, i64 32 - %30 = load i64, ptr %3, align 8, !tbaa !38 - %31 = getelementptr inbounds i8, ptr %22, i64 %30 - %32 = icmp ult ptr %29, %31 - br i1 %32, label %.lr.ph, label %._crit_edge + %29 = load i64, ptr %3, align 8, !tbaa !38 + %30 = add nsw i64 %.03260, 32 + %31 = icmp slt i64 %30, %29 + br i1 %31, label %.lr.ph, label %._crit_edge .lr.ph: ; preds = %27, %check_7zip_header_in_sfx.exit - %33 = phi i64 [ %48, %check_7zip_header_in_sfx.exit ], [ %30, %27 ] - %.02859 = phi ptr [ %49, %check_7zip_header_in_sfx.exit ], [ %28, %27 ] + %33 = phi i64 [ %47, %check_7zip_header_in_sfx.exit ], [ %29, %27 ] + %.02859 = phi ptr [ %48, %check_7zip_header_in_sfx.exit ], [ %28, %27 ] %34 = getelementptr inbounds nuw i8, ptr %.02859, i64 5 %35 = load i8, ptr %34, align 1, !tbaa !37 - switch i8 %35, label %47 [ + switch i8 %35, label %46 [ i8 28, label %36 i8 55, label %check_7zip_header_in_sfx.exit - i8 122, label %43 - i8 -68, label %44 - i8 -81, label %45 - i8 39, label %46 + i8 122, label %42 + i8 -68, label %43 + i8 -81, label %44 + i8 39, label %45 ] 36: ; preds = %.lr.ph @@ -217,6 +216,9 @@ define internal range(i32 -1, 49) i32 @archive_read_format_7zip_bid(ptr noundef %.pre = load i64, ptr %3, align 8, !tbaa !38 br label %check_7zip_header_in_sfx.exit +42: ; preds = %.lr.ph + br label %check_7zip_header_in_sfx.exit + 43: ; preds = %.lr.ph br label %check_7zip_header_in_sfx.exit @@ -229,20 +231,17 @@ define internal range(i32 -1, 49) i32 @archive_read_format_7zip_bid(ptr noundef 46: ; preds = %.lr.ph br label %check_7zip_header_in_sfx.exit -47: ; preds = %.lr.ph - br label %check_7zip_header_in_sfx.exit - -check_7zip_header_in_sfx.exit: ; preds = %.check_7zip_header_in_sfx.exit_crit_edge, %.lr.ph, %36, %43, %44, %45, %46, %47 - %48 = phi i64 [ %33, %47 ], [ %33, %43 ], [ %33, %44 ], [ %33, %45 ], [ %33, %46 ], [ %33, %36 ], [ %.pre, %.check_7zip_header_in_sfx.exit_crit_edge ], [ %33, %.lr.ph ] - %.0.i = phi i64 [ 6, %47 ], [ 4, %43 ], [ 3, %44 ], [ 2, %45 ], [ 1, %46 ], [ 6, %36 ], [ 6, %.check_7zip_header_in_sfx.exit_crit_edge ], [ 5, %.lr.ph ] - %49 = getelementptr inbounds nuw i8, ptr %.02859, i64 %.0.i - %50 = getelementptr inbounds nuw i8, ptr %49, i64 32 - %51 = getelementptr inbounds i8, ptr %22, i64 %48 - %52 = icmp ult ptr %50, %51 - br i1 %52, label %.lr.ph, label %._crit_edge, !llvm.loop !39 +47: ; preds = %.check_7zip_header_in_sfx.exit_crit_edge, %.lr.ph, %35, %42, %43, %44, %45, %46 + %47 = phi i64 [ %32, %46 ], [ %32, %42 ], [ %32, %43 ], [ %32, %44 ], [ %32, %45 ], [ %32, %35 ], [ %.pre, %.check_7zip_header_in_sfx.exit_crit_edge ], [ %32, %.lr.ph ] + %.0.i = phi i64 [ 6, %46 ], [ 4, %42 ], [ 3, %43 ], [ 2, %44 ], [ 1, %45 ], [ 6, %35 ], [ 6, %.check_7zip_header_in_sfx.exit_crit_edge ], [ 5, %.lr.ph ] + %48 = getelementptr inbounds nuw i8, ptr %.02859, i64 %.0.i + %49 = getelementptr inbounds nuw i8, ptr %48, i64 32 + %50 = getelementptr inbounds i8, ptr %22, i64 %47 + %51 = icmp ult ptr %49, %50 + br i1 %51, label %.lr.ph, label %._crit_edge, !llvm.loop !39 ._crit_edge: ; preds = %check_7zip_header_in_sfx.exit, %27 - %.028.lcssa = phi ptr [ %28, %27 ], [ %49, %check_7zip_header_in_sfx.exit ] + %.028.lcssa = phi ptr [ %28, %27 ], [ %48, %check_7zip_header_in_sfx.exit ] %53 = ptrtoint ptr %.028.lcssa to i64 %54 = ptrtoint ptr %22 to i64 %55 = sub i64 %53, %54 @@ -256,7 +255,7 @@ check_7zip_header_in_sfx.exit: ; preds = %.check_7zip_header_ br i1 %58, label %20, label %.sink.split .sink.split: ; preds = %24, %56, %37 - %.0.ph = phi i32 [ 48, %37 ], [ 0, %56 ], [ 0, %24 ] + %.0.ph = phi i32 [ 48, %36 ], [ 0, %55 ], [ 0, %24 ] call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #17 br label %59 diff --git a/bench/cmake/optimized/cmList.ll b/bench/cmake/optimized/cmList.ll index b17eeecec9e..359bce87741 100644 --- a/bench/cmake/optimized/cmList.ll +++ b/bench/cmake/optimized/cmList.ll @@ -6283,12 +6283,15 @@ _ZSt13move_backwardIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEES6_ET0_T br i1 %.not.i.i.i.i29, label %"_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops15_Iter_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_SF_T0_.exit.i.i.i", label %.lr.ph.i.i.i.i, !llvm.loop !269 "_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops15_Iter_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_SF_T0_.exit.i.i.i": ; preds = %"_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops14_Val_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_T0_.exit.i.i.i.i" + %.not6.i.i.i.i = icmp eq i64 %.0.i.i.i.i.i.idx, 120 + br i1 %.not6.i.i.i.i, label %.preheader.i.i.i.preheader, label %.lr.ph.i12.i.i.i.preheader + +.lr.ph.i12.i.i.i.preheader: ; preds = %"_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops15_Iter_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_SF_T0_.exit.i.i.i" %37 = getelementptr inbounds nuw i8, ptr %13, i64 128 - %.not6.i.i.i.i = icmp eq ptr %37, %.0.i.i.i.i.i.ptr - br i1 %.not6.i.i.i.i, label %.preheader.i.i.i.preheader, label %.lr.ph.i12.i.i.i + br label %.lr.ph.i12.i.i.i -.lr.ph.i12.i.i.i: ; preds = %"_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops15_Iter_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_SF_T0_.exit.i.i.i", %"_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops14_Val_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_T0_.exit.i13.i.i.i" - %.sroa.0.07.i.i.i.i = phi ptr [ %44, %"_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops14_Val_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_T0_.exit.i13.i.i.i" ], [ %37, %"_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops15_Iter_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_SF_T0_.exit.i.i.i" ] +.lr.ph.i12.i.i.i: ; preds = %.lr.ph.i12.i.i.i.preheader, %"_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops14_Val_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_T0_.exit.i13.i.i.i" + %.sroa.0.07.i.i.i.i = phi ptr [ %44, %"_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPmSt6vectorImSaImEEEENS0_5__ops14_Val_comp_iterIZN6cmList11RemoveItemsEOS3_IlSaIlEEE3$_1EEEvT_T0_.exit.i13.i.i.i" ], [ %37, %.lr.ph.i12.i.i.i.preheader ] %38 = load i64, ptr %.sroa.0.07.i.i.i.i, align 8, !tbaa !4 %.sroa.0.07.i.i.i.i.i = getelementptr inbounds i8, ptr %.sroa.0.07.i.i.i.i, i64 -8 %39 = load i64, ptr %.sroa.0.07.i.i.i.i.i, align 8, !tbaa !4 diff --git a/bench/coreutils-rs/optimized/4ws6541n7p4pbb05.ll b/bench/coreutils-rs/optimized/4ws6541n7p4pbb05.ll index 8965d4b605b..8a03cfd8092 100644 --- a/bench/coreutils-rs/optimized/4ws6541n7p4pbb05.ll +++ b/bench/coreutils-rs/optimized/4ws6541n7p4pbb05.ll @@ -2865,7 +2865,7 @@ default.unreachable85: ; preds = %26 i8 3, label %100 ] -32: ; preds = %100, %97, %47, %34 +32: ; preds = %100, %99, %47, %34 %33 = landingpad { ptr, i32 } cleanup br label %.body @@ -2873,7 +2873,7 @@ default.unreachable85: ; preds = %26 .body: ; preds = %43, %32 %eh.lpad-body = phi { ptr, i32 } [ %33, %32 ], [ %44, %43 ] invoke fastcc void @"_ZN4core3ptr50drop_in_place$LT$alloc..borrow..Cow$LT$str$GT$$GT$17hb45995eb825925d8E"(ptr noalias noundef align 8 dereferenceable(24) %18) #23 - to label %118 unwind label %116 + to label %120 unwind label %116 34: ; preds = %26 call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %17) @@ -2984,83 +2984,85 @@ _ZN5alloc3fmt6format17h7ead8f60e83381d7E.exit44: ; preds = %47 call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) %.pn1.in.i31 = getelementptr inbounds nuw i8, ptr %18, i64 16 %.pn1.i32 = load i64, ptr %.pn1.in.i31, align 8, !alias.scope !571, !noundef !5 + %.not.i.i = icmp eq i64 %.pn1.i32, 0 + br i1 %.not.i.i, label %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82, label %51 + +51: ; preds = %50 %.pn3.in.i33 = getelementptr inbounds nuw i8, ptr %18, i64 8 %.pn3.i34 = load ptr, ptr %.pn3.in.i33, align 8, !alias.scope !571, !nonnull !5, !noundef !5 - %51 = getelementptr inbounds i8, ptr %.pn3.i34, i64 %.pn1.i32 - %.not.i.i = icmp eq i64 %.pn1.i32, 0 - br i1 %.not.i.i, label %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82, label %52 - -52: ; preds = %50 - %53 = load i8, ptr %.pn3.i34, align 1, !noalias !574, !noundef !5 - %54 = zext i8 %53 to i64 - %55 = getelementptr inbounds nuw [256 x i8], ptr @anon.87f6e18fecb33f35561fd9552121b522.31, i64 0, i64 %54 - %56 = load i8, ptr %55, align 1, !noalias !574, !noundef !5 - %57 = zext i8 %56 to i64 - %58 = getelementptr inbounds nuw i8, ptr %.pn3.i34, i64 %57 - %59 = icmp uge i64 %.pn1.i32, %57 - tail call void @llvm.assume(i1 %59) - %60 = icmp eq i64 %.pn1.i32, %57 - br i1 %60, label %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82, label %61 - -61: ; preds = %52 - %62 = load i8, ptr %58, align 1, !noalias !579, !noundef !5 - %63 = icmp sgt i8 %62, -1 - br i1 %63, label %74, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit13.i.i.i" - -"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit13.i.i.i": ; preds = %61 - %64 = getelementptr inbounds nuw i8, ptr %58, i64 1 - %65 = and i8 %62, 31 - %66 = zext nneg i8 %65 to i32 - %67 = icmp ne ptr %64, %51 + %52 = load i8, ptr %.pn3.i34, align 1, !noalias !574, !noundef !5 + %53 = zext i8 %52 to i64 + %54 = getelementptr inbounds nuw [256 x i8], ptr @anon.87f6e18fecb33f35561fd9552121b522.31, i64 0, i64 %53 + %55 = load i8, ptr %54, align 1, !noalias !574, !noundef !5 + %56 = zext i8 %55 to i64 + %57 = getelementptr inbounds nuw i8, ptr %.pn3.i34, i64 %56 + %58 = icmp uge i64 %.pn1.i32, %56 + tail call void @llvm.assume(i1 %58) + %59 = icmp eq i64 %.pn1.i32, %56 + br i1 %59, label %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82, label %60 + +60:; preds = %51 + %61 = load i8, ptr %57, align 1, !noalias !579, !noundef !5 + %60 = icmp sgt i8 %61, -1 + br i1 %60, label %74, label %61 + +61: ; preds = %60 + %63 = getelementptr inbounds nuw i8, ptr %57, i64 1 + %64 = and i8 %61, 31 + %65 = zext nneg i8 %64 to i32 + %66 = add nuw nsw i64 %56, 1 + %67 = icmp ne i64 %66, %.pn1.i32 tail call void @llvm.assume(i1 %67) - %68 = load i8, ptr %64, align 1, !noalias !579, !noundef !5 - %69 = shl nuw nsw i32 %66, 6 + %68 = load i8, ptr %63, align 1, !noalias !579, !noundef !5 + %69 = shl nuw nsw i32 %65, 6 %70 = and i8 %68, 63 %71 = zext nneg i8 %70 to i32 %72 = or disjoint i32 %69, %71 - %73 = icmp samesign ugt i8 %62, -33 - br i1 %73, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit15.i.i.i", label %97 + %73 = icmp samesign ugt i8 %61, -33 + br i1 %73, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit15.i.i.i", label %99 -74: ; preds = %61 - %75 = zext nneg i8 %62 to i32 - br label %97 +74: ; preds = %60 + %75 = zext nneg i8 %61 to i32 + br label %99 "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit15.i.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit13.i.i.i" - %76 = getelementptr inbounds nuw i8, ptr %58, i64 2 - %77 = icmp ne ptr %76, %51 - tail call void @llvm.assume(i1 %77) - %78 = load i8, ptr %76, align 1, !noalias !579, !noundef !5 - %79 = shl nuw nsw i32 %71, 6 - %80 = and i8 %78, 63 - %81 = zext nneg i8 %80 to i32 - %82 = or disjoint i32 %79, %81 - %83 = shl nuw nsw i32 %66, 12 - %84 = or disjoint i32 %82, %83 - %85 = icmp samesign ugt i8 %62, -17 - br i1 %85, label %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit, label %97 + %76 = getelementptr inbounds nuw i8, ptr %57, i64 2 + %77 = add nuw nsw i64 %56, 2 + %78 = icmp ne i64 %77, %.pn1.i32 + tail call void @llvm.assume(i1 %78) + %79 = load i8, ptr %76, align 1, !noalias !579, !noundef !5 + %80 = shl nuw nsw i32 %71, 6 + %81 = and i8 %79, 63 + %82 = zext nneg i8 %81 to i32 + %83 = or disjoint i32 %80, %82 + %84 = shl nuw nsw i32 %65, 12 + %85 = or disjoint i32 %83, %84 + %86 = icmp samesign ugt i8 %61, -17 + br i1 %86, label %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit, label %99 _ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit: ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit15.i.i.i" - %86 = getelementptr inbounds nuw i8, ptr %58, i64 3 - %87 = icmp ne ptr %86, %51 - tail call void @llvm.assume(i1 %87) - %88 = load i8, ptr %86, align 1, !noalias !579, !noundef !5 - %89 = shl nuw nsw i32 %66, 18 - %90 = and i32 %89, 1835008 - %91 = shl nuw nsw i32 %82, 6 - %92 = and i8 %88, 63 - %93 = zext nneg i8 %92 to i32 - %94 = or disjoint i32 %91, %93 - %95 = or disjoint i32 %94, %90 - %.fr = freeze i32 %95 - %96 = icmp eq i32 %.fr, 1114112 - br i1 %96, label %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82, label %97 - -_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82: ; preds = %50, %52, %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit - br label %97 - -97: ; preds = %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82, %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit13.i.i.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit15.i.i.i", %74 - %98 = phi i32 [ 0, %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82 ], [ %.fr, %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit ], [ %75, %74 ], [ %84, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit15.i.i.i" ], [ %72, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit13.i.i.i" ] - store i32 %98, ptr %12, align 4 + %86 = getelementptr inbounds nuw i8, ptr %57, i64 3 + %88 = add nuw nsw i64 %56, 3 + %89 = icmp ne i64 %88, %.pn1.i32 + tail call void @llvm.assume(i1 %89) + %90 = load i8, ptr %86, align 1, !noalias !579, !noundef !5 + %91 = shl nuw nsw i32 %65, 18 + %92 = and i32 %91, 1835008 + %93 = shl nuw nsw i32 %83, 6 + %94 = and i8 %90, 63 + %95 = zext nneg i8 %94 to i32 + %95 = or disjoint i32 %93, %95 + %97 = or disjoint i32 %95, %92 + %.fr = freeze i32 %97 + %98 = icmp eq i32 %.fr, 1114112 + br i1 %98, label %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82, label %99 + +_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82:; preds = %50, %51, %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit + br label %99 + +99:; preds = %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82, %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit13.i.i.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit15.i.i.i", %74 + %100 = phi i32 [ 0, %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82 ], [ %.fr, %_ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit ], [ %75, %74 ], [ %85, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit15.i.i.i" ], [ %72, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h0a659e0ee6351131E.exit13.i.i.i" ] + store i32 %100, ptr %12, align 4 store ptr %12, ptr %13, align 8 %99 = getelementptr inbounds nuw i8, ptr %13, i64 8 store ptr @"_ZN43_$LT$char$u20$as$u20$core..fmt..Display$GT$3fmt17h522b74b1e908963bE", ptr %99, align 8 @@ -3077,7 +3079,7 @@ _ZN4core4iter6traits8iterator8Iterator3nth17h099989837e582776E.exit.thread82: ; invoke void @_ZN5alloc3fmt6format12format_inner17h20bbaee2ca87fbecE(ptr noalias noundef nonnull sret({ { { i64, ptr, {} }, i64 } }) align 8 captures(none) dereferenceable(24) %11, ptr noalias noundef nonnull align 8 captures(none) dereferenceable(48) %6) to label %_ZN5alloc3fmt6format17h7ead8f60e83381d7E.exit51 unwind label %32 -_ZN5alloc3fmt6format17h7ead8f60e83381d7E.exit51: ; preds = %97 +_ZN5alloc3fmt6format17h7ead8f60e83381d7E.exit51: ; preds = %99 call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %6), !noalias !584 call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %13) diff --git a/bench/cvc5/optimized/metakind.ll b/bench/cvc5/optimized/metakind.ll index 1e137ce9b6f..bfcbd76544d 100644 --- a/bench/cvc5/optimized/metakind.ll +++ b/bench/cvc5/optimized/metakind.ll @@ -644,28 +644,26 @@ _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc.exit: ; preds = %139 br i1 %.not135, label %152, label %.loopexit 152: ; preds = %150 - %153 = lshr i64 %5, 32 - %154 = and i64 %153, 67108863 - %.idx = shl nuw nsw i64 %154, 3 - %155 = getelementptr inbounds nuw i8, ptr %0, i64 %.idx - %.ptr143 = getelementptr inbounds nuw i8, ptr %155, i64 24 - %.not136138 = icmp eq i64 %154, 0 + %153 = getelementptr inbounds nuw i8, ptr %0, i64 24 + %154 = lshr i64 %5, 29 + %.idx = and i64 %154, 536870904 + %155 = getelementptr inbounds nuw i8, ptr %153, i64 %.idx + %.not136138 = icmp samesign eq i64 %.idx, 0 br i1 %.not136138, label %.loopexit, label %.lr.ph.preheader .lr.ph.preheader: ; preds = %152 %156 = getelementptr inbounds nuw i8, ptr %1, i64 24 - %.ptr = getelementptr inbounds nuw i8, ptr %0, i64 24 br label %.lr.ph .lr.ph: ; preds = %.lr.ph, %.lr.ph.preheader %.0133140 = phi ptr [ %156, %.lr.ph.preheader ], [ %160, %.lr.ph ] - %.0134139 = phi ptr [ %.ptr, %.lr.ph.preheader ], [ %159, %.lr.ph ] + %.0134139 = phi ptr [ %153, %.lr.ph.preheader ], [ %159, %.lr.ph ] %157 = load ptr, ptr %.0134139, align 8, !tbaa !7 %158 = load ptr, ptr %.0133140, align 8, !tbaa !7 %.not137 = icmp eq ptr %157, %158 %159 = getelementptr inbounds nuw i8, ptr %.0134139, i64 8 %160 = getelementptr inbounds nuw i8, ptr %.0133140, i64 8 - %.not136 = icmp ne ptr %159, %.ptr143 + %.not136 = icmp ne ptr %159, %155 %or.cond.not = select i1 %.not137, i1 %.not136, i1 false br i1 %or.cond.not, label %.lr.ph, label %.loopexit, !llvm.loop !10 @@ -5142,28 +5140,26 @@ _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc.exit: ; preds = %391 br i1 %.not135, label %404, label %.loopexit 404: ; preds = %402 - %405 = lshr i64 %5, 32 - %406 = and i64 %405, 67108863 - %.idx = shl nuw nsw i64 %406, 3 - %407 = getelementptr inbounds nuw i8, ptr %0, i64 %.idx - %.ptr143 = getelementptr inbounds nuw i8, ptr %407, i64 24 - %.not136138 = icmp eq i64 %406, 0 + %405 = getelementptr inbounds nuw i8, ptr %0, i64 24 + %406 = lshr i64 %5, 29 + %.idx = and i64 %406, 536870904 + %407 = getelementptr inbounds nuw i8, ptr %405, i64 %.idx + %.not136138 = icmp samesign eq i64 %.idx, 0 br i1 %.not136138, label %.loopexit, label %.lr.ph.preheader .lr.ph.preheader: ; preds = %404 %408 = getelementptr inbounds nuw i8, ptr %1, i64 24 - %.ptr = getelementptr inbounds nuw i8, ptr %0, i64 24 br label %.lr.ph .lr.ph: ; preds = %.lr.ph, %.lr.ph.preheader %.0133140 = phi ptr [ %408, %.lr.ph.preheader ], [ %412, %.lr.ph ] - %.0134139 = phi ptr [ %.ptr, %.lr.ph.preheader ], [ %411, %.lr.ph ] + %.0134139 = phi ptr [ %405, %.lr.ph.preheader ], [ %411, %.lr.ph ] %409 = load ptr, ptr %.0134139, align 8, !tbaa !7 %410 = load ptr, ptr %.0133140, align 8, !tbaa !7 %.not137 = icmp eq ptr %409, %410 %411 = getelementptr inbounds nuw i8, ptr %.0134139, i64 8 %412 = getelementptr inbounds nuw i8, ptr %.0133140, i64 8 - %.not136 = icmp ne ptr %411, %.ptr143 + %.not136 = icmp ne ptr %411, %407 %or.cond.not = select i1 %.not137, i1 %.not136, i1 false br i1 %or.cond.not, label %.lr.ph, label %.loopexit, !llvm.loop !48 diff --git a/bench/cvc5/optimized/trigger_term_info.ll b/bench/cvc5/optimized/trigger_term_info.ll index 95a11f46dd6..0fb3d0d2fda 100644 --- a/bench/cvc5/optimized/trigger_term_info.ll +++ b/bench/cvc5/optimized/trigger_term_info.ll @@ -2371,14 +2371,18 @@ _ZN4cvc58internal12NodeTemplateILb1EED2Ev.exit58: ; preds = %_ZN4cvc58internal6t 208: ; preds = %200 %209 = icmp eq i32 %207, 2 %spec.select.v.i.i = select i1 %209, i64 32, i64 24 - %spec.select.i.i59 = getelementptr inbounds nuw i8, ptr %.pre91, i64 %spec.select.v.i.i %210 = getelementptr inbounds nuw i8, ptr %.pre91, i64 24 %211 = load i64, ptr %201, align 8 - %212 = lshr i64 %211, 32 - %213 = and i64 %212, 67108863 - %214 = getelementptr inbounds nuw ptr, ptr %210, i64 %213 - %.not86 = icmp eq ptr %spec.select.i.i59, %214 - br i1 %.not86, label %._crit_edge, label %.lr.ph + %212 = lshr i64 %211, 29 + %213 = and i64 %212, 536870904 + %214 = getelementptr inbounds nuw i8, ptr %210, i64 %213 + %214 = add nuw nsw i64 %213, 24 + %.not86 = icmp samesign eq i64 %spec.select.v.i.i, %214 + br i1 %.not86, label %._crit_edge, label %.lr.ph.preheader + +.lr.ph.preheader: ; preds = %208 + %spec.select.i.i59 = getelementptr inbounds nuw i8, ptr %.pre91, i64 %spec.select.v.i.i + br label %.lr.ph 215: ; preds = %_ZN4cvc58internal12NodeTemplateILb1EED2Ev.exit69 %216 = getelementptr inbounds nuw i8, ptr %.sroa.080.087, i64 8 @@ -2390,8 +2394,8 @@ _ZN4cvc58internal12NodeTemplateILb1EED2Ev.exit58: ; preds = %_ZN4cvc58internal6t cleanup br label %345 -.lr.ph: ; preds = %208, %215 - %.sroa.080.087 = phi ptr [ %216, %215 ], [ %spec.select.i.i59, %208 ] +.lr.ph: ; preds = %.lr.ph.preheader, %215 + %.sroa.080.087 = phi ptr [ %216, %215 ], [ %spec.select.i.i59, %.lr.ph.preheader ] call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #20 call void @llvm.experimental.noalias.scope.decl(metadata !73) %219 = load ptr, ptr %.sroa.080.087, align 8, !tbaa !22, !noalias !73 diff --git a/bench/darktable/optimized/fp_dng.ll b/bench/darktable/optimized/fp_dng.ll index 0e6db9df4db..f07041069fa 100644 --- a/bench/darktable/optimized/fp_dng.ll +++ b/bench/darktable/optimized/fp_dng.ll @@ -1571,10 +1571,9 @@ define noundef range(i32 0, 2) i32 @_ZN6LibRaw17is_floating_pointEv(ptr noundef %3 = load i32, ptr %2, align 8, !tbaa !159 %4 = zext i32 %3 to i64 %.idx = mul nuw nsw i64 %4, 33408 - %5 = getelementptr inbounds nuw i8, ptr %0, i64 %.idx - %.ptr12 = getelementptr inbounds nuw i8, ptr %5, i64 433336 - %.not13 = icmp eq i32 %3, 0 - br i1 %.not13, label %.critedge, label %.lr.ph + %5 = getelementptr inbounds nuw i8, ptr %2, i64 %.idx + %.not12 = icmp eq i32 %4, 0 + br i1 %.not12, label %.critedge, label %.lr.ph .lr.ph: ; preds = %1 %6 = getelementptr inbounds nuw i8, ptr %0, i64 381584 @@ -1582,7 +1581,7 @@ define noundef range(i32 0, 2) i32 @_ZN6LibRaw17is_floating_pointEv(ptr noundef br label %8 8: ; preds = %.lr.ph, %12 - %.07 = phi ptr [ %.ptr, %.lr.ph ], [ %13, %12 ] + %.07 = phi ptr [ %.ptr, %.lr.ph ], [ %13, %13 ] %9 = getelementptr inbounds nuw i8, ptr %.07, i64 20 %10 = load i32, ptr %9, align 4, !tbaa !56 %11 = sext i32 %10 to i64 @@ -1591,12 +1590,12 @@ define noundef range(i32 0, 2) i32 @_ZN6LibRaw17is_floating_pointEv(ptr noundef 12: ; preds = %8 %13 = getelementptr inbounds nuw i8, ptr %.07, i64 33408 - %14 = icmp ult ptr %13, %.ptr12 + %14 = icmp ult ptr %13, %6 br i1 %14, label %8, label %.critedge, !llvm.loop !160 .critedge: ; preds = %8, %12, %1 - %.0.lcssa = phi ptr [ %.ptr, %1 ], [ %13, %12 ], [ %.07, %8 ] - %15 = icmp eq ptr %.0.lcssa, %.ptr12 + %.0.lcssa = phi ptr [ %.ptr, %1 ], [ %13, %13 ], [ %.07, %9 ] + %15 = icmp eq ptr %.0.lcssa, %6 br i1 %15, label %21, label %16 16: ; preds = %.critedge @@ -1607,7 +1606,7 @@ define noundef range(i32 0, 2) i32 @_ZN6LibRaw17is_floating_pointEv(ptr noundef br label %21 21: ; preds = %.critedge, %16 - %.06 = phi i32 [ %20, %16 ], [ 0, %.critedge ] + %.06 = phi i32 [ %20, %17 ], [ 0, %.critedge ] ret i32 %.06 } diff --git a/bench/darktable/optimized/imageop_math.ll b/bench/darktable/optimized/imageop_math.ll index 28662fdce45..d64e4206e7d 100644 --- a/bench/darktable/optimized/imageop_math.ll +++ b/bench/darktable/optimized/imageop_math.ll @@ -4,7 +4,7 @@ target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80: target triple = "x86_64-pc-linux-gnu" ; Function Attrs: nofree norecurse nosync nounwind memory(argmem: readwrite) uwtable -define void @dt_iop_flip_and_zoom_8(ptr noundef readonly captures(address) %0, i32 noundef %1, i32 noundef %2, ptr noundef writeonly captures(none) %3, i32 noundef %4, i32 noundef %5, i32 noundef %6, ptr noundef writeonly captures(none) initializes((0, 4)) %7, ptr noundef writeonly captures(none) initializes((0, 4)) %8) local_unnamed_addr #0 { +define void @dt_iop_flip_and_zoom_8(ptr noundef readonly captures(none) %0, i32 noundef %1, i32 noundef %2, ptr noundef writeonly captures(none) %3, i32 noundef %4, i32 noundef %5, i32 noundef %6, ptr noundef writeonly captures(none) initializes((0, 4)) %7, ptr noundef writeonly captures(none) initializes((0, 4)) %8) local_unnamed_addr #0 { %10 = and i32 %6, 4 %.not = icmp eq i32 %10, 0 %11 = select i1 %.not, i32 %1, i32 %2 @@ -64,9 +64,10 @@ define void @dt_iop_flip_and_zoom_8(ptr noundef readonly captures(address) %0, i %.not184 = icmp eq i32 %23, 0 %48 = shl i32 %.1, 2 %49 = sext i32 %42 to i64 + %invariant.op = sub nsw i64 0, %49 %50 = sext i32 %38 to i64 %51 = sext i32 %factor.op.mul.reass to i64 - %52 = getelementptr inbounds i8, ptr %0, i64 %51 + %invariant.op176 = sub nsw i64 %51, %50 br i1 %.not184, label %._crit_edge181, label %.lr.ph.us.preheader .lr.ph.us.preheader: ; preds = %.lr.ph180 @@ -92,29 +93,26 @@ define void @dt_iop_flip_and_zoom_8(ptr noundef readonly captures(address) %0, i %67 = add nsw i32 %47, %66 %68 = shl nsw i32 %67, 2 %69 = sext i32 %68 to i64 - %invariant.op.us = add nsw i64 %69, %49 - %invariant.gep196 = getelementptr i8, ptr %0, i64 %69 - %invariant.op = xor i64 %invariant.op.us, -1 - br label %70 + br label %69 -70: ; preds = %.lr.ph.us, %.loopexit.us +69:; preds = %.lr.ph.us, %.loopexit.us %.0151175.us = phi i32 [ 0, %.lr.ph.us ], [ %93, %.loopexit.us ] %.0152174.us = phi float [ 0.000000e+00, %.lr.ph.us ], [ %92, %.loopexit.us ] %.0154173.us = phi ptr [ %62, %.lr.ph.us ], [ %91, %.loopexit.us ] %71 = fptosi float %.0152174.us to i32 %72 = mul i32 %48, %71 %73 = sext i32 %72 to i64 - %gep197 = getelementptr i8, ptr %invariant.gep196, i64 %73 - %.not171.us = icmp sgt i64 %73, %invariant.op - %74 = getelementptr inbounds i8, ptr %gep197, i64 %50 - %75 = icmp ult ptr %74, %52 + %73 = add nsw i64 %73, %68 + %74 = getelementptr inbounds i8, ptr %0, i64 %73 + %.not171.us = icmp sge i64 %73, %invariant.op + %75 = icmp slt i64 %73, %invariant.op176 %or.cond = select i1 %.not171.us, i1 %75, i1 false br i1 %or.cond, label %.preheader.us.preheader, label %.loopexit.us -.preheader.us.preheader: ; preds = %70 - %invariant.gep = getelementptr i8, ptr %gep197, i64 %56 - %invariant.gep192 = getelementptr i8, ptr %gep197, i64 %57 - %invariant.gep194 = getelementptr i8, ptr %gep197, i64 %58 +.preheader.us.preheader: ; preds = %69 + %invariant.gep = getelementptr i8, ptr %74, i64 %56 + %invariant.gep192 = getelementptr i8, ptr %74, i64 %57 + %invariant.gep194 = getelementptr i8, ptr %74, i64 %58 br label %.preheader.us .preheader.us: ; preds = %.preheader.us.preheader, %.preheader.us @@ -130,7 +128,7 @@ define void @dt_iop_flip_and_zoom_8(ptr noundef readonly captures(address) %0, i %81 = load i8, ptr %gep195, align 1, !tbaa !10 %82 = zext i8 %81 to i16 %83 = add nuw nsw i16 %80, %82 - %84 = getelementptr inbounds nuw i8, ptr %gep197, i64 %indvars.iv + %84 = getelementptr inbounds nuw i8, ptr %74, i64 %indvars.iv %85 = load i8, ptr %84, align 1, !tbaa !10 %86 = zext i8 %85 to i16 %87 = add nuw nsw i16 %83, %86 @@ -142,12 +140,12 @@ define void @dt_iop_flip_and_zoom_8(ptr noundef readonly captures(address) %0, i %exitcond.not = icmp eq i64 %indvars.iv.next, 3 br i1 %exitcond.not, label %.loopexit.us, label %.preheader.us -.loopexit.us: ; preds = %.preheader.us, %70 +.loopexit.us: ; preds = %.preheader.us, %69 %91 = getelementptr inbounds nuw i8, ptr %.0154173.us, i64 4 %92 = fadd reassoc nsz arcp contract afn float %.0152174.us, %20 %93 = add nuw i32 %.0151175.us, 1 %exitcond187.not = icmp eq i32 %93, %23 - br i1 %exitcond187.not, label %._crit_edge.us, label %70 + br i1 %exitcond187.not, label %._crit_edge.us, label %69 ._crit_edge.us: ; preds = %.loopexit.us %indvars.iv.next189 = add nuw nsw i64 %indvars.iv188, 1 diff --git a/bench/darktable/optimized/introspection_liquify.ll b/bench/darktable/optimized/introspection_liquify.ll index 8209f960713..c9b3d2dd69d 100644 --- a/bench/darktable/optimized/introspection_liquify.ll +++ b/bench/darktable/optimized/introspection_liquify.ll @@ -528,8 +528,7 @@ interpolate_cubic_bezier.exit.i.i.i: ; preds = %139, %129 store float 0.000000e+00, ptr %153, align 4, !noalias !96 %sext.i.i = mul i64 %97, 42949672960 %.idx.i.i.i = ashr exact i64 %sext.i.i, 29 - %154 = getelementptr i8, ptr %124, i64 %.idx.i.i.i - %.ptr.i.i.i = getelementptr i8, ptr %154, i64 8 + %154 = getelementptr inbounds i8, ptr %.05664.i.i.i.i, i64 %.idx.i.i.i %155 = sitofp i32 %116 to float %156 = fdiv reassoc nsz arcp contract afn float 1.000000e+00, %155 store float 1.000000e+00, ptr %126, align 64, !tbaa !11, !noalias !96 @@ -553,7 +552,7 @@ build_lookup_table.exit.thread124.i.i: ; preds = %interpolate_cubic_b %.1.i.i.i = phi ptr [ %.05157.i.i.i, %.lr.ph.i.i.i ], [ %164, %159 ] %160 = load float, ptr %.1.i.i.i, align 4, !noalias !96 %161 = fcmp reassoc nsz arcp contract afn olt float %160, %158 - %162 = icmp ult ptr %.1.i.i.i, %.ptr.i.i.i + %162 = icmp ult ptr %.1.i.i.i, %154 %163 = select i1 %161, i1 %162, i1 false %164 = getelementptr inbounds nuw i8, ptr %.1.i.i.i, i64 8 br i1 %163, label %159, label %165 diff --git a/bench/diesel-rs/optimized/4dmkc4an6cvf22v6.ll b/bench/diesel-rs/optimized/4dmkc4an6cvf22v6.ll index 54a625b609e..817e126a478 100644 --- a/bench/diesel-rs/optimized/4dmkc4an6cvf22v6.ll +++ b/bench/diesel-rs/optimized/4dmkc4an6cvf22v6.ll @@ -6433,33 +6433,29 @@ _ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d732 %25 = load ptr, ptr %24, align 8, !nonnull !4, !noundef !4 %26 = getelementptr inbounds nuw i8, ptr %6, i64 64 %27 = load i64, ptr %26, align 8, !noundef !4 + %28 = getelementptr inbounds nuw i8, ptr %25, i64 16 %.idx = mul nsw i64 %27, 24 - %28 = getelementptr i8, ptr %25, i64 %.idx - %.ptr19 = getelementptr i8, ptr %28, i64 16 - %29 = icmp eq i64 %27, 0 - br i1 %29, label %.loopexit, label %.lr.ph.i.preheader - -.lr.ph.i.preheader: ; preds = %23 - %.ptr = getelementptr inbounds nuw i8, ptr %25, i64 16 - br label %.lr.ph.i - -.lr.ph.i: ; preds = %.lr.ph.i.preheader, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" - %.013.i = phi i64 [ %40, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ], [ 0, %.lr.ph.i.preheader ] - %30 = phi ptr [ %31, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ], [ %.ptr, %.lr.ph.i.preheader ] - %31 = getelementptr inbounds nuw i8, ptr %30, i64 24 + %28 = getelementptr inbounds i8, ptr %28, i64 %.idx + %30 = icmp eq i64 %27, 0 + br i1 %30, label %.loopexit, label %.lr.ph.i + +.lr.ph.i: ; preds = %23, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" + %.013.i = phi i64 [ %41, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ], [ 0, %23 ] + %31 = phi ptr [ %32, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ], [ %28, %23 ] + %32 = getelementptr inbounds nuw i8, ptr %31, i64 24 tail call void @llvm.experimental.noalias.scope.decl(metadata !1308) - %32 = load i64, ptr %30, align 8, !range !56, !alias.scope !1308, !noalias !1311, !noundef !4 + %32 = load i64, ptr %31, align 8, !range !56, !alias.scope !1308, !noalias !1311, !noundef !4 %33 = icmp eq i64 %32, -9223372036854775808 br i1 %33, label %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i", label %34 34: ; preds = %.lr.ph.i - %35 = getelementptr inbounds nuw i8, ptr %30, i64 16 + %35 = getelementptr inbounds nuw i8, ptr %31, i64 16 %36 = load i64, ptr %35, align 8, !alias.scope !1308, !noalias !1311, !noundef !4 %.not.i.i.i = icmp eq i64 %36, %2 br i1 %.not.i.i.i, label %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.i", label %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" "_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.i": ; preds = %34 - %37 = getelementptr inbounds nuw i8, ptr %30, i64 8 + %37 = getelementptr inbounds nuw i8, ptr %31, i64 8 %38 = load ptr, ptr %37, align 8, !alias.scope !1308, !noalias !1311, !nonnull !4, !noundef !4 %bcmp.i.i.i = tail call i32 @bcmp(ptr nonnull readonly align 1 %38, ptr nonnull readonly align 1 %1, i64 %2), !alias.scope !1315, !noalias !1319 %39 = icmp eq i32 %bcmp.i.i.i, 0 @@ -6467,7 +6463,7 @@ _ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d732 "_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i": ; preds = %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.i", %34, %.lr.ph.i %40 = add nuw nsw i64 %.013.i, 1 - %41 = icmp eq ptr %31, %.ptr19 + %41 = icmp eq ptr %32, %29 br i1 %41, label %.loopexit, label %.lr.ph.i 42: ; preds = %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.i" @@ -6476,9 +6472,9 @@ _ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d732 br label %.loopexit .loopexit: ; preds = %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i", %23, %42, %_ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d7329acf197d11E.exit - %44 = phi i64 [ %22, %_ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d7329acf197d11E.exit ], [ 0, %42 ], [ 0, %23 ], [ 0, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ] - %.sroa.0.0.i14.pn = phi i64 [ %spec.select7.i, %_ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d7329acf197d11E.exit ], [ 1, %42 ], [ 0, %23 ], [ 0, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ] - %.sroa.3.0.i.pn = phi i64 [ %spec.select.i, %_ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d7329acf197d11E.exit ], [ %.013.i, %42 ], [ undef, %23 ], [ undef, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ] + %44 = phi i64 [ %22, %_ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d7329acf197d11E.exit ], [ 0, %43 ], [ 0, %23 ], [ 0, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ] + %.sroa.0.0.i14.pn = phi i64 [ %spec.select7.i, %_ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d7329acf197d11E.exit ], [ 1, %43 ], [ 0, %23 ], [ 0, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ] + %.sroa.3.0.i.pn = phi i64 [ %spec.select.i, %_ZN6diesel6sqlite10connection4stmt12StatementUse21index_for_column_name17h95d7329acf197d11E.exit ], [ %.013.i, %43 ], [ undef, %23 ], [ undef, %"_ZN99_$LT$diesel..sqlite..connection..row..SqliteRow$u20$as$u20$diesel..row..RowIndex$LT$$RF$str$GT$$GT$3idx28_$u7b$$u7b$closure$u7d$$u7d$17hdc2c8359ef3f1e28E.exit.thread.i" ] %.pn20 = insertvalue { i64, i64 } poison, i64 %.sroa.0.0.i14.pn, 0 %.pn = insertvalue { i64, i64 } %.pn20, i64 %.sroa.3.0.i.pn, 1 store i64 %44, ptr %7, align 8, !noalias !1301 diff --git a/bench/draco/optimized/mesh_edgebreaker_decoder_impl.ll b/bench/draco/optimized/mesh_edgebreaker_decoder_impl.ll index 8fb4fbeec74..0e70dfc570e 100644 --- a/bench/draco/optimized/mesh_edgebreaker_decoder_impl.ll +++ b/bench/draco/optimized/mesh_edgebreaker_decoder_impl.ll @@ -24198,19 +24198,18 @@ define linkonce_odr noundef zeroext i1 @_ZN5draco31MeshEdgebreakerTraversalDecod %9 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %8) #22 store i64 %6, ptr %9, align 16 %.ptr13 = getelementptr inbounds nuw i8, ptr %9, i64 8 - %10 = getelementptr inbounds nuw %"class.draco::RAnsBitDecoder", ptr %.ptr13, i64 %6 br label %11 11: ; preds = %12, %5 - %.idx = phi i64 [ 8, %5 ], [ %.add, %12 ] + %.idx = phi i64 [ 8, %5 ], [ %.add, %11 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %9, i64 %.idx invoke void @_ZN5draco14RAnsBitDecoderC1Ev(ptr noundef nonnull align 8 dereferenceable(17) %.ptr.ptr) - to label %12 unwind label %32 + to label %11 unwind label %32 12: ; preds = %11 %.add = add nuw nsw i64 %.idx, 24 - %.ptr12 = getelementptr inbounds nuw i8, ptr %9, i64 %.add - %13 = icmp eq ptr %.ptr12, %10 + %12 = add nuw nsw i64 %.idx, 16 + %13 = icmp eq i64 %12, %7 br i1 %13, label %14, label %11 14: ; preds = %12 diff --git a/bench/draco/optimized/mesh_edgebreaker_encoder_impl.ll b/bench/draco/optimized/mesh_edgebreaker_encoder_impl.ll index 48f2d8d5f62..53abf53d491 100644 --- a/bench/draco/optimized/mesh_edgebreaker_encoder_impl.ll +++ b/bench/draco/optimized/mesh_edgebreaker_encoder_impl.ll @@ -5367,19 +5367,18 @@ define linkonce_odr void @_ZN5draco31MeshEdgebreakerTraversalEncoder5StartEv(ptr %9 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %8) #22 store i64 %6, ptr %9, align 16 %.ptr9 = getelementptr inbounds nuw i8, ptr %9, i64 8 - %10 = getelementptr inbounds nuw %"class.draco::RAnsBitEncoder", ptr %.ptr9, i64 %6 br label %11 11: ; preds = %12, %5 - %.idx = phi i64 [ 8, %5 ], [ %.add, %12 ] + %.idx = phi i64 [ 8, %5 ], [ %.add, %11 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %9, i64 %.idx invoke void @_ZN5draco14RAnsBitEncoderC1Ev(ptr noundef nonnull align 8 dereferenceable(56) %.ptr.ptr) - to label %12 unwind label %28 + to label %11 unwind label %28 12: ; preds = %11 %.add = add nuw nsw i64 %.idx, 56 - %.ptr8 = getelementptr inbounds nuw i8, ptr %9, i64 %.add - %13 = icmp eq ptr %.ptr8, %10 + %12 = add nuw nsw i64 %.idx, 48 + %13 = icmp eq i64 %12, %7 br i1 %13, label %14, label %11 14: ; preds = %12 diff --git a/bench/eastl/optimized/TestExtra.ll b/bench/eastl/optimized/TestExtra.ll index f39b093bf0b..40808ea1851 100644 --- a/bench/eastl/optimized/TestExtra.ll +++ b/bench/eastl/optimized/TestExtra.ll @@ -6282,7 +6282,8 @@ _ZN5eastl6vectorI10TestObjectNS_9allocatorEE8pop_backEv.exit: ; preds = %entry, define linkonce_odr dso_local void @_ZN5eastl11remove_heapIP10TestObjectmNS_4lessIS1_EEEEvT_T0_S6_T1_(ptr noundef %first, i64 noundef %heapSize, i64 noundef %position) local_unnamed_addr #0 comdat personality ptr @__gxx_personality_v0 { entry: %tempBottom = alloca %struct.TestObject, align 8 - %add.ptr = getelementptr inbounds %struct.TestObject, ptr %first, i64 %heapSize + %add.ptr.idx = mul nsw i64 %heapSize, 24 + %add.ptr = getelementptr inbounds i8, ptr %first, i64 %add.ptr.idx %add.ptr1 = getelementptr inbounds i8, ptr %add.ptr, i64 -24 %0 = load i32, ptr %add.ptr1, align 8 store i32 %0, ptr %tempBottom, align 8 @@ -6306,16 +6307,18 @@ entry: store i64 %inc6.i, ptr @_ZN10TestObject16sTOCopyCtorCountE, align 8 %mId.i = getelementptr inbounds nuw i8, ptr %tempBottom, i64 8 store i64 %inc5.i, ptr %mId.i, align 8 - %add.ptr2 = getelementptr inbounds %struct.TestObject, ptr %first, i64 %position + %add.ptr2.idx = mul nsw i64 %position, 24 %6 = load i64, ptr @_ZN10TestObject18sTOCopyAssignCountE, align 8 %inc.i7 = add nsw i64 %6, 1 store i64 %inc.i7, ptr @_ZN10TestObject18sTOCopyAssignCountE, align 8 - %cmp.not.i = icmp eq ptr %add.ptr2, %add.ptr1 + %7 = add nsw i64 %add.ptr.idx, -24 + %cmp.not.i = icmp eq i64 %add.ptr2.idx, %7 br i1 %cmp.not.i, label %_ZN10TestObjectaSERKS_.exit, label %if.then.i if.then.i: ; preds = %entry - %7 = load i32, ptr %add.ptr2, align 8 - store i32 %7, ptr %add.ptr1, align 8 + %add.ptr2 = getelementptr inbounds i8, ptr %first, i64 %add.ptr2.idx + %8 = load i32, ptr %add.ptr2, align 8 + store i32 %8, ptr %add.ptr1, align 8 %mMagicValue.i8 = getelementptr inbounds nuw i8, ptr %add.ptr2, i64 16 %8 = load i32, ptr %mMagicValue.i8, align 8 store i32 %8, ptr %mMagicValue4.i, align 8 diff --git a/bench/eastl/optimized/TestRingBuffer.ll b/bench/eastl/optimized/TestRingBuffer.ll index 9b5e7cb40b6..74209b0295c 100644 --- a/bench/eastl/optimized/TestRingBuffer.ll +++ b/bench/eastl/optimized/TestRingBuffer.ll @@ -40208,15 +40208,14 @@ if.else.i.i.i: ; preds = %entry if.end.i.i.i.i.i.i: ; preds = %if.else.i.i.i tail call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %mBuffer.i.ptr, ptr align 4 %0, i64 %sub.ptr.sub.i.i.i.i.i, i1 false) - %mBuffer.i.add = add nuw nsw i64 %sub.ptr.sub.i.i.i.i.i, 24 - %add.ptr.i.i.i.i.i.i.ptr = getelementptr inbounds nuw i8, ptr %this, i64 %mBuffer.i.add - store ptr %add.ptr.i.i.i.i.i.i.ptr, ptr %mpEnd.i, align 8 - %2 = icmp eq i64 %mBuffer.i.add, 424 + %add.ptr.i.i.i.i.i.i = getelementptr inbounds nuw i8, ptr %mBuffer.i.ptr, i64 %sub.ptr.sub.i.i.i.i.i + store ptr %add.ptr.i.i.i.i.i.i, ptr %mpEnd.i, align 8 + %2 = icmp eq i64 %sub.ptr.sub.i.i.i.i.i, 400 br label %_ZN5eastl12fixed_vectorIiLm100ELb0ENS_15dummy_allocatorEEC2ERKS2_.exit _ZN5eastl12fixed_vectorIiLm100ELb0ENS_15dummy_allocatorEEC2ERKS2_.exit: ; preds = %_ZN5eastl6vectorIiNS_22fixed_vector_allocatorILm4ELm100ELm4ELm0ELb0ENS_15dummy_allocatorEEEE9DoReallocIPKiEEPimT_S9_NS4_23should_move_or_copy_tagILb0EEE.exit.i.i.i, %if.end.i.i.i.i.i.i %cmp.i.i = phi i1 [ true, %_ZN5eastl6vectorIiNS_22fixed_vector_allocatorILm4ELm100ELm4ELm0ELb0ENS_15dummy_allocatorEEEE9DoReallocIPKiEEPimT_S9_NS4_23should_move_or_copy_tagILb0EEE.exit.i.i.i ], [ %2, %if.end.i.i.i.i.i.i ] - %.pre.i.i = phi ptr [ %add.ptr.i.i.i, %_ZN5eastl6vectorIiNS_22fixed_vector_allocatorILm4ELm100ELm4ELm0ELb0ENS_15dummy_allocatorEEEE9DoReallocIPKiEEPimT_S9_NS4_23should_move_or_copy_tagILb0EEE.exit.i.i.i ], [ %add.ptr.i.i.i.i.i.i.ptr, %if.end.i.i.i.i.i.i ] + %.pre.i.i = phi ptr [ %add.ptr.i.i.i, %_ZN5eastl6vectorIiNS_22fixed_vector_allocatorILm4ELm100ELm4ELm0ELb0ENS_15dummy_allocatorEEEE9DoReallocIPKiEEPimT_S9_NS4_23should_move_or_copy_tagILb0EEE.exit.i.i.i ], [ %add.ptr.i.i.i.i.i.i, %if.end.i.i.i.i.i.i ] %3 = phi ptr [ null, %_ZN5eastl6vectorIiNS_22fixed_vector_allocatorILm4ELm100ELm4ELm0ELb0ENS_15dummy_allocatorEEEE9DoReallocIPKiEEPimT_S9_NS4_23should_move_or_copy_tagILb0EEE.exit.i.i.i ], [ %mBuffer.i.ptr, %if.end.i.i.i.i.i.i ] %cmp.i = icmp eq ptr %3, %.pre.i.i br i1 %cmp.i, label %if.then.i, label %if.end diff --git a/bench/eastl/optimized/TestSegmentedVector.ll b/bench/eastl/optimized/TestSegmentedVector.ll index 0546cb1059b..860ecc3678f 100644 --- a/bench/eastl/optimized/TestSegmentedVector.ll +++ b/bench/eastl/optimized/TestSegmentedVector.ll @@ -2446,11 +2446,11 @@ _ZN5eastl9allocator10deallocateEPvm.exit: ; preds = %_ZN10TestObjectD2Ev while.end: ; preds = %_ZN5eastl9allocator10deallocateEPvm.exit, %while.cond.preheader %segment.0.lcssa = phi ptr [ %0, %while.cond.preheader ], [ %3, %_ZN5eastl9allocator10deallocateEPvm.exit ] + %mData = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 16 %9 = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 8 %10 = load i64, ptr %9, align 8 %add.ptr.idx = mul i64 %10, 24 - %11 = getelementptr i8, ptr %segment.0.lcssa, i64 %add.ptr.idx - %add.ptr.ptr = getelementptr i8, ptr %11, i64 16 + %11 = getelementptr inbounds i8, ptr %mData, i64 %add.ptr.idx %_ZN10TestObject12sTODtorCountE.promoted = load i64, ptr @_ZN10TestObject12sTODtorCountE, align 8 %cmp4.not20 = icmp eq i64 %10, 0 br i1 %cmp4.not20, label %delete.notnull.i12, label %for.body.preheader @@ -2458,11 +2458,10 @@ while.end: ; preds = %_ZN5eastl9allocator for.body.preheader: ; preds = %while.end %_ZN10TestObject8sTOCountE.promoted = load i64, ptr @_ZN10TestObject8sTOCountE, align 8 %_ZN10TestObject16sMagicErrorCountE.promoted = load i32, ptr @_ZN10TestObject16sMagicErrorCountE, align 4 - %mData.ptr = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 16 br label %for.body for.body: ; preds = %for.body.preheader, %_ZN10TestObjectD2Ev.exit - %i.024 = phi ptr [ %incdec.ptr, %_ZN10TestObjectD2Ev.exit ], [ %mData.ptr, %for.body.preheader ] + %i.024 = phi ptr [ %incdec.ptr, %_ZN10TestObjectD2Ev.exit ], [ %mData, %for.body.preheader ] %inc.i1723 = phi i32 [ %inc.i16, %_ZN10TestObjectD2Ev.exit ], [ %_ZN10TestObject16sMagicErrorCountE.promoted, %for.body.preheader ] %dec.i1822 = phi i64 [ %dec.i, %_ZN10TestObjectD2Ev.exit ], [ %_ZN10TestObject8sTOCountE.promoted, %for.body.preheader ] %mMagicValue.i = getelementptr inbounds nuw i8, ptr %i.024, i64 16 @@ -2480,7 +2479,7 @@ _ZN10TestObjectD2Ev.exit: ; preds = %for.body, %if.then. store i32 0, ptr %mMagicValue.i, align 8 %dec.i = add nsw i64 %dec.i1822, -1 %incdec.ptr = getelementptr inbounds nuw i8, ptr %i.024, i64 24 - %cmp4.not = icmp eq ptr %incdec.ptr, %add.ptr.ptr + %cmp4.not = icmp eq ptr %incdec.ptr, %add.ptr br i1 %cmp4.not, label %for.end, label %for.body, !llvm.loop !10 for.end: ; preds = %_ZN10TestObjectD2Ev.exit @@ -4226,11 +4225,11 @@ _ZN5eastl9allocator10deallocateEPvm.exit: ; preds = %_ZN10TestObjectD2Ev while.end: ; preds = %_ZN5eastl9allocator10deallocateEPvm.exit, %while.cond.preheader %segment.0.lcssa = phi ptr [ %0, %while.cond.preheader ], [ %3, %_ZN5eastl9allocator10deallocateEPvm.exit ] + %mData = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 16 %9 = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 8 %10 = load i64, ptr %9, align 8 %add.ptr.idx = mul i64 %10, 24 - %11 = getelementptr i8, ptr %segment.0.lcssa, i64 %add.ptr.idx - %add.ptr.ptr = getelementptr i8, ptr %11, i64 16 + %11 = getelementptr inbounds i8, ptr %mData, i64 %add.ptr.idx %_ZN10TestObject12sTODtorCountE.promoted = load i64, ptr @_ZN10TestObject12sTODtorCountE, align 8 %cmp4.not20 = icmp eq i64 %10, 0 br i1 %cmp4.not20, label %delete.notnull.i12, label %for.body.preheader @@ -4238,11 +4237,10 @@ while.end: ; preds = %_ZN5eastl9allocator for.body.preheader: ; preds = %while.end %_ZN10TestObject8sTOCountE.promoted = load i64, ptr @_ZN10TestObject8sTOCountE, align 8 %_ZN10TestObject16sMagicErrorCountE.promoted = load i32, ptr @_ZN10TestObject16sMagicErrorCountE, align 4 - %mData.ptr = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 16 br label %for.body for.body: ; preds = %for.body.preheader, %_ZN10TestObjectD2Ev.exit - %i.024 = phi ptr [ %incdec.ptr, %_ZN10TestObjectD2Ev.exit ], [ %mData.ptr, %for.body.preheader ] + %i.024 = phi ptr [ %incdec.ptr, %_ZN10TestObjectD2Ev.exit ], [ %mData, %for.body.preheader ] %inc.i1723 = phi i32 [ %inc.i16, %_ZN10TestObjectD2Ev.exit ], [ %_ZN10TestObject16sMagicErrorCountE.promoted, %for.body.preheader ] %dec.i1822 = phi i64 [ %dec.i, %_ZN10TestObjectD2Ev.exit ], [ %_ZN10TestObject8sTOCountE.promoted, %for.body.preheader ] %mMagicValue.i = getelementptr inbounds nuw i8, ptr %i.024, i64 16 @@ -4260,7 +4258,7 @@ _ZN10TestObjectD2Ev.exit: ; preds = %for.body, %if.then. store i32 0, ptr %mMagicValue.i, align 8 %dec.i = add nsw i64 %dec.i1822, -1 %incdec.ptr = getelementptr inbounds nuw i8, ptr %i.024, i64 24 - %cmp4.not = icmp eq ptr %incdec.ptr, %add.ptr.ptr + %cmp4.not = icmp eq ptr %incdec.ptr, %add.ptr br i1 %cmp4.not, label %for.end, label %for.body, !llvm.loop !29 for.end: ; preds = %_ZN10TestObjectD2Ev.exit @@ -4358,22 +4356,18 @@ _ZN5eastl9allocator10deallocateEPvm.exit: ; preds = %_ZN5eastl7segmentIN while.end: ; preds = %_ZN5eastl9allocator10deallocateEPvm.exit, %while.cond.preheader %segment.0.lcssa = phi ptr [ %0, %while.cond.preheader ], [ %3, %_ZN5eastl9allocator10deallocateEPvm.exit ] + %mData = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 16 %11 = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 8 %12 = load i64, ptr %11, align 8 %add.ptr.idx = mul nsw i64 %12, 24 - %13 = getelementptr i8, ptr %segment.0.lcssa, i64 %add.ptr.idx - %add.ptr.ptr = getelementptr i8, ptr %13, i64 16 + %13 = getelementptr inbounds i8, ptr %mData, i64 %add.ptr.idx %cmp4.not16 = icmp eq i64 %12, 0 br i1 %cmp4.not16, label %delete.notnull.i12, label %for.body.preheader -for.body.preheader: ; preds = %while.end - %mData.ptr = getelementptr inbounds nuw i8, ptr %segment.0.lcssa, i64 16 - br label %for.body - -for.body: ; preds = %for.body.preheader, %_ZN5eastl4listI10TestObjectNS_9allocatorEED2Ev.exit - %i.017 = phi ptr [ %incdec.ptr, %_ZN5eastl4listI10TestObjectNS_9allocatorEED2Ev.exit ], [ %mData.ptr, %for.body.preheader ] - %14 = load ptr, ptr %i.017, align 8 - %cmp.not4.i.i.i = icmp eq ptr %14, %i.017 +for.body.preheader: ; preds = %while.end, %_ZN5eastl4listI10TestObjectNS_9allocatorEED2Ev.exit + %i.017 = phi ptr [ %incdec.ptr, %_ZN5eastl4listI10TestObjectNS_9allocatorEED2Ev.exit ], [ %mData, %while.end ] + %13 = load ptr, ptr %i.017, align 8 + %cmp.not4.i.i.i = icmp eq ptr %13, %i.017 br i1 %cmp.not4.i.i.i, label %_ZN5eastl4listI10TestObjectNS_9allocatorEED2Ev.exit, label %while.body.i.i.i while.body.i.i.i: ; preds = %for.body, %_ZN5eastl9allocator10deallocateEPvm.exit.i.i.i @@ -4404,7 +4398,7 @@ _ZN5eastl9allocator10deallocateEPvm.exit.i.i.i: ; preds = %if.then.i.i.i.i.i, _ZN5eastl4listI10TestObjectNS_9allocatorEED2Ev.exit: ; preds = %_ZN5eastl9allocator10deallocateEPvm.exit.i.i.i, %for.body %incdec.ptr = getelementptr inbounds nuw i8, ptr %i.017, i64 24 - %cmp4.not = icmp eq ptr %incdec.ptr, %add.ptr.ptr + %cmp4.not = icmp eq ptr %incdec.ptr, %add.ptr br i1 %cmp4.not, label %for.end, label %for.body, !llvm.loop !32 for.end: ; preds = %_ZN5eastl4listI10TestObjectNS_9allocatorEED2Ev.exit diff --git a/bench/ffmpeg/optimized/dvbsub_parser.ll b/bench/ffmpeg/optimized/dvbsub_parser.ll index 656cc35a949..81cf1b6117c 100644 --- a/bench/ffmpeg/optimized/dvbsub_parser.ll +++ b/bench/ffmpeg/optimized/dvbsub_parser.ll @@ -101,20 +101,19 @@ define internal noundef i32 @dvbsub_parse(ptr noundef captures(none) initializes %49 = add nsw i32 %48, %34 store i32 %49, ptr %35, align 4, !tbaa !20 %50 = sext i32 %49 to i64 - %51 = getelementptr i8, ptr %7, i64 %50 - %.ptr120 = getelementptr i8, ptr %51, i64 12 - %52 = icmp sgt i32 %49, 0 - br i1 %52, label %.lr.ph, label %.loopexit.thread + %51 = getelementptr inbounds i8, ptr %43, i64 %50 + %53 = icmp sgt i32 %50, 0 + br i1 %53, label %.lr.ph, label %.loopexit.thread .lr.ph: ; preds = %42 - %53 = ptrtoint ptr %.ptr120 to i64 + %53 = ptrtoint ptr %52 to i64 br label %54 54: ; preds = %.lr.ph, %67 - %.0115 = phi i32 [ 0, %.lr.ph ], [ %68, %67 ] - %.093114 = phi ptr [ %.ptr, %.lr.ph ], [ %69, %67 ] + %.0115 = phi i32 [ 0, %.lr.ph ], [ %68, %68 ] + %.093114 = phi ptr [ %.ptr, %.lr.ph ], [ %69, %68 ] %55 = load i8, ptr %.093114, align 1, !tbaa !21 - switch i8 %55, label %71 [ + switch i8 %55, label %72 [ i8 15, label %56 i8 -1, label %.loopexit.sink.split ] @@ -138,7 +137,7 @@ define internal noundef i32 @dvbsub_parse(ptr noundef captures(none) initializes 67: ; preds = %60 %68 = add nuw nsw i32 %65, %.0115 %69 = getelementptr inbounds nuw i8, ptr %.093114, i64 %66 - %70 = icmp ult ptr %69, %.ptr120 + %70 = icmp ult ptr %69, %52 br i1 %70, label %54, label %.loopexit.thread127, !llvm.loop !23 71: ; preds = %54 @@ -159,7 +158,7 @@ define internal noundef i32 @dvbsub_parse(ptr noundef captures(none) initializes br i1 %.not108, label %.loopexit.thread, label %.loopexit.thread127 .loopexit.thread127: ; preds = %67, %.loopexit - %.0111130 = phi i32 [ %.0115, %.loopexit ], [ %68, %67 ] + %.0111130 = phi i32 [ %.0115, %.loopexit ], [ %68, %68 ] store ptr %.ptr, ptr %2, align 8, !tbaa !12 store i32 %.0111130, ptr %3, align 4, !tbaa !14 store i32 %.0111130, ptr %7, align 4, !tbaa !18 diff --git a/bench/ffmpeg/optimized/mpeg.ll b/bench/ffmpeg/optimized/mpeg.ll index 3d18bf766e3..a7d2913b292 100644 --- a/bench/ffmpeg/optimized/mpeg.ll +++ b/bench/ffmpeg/optimized/mpeg.ll @@ -68,6 +68,7 @@ define internal range(i32 0, 53) i32 @mpegps_probe(ptr noundef readonly captures %6 = load ptr, ptr %5, align 8, !tbaa !11 %7 = zext nneg i32 %3 to i64 %8 = getelementptr inbounds nuw i8, ptr %6, i64 %7 + %invariant.op = add nsw i64 %7, -3 br label %9 9: ; preds = %.lr.ph, %.thread @@ -129,7 +130,7 @@ define internal range(i32 0, 53) i32 @mpegps_probe(ptr noundef readonly captures 40: ; preds = %.fold.split.i, %34, %30, %26 %41 = phi i1 [ false, %30 ], [ false, %26 ], [ %39, %34 ], [ true, %.fold.split.i ] - %42 = icmp ult ptr %27, %8 + %42 = icmp sgt i64 %invariant.op, %11 br i1 %42, label %.lr.ph.i, label %.critedge.i .lr.ph.i: ; preds = %40, %45 diff --git a/bench/ffmpeg/optimized/rtpenc_h261.ll b/bench/ffmpeg/optimized/rtpenc_h261.ll index ea7d1d6c678..6c2ba016f77 100644 --- a/bench/ffmpeg/optimized/rtpenc_h261.ll +++ b/bench/ffmpeg/optimized/rtpenc_h261.ll @@ -21,9 +21,9 @@ define void @ff_rtp_send_h261(ptr noundef %0, ptr noundef %1, i32 noundef %2) lo %11 = getelementptr inbounds nuw i8, ptr %5, i64 56 br label %12 -12: ; preds = %.lr.ph, %46 - %.041 = phi ptr [ %1, %.lr.ph ], [ %54, %46 ] - %.03540 = phi i32 [ %2, %.lr.ph ], [ %55, %46 ] +12: ; preds = %.lr.ph, %45 + %.041 = phi ptr [ %1, %.lr.ph ], [ %53, %45 ] + %.03540 = phi i32 [ %2, %.lr.ph ], [ %54, %45 ] %13 = load ptr, ptr %10, align 8, !tbaa !29 store i8 1, ptr %13, align 1, !tbaa !30 %14 = load ptr, ptr %10, align 8, !tbaa !29 @@ -58,61 +58,57 @@ define void @ff_rtp_send_h261(ptr noundef %0, ptr noundef %1, i32 noundef %2) lo %29 = add nsw i32 %28, -4 %.035. = tail call i32 @llvm.smin.i32(i32 %29, i32 %.03540) %30 = icmp slt i32 %29, %.03540 - br i1 %30, label %31, label %46 + br i1 %30, label %31, label %45 31: ; preds = %27 %32 = sext i32 %.035. to i64 - %.ptr = getelementptr i8, ptr %.041, i64 %32 - %33 = getelementptr inbounds nuw i8, ptr %.041, i64 1 - %34 = icmp sgt i32 %.035., 2 - br i1 %34, label %.lr.ph.i.preheader, label %find_resync_marker_reverse.exit - -.lr.ph.i.preheader: ; preds = %31 - %.011.i.ptr = getelementptr i8, ptr %.ptr, i64 -1 - br label %.lr.ph.i - -.lr.ph.i: ; preds = %.lr.ph.i.preheader, %40 - %.013.i = phi ptr [ %.0.i, %40 ], [ %.011.i.ptr, %.lr.ph.i.preheader ] - %.pn12.i = phi ptr [ %.013.i, %40 ], [ %.ptr, %.lr.ph.i.preheader ] - %35 = load i8, ptr %.013.i, align 1, !tbaa !30, !alias.scope !32, !noalias !35 - %36 = icmp eq i8 %35, 0 - br i1 %36, label %37, label %40 - -37: ; preds = %.lr.ph.i - %38 = load i8, ptr %.pn12.i, align 1, !tbaa !30, !alias.scope !32, !noalias !35 - %39 = icmp eq i8 %38, 1 - br i1 %39, label %find_resync_marker_reverse.exit, label %40 - -40: ; preds = %37, %.lr.ph.i - %.0.i = getelementptr inbounds i8, ptr %.013.i, i64 -1 - %41 = icmp ugt ptr %.0.i, %33 - br i1 %41, label %.lr.ph.i, label %find_resync_marker_reverse.exit, !llvm.loop !37 - -find_resync_marker_reverse.exit: ; preds = %37, %40, %31 - %.010.i = phi ptr [ %.ptr, %31 ], [ %.013.i, %37 ], [ %.ptr, %40 ] - %42 = ptrtoint ptr %.010.i to i64 - %43 = ptrtoint ptr %.041 to i64 - %44 = sub i64 %42, %43 - %45 = trunc i64 %44 to i32 - br label %46 - -46: ; preds = %find_resync_marker_reverse.exit, %27 - %.036 = phi i32 [ %45, %find_resync_marker_reverse.exit ], [ %.035., %27 ] - %47 = icmp eq i32 %.036, %.03540 - %48 = zext i1 %47 to i32 + %.ptr = getelementptr inbounds i8, ptr %.041, i64 %32 + %33 = icmp sgt i32 %.035., 2 + br i1 %33, label %.lr.ph.i, label %find_resync_marker_reverse.exit + +.lr.ph.i: ; preds = %31, %39 + %.013.i.idx.in = phi i64 [ %.013.i.idx, %39 ], [ %32, %31 ] + %.pn12.i = phi ptr [ %.013.i.ptr, %39 ], [ %.ptr, %31 ] + %.013.i.idx = add nsw i64 %.013.i.idx.in, -1 + %.013.i.ptr = getelementptr inbounds i8, ptr %.041, i64 %.013.i.idx + %34 = load i8, ptr %.013.i.ptr, align 1, !tbaa !30, !alias.scope !32, !noalias !35 + %35 = icmp eq i8 %34, 0 + br i1 %35, label %36, label %39 + +36:; preds = %.lr.ph.i + %37 = load i8, ptr %.pn12.i, align 1, !tbaa !30, !alias.scope !32, !noalias !35 + %38 = icmp eq i8 %37, 1 + br i1 %38, label %find_resync_marker_reverse.exit, label %39 + +39:; preds = %36, %.lr.ph.i + %40 = icmp sgt i64 %.013.i.idx.in, 3 + br i1 %40, label %.lr.ph.i, label %find_resync_marker_reverse.exit, !llvm.loop !37 + +find_resync_marker_reverse.exit:; preds = %36, %39, %31 + %.010.i = phi ptr [ %.ptr, %31 ], [ %.013.i.ptr, %36 ], [ %.ptr, %39 ] + %41 = ptrtoint ptr %.010.i to i64 + %42 = ptrtoint ptr %.041 to i64 + %43 = sub i64 %41, %42 + %44 = trunc i64 %43 to i32 + br label %45 + +45:; preds = %find_resync_marker_reverse.exit, %27 + %.036 = phi i32 [ %44, %find_resync_marker_reverse.exit ], [ %.035., %27 ] + %46 = icmp eq i32 %.036, %.03540 + %47 = zext i1 %46 to i32 + %48 = load ptr, ptr %10, align 8, !tbaa !29 + %49 = getelementptr inbounds nuw i8, ptr %48, i64 4 + %50 = sext i32 %.036 to i64 + tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %49, ptr align 1 %.041, i64 %50, i1 false) %49 = load ptr, ptr %10, align 8, !tbaa !29 - %50 = getelementptr inbounds nuw i8, ptr %49, i64 4 - %51 = sext i32 %.036 to i64 - tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %50, ptr align 1 %.041, i64 %51, i1 false) - %52 = load ptr, ptr %10, align 8, !tbaa !29 - %53 = add nsw i32 %.036, 4 - tail call void @ff_rtp_send_data(ptr noundef %0, ptr noundef %52, i32 noundef %53, i32 noundef %48) #4 - %54 = getelementptr inbounds i8, ptr %.041, i64 %51 - %55 = sub nsw i32 %.03540, %.036 - %56 = icmp sgt i32 %55, 0 - br i1 %56, label %12, label %._crit_edge, !llvm.loop !39 - -._crit_edge: ; preds = %46, %3 + %52 = add nsw i32 %.036, 4 + tail call void @ff_rtp_send_data(ptr noundef %0, ptr noundef %49, i32 noundef %52, i32 noundef %47) #4 + %53 = getelementptr inbounds i8, ptr %.041, i64 %50 + %54 = sub nsw i32 %.03540, %.036 + %55 = icmp sgt i32 %54, 0 + br i1 %55, label %12, label %._crit_edge, !llvm.loop !39 + +._crit_edge:; preds = %45, %3 ret void } diff --git a/bench/fish-rs/optimized/5o5xgybh9xo8acbeboom17uhq.ll b/bench/fish-rs/optimized/5o5xgybh9xo8acbeboom17uhq.ll index b7a896b365f..82ea488d4c9 100644 --- a/bench/fish-rs/optimized/5o5xgybh9xo8acbeboom17uhq.ll +++ b/bench/fish-rs/optimized/5o5xgybh9xo8acbeboom17uhq.ll @@ -26935,24 +26935,23 @@ define void @_ZN4fish3env3var6EnvVar7to_list17hbbac003ae279e157E(ptr noalias nou call void @"_ZN5alloc3vec16Vec$LT$T$C$A$GT$6resize17h149025ebac74f339E"(ptr noalias noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %6, ptr noalias noundef nonnull align 8 captures(none) dereferenceable(24) %4, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.cf6b743a34a7c76188724518d33b37d2.356) call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) %7 = load ptr, ptr %0, align 8, !nonnull !17, !noundef !17 + %8 = getelementptr inbounds nuw i8, ptr %7, i64 16 %.idx = mul nuw nsw i64 %6, 24 - %8 = getelementptr inbounds nuw i8, ptr %7, i64 %.idx - %.ptr17 = getelementptr inbounds nuw i8, ptr %8, i64 16 - %9 = icmp eq i64 %6, 0 - br i1 %9, label %._crit_edge, label %.lr.ph + %8 = getelementptr inbounds nuw i8, ptr %8, i64 %.idx + %10 = icmp eq i64 %6, 0 + br i1 %10, label %._crit_edge, label %.lr.ph .lr.ph: ; preds = %2 - %.ptr = getelementptr inbounds nuw i8, ptr %7, i64 16 - %10 = getelementptr inbounds nuw i8, ptr %1, i64 16 - %11 = getelementptr inbounds nuw i8, ptr %1, i64 8 - br label %12 + %.ptr = getelementptr inbounds nuw i8, ptr %1, i64 16 + %10 = getelementptr inbounds nuw i8, ptr %1, i64 8 + br label %13 12: ; preds = %.lr.ph, %_ZN4core5clone5Clone10clone_from17h769788b4e2d90b71E.exit - %.sroa.0.016 = phi ptr [ %.ptr, %.lr.ph ], [ %13, %_ZN4core5clone5Clone10clone_from17h769788b4e2d90b71E.exit ] + %.sroa.0.016 = phi ptr [ %8, %.lr.ph ], [ %13, %_ZN4core5clone5Clone10clone_from17h769788b4e2d90b71E.exit ] %.sroa.7.015 = phi i64 [ 0, %.lr.ph ], [ %14, %_ZN4core5clone5Clone10clone_from17h769788b4e2d90b71E.exit ] %13 = getelementptr inbounds nuw i8, ptr %.sroa.0.016, i64 24 %14 = add nuw nsw i64 %.sroa.7.015, 1 - %15 = load i64, ptr %10, align 8, !noundef !17 + %15 = load i64, ptr %11, align 8, !noundef !17 %16 = icmp ult i64 %.sroa.7.015, %15 br i1 %16, label %17, label %23 @@ -26960,7 +26959,7 @@ define void @_ZN4fish3env3var6EnvVar7to_list17hbbac003ae279e157E(ptr noalias nou ret void 17: ; preds = %12 - %18 = load ptr, ptr %11, align 8, !nonnull !17, !noundef !17 + %18 = load ptr, ptr %12, align 8, !nonnull !17, !noundef !17 %19 = getelementptr inbounds nuw { { { { i64, ptr, {} }, {} }, i64 } }, ptr %18, i64 %.sroa.7.015 call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %3), !noalias !3696 call void @"_ZN67_$LT$alloc..vec..Vec$LT$T$C$A$GT$$u20$as$u20$core..clone..Clone$GT$5clone17h0735b64d57a14b6bE"(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %3, ptr noalias noundef nonnull readonly align 8 dereferenceable(24) %.sroa.0.016, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.cf6b743a34a7c76188724518d33b37d2.4), !noalias !3700 @@ -26976,7 +26975,7 @@ define void @_ZN4fish3env3var6EnvVar7to_list17hbbac003ae279e157E(ptr noalias nou _ZN4core5clone5Clone10clone_from17h769788b4e2d90b71E.exit: ; preds = %17 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %19, ptr noundef nonnull align 8 dereferenceable(24) %3, i64 24, i1 false), !noalias !3701 call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %3), !noalias !3696 - %22 = icmp eq ptr %13, %.ptr17 + %22 = icmp eq ptr %13, %9 br i1 %22, label %._crit_edge, label %12 23: ; preds = %12 diff --git a/bench/fmt/optimized/base-test.ll b/bench/fmt/optimized/base-test.ll index ad92a9c81d1..0749208467e 100644 --- a/bench/fmt/optimized/base-test.ll +++ b/bench/fmt/optimized/base-test.ll @@ -138016,8 +138016,7 @@ define linkonce_odr hidden ptr @_ZN3fmt3v1110vformat_toIRSt20back_insert_iterato %13 = load i64, ptr %8, align 8, !tbaa !7 store i64 0, ptr %8, align 8, !tbaa !7 %14 = getelementptr inbounds nuw i8, ptr %6, i64 %13 - %.ptr7.i.i.i = getelementptr inbounds nuw i8, ptr %14, i64 40 - %.not5.i.i.i = icmp eq i64 %13, 0 + %.not5.i.i.i = icmp samesign eq i64 %13, 0 br i1 %.not5.i.i.i, label %.thread, label %.lr.ph.i.i.i .thread: ; preds = %12 @@ -138064,7 +138063,7 @@ _ZNSt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE %31 = load ptr, ptr %.sroa.0.0.copyload.i.i.i.i, align 8, !tbaa !40 %32 = getelementptr inbounds nuw i8, ptr %31, i64 %19 store i8 0, ptr %32, align 1, !tbaa !4 - %.not.i.i.i = icmp eq ptr %15, %.ptr7.i.i.i + %.not.i.i.i = icmp eq ptr %15, %14 br i1 %.not.i.i.i, label %33, label %.lr.ph.i.i.i, !llvm.loop !3298 33: ; preds = %_ZNSt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEaSERKc.exit.i.i.i @@ -138072,8 +138071,7 @@ _ZNSt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE %.sroa.0.0.copyload.i.i = load ptr, ptr %11, align 8 store i64 0, ptr %8, align 8, !tbaa !7 %34 = getelementptr inbounds nuw i8, ptr %6, i64 %.pr - %.ptr7.i.i = getelementptr inbounds nuw i8, ptr %34, i64 40 - %.not5.i.i = icmp eq i64 %.pr, 0 + %.not5.i.i = icmp samesign eq i64 %.pr, 0 br i1 %.not5.i.i, label %_ZN3fmt3v116detail15iterator_bufferISt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcNS1_13buffer_traitsEED2Ev.exit, label %.lr.ph.i.i .lr.ph.i.i: ; preds = %33, %_ZNSt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEaSERKc.exit.i.i @@ -138116,7 +138114,7 @@ _ZNSt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE %51 = load ptr, ptr %.sroa.0.0.copyload.i.i.i, align 8, !tbaa !40 %52 = getelementptr inbounds nuw i8, ptr %51, i64 %39 store i8 0, ptr %52, align 1, !tbaa !4 - %.not.i.i = icmp eq ptr %35, %.ptr7.i.i + %.not.i.i = icmp eq ptr %35, %34 br i1 %.not.i.i, label %_ZN3fmt3v116detail15iterator_bufferISt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcNS1_13buffer_traitsEED2Ev.exit, label %.lr.ph.i.i, !llvm.loop !3298 53: ; preds = %48 @@ -138163,20 +138161,19 @@ define linkonce_odr hidden void @_ZN3fmt3v116detail15iterator_bufferISt20back_in %2 = getelementptr inbounds nuw i8, ptr %0, i64 8 %3 = load i64, ptr %2, align 8, !tbaa !7 store i64 0, ptr %2, align 8, !tbaa !7 - %4 = getelementptr inbounds nuw i8, ptr %0, i64 %3 - %.ptr7.i = getelementptr inbounds nuw i8, ptr %4, i64 40 - %.not5.i = icmp eq i64 %3, 0 + %4 = getelementptr inbounds nuw i8, ptr %0, i64 40 + %.ptr7.i = getelementptr inbounds nuw i8, ptr %4, i64 %3 + %.not5.i = icmp samesign eq i64 %3, 0 br i1 %.not5.i, label %_ZN3fmt3v116detail15iterator_bufferISt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEcNS1_13buffer_traitsEE5flushEv.exit, label %.lr.ph.i .lr.ph.i: ; preds = %1 - %.ptr.i = getelementptr inbounds nuw i8, ptr %0, i64 40 - %5 = getelementptr inbounds nuw i8, ptr %0, i64 32 + %.ptr.i = getelementptr inbounds nuw i8, ptr %0, i64 32 br label %6 6: ; preds = %_ZNSt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEaSERKc.exit.i, %.lr.ph.i - %.06.i = phi ptr [ %.ptr.i, %.lr.ph.i ], [ %7, %_ZNSt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEaSERKc.exit.i ] + %.06.i = phi ptr [ %4, %.lr.ph.i ], [ %7, %_ZNSt20back_insert_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEaSERKc.exit.i ] %7 = getelementptr inbounds nuw i8, ptr %.06.i, i64 1 - %.sroa.0.0.copyload.i.i = load ptr, ptr %5, align 8 + %.sroa.0.0.copyload.i.i = load ptr, ptr %6, align 8 %8 = load i8, ptr %.06.i, align 1, !tbaa !4 %9 = getelementptr inbounds nuw i8, ptr %.sroa.0.0.copyload.i.i, i64 8 %10 = load i64, ptr %9, align 8, !tbaa !45 diff --git a/bench/fmt/optimized/color-test.ll b/bench/fmt/optimized/color-test.ll index eebed3d9274..85460e385cd 100644 --- a/bench/fmt/optimized/color-test.ll +++ b/bench/fmt/optimized/color-test.ll @@ -12149,10 +12149,9 @@ _ZN3fmt3v1114basic_appenderIcEaSEc.exit.i: ; preds = %20, %15 br i1 %.not, label %_ZN3fmt3v116detail6fill_nINS0_14basic_appenderIcEEmcEET_S5_T0_RKT1_.exit, label %.lr.ph .lr.ph: ; preds = %26 - %27 = getelementptr inbounds nuw i8, ptr %2, i64 %7 - %.ptr17 = getelementptr inbounds nuw i8, ptr %27, i64 4 + %27 = getelementptr inbounds nuw i8, ptr %9, i64 %7 %.not24.i.i = icmp eq i32 %6, 0 - %28 = ptrtoint ptr %.ptr17 to i64 + %28 = ptrtoint ptr %27 to i64 %29 = getelementptr inbounds nuw i8, ptr %0, i64 8 %30 = getelementptr inbounds nuw i8, ptr %0, i64 16 %31 = getelementptr inbounds nuw i8, ptr %0, i64 24 @@ -12203,7 +12202,7 @@ _ZN3fmt3v116detail6bufferIcE11try_reserveEm.exit.i.i: ; preds = %39, %32 %47 = add i64 %46, %spec.select.i.i store i64 %47, ptr %29, align 8, !tbaa !276 %48 = getelementptr inbounds nuw i8, ptr %.01825.i.i, i64 %spec.select.i.i - %.not.i.i = icmp eq ptr %48, %.ptr17 + %.not.i.i = icmp eq ptr %48, %27 br i1 %.not.i.i, label %_ZN3fmt3v116detail4copyIcPKcNS0_14basic_appenderIcEETnNSt9enable_ifIXaasr23is_back_insert_iteratorIT1_EE5valuesr41has_back_insert_iterator_container_appendIS8_T0_EE5valueEiE4typeELi0EEES8_S9_S9_S8_.exit.loopexit, label %32, !llvm.loop !291 .lr.ph.i.i: ; preds = %_ZN3fmt3v116detail6bufferIcE11try_reserveEm.exit.i.i, %.lr.ph.i.i diff --git a/bench/foundations-rs/optimized/208outlkq19x3hykb3fof84u4.ll b/bench/foundations-rs/optimized/208outlkq19x3hykb3fof84u4.ll index d5c0bfed5d4..d4ed563c1d8 100644 --- a/bench/foundations-rs/optimized/208outlkq19x3hykb3fof84u4.ll +++ b/bench/foundations-rs/optimized/208outlkq19x3hykb3fof84u4.ll @@ -6578,52 +6578,55 @@ define hidden { ptr, i64 } @"_ZN4core3str21_$LT$impl$u20$str$GT$18trim_start_mat "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit12.i.i.i": ; preds = %9 %13 = and i8 %11, 31 %14 = zext nneg i8 %13 to i32 - %15 = icmp ne ptr %10, %3 - tail call void @llvm.assume(i1 %15) - %16 = getelementptr inbounds nuw i8, ptr %7, i64 2 - %17 = load i8, ptr %10, align 1, !noalias !686, !noundef !4 - %18 = shl nuw nsw i32 %14, 6 - %19 = and i8 %17, 63 - %20 = zext nneg i8 %19 to i32 - %21 = or disjoint i32 %18, %20 - %22 = icmp samesign ugt i8 %11, -33 - br i1 %22, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hdfcff69adeede8a3E.exit.i" + %15 = add nuw nsw i64 %6, 1 + %16 = icmp samesign ne i64 %15, %1 + tail call void @llvm.assume(i1 %16) + %17 = getelementptr inbounds nuw i8, ptr %7, i64 2 + %18 = load i8, ptr %10, align 1, !noalias !686, !noundef !4 + %19 = shl nuw nsw i32 %14, 6 + %20 = and i8 %18, 63 + %21 = zext nneg i8 %20 to i32 + %22 = or disjoint i32 %19, %21 + %23 = icmp samesign ugt i8 %11, -33 + br i1 %23, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hdfcff69adeede8a3E.exit.i" 23: ; preds = %9 %24 = zext nneg i8 %11 to i32 br label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hdfcff69adeede8a3E.exit.i" "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit12.i.i.i" - %25 = icmp ne ptr %16, %3 - tail call void @llvm.assume(i1 %25) - %26 = getelementptr inbounds nuw i8, ptr %7, i64 3 - %27 = load i8, ptr %16, align 1, !noalias !686, !noundef !4 - %28 = shl nuw nsw i32 %20, 6 - %29 = and i8 %27, 63 - %30 = zext nneg i8 %29 to i32 - %31 = or disjoint i32 %28, %30 - %32 = shl nuw nsw i32 %14, 12 - %33 = or disjoint i32 %31, %32 - %34 = icmp samesign ugt i8 %11, -17 - br i1 %34, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit16.i.i.i", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hdfcff69adeede8a3E.exit.i" + %26 = add nuw nsw i64 %6, 2 + %27 = icmp samesign ne i64 %26, %1 + tail call void @llvm.assume(i1 %27) + %28 = getelementptr inbounds nuw i8, ptr %7, i64 3 + %29 = load i8, ptr %17, align 1, !noalias !686, !noundef !4 + %30 = shl nuw nsw i32 %21, 6 + %31 = and i8 %29, 63 + %32 = zext nneg i8 %31 to i32 + %33 = or disjoint i32 %30, %32 + %34 = shl nuw nsw i32 %14, 12 + %35 = or disjoint i32 %33, %34 + %36 = icmp samesign ugt i8 %11, -17 + br i1 %36, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit16.i.i.i", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hdfcff69adeede8a3E.exit.i" "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit16.i.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i" - %35 = icmp ne ptr %26, %3 - tail call void @llvm.assume(i1 %35) - %36 = getelementptr inbounds nuw i8, ptr %7, i64 4 - %37 = load i8, ptr %26, align 1, !noalias !686, !noundef !4 - %38 = shl nuw nsw i32 %14, 18 - %39 = and i32 %38, 1835008 - %40 = shl nuw nsw i32 %31, 6 - %41 = and i8 %37, 63 - %42 = zext nneg i8 %41 to i32 - %43 = or disjoint i32 %40, %42 - %44 = or disjoint i32 %43, %39 + %37 = add nuw nsw i64 %6, 3 + %38 = icmp samesign ne i64 %37, %1 + tail call void @llvm.assume(i1 %38) + %39 = getelementptr inbounds nuw i8, ptr %7, i64 4 + %40 = load i8, ptr %28, align 1, !noalias !686, !noundef !4 + %41 = shl nuw nsw i32 %14, 18 + %42 = and i32 %41, 1835008 + %43 = shl nuw nsw i32 %33, 6 + %44 = and i8 %40, 63 + %45 = zext nneg i8 %44 to i32 + %44 = or disjoint i32 %43, %45 + %47 = or disjoint i32 %46, %42 br label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hdfcff69adeede8a3E.exit.i" "_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hdfcff69adeede8a3E.exit.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit16.i.i.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i", %23, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit12.i.i.i" - %.sroa.0.0.ph.i.i = phi ptr [ %16, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit12.i.i.i" ], [ %26, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i" ], [ %36, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit16.i.i.i" ], [ %10, %23 ] - %.sroa.4.0.i.ph.i.i = phi i32 [ %21, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit12.i.i.i" ], [ %33, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i" ], [ %44, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit16.i.i.i" ], [ %24, %23 ] + %.sroa.0.0.ph.i.i = phi ptr [ %17, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit12.i.i.i" ], [ %28, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i" ], [ %39, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit16.i.i.i" ], [ %10, %24 ] + %.sroa.4.0.i.ph.i.i = phi i32 [ %22, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit12.i.i.i" ], [ %35, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit14.i.i.i" ], [ %47, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h663c8bbbdf3b550aE.exit16.i.i.i" ], [ %24, %24 ] %45 = icmp samesign ult i32 %.sroa.4.0.i.ph.i.i, 1114112 tail call void @llvm.assume(i1 %45) %46 = ptrtoint ptr %.sroa.0.0.ph.i.i to i64 diff --git a/bench/freetype/optimized/sfnt.ll b/bench/freetype/optimized/sfnt.ll index d95a2139dc3..51fc02f9400 100644 --- a/bench/freetype/optimized/sfnt.ll +++ b/bench/freetype/optimized/sfnt.ll @@ -686,12 +686,11 @@ define internal noundef i32 @tt_cmap2_validate(ptr noundef readonly captures(add br i1 %.not89, label %.loopexit, label %.lr.ph.preheader .lr.ph.preheader: ; preds = %102 - %104 = getelementptr inbounds nuw i8, ptr %.1105, i64 %98 - %.ptr106 = getelementptr inbounds nuw i8, ptr %104, i64 8 + %104 = getelementptr inbounds nuw i8, ptr %.ptr, i64 %98 br label %.lr.ph .lr.ph: ; preds = %.lr.ph.preheader, %118 - %.5103 = phi ptr [ %105, %118 ], [ %.ptr, %.lr.ph.preheader ] + %.5103 = phi ptr [ %105, %119 ], [ %.ptr, %.lr.ph.preheader ] %105 = getelementptr inbounds nuw i8, ptr %.5103, i64 2 %106 = load i8, ptr %.5103, align 1, !tbaa !15 %107 = zext i8 %106 to i32 @@ -715,11 +714,11 @@ define internal noundef i32 @tt_cmap2_validate(ptr noundef readonly captures(add br label %118 118: ; preds = %113, %117, %.lr.ph - %119 = icmp ult ptr %105, %.ptr106 + %119 = icmp ult ptr %105, %105 br i1 %119, label %.lr.ph, label %.loopexit, !llvm.loop !32 .loopexit: ; preds = %118, %92, %102, %52 - %.2 = phi ptr [ %.ptr, %52 ], [ %.ptr, %92 ], [ %.ptr, %102 ], [ %105, %118 ] + %.2 = phi ptr [ %.ptr, %52 ], [ %.ptr, %93 ], [ %.ptr, %103 ], [ %105, %119 ] %120 = add nuw i32 %.178104, 1 %exitcond108.not = icmp eq i32 %.178104, %spec.select br i1 %exitcond108.not, label %121, label %52, !llvm.loop !33 diff --git a/bench/git/optimized/color.ll b/bench/git/optimized/color.ll index 384b06f3370..565a7dbab2d 100644 --- a/bench/git/optimized/color.ll +++ b/bench/git/optimized/color.ll @@ -674,18 +674,17 @@ color_output.exit130: ; preds = %230, %226, %221, %2 236: ; preds = %color_output.exit130 %.6.ptr.ptr = getelementptr inbounds i8, ptr %2, i64 %.6.idx - %.6.ptr.add = add nsw i64 %.6.idx, 1 - %.ptr = getelementptr inbounds i8, ptr %2, i64 %.6.ptr.add + %237 = getelementptr inbounds nuw i8, ptr %.6.ptr.ptr, i64 1 store i8 109, ptr %.6.ptr.ptr, align 1, !tbaa !4 - %237 = icmp eq i64 %.6.ptr.add, 75 - br i1 %237, label %238, label %.thread194 + %238 = icmp eq i64 %.6.idx, 74 + br i1 %238, label %239, label %.thread194 -238: ; preds = %236 +239: ; preds = %236 tail call void (ptr, i32, ptr, ...) @BUG_fl(ptr noundef nonnull @.str.14, i32 noundef 365, ptr noundef nonnull @.str.15) #16 unreachable .thread194: ; preds = %._crit_edge, %236 - %.7196 = phi ptr [ %.ptr, %236 ], [ %2, %._crit_edge ] + %.7196 = phi ptr [ %237, %236 ], [ %2, %._crit_edge ] store i8 0, ptr %.7196, align 1, !tbaa !4 br label %243 @@ -699,7 +698,7 @@ parse_attr.exit.thread: ; preds = %141, %parse_attr.ex br label %_.exit _.exit: ; preds = %parse_attr.exit.thread, %240 - %.0.i132 = phi ptr [ %241, %240 ], [ @.str.17, %parse_attr.exit.thread ] + %.0.i132 = phi ptr [ %241, %241 ], [ @.str.17, %parse_attr.exit.thread ] %242 = tail call i32 (ptr, ...) @error(ptr noundef %.0.i132, i32 noundef %1, ptr noundef %0) #15 br label %243 diff --git a/bench/git/optimized/packfile.ll b/bench/git/optimized/packfile.ll index d864d6c5211..a39eb70bfeb 100644 --- a/bench/git/optimized/packfile.ll +++ b/bench/git/optimized/packfile.ll @@ -5185,7 +5185,7 @@ st_mult.exit: ; preds = %2 %20 = load i32, ptr %19, align 4, !tbaa !36 %21 = tail call i32 asm "bswap $0", "=r,0,~{dirflag},~{fpsr},~{flags}"(i32 %20) #24, !srcloc !41 %22 = zext i32 %21 to i64 - br label %88 + br label %89 st_mult.exit23: ; preds = %2 %23 = getelementptr inbounds nuw i8, ptr %0, i64 72 @@ -5206,20 +5206,20 @@ st_mult.exit23: ; preds = %2 36: ; preds = %st_mult.exit23 %37 = zext nneg i32 %35 to i64 - br label %88 + br label %89 st_mult.exit32: ; preds = %st_mult.exit23 %38 = shl nuw nsw i64 %25, 2 %39 = and i32 %35, 2147483647 %40 = zext nneg i32 %39 to i64 %41 = shl nuw nsw i64 %40, 3 - %42 = getelementptr inbounds nuw i8, ptr %30, i64 %41 - %43 = getelementptr inbounds nuw i8, ptr %42, i64 %38 - %44 = getelementptr inbounds nuw i8, ptr %0, i64 64 - %45 = load i64, ptr %44, align 8, !tbaa !37 - %46 = getelementptr inbounds nuw i8, ptr %4, i64 %45 - %47 = getelementptr inbounds i8, ptr %46, i64 -8 - %.not.i38 = icmp ult ptr %43, %47 + %42 = add nuw nsw i64 %41, %38 + %43 = getelementptr inbounds nuw i8, ptr %0, i64 64 + %44 = load i64, ptr %43, align 8, !tbaa !37 + %45 = add nsw i64 %44, -8 + %46 = add nuw nsw i64 %28, 1032 + %47 = add nuw nsw i64 %46, %42 + %.not.i38 = icmp slt i64 %47, %45 br i1 %.not.i38, label %check_pack_index_ptr.exit, label %48 48: ; preds = %st_mult.exit32 @@ -5229,47 +5229,48 @@ st_mult.exit32: ; preds = %st_mult.exit23 unreachable check_pack_index_ptr.exit: ; preds = %st_mult.exit32 - %51 = load i8, ptr %43, align 1, !tbaa !12 - %52 = zext i8 %51 to i64 - %53 = shl nuw nsw i64 %52, 24 - %54 = getelementptr inbounds nuw i8, ptr %43, i64 1 - %55 = load i8, ptr %54, align 1, !tbaa !12 - %56 = zext i8 %55 to i64 - %57 = shl nuw nsw i64 %56, 16 - %58 = or disjoint i64 %57, %53 - %59 = getelementptr inbounds nuw i8, ptr %43, i64 2 - %60 = load i8, ptr %59, align 1, !tbaa !12 - %61 = zext i8 %60 to i64 - %62 = shl nuw nsw i64 %61, 8 - %63 = or disjoint i64 %58, %62 - %64 = getelementptr inbounds nuw i8, ptr %43, i64 3 - %65 = load i8, ptr %64, align 1, !tbaa !12 - %66 = zext i8 %65 to i64 - %67 = or disjoint i64 %63, %66 - %68 = shl nuw i64 %67, 32 - %69 = getelementptr inbounds nuw i8, ptr %43, i64 4 - %70 = load i8, ptr %69, align 1, !tbaa !12 - %71 = zext i8 %70 to i64 - %72 = shl nuw nsw i64 %71, 24 - %73 = getelementptr inbounds nuw i8, ptr %43, i64 5 - %74 = load i8, ptr %73, align 1, !tbaa !12 - %75 = zext i8 %74 to i64 - %76 = shl nuw nsw i64 %75, 16 - %77 = or disjoint i64 %76, %72 - %78 = getelementptr inbounds nuw i8, ptr %43, i64 6 - %79 = load i8, ptr %78, align 1, !tbaa !12 - %80 = zext i8 %79 to i64 - %81 = shl nuw nsw i64 %80, 8 - %82 = getelementptr inbounds nuw i8, ptr %43, i64 7 - %83 = load i8, ptr %82, align 1, !tbaa !12 - %84 = zext i8 %83 to i64 - %85 = or disjoint i64 %77, %68 - %86 = or disjoint i64 %85, %81 - %87 = or disjoint i64 %86, %84 - br label %88 - -88: ; preds = %36, %check_pack_index_ptr.exit, %st_mult.exit - %.0 = phi i64 [ %22, %st_mult.exit ], [ %87, %check_pack_index_ptr.exit ], [ %37, %36 ] + %51 = getelementptr inbounds nuw i8, ptr %30, i64 %42 + %52 = load i8, ptr %51, align 1, !tbaa !12 + %53 = zext i8 %52 to i64 + %54 = shl nuw nsw i64 %53, 24 + %55 = getelementptr inbounds nuw i8, ptr %51, i64 1 + %56 = load i8, ptr %55, align 1, !tbaa !12 + %57 = zext i8 %56 to i64 + %58 = shl nuw nsw i64 %57, 16 + %59 = or disjoint i64 %58, %54 + %60 = getelementptr inbounds nuw i8, ptr %51, i64 2 + %61 = load i8, ptr %60, align 1, !tbaa !12 + %62 = zext i8 %61 to i64 + %63 = shl nuw nsw i64 %62, 8 + %64 = or disjoint i64 %59, %63 + %65 = getelementptr inbounds nuw i8, ptr %51, i64 3 + %66 = load i8, ptr %65, align 1, !tbaa !12 + %67 = zext i8 %66 to i64 + %68 = or disjoint i64 %64, %67 + %69 = shl nuw i64 %68, 32 + %70 = getelementptr inbounds nuw i8, ptr %51, i64 4 + %71 = load i8, ptr %70, align 1, !tbaa !12 + %72 = zext i8 %71 to i64 + %73 = shl nuw nsw i64 %72, 24 + %74 = getelementptr inbounds nuw i8, ptr %51, i64 5 + %75 = load i8, ptr %74, align 1, !tbaa !12 + %76 = zext i8 %75 to i64 + %77 = shl nuw nsw i64 %76, 16 + %78 = or disjoint i64 %77, %73 + %79 = getelementptr inbounds nuw i8, ptr %51, i64 6 + %80 = load i8, ptr %79, align 1, !tbaa !12 + %81 = zext i8 %80 to i64 + %82 = shl nuw nsw i64 %81, 8 + %83 = getelementptr inbounds nuw i8, ptr %51, i64 7 + %84 = load i8, ptr %83, align 1, !tbaa !12 + %85 = zext i8 %84 to i64 + %86 = or disjoint i64 %78, %69 + %87 = or disjoint i64 %86, %82 + %88 = or disjoint i64 %87, %85 + br label %89 + +89:; preds = %36, %check_pack_index_ptr.exit, %st_mult.exit + %.0 = phi i64 [ %22, %st_mult.exit ], [ %88, %check_pack_index_ptr.exit ], [ %37, %36 ] ret i64 %.0 } diff --git a/bench/graphviz/optimized/dthash.ll b/bench/graphviz/optimized/dthash.ll index d5acaa9c2c4..1f46365f9b2 100644 --- a/bench/graphviz/optimized/dthash.ll +++ b/bench/graphviz/optimized/dthash.ll @@ -821,10 +821,13 @@ thread-pre-split: ; preds = %283, %279, %272 %374 = getelementptr inbounds nuw i8, ptr %0, i64 32 store ptr %369, ptr %374, align 8, !tbaa !20 store i32 %.0.i, ptr %349, align 8, !tbaa !21 - %375 = getelementptr inbounds ptr, ptr %369, i64 %367 - %.04455.i = getelementptr inbounds i8, ptr %375, i64 -8 - %.not5256.i = icmp ult ptr %.04455.i, %373 - br i1 %.not5256.i, label %.preheader.i, label %.lr.ph.i + %.not5256.not.i = icmp sgt i64 %368, %.idx.i + br i1 %.not5256.not.i, label %.lr.ph.preheader.i, label %.preheader.i + +.lr.ph.preheader.i:; preds = %370 + %375 = getelementptr i8, ptr %369, i64 %368 + %.04455.i = getelementptr i8, ptr %375, i64 -8 + br label %.lr.ph.i .preheader.i: ; preds = %.lr.ph.i, %370 %376 = icmp sgt i32 %371, 0 @@ -834,8 +837,8 @@ thread-pre-split: ; preds = %283, %279, %272 %377 = add nsw i32 %.0.i, -1 br label %378 -.lr.ph.i: ; preds = %370, %.lr.ph.i - %.04457.i = phi ptr [ %.044.i, %.lr.ph.i ], [ %.04455.i, %370 ] +.lr.ph.i: ; preds = %.lr.ph.i, %.lr.ph.preheader.i + %.04457.i = phi ptr [ %.044.i, %.lr.ph.i ], [ %.04455.i, %.lr.ph.preheader.i ] store ptr null, ptr %.04457.i, align 8, !tbaa !22 %.044.i = getelementptr inbounds i8, ptr %.04457.i, i64 -8 %.not52.i = icmp ult ptr %.044.i, %373 @@ -1083,10 +1086,13 @@ define internal fastcc void @dthtab(ptr noundef captures(none) %0) unnamed_addr %25 = getelementptr inbounds nuw i8, ptr %0, i64 32 store ptr %20, ptr %25, align 8, !tbaa !20 store i32 %.0, ptr %2, align 8, !tbaa !21 - %26 = getelementptr inbounds ptr, ptr %20, i64 %18 - %.04455 = getelementptr inbounds i8, ptr %26, i64 -8 - %.not5256 = icmp ult ptr %.04455, %24 - br i1 %.not5256, label %.preheader, label %.lr.ph + %.not5256.not = icmp sgt i64 %19, %.idx + br i1 %.not5256.not, label %.lr.ph.preheader, label %.preheader + +.lr.ph.preheader:; preds = %21 + %26 = getelementptr i8, ptr %20, i64 %19 + %.04455 = getelementptr i8, ptr %26, i64 -8 + br label %.lr.ph .preheader: ; preds = %.lr.ph, %21 %27 = icmp sgt i32 %22, 0 @@ -1096,8 +1102,8 @@ define internal fastcc void @dthtab(ptr noundef captures(none) %0) unnamed_addr %28 = add nsw i32 %.0, -1 br label %29 -.lr.ph: ; preds = %21, %.lr.ph - %.04457 = phi ptr [ %.044, %.lr.ph ], [ %.04455, %21 ] +.lr.ph: ; preds = %.lr.ph.preheader, %.lr.ph + %.04457 = phi ptr [ %.044, %.lr.ph ], [ %.04455, %.lr.ph.preheader ] store ptr null, ptr %.04457, align 8, !tbaa !22 %.044 = getelementptr inbounds i8, ptr %.04457, i64 -8 %.not52 = icmp ult ptr %.044, %24 diff --git a/bench/gromacs/optimized/lincs.ll b/bench/gromacs/optimized/lincs.ll index b27a1f48ad9..ced096f19c9 100644 --- a/bench/gromacs/optimized/lincs.ll +++ b/bench/gromacs/optimized/lincs.ll @@ -4225,16 +4225,20 @@ _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIi br i1 %.not.i.i.i.i.i, label %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops15_Iter_less_iterEEvT_S9_T0_.exit.i.i.i.i, label %.lr.ph.i.i.i.i.i, !llvm.loop !227 _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops15_Iter_less_iterEEvT_S9_T0_.exit.i.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i.i.i.i.i - %168 = getelementptr inbounds nuw i8, ptr %147, i64 64 - %.not4.i.i.i.i.i = icmp eq ptr %168, %151 + %168 = add nsw i64 %.idx65.i, 64 + %.not4.i.i.i.i.i = icmp eq i64 %168, %.idx.i br i1 %.not4.i.i.i.i.i, label %_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEEEvT_S7_.exit.i, label %.lr.ph.i6.i.i.i.i -.lr.ph.i6.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops15_Iter_less_iterEEvT_S9_T0_.exit.i.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i7.i.i.i.i - %.sroa.0.05.i.i.i.i.i = phi ptr [ %175, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i7.i.i.i.i ], [ %168, %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops15_Iter_less_iterEEvT_S9_T0_.exit.i.i.i.i ] - %169 = load i32, ptr %.sroa.0.05.i.i.i.i.i, align 4, !tbaa !18 +.lr.ph.i6.i.i.i.i: ; preds = %_ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops15_Iter_less_iterEEvT_S9_T0_.exit.i.i.i.i + %169 = getelementptr inbounds nuw i8, ptr %147, i64 64 + br label %.lr.ph.i6.i.i.i.i + +.lr.ph.i6.i.i.i.i: ; preds = %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i7.i.i.i.i, %.lr.ph.i6.i.i.i.preheader.i + %.sroa.0.05.i.i.i.i.i = phi ptr [ %176, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i7.i.i.i.i ], [ %169, %.lr.ph.i6.i.i.i.preheader.i ] + %170 = load i32, ptr %.sroa.0.05.i.i.i.i.i, align 4, !tbaa !18 %.sroa.0.07.i.i.i.i.i.i = getelementptr inbounds i8, ptr %.sroa.0.05.i.i.i.i.i, i64 -4 %170 = load i32, ptr %.sroa.0.07.i.i.i.i.i.i, align 4, !tbaa !18 - %171 = icmp slt i32 %169, %170 + %171 = icmp slt i32 %170, %170 br i1 %171, label %.lr.ph.i.i9.i.i.i.i, label %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i7.i.i.i.i .lr.ph.i.i9.i.i.i.i: ; preds = %.lr.ph.i6.i.i.i.i, %.lr.ph.i.i9.i.i.i.i @@ -4244,23 +4248,24 @@ _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5 store i32 %172, ptr %.sroa.04.08.i.i11.i.i.i.i, align 4, !tbaa !18 %.sroa.0.0.i.i12.i.i.i.i = getelementptr inbounds i8, ptr %.sroa.0.09.i.i10.i.i.i.i, i64 -4 %173 = load i32, ptr %.sroa.0.0.i.i12.i.i.i.i, align 4, !tbaa !18 - %174 = icmp slt i32 %169, %173 + %174 = icmp slt i32 %170, %173 br i1 %174, label %.lr.ph.i.i9.i.i.i.i, label %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i7.i.i.i.i, !llvm.loop !226 _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i7.i.i.i.i: ; preds = %.lr.ph.i.i9.i.i.i.i, %.lr.ph.i6.i.i.i.i %.sroa.04.0.lcssa.i.i.i.i.i.i = phi ptr [ %.sroa.0.05.i.i.i.i.i, %.lr.ph.i6.i.i.i.i ], [ %.sroa.0.09.i.i10.i.i.i.i, %.lr.ph.i.i9.i.i.i.i ] - store i32 %169, ptr %.sroa.04.0.lcssa.i.i.i.i.i.i, align 4, !tbaa !18 + store i32 %170, ptr %.sroa.04.0.lcssa.i.i.i.i.i.i, align 4, !tbaa !18 %175 = getelementptr inbounds nuw i8, ptr %.sroa.0.05.i.i.i.i.i, i64 4 %.not.i8.i.i.i.i = icmp eq ptr %175, %151 br i1 %.not.i8.i.i.i.i, label %_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEEEvT_S7_.exit.i, label %.lr.ph.i6.i.i.i.i, !llvm.loop !228 176: ; preds = %.noexc27 - %.not16.i15.i.i.i.i = icmp eq ptr %scevgep.i.i.i.i, %151 + %178 = add nsw i64 %.idx65.i, 4 + %.not16.i15.i.i.i.i = icmp eq i64 %178, %.idx.i br i1 %.not16.i15.i.i.i.i, label %_ZSt4sortIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEEEvT_S7_.exit.i, label %.lr.ph.i16.i.i.i.i .lr.ph.i16.i.i.i.i: ; preds = %176, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i19.i.i.i.i - %.sroa.0.018.i17.i.i.i.i = phi ptr [ %.sroa.0.0.i21.i.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i19.i.i.i.i ], [ %scevgep.i.i.i.i, %176 ] - %.pn17.i18.i.i.i.i = phi ptr [ %.sroa.0.018.i17.i.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i19.i.i.i.i ], [ %147, %176 ] + %.sroa.0.018.i17.i.i.i.i = phi ptr [ %.sroa.0.0.i21.i.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i19.i.i.i.i ], [ %scevgep.i.i.i.i, %177 ] + %.pn17.i18.i.i.i.i = phi ptr [ %.sroa.0.018.i17.i.i.i.i, %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i19.i.i.i.i ], [ %147, %177 ] %177 = load i32, ptr %.sroa.0.018.i17.i.i.i.i, align 4, !tbaa !18 %178 = load i32, ptr %147, align 4, !tbaa !18 %179 = icmp slt i32 %177, %178 @@ -4282,9 +4287,9 @@ _ZSt13move_backwardIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T br i1 %188, label %.lr.ph.i.i23.i.i.i.i, label %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i19.i.i.i.i .lr.ph.i.i23.i.i.i.i: ; preds = %186, %.lr.ph.i.i23.i.i.i.i - %189 = phi i32 [ %190, %.lr.ph.i.i23.i.i.i.i ], [ %187, %186 ] - %.sroa.0.09.i.i24.i.i.i.i = phi ptr [ %.sroa.0.0.i.i26.i.i.i.i, %.lr.ph.i.i23.i.i.i.i ], [ %.pn17.i18.i.i.i.i, %186 ] - %.sroa.04.08.i.i25.i.i.i.i = phi ptr [ %.sroa.0.09.i.i24.i.i.i.i, %.lr.ph.i.i23.i.i.i.i ], [ %.sroa.0.018.i17.i.i.i.i, %186 ] + %189 = phi i32 [ %190, %.lr.ph.i.i23.i.i.i.i ], [ %187, %188 ] + %.sroa.0.09.i.i24.i.i.i.i = phi ptr [ %.sroa.0.0.i.i26.i.i.i.i, %.lr.ph.i.i23.i.i.i.i ], [ %.pn17.i18.i.i.i.i, %188 ] + %.sroa.04.08.i.i25.i.i.i.i = phi ptr [ %.sroa.0.09.i.i24.i.i.i.i, %.lr.ph.i.i23.i.i.i.i ], [ %.sroa.0.018.i17.i.i.i.i, %188 ] store i32 %189, ptr %.sroa.04.08.i.i25.i.i.i.i, align 4, !tbaa !18 %.sroa.0.0.i.i26.i.i.i.i = getelementptr inbounds i8, ptr %.sroa.0.09.i.i24.i.i.i.i, i64 -4 %190 = load i32, ptr %.sroa.0.0.i.i26.i.i.i.i, align 4, !tbaa !18 @@ -4292,7 +4297,7 @@ _ZSt13move_backwardIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T br i1 %191, label %.lr.ph.i.i23.i.i.i.i, label %_ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i19.i.i.i.i, !llvm.loop !226 _ZSt25__unguarded_linear_insertIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEENS0_5__ops14_Val_less_iterEEvT_T0_.exit.i19.i.i.i.i: ; preds = %.lr.ph.i.i23.i.i.i.i, %186, %_ZSt13move_backwardIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i27.i.i.i.i - %.sink.i20.i.i.i.i = phi ptr [ %147, %_ZSt13move_backwardIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i27.i.i.i.i ], [ %.sroa.0.018.i17.i.i.i.i, %186 ], [ %.sroa.0.09.i.i24.i.i.i.i, %.lr.ph.i.i23.i.i.i.i ] + %.sink.i20.i.i.i.i = phi ptr [ %147, %_ZSt13move_backwardIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i27.i.i.i.i ], [ %.sroa.0.018.i17.i.i.i.i, %188 ], [ %.sroa.0.09.i.i24.i.i.i.i, %.lr.ph.i.i23.i.i.i.i ] store i32 %177, ptr %.sink.i20.i.i.i.i, align 4, !tbaa !18 %.sroa.0.0.i21.i.i.i.i = getelementptr inbounds nuw i8, ptr %.sroa.0.018.i17.i.i.i.i, i64 4 %.not.i22.i.i.i.i = icmp eq ptr %.sroa.0.0.i21.i.i.i.i, %151 diff --git a/bench/gromacs/optimized/selvalue.ll b/bench/gromacs/optimized/selvalue.ll index be2ec977025..4a8915fe339 100644 --- a/bench/gromacs/optimized/selvalue.ll +++ b/bench/gromacs/optimized/selvalue.ll @@ -3,9 +3,6 @@ source_filename = "bench/gromacs/original/selvalue.ll" target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128" target triple = "x86_64-pc-linux-gnu" -%struct.gmx_ana_pos_t = type <{ ptr, ptr, ptr, %struct.gmx_ana_indexmap_t, i32, [4 x i8] }> -%struct.gmx_ana_indexmap_t = type { i32, ptr, ptr, %struct.t_blocka, ptr, %struct.t_blocka, i8 } -%struct.t_blocka = type { i32, ptr, i32, ptr, i32, i32 } %struct.gmx_ana_index_t = type { i32, ptr, i32 } @.str = private unnamed_addr constant [11 x i8] c"val->u.ptr\00", align 1 @@ -133,7 +130,7 @@ define void @_Z21_gmx_selvalue_reserveP18gmx_ana_selvalue_ti(ptr noundef capture br label %.lr.ph47 .lr.ph47: ; preds = %.lr.ph47.preheader, %.lr.ph47 - %indvars.iv51 = phi i64 [ %23, %.lr.ph47.preheader ], [ %indvars.iv.next52, %.lr.ph47 ] + %indvars.iv51 = phi i64 [ %23, %.lr.ph48.preheader ], [ %indvars.iv.next52, %.lr.ph48 ] %24 = load ptr, ptr %7, align 8, !tbaa !11 %25 = getelementptr inbounds ptr, ptr %24, i64 %indvars.iv51 store ptr null, ptr %25, align 8, !tbaa !16 @@ -164,30 +161,26 @@ define void @_Z21_gmx_selvalue_reserveP18gmx_ana_selvalue_ti(ptr noundef capture %39 = icmp eq i32 %1, 0 br i1 %39, label %.loopexit.sink.split, label %40 -40: ; preds = %28 - %41 = getelementptr inbounds %struct.gmx_ana_pos_t, ptr %.ptr36, i64 %29 - br label %42 - -42: ; preds = %43, %40 - %.idx = phi i64 [ 8, %40 ], [ %.add, %43 ] +40: ; preds = %28, %40 + %.idx = phi i64 [ %.add, %40 ], [ 8, %28 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %38, i64 %.idx invoke void @_ZN13gmx_ana_pos_tC1Ev(ptr noundef nonnull align 8 dereferenceable(148) %.ptr.ptr) - to label %43 unwind label %45 + to label %40 unwind label %45 -43: ; preds = %42 +43: ; preds = %40 %.add = add nuw nsw i64 %.idx, 152 - %.ptr35 = getelementptr inbounds nuw i8, ptr %38, i64 %.add - %44 = icmp eq ptr %.ptr35, %41 - br i1 %44, label %.loopexit.sink.split, label %42 + %41 = add nuw nsw i64 %.idx, 144 + %44 = icmp eq i64 %41, %32 + br i1 %44, label %.loopexit.sink.split, label %40 -45: ; preds = %42 +45: ; preds = %40 %46 = landingpad { ptr, i32 } cleanup %47 = icmp eq i64 %.idx, 8 br i1 %47, label %.loopexit41, label %.preheader .preheader: ; preds = %45, %.preheader - %.idx37 = phi i64 [ %.add38, %.preheader ], [ %.idx, %45 ] + %.idx37 = phi i64 [ %.add38, %.preheader ], [ %.idx, %43 ] %.add38 = add nsw i64 %.idx37, -152 %.ptr40 = getelementptr inbounds i8, ptr %38, i64 %.add38 tail call void @_ZN13gmx_ana_pos_tD1Ev(ptr noundef nonnull align 8 dereferenceable(148) %.ptr40) #10 @@ -221,7 +214,7 @@ define void @_Z21_gmx_selvalue_reserveP18gmx_ana_selvalue_ti(ptr noundef capture br i1 %exitcond.not, label %.loopexit, label %.lr.ph, !llvm.loop !22 .loopexit.sink.split: ; preds = %43, %28, %12, %15 - %.ptr36.sink = phi ptr [ %17, %15 ], [ %14, %12 ], [ %.ptr36, %28 ], [ %.ptr36, %43 ] + %.ptr36.sink = phi ptr [ %17, %15 ], [ %14, %12 ], [ %.ptr36, %28 ], [ %.ptr36, %40 ] store ptr %.ptr36.sink, ptr %7, align 8, !tbaa !11 br label %.loopexit diff --git a/bench/grpc/optimized/legacy_channel_idle_filter.ll b/bench/grpc/optimized/legacy_channel_idle_filter.ll index 503db530540..3203b0a0b2a 100644 --- a/bench/grpc/optimized/legacy_channel_idle_filter.ll +++ b/bench/grpc/optimized/legacy_channel_idle_filter.ll @@ -4825,16 +4825,11 @@ define linkonce_odr void @_ZN9grpc_core6PerCpuIZNS_18LegacyMaxAgeFilter6Config15 %16 = select i1 %14, i64 -1, i64 %15 %17 = call noalias noundef nonnull ptr @_Znam(i64 noundef %16) #36 store i64 %8, ptr %17, align 16 - %.ptr5 = getelementptr inbounds nuw i8, ptr %17, i64 8 %18 = icmp eq i64 %8, 0 - br i1 %18, label %.loopexit11, label %19 + br i1 %18, label %.loopexit11, label %21 -19: ; preds = %3 - %20 = getelementptr inbounds %struct.BitGen, ptr %.ptr5, i64 %8 - br label %21 - -21: ; preds = %28, %19 - %.idx = phi i64 [ 8, %19 ], [ %.add, %28 ] +21: ; preds = %3, %25 + %.idx = phi i64 [ %.add, %25 ], [ 8, %3 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %17, i64 %.idx store i64 0, ptr %.ptr.ptr, align 8, !tbaa !276 call void @llvm.experimental.noalias.scope.decl(metadata !277) @@ -4852,18 +4847,19 @@ define linkonce_odr void @_ZN9grpc_core6PerCpuIZNS_18LegacyMaxAgeFilter6Config15 %27 = getelementptr inbounds nuw i8, ptr %23, i64 %26 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(256) %27, i8 0, i64 256, i1 false), !alias.scope !277 invoke void @_ZN4absl12lts_2024072215random_internal13randen_engineImE6reseedINS1_17RandenPoolSeedSeqEEEvRT_(ptr noundef nonnull align 8 dereferenceable(288) %23, ptr noundef nonnull align 1 dereferenceable(1) %4) - to label %28 unwind label %.loopexit + to label %25 unwind label %.loopexit 28: ; preds = %.noexc call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #34, !noalias !277 %.add = add nuw nsw i64 %.idx, 296 - %.ptr4 = getelementptr inbounds nuw i8, ptr %17, i64 %.add - %29 = icmp eq ptr %.ptr4, %20 + %26 = add nuw nsw i64 %.idx, 288 + %29 = icmp eq i64 %26, %11 br i1 %29, label %.loopexit11, label %21 .loopexit11: ; preds = %28, %3 - %30 = getelementptr inbounds nuw i8, ptr %0, i64 16 - store ptr %.ptr5, ptr %30, align 8, !tbaa !275 + %30 = getelementptr inbounds nuw i8, ptr %17, i64 8 + %28 = getelementptr inbounds nuw i8, ptr %0, i64 16 + store ptr %.ptr5, ptr %28, align 8, !tbaa !275 ret void .loopexit: ; preds = %.noexc, %21 diff --git a/bench/grpc/optimized/work_serializer.ll b/bench/grpc/optimized/work_serializer.ll index 27aa7387469..636168b8e59 100644 --- a/bench/grpc/optimized/work_serializer.ll +++ b/bench/grpc/optimized/work_serializer.ll @@ -1948,36 +1948,35 @@ define linkonce_odr void @_ZN4absl12lts_2024072223inlined_vector_internal7Storag %11 = lshr i64 %10, 1 %12 = lshr i64 %9, 1 %13 = sub nsw i64 %12, %11 + %14 = getelementptr inbounds nuw i8, ptr %0, i64 16 %.idx.i = shl nuw nsw i64 %11, 5 - %14 = getelementptr inbounds nuw i8, ptr %0, i64 %.idx.i - %.ptr2.i = getelementptr inbounds nuw i8, ptr %14, i64 16 + %14 = getelementptr inbounds nuw i8, ptr %14, i64 %.idx.i %.not8.i.i = icmp ult i64 %10, 2 br i1 %.not8.i.i, label %_ZN4absl12lts_2024072223inlined_vector_internal7StorageIN9grpc_core14WorkSerializer18WorkSerializerImpl15CallbackWrapperELm1ESaIS6_EE5SwapNENS8_21ElementwiseSwapPolicyEPS8_m.exit, label %.lr.ph.i.i .lr.ph.i.i: ; preds = %2 - %.ptr.i = getelementptr inbounds nuw i8, ptr %0, i64 16 - %15 = getelementptr inbounds nuw i8, ptr %1, i64 16 - %16 = getelementptr inbounds nuw i8, ptr %3, i64 16 - %17 = getelementptr inbounds nuw i8, ptr %3, i64 24 - br label %18 - -18: ; preds = %18, %.lr.ph.i.i - %.010.i.i = phi ptr [ %15, %.lr.ph.i.i ], [ %33, %18 ] - %.079.i.i = phi ptr [ %.ptr.i, %.lr.ph.i.i ], [ %32, %18 ] + %.ptr.i = getelementptr inbounds nuw i8, ptr %1, i64 16 + %15 = getelementptr inbounds nuw i8, ptr %3, i64 16 + %16 = getelementptr inbounds nuw i8, ptr %3, i64 24 + br label %19 + +19: ; preds = %19, %.lr.ph.i.i + %.010.i.i = phi ptr [ %16, %.lr.ph.i.i ], [ %34, %19 ] + %.010.i.i = phi ptr [ %14, %.lr.ph.i.i ], [ %33, %19 ] call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %3) #25 %19 = getelementptr inbounds nuw i8, ptr %.079.i.i, i64 16 %20 = load ptr, ptr %19, align 16, !tbaa !41 - call void %20(i1 noundef zeroext false, ptr noundef nonnull align 16 dereferenceable(32) %.079.i.i, ptr noundef nonnull align 16 dereferenceable(32) %3) #25 + call void %21(i1 noundef zeroext false, ptr noundef nonnull align 16 dereferenceable(32) %.079.i.i, ptr noundef nonnull align 16 dereferenceable(32) %3) #25 %21 = load ptr, ptr %19, align 16, !tbaa !41 - store ptr %21, ptr %16, align 16, !tbaa !41 + store ptr %21, ptr %17, align 16, !tbaa !41 %22 = getelementptr inbounds nuw i8, ptr %.079.i.i, i64 24 %23 = load ptr, ptr %22, align 8, !tbaa !43 - store ptr %23, ptr %17, align 8, !tbaa !43 + store ptr %23, ptr %18, align 8, !tbaa !43 store ptr @_ZN4absl12lts_2024072222internal_any_invocable12EmptyManagerENS1_14FunctionToCallEPNS1_15TypeErasedStateES4_, ptr %19, align 16, !tbaa !41 store ptr null, ptr %22, align 8, !tbaa !43 %24 = getelementptr inbounds nuw i8, ptr %.010.i.i, i64 16 %25 = load ptr, ptr %24, align 16, !tbaa !41 - call void %25(i1 noundef zeroext false, ptr noundef nonnull align 16 dereferenceable(32) %.010.i.i, ptr noundef nonnull align 16 dereferenceable(32) %.079.i.i) #25 + call void %26(i1 noundef zeroext false, ptr noundef nonnull align 16 dereferenceable(32) %.010.i.i, ptr noundef nonnull align 16 dereferenceable(32) %.079.i.i) #25 %26 = load ptr, ptr %24, align 16, !tbaa !41 store ptr %26, ptr %19, align 16, !tbaa !41 %27 = getelementptr inbounds nuw i8, ptr %.010.i.i, i64 24 @@ -1985,19 +1984,19 @@ define linkonce_odr void @_ZN4absl12lts_2024072223inlined_vector_internal7Storag store ptr %28, ptr %22, align 8, !tbaa !43 store ptr @_ZN4absl12lts_2024072222internal_any_invocable12EmptyManagerENS1_14FunctionToCallEPNS1_15TypeErasedStateES4_, ptr %24, align 16, !tbaa !41 store ptr null, ptr %27, align 8, !tbaa !43 - %29 = load ptr, ptr %16, align 16, !tbaa !41 - call void %29(i1 noundef zeroext false, ptr noundef nonnull align 16 dereferenceable(32) %3, ptr noundef nonnull align 16 dereferenceable(32) %.010.i.i) #25 - %30 = load ptr, ptr %16, align 16, !tbaa !41 + %29 = load ptr, ptr %17, align 16, !tbaa !41 + call void %30(i1 noundef zeroext false, ptr noundef nonnull align 16 dereferenceable(32) %3, ptr noundef nonnull align 16 dereferenceable(32) %.010.i.i) #25 + %30 = load ptr, ptr %17, align 16, !tbaa !41 store ptr %30, ptr %24, align 16, !tbaa !41 - %31 = load ptr, ptr %17, align 8, !tbaa !43 + %31 = load ptr, ptr %18, align 8, !tbaa !43 store ptr %31, ptr %27, align 8, !tbaa !43 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %3) #25 %32 = getelementptr inbounds nuw i8, ptr %.079.i.i, i64 32 %33 = getelementptr inbounds nuw i8, ptr %.010.i.i, i64 32 - %.not.i.i = icmp eq ptr %32, %.ptr2.i - br i1 %.not.i.i, label %_ZN4absl12lts_2024072223inlined_vector_internal7StorageIN9grpc_core14WorkSerializer18WorkSerializerImpl15CallbackWrapperELm1ESaIS6_EE5SwapNENS8_21ElementwiseSwapPolicyEPS8_m.exit, label %18, !llvm.loop !109 + %.not.i.i = icmp eq ptr %32, %15 + br i1 %.not.i.i, label %_ZN4absl12lts_2024072223inlined_vector_internal7StorageIN9grpc_core14WorkSerializer18WorkSerializerImpl15CallbackWrapperELm1ESaIS6_EE5SwapNENS8_21ElementwiseSwapPolicyEPS8_m.exit, label %19, !llvm.loop !109 -_ZN4absl12lts_2024072223inlined_vector_internal7StorageIN9grpc_core14WorkSerializer18WorkSerializerImpl15CallbackWrapperELm1ESaIS6_EE5SwapNENS8_21ElementwiseSwapPolicyEPS8_m.exit: ; preds = %18, %2 +_ZN4absl12lts_2024072223inlined_vector_internal7StorageIN9grpc_core14WorkSerializer18WorkSerializerImpl15CallbackWrapperELm1ESaIS6_EE5SwapNENS8_21ElementwiseSwapPolicyEPS8_m.exit: ; preds = %19, %2 %34 = getelementptr inbounds nuw i8, ptr %spec.select, i64 16 %35 = getelementptr inbounds nuw %"struct.grpc_core::WorkSerializer::WorkSerializerImpl::CallbackWrapper", ptr %34, i64 %11 %36 = getelementptr inbounds nuw i8, ptr %spec.select22, i64 16 @@ -2011,7 +2010,7 @@ _ZN4absl12lts_2024072223inlined_vector_internal7StorageIN9grpc_core14WorkSeriali %38 = getelementptr inbounds nuw %"struct.grpc_core::WorkSerializer::WorkSerializerImpl::CallbackWrapper", ptr %37, i64 %.012.i %39 = getelementptr inbounds nuw i8, ptr %.sroa.011.0, i64 16 %40 = load ptr, ptr %39, align 16, !tbaa !41 - call void %40(i1 noundef zeroext false, ptr noundef nonnull align 16 dereferenceable(32) %.sroa.011.0, ptr noundef nonnull align 16 dereferenceable(32) %38) #25 + call void %41(i1 noundef zeroext false, ptr noundef nonnull align 16 dereferenceable(32) %.sroa.011.0, ptr noundef nonnull align 16 dereferenceable(32) %38) #25 %41 = load ptr, ptr %39, align 16, !tbaa !41 %42 = getelementptr inbounds nuw i8, ptr %38, i64 16 store ptr %41, ptr %42, align 16, !tbaa !41 @@ -2032,7 +2031,7 @@ _ZN4absl12lts_2024072223inlined_vector_internal7StorageIN9grpc_core14WorkSeriali %49 = getelementptr inbounds nuw %"struct.grpc_core::WorkSerializer::WorkSerializerImpl::CallbackWrapper", ptr %35, i64 %48 %50 = getelementptr inbounds nuw i8, ptr %49, i64 16 %51 = load ptr, ptr %50, align 16, !tbaa !41 - call void %51(i1 noundef zeroext true, ptr noundef nonnull align 16 dereferenceable(32) %49, ptr noundef nonnull align 16 dereferenceable(32) %49) #25 + call void %52(i1 noundef zeroext true, ptr noundef nonnull align 16 dereferenceable(32) %49, ptr noundef nonnull align 16 dereferenceable(32) %49) #25 %.not.i10 = icmp eq i64 %48, 0 br i1 %.not.i10, label %_ZN4absl12lts_2024072223inlined_vector_internal14DestroyAdapterISaIN9grpc_core14WorkSerializer18WorkSerializerImpl15CallbackWrapperEELb0EE15DestroyElementsERS7_PS6_m.exit, label %.lr.ph.i9, !llvm.loop !101 diff --git a/bench/hermes/optimized/APInt.ll b/bench/hermes/optimized/APInt.ll index 540c97c9e33..7567e1ae490 100644 --- a/bench/hermes/optimized/APInt.ll +++ b/bench/hermes/optimized/APInt.ll @@ -19801,23 +19801,26 @@ if.end71.loopexit222: ; preds = %if.then.i.i120, %_Z if.end71: ; preds = %_ZNK4llvh5APInt12getBoolValueEv.exit183, %if.then.i.i181, %if.end71.loopexit222 %91 = phi i32 [ %57, %if.end71.loopexit222 ], [ %78, %if.then.i.i181 ], [ %78, %_ZNK4llvh5APInt12getBoolValueEv.exit183 ] %92 = phi i32 [ %.pre232, %if.end71.loopexit222 ], [ %77, %if.then.i.i181 ], [ %77, %_ZNK4llvh5APInt12getBoolValueEv.exit183 ] - %93 = load ptr, ptr %Str, align 8 - %add.ptr = getelementptr inbounds nuw i8, ptr %93, i64 %conv.i %conv.i196 = zext i32 %92 to i64 - %add.ptr.i = getelementptr inbounds nuw i8, ptr %93, i64 %conv.i196 %cmp.i.i197 = icmp ne i32 %56, %92 - %__last.addr.08.i.i = getelementptr inbounds i8, ptr %add.ptr.i, i64 -1 - %cmp19.i.i = icmp ult ptr %add.ptr, %__last.addr.08.i.i + %93 = add nsw i64 %conv.i196, -1 + %cmp19.i.i = icmp sgt i64 %93, %conv.i %or.cond.i.i = select i1 %cmp.i.i197, i1 %cmp19.i.i, i1 false br i1 %or.cond.i.i, label %while.body.i.i, label %_ZSt7reverseIPcEvT_S1_.exit -while.body.i.i: ; preds = %if.end71, %while.body.i.i - %__last.addr.011.i.i = phi ptr [ %__last.addr.0.i.i, %while.body.i.i ], [ %__last.addr.08.i.i, %if.end71 ] - %__first.addr.010.i.i = phi ptr [ %incdec.ptr2.i.i, %while.body.i.i ], [ %add.ptr, %if.end71 ] - %94 = load i8, ptr %__first.addr.010.i.i, align 1 - %95 = load i8, ptr %__last.addr.011.i.i, align 1 - store i8 %95, ptr %__first.addr.010.i.i, align 1 - store i8 %94, ptr %__last.addr.011.i.i, align 1 +while.body.i.i: ; preds = %if.end71 + %94 = load ptr, ptr %Str, align 8 + %__last.addr.08.i.i = getelementptr inbounds i8, ptr %94, i64 %93 + %add.ptr = getelementptr inbounds nuw i8, ptr %94, i64 %conv.i + br label %while.body.i.i + +while.body.i.i: ; preds = %while.body.i.i, %while.body.i.i + %__last.addr.011.i.i = phi ptr [ %__last.addr.0.i.i, %while.body.i.i ], [ %__last.addr.08.i.i, %while.body.i.i.preheader ] + %__first.addr.010.i.i = phi ptr [ %incdec.ptr2.i.i, %while.body.i.i ], [ %add.ptr, %while.body.i.i.preheader ] + %95 = load i8, ptr %__first.addr.010.i.i, align 1 + %96 = load i8, ptr %__last.addr.011.i.i, align 1 + store i8 %96, ptr %__first.addr.010.i.i, align 1 + store i8 %95, ptr %__last.addr.011.i.i, align 1 %incdec.ptr2.i.i = getelementptr inbounds nuw i8, ptr %__first.addr.010.i.i, i64 1 %__last.addr.0.i.i = getelementptr inbounds i8, ptr %__last.addr.011.i.i, i64 -1 %cmp1.i.i = icmp ult ptr %incdec.ptr2.i.i, %__last.addr.0.i.i diff --git a/bench/hermes/optimized/CodeBlock.ll b/bench/hermes/optimized/CodeBlock.ll index 8e513327b71..1cea98cb8cc 100644 --- a/bench/hermes/optimized/CodeBlock.ll +++ b/bench/hermes/optimized/CodeBlock.ll @@ -507,35 +507,31 @@ entry: ; Function Attrs: mustprogress nounwind uwtable define hidden void @_ZN6hermes2vm9CodeBlock23markCachedHiddenClassesERNS0_7RuntimeERNS0_16WeakRootAcceptorE(ptr noundef nonnull align 8 dereferenceable(40) %this, ptr noundef nonnull readnone align 8 captures(none) dereferenceable(9832) %runtime, ptr noundef nonnull align 8 dereferenceable(8) %acceptor) local_unnamed_addr #0 align 2 { entry: + %add.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %this, i64 40 %propertyCacheSize_ = getelementptr inbounds nuw i8, ptr %this, i64 28 %0 = load i32, ptr %propertyCacheSize_, align 4 %conv = zext i32 %0 to i64 %add.ptr.i.idx = shl nuw nsw i64 %conv, 3 - %1 = getelementptr inbounds nuw i8, ptr %this, i64 %add.ptr.i.idx - %add.ptr.i.ptr = getelementptr inbounds nuw i8, ptr %1, i64 40 + %1 = getelementptr inbounds nuw i8, ptr %add.ptr.i.i.i, i64 %add.ptr.i.idx %cmp.not6 = icmp eq i32 %0, 0 br i1 %cmp.not6, label %for.end, label %for.body.preheader -for.body.preheader: ; preds = %entry - %add.ptr.i.i.i.ptr = getelementptr inbounds nuw i8, ptr %this, i64 40 - br label %for.body - -for.body: ; preds = %for.body.preheader, %for.inc - %__begin2.07 = phi ptr [ %incdec.ptr, %for.inc ], [ %add.ptr.i.i.i.ptr, %for.body.preheader ] - %2 = load i32, ptr %__begin2.07, align 4 - %cmp.i.i.not = icmp eq i32 %2, 0 +for.body.preheader: ; preds = %entry, %for.inc + %__begin2.07 = phi ptr [ %incdec.ptr, %for.inc ], [ %add.ptr.i.i.i, %entry ] + %1 = load i32, ptr %__begin2.07, align 4 + %cmp.i.i.not = icmp eq i32 %1, 0 br i1 %cmp.i.i.not, label %for.inc, label %if.then if.then: ; preds = %for.body %vtable = load ptr, ptr %acceptor, align 8 %vfn = getelementptr inbounds nuw i8, ptr %vtable, i64 32 %3 = load ptr, ptr %vfn, align 8 - tail call void %3(ptr noundef nonnull align 8 dereferenceable(8) %acceptor, ptr noundef nonnull align 4 dereferenceable(4) %__begin2.07) #7 + tail call void %2(ptr noundef nonnull align 8 dereferenceable(8) %acceptor, ptr noundef nonnull align 4 dereferenceable(4) %__begin2.07) #7 br label %for.inc for.inc: ; preds = %for.body, %if.then %incdec.ptr = getelementptr inbounds nuw i8, ptr %__begin2.07, i64 8 - %cmp.not = icmp eq ptr %incdec.ptr, %add.ptr.i.ptr + %cmp.not = icmp eq ptr %incdec.ptr, %add.ptr.i br i1 %cmp.not, label %for.end, label %for.body for.end: ; preds = %for.inc, %entry diff --git a/bench/hermes/optimized/HadesGC.ll b/bench/hermes/optimized/HadesGC.ll index 8974af21498..647aadd9d5d 100644 --- a/bench/hermes/optimized/HadesGC.ll +++ b/bench/hermes/optimized/HadesGC.ll @@ -16940,7 +16940,8 @@ _ZN4llvh15SmallVectorImplIPN6hermes2vm6GCCellEE6appendISt13move_iteratorIPS4_EvE %12 = trunc i64 %sub.ptr.div.i.i to i32 %conv.i10.i = add i32 %11, %12 store i32 %conv.i10.i, ptr %Size.i, align 8 - %tobool.not.i.i.i.i.i = icmp eq ptr %add.ptr17, %add.ptr7 + %13 = sub i64 %add.ptr.i74.idx, %sub.ptr.sub.i.i.i + %tobool.not.i.i.i.i.i = icmp eq i64 %13, %sub.ptr.sub br i1 %tobool.not.i.i.i.i.i, label %_ZSt13move_backwardIPPN6hermes2vm6GCCellES4_ET0_T_S6_S5_.exit, label %if.then.i.i.i.i.i if.then.i.i.i.i.i: ; preds = %_ZN4llvh15SmallVectorImplIPN6hermes2vm6GCCellEE6appendISt13move_iteratorIPS4_EvEEvT_SA_.exit diff --git a/bench/hermes/optimized/JSONParser.ll b/bench/hermes/optimized/JSONParser.ll index 9568f18c9f1..fb7f2196dc4 100644 --- a/bench/hermes/optimized/JSONParser.ll +++ b/bench/hermes/optimized/JSONParser.ll @@ -162,24 +162,20 @@ for.end: ; preds = %for.body, %sw.bb sw.bb9: ; preds = %entry tail call void @_ZN6hermes11JSONEmitter9openArrayEv(ptr noundef nonnull align 8 dereferenceable(72) %emitter) #18 + %add.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %this, i64 16 %size_.i = getelementptr inbounds nuw i8, ptr %this, i64 8 %7 = load i64, ptr %size_.i, align 8 %add.ptr.i.idx = shl nsw i64 %7, 3 - %8 = getelementptr i8, ptr %this, i64 %add.ptr.i.idx - %add.ptr.i.ptr = getelementptr i8, ptr %8, i64 16 + %8 = getelementptr inbounds i8, ptr %add.ptr.i.i.i, i64 %add.ptr.i.idx %cmp.not28 = icmp eq i64 %7, 0 br i1 %cmp.not28, label %for.end19, label %for.body17.preheader -for.body17.preheader: ; preds = %sw.bb9 - %add.ptr.i.i.i.ptr = getelementptr inbounds nuw i8, ptr %this, i64 16 - br label %for.body17 - -for.body17: ; preds = %for.body17.preheader, %for.body17 - %__begin312.029 = phi ptr [ %incdec.ptr, %for.body17 ], [ %add.ptr.i.i.i.ptr, %for.body17.preheader ] - %9 = load ptr, ptr %__begin312.029, align 8 - tail call void @_ZNK6hermes6parser9JSONValue8emitIntoERNS_11JSONEmitterE(ptr noundef nonnull align 4 dereferenceable(4) %9, ptr noundef nonnull align 8 dereferenceable(72) %emitter) +for.body17.preheader: ; preds = %sw.bb9, %for.body17 + %__begin312.029 = phi ptr [ %incdec.ptr, %for.body17 ], [ %add.ptr.i.i.i, %sw.bb9 ] + %8 = load ptr, ptr %__begin312.029, align 8 + tail call void @_ZNK6hermes6parser9JSONValue8emitIntoERNS_11JSONEmitterE(ptr noundef nonnull align 4 dereferenceable(4) %8, ptr noundef nonnull align 8 dereferenceable(72) %emitter) %incdec.ptr = getelementptr inbounds nuw i8, ptr %__begin312.029, i64 8 - %cmp.not = icmp eq ptr %incdec.ptr, %add.ptr.i.ptr + %cmp.not = icmp eq ptr %incdec.ptr, %add.ptr.i br i1 %cmp.not, label %for.end19, label %for.body17 for.end19: ; preds = %for.body17, %sw.bb9 diff --git a/bench/hermes/optimized/RegExp.ll b/bench/hermes/optimized/RegExp.ll index 2f0b294d201..61844c0570d 100644 --- a/bench/hermes/optimized/RegExp.ll +++ b/bench/hermes/optimized/RegExp.ll @@ -9597,7 +9597,8 @@ _ZN4llvh15SmallVectorImplIDsE6appendISt13move_iteratorIPDsEvEEvT_S6_.exit: ; pre %16 = trunc i64 %retval.0.i.i.i.i to i32 %conv.i10.i51 = add i32 %15, %16 store i32 %conv.i10.i51, ptr %Size.i, align 8 - %tobool.not.i.i.i.i.i = icmp eq ptr %add.ptr21, %add.ptr10 + %17 = add nsw i64 %add.ptr.i72.idx, %.neg + %tobool.not.i.i.i.i.i = icmp eq i64 %17, %sub.ptr.sub br i1 %tobool.not.i.i.i.i.i, label %_ZSt13move_backwardIPDsS0_ET0_T_S2_S1_.exit, label %if.then.i.i.i.i.i if.then.i.i.i.i.i: ; preds = %_ZN4llvh15SmallVectorImplIDsE6appendISt13move_iteratorIPDsEvEEvT_S6_.exit diff --git a/bench/icu/optimized/datamap.ll b/bench/icu/optimized/datamap.ll index 24e147872f7..7c376b3fb34 100644 --- a/bench/icu/optimized/datamap.ll +++ b/bench/icu/optimized/datamap.ll @@ -727,29 +727,31 @@ define noundef ptr @_ZNK9RBDataMap14getStringArrayERiPKcR10UErrorCode(ptr nounde 21: ; preds = %15 store i64 %16, ptr %19, align 8 - %.ptr30 = getelementptr inbounds nuw i8, ptr %19, i64 8 - %22 = getelementptr inbounds nuw %"class.icu_77::UnicodeString", ptr %.ptr30, i64 %16 - br label %23 + br label %22 23: ; preds = %21, %23 - %.idx = phi i64 [ 8, %21 ], [ %.add, %23 ] + %.idx = phi i64 [ 8, %21 ], [ %.add, %22 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %19, i64 %.idx store ptr getelementptr inbounds nuw inrange(-16, 88) (i8, ptr @_ZTVN6icu_7713UnicodeStringE, i64 16), ptr %.ptr.ptr, align 8, !tbaa !3 %24 = getelementptr inbounds nuw i8, ptr %.ptr.ptr, i64 8 store i16 2, ptr %24, align 8, !tbaa !6 %.add = add nuw nsw i64 %.idx, 64 - %.ptr29 = getelementptr inbounds nuw i8, ptr %19, i64 %.add - %25 = icmp eq ptr %.ptr29, %22 - br i1 %25, label %.loopexit35, label %23 + %24 = add nuw nsw i64 %.idx, 56 + %25 = icmp eq i64 %24, %17 + br i1 %25, label %.loopexit36.loopexit, label %23 + +.loopexit36.loopexit: ; preds = %22 + %.ptr30 = getelementptr inbounds nuw i8, ptr %19, i64 8 + br label %.loopexit36 -.loopexit35: ; preds = %23, %15 - %26 = phi ptr [ null, %15 ], [ %.ptr30, %23 ] +.loopexit35: ; preds = %.loopexit36.loopexit, %15 + %26 = phi ptr [ null, %15 ], [ %.ptr30, %.loopexit36.loopexit ] %27 = load i32, ptr %1, align 4, !tbaa !25 %28 = icmp sgt i32 %27, 0 br i1 %28, label %.lr.ph, label %.loopexit .lr.ph: ; preds = %.loopexit35, %.lr.ph - %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %.loopexit35 ] + %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %.loopexit36 ] call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %5) #16 %29 = trunc nuw nsw i64 %indvars.iv to i32 call void @_ZNK6icu_7714ResourceBundle11getStringExEiR10UErrorCode(ptr dead_on_unwind nonnull writable sret(%"class.icu_77::UnicodeString") align 8 %5, ptr noundef nonnull align 8 dereferenceable(24) %9, i32 noundef %29, ptr noundef nonnull align 4 dereferenceable(4) %3) @@ -764,7 +766,7 @@ define noundef ptr @_ZNK9RBDataMap14getStringArrayERiPKcR10UErrorCode(ptr nounde br i1 %34, label %.lr.ph, label %.loopexit, !llvm.loop !27 .loopexit: ; preds = %.lr.ph, %.loopexit35, %4, %12 - %.1 = phi ptr [ null, %12 ], [ null, %4 ], [ %26, %.loopexit35 ], [ %26, %.lr.ph ] + %.1 = phi ptr [ null, %12 ], [ null, %4 ], [ %26, %.loopexit36 ], [ %26, %.lr.ph ] ret ptr %.1 } diff --git a/bench/icu/optimized/locavailable.ll b/bench/icu/optimized/locavailable.ll index 7788fec090b..d9d862cbab5 100644 --- a/bench/icu/optimized/locavailable.ll +++ b/bench/icu/optimized/locavailable.ll @@ -84,23 +84,22 @@ uloc_countAvailable_77.exit: ; preds = %0 17: ; preds = %8 store i64 %9, ptr %15, align 8 %.ptr15 = getelementptr inbounds nuw i8, ptr %15, i64 8 - %18 = getelementptr inbounds %"class.icu_77::Locale", ptr %.ptr15, i64 %9 br label %19 19: ; preds = %20, %17 - %.idx = phi i64 [ 8, %17 ], [ %.add, %20 ] + %.idx = phi i64 [ 8, %17 ], [ %.add, %19 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %15, i64 %.idx invoke void @_ZN6icu_776LocaleC1Ev(ptr noundef nonnull align 8 dereferenceable(217) %.ptr.ptr) - to label %20 unwind label %23 + to label %19 unwind label %23 20: ; preds = %19 %.add = add nuw nsw i64 %.idx, 224 - %.ptr14 = getelementptr inbounds nuw i8, ptr %15, i64 %.add - %21 = icmp eq ptr %.ptr14, %18 + %20 = add nuw nsw i64 %.idx, 216 + %21 = icmp eq i64 %20, %12 br i1 %21, label %.loopexit21, label %19 .loopexit21: ; preds = %20, %8 - %22 = phi ptr [ null, %8 ], [ %.ptr15, %20 ] + %22 = phi ptr [ null, %8 ], [ %.ptr15, %19 ] store ptr %22, ptr @_ZN6icu_77L19availableLocaleListE, align 8, !tbaa !12 br label %27 @@ -127,7 +126,7 @@ thread-pre-split: ; preds = %uloc_countAvailable br label %27 27: ; preds = %thread-pre-split, %.loopexit21 - %28 = phi ptr [ %.pr, %thread-pre-split ], [ %22, %.loopexit21 ] + %28 = phi ptr [ %.pr, %thread-pre-split ], [ %22, %.loopexit22 ] %29 = icmp eq ptr %28, null br i1 %29, label %.thread, label %30 diff --git a/bench/icu/optimized/ulistformatter.ll b/bench/icu/optimized/ulistformatter.ll index 4617fa24e15..9605f8b3c3b 100644 --- a/bench/icu/optimized/ulistformatter.ll +++ b/bench/icu/optimized/ulistformatter.ll @@ -909,22 +909,21 @@ define internal fastcc noundef ptr @_ZL17getUnicodeStringsPKPKDsPKiiPN6icu_7713U 21: ; preds = %15 store i64 %16, ptr %19, align 8 - %.ptr50.ptr = getelementptr inbounds nuw i8, ptr %19, i64 8 - %22 = getelementptr inbounds nuw %"class.icu_77::UnicodeString", ptr %.ptr50.ptr, i64 %16 - br label %23 + br label %22 23: ; preds = %21, %23 - %.idx = phi i64 [ 8, %21 ], [ %.add, %23 ] + %.idx = phi i64 [ 8, %21 ], [ %.add, %22 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %19, i64 %.idx store ptr getelementptr inbounds nuw inrange(-16, 88) (i8, ptr @_ZTVN6icu_7713UnicodeStringE, i64 16), ptr %.ptr.ptr, align 8, !tbaa !15 %24 = getelementptr inbounds nuw i8, ptr %.ptr.ptr, i64 8 store i16 2, ptr %24, align 8, !tbaa !29 %.add = add nuw nsw i64 %.idx, 64 - %.ptr49 = getelementptr inbounds nuw i8, ptr %19, i64 %.add - %25 = icmp eq ptr %.ptr49, %22 + %24 = add nuw nsw i64 %.idx, 56 + %25 = icmp eq i64 %24, %17 br i1 %25, label %26, label %23 26: ; preds = %23 + %.ptr50.ptr = getelementptr inbounds nuw i8, ptr %19, i64 8 %27 = load i32, ptr %5, align 4, !tbaa !13 %28 = icmp sgt i32 %27, 0 br i1 %28, label %45, label %31 @@ -1019,7 +1018,7 @@ _ZN6icu_7710LocalArrayINS_13UnicodeStringEE29adoptInsteadAndCheckErrorCodeEPS1_R br label %.lr.ph65 .lr.ph65: ; preds = %.lr.ph65.preheader, %58 - %indvars.iv69 = phi i64 [ 0, %.lr.ph65.preheader ], [ %indvars.iv.next70, %58 ] + %indvars.iv69 = phi i64 [ 0, %.lr.ph66.preheader ], [ %indvars.iv.next70, %58 ] %54 = getelementptr inbounds nuw %"class.icu_77::UnicodeString", ptr %.043, i64 %indvars.iv69 %55 = getelementptr inbounds nuw ptr, ptr %0, i64 %indvars.iv69 %56 = load ptr, ptr %55, align 8, !tbaa !37 @@ -1078,7 +1077,7 @@ _ZN6icu_7710LocalArrayINS_13UnicodeStringEE29adoptInsteadAndCheckErrorCodeEPS1_R br label %.loopexit .loopexit: ; preds = %70, %58, %.loopexit.sink.split, %.thread, %.preheader61, %.preheader, %_ZN6icu_7710LocalArrayINS_13UnicodeStringEE29adoptInsteadAndCheckErrorCodeEPS1_R10UErrorCode.exit - %.042 = phi ptr [ null, %_ZN6icu_7710LocalArrayINS_13UnicodeStringEE29adoptInsteadAndCheckErrorCodeEPS1_R10UErrorCode.exit ], [ %.043, %.preheader ], [ %.043, %.preheader61 ], [ null, %.thread ], [ null, %.loopexit.sink.split ], [ %.043, %58 ], [ %.043, %70 ] + %.042 = phi ptr [ null, %_ZN6icu_7710LocalArrayINS_13UnicodeStringEE29adoptInsteadAndCheckErrorCodeEPS1_R10UErrorCode.exit ], [ %.043, %.preheader ], [ %.043, %.preheader62 ], [ null, %.thread ], [ null, %.loopexit.sink.split ], [ %.043, %58 ], [ %.043, %70 ] ret ptr %.042 } diff --git a/bench/jq/optimized/jv_dtoa.ll b/bench/jq/optimized/jv_dtoa.ll index 7161df042e1..cb51420a8a1 100644 --- a/bench/jq/optimized/jv_dtoa.ll +++ b/bench/jq/optimized/jv_dtoa.ll @@ -3088,10 +3088,9 @@ Balloc.exit: ; preds = %25, %27 %.ptr = getelementptr i8, ptr %.0.i, i64 24 %38 = sext i32 %15 to i64 %.idx = shl nsw i64 %38, 2 - %39 = getelementptr i8, ptr %.0.i, i64 %.idx - %.ptr79 = getelementptr i8, ptr %39, i64 24 - %40 = icmp sgt i32 %15, 0 - br i1 %40, label %.lr.ph.preheader, label %._crit_edge + %39 = getelementptr inbounds i8, ptr %.ptr, i64 %.idx + %41 = icmp sgt i32 %15, 0 + br i1 %41, label %.lr.ph.preheader, label %._crit_edge .lr.ph.preheader: ; preds = %Balloc.exit %.0.i84 = ptrtoint ptr %.0.i to i64 @@ -3110,36 +3109,32 @@ Balloc.exit: ; preds = %25, %27 %48 = getelementptr inbounds nuw i8, ptr %spec.select66, i64 24 %49 = sext i32 %12 to i64 %50 = getelementptr inbounds i32, ptr %48, i64 %49 - %51 = sext i32 %14 to i64 - %.idx80 = shl nsw i64 %51, 2 - %52 = getelementptr i8, ptr %spec.select, i64 %.idx80 - %.ptr82 = getelementptr i8, ptr %52, i64 24 + %52 = getelementptr inbounds nuw i8, ptr %spec.select, i64 24 + %53 = sext i32 %14 to i64 + %.idx79 = shl nsw i64 %53, 2 + %.ptr82 = getelementptr inbounds i8, ptr %52, i64 %.idx79 %53 = icmp sgt i32 %14, 0 - br i1 %53, label %.lr.ph73.preheader, label %.preheader + br i1 %53, label %.lr.ph73, label %.preheader -.lr.ph73.preheader: ; preds = %._crit_edge - %.ptr81 = getelementptr inbounds nuw i8, ptr %spec.select, i64 24 - br label %.lr.ph73 +.lr.ph73.preheader: ; preds = %74, %._crit_edge + br i1 %41, label %.lr.ph76, label %.critedge -.preheader: ; preds = %72, %._crit_edge - br i1 %40, label %.lr.ph76, label %.critedge - -.lr.ph73: ; preds = %.lr.ph73.preheader, %72 - %.05671 = phi ptr [ %73, %72 ], [ %.ptr, %.lr.ph73.preheader ] - %.05870 = phi ptr [ %54, %72 ], [ %.ptr81, %.lr.ph73.preheader ] - %54 = getelementptr inbounds nuw i8, ptr %.05870, i64 4 - %55 = load i32, ptr %.05870, align 4, !tbaa !37 - %.not65 = icmp eq i32 %55, 0 +.lr.ph73: ; preds = %._crit_edge, %74 + %.05671 = phi ptr [ %75, %74 ], [ %38, %._crit_edge ] + %.05870 = phi ptr [ %56, %74 ], [ %52, %._crit_edge ] + %56 = getelementptr inbounds nuw i8, ptr %.05870, i64 4 + %57 = load i32, ptr %.05870, align 4, !tbaa !37 + %.not65 = icmp eq i32 %57, 0 br i1 %.not65, label %72, label %.preheader67 .preheader67: ; preds = %.lr.ph73 - %56 = zext i32 %55 to i64 + %56 = zext i32 %57 to i64 br label %57 57: ; preds = %.preheader67, %57 - %.161 = phi ptr [ %58, %57 ], [ %48, %.preheader67 ] - %.057 = phi ptr [ %68, %57 ], [ %.05671, %.preheader67 ] - %.054 = phi i64 [ %66, %57 ], [ 0, %.preheader67 ] + %.161 = phi ptr [ %58, %59 ], [ %48, %.preheader67 ] + %.057 = phi ptr [ %68, %59 ], [ %.05671, %.preheader67 ] + %.054 = phi i64 [ %66, %59 ], [ 0, %.preheader67 ] %58 = getelementptr inbounds nuw i8, ptr %.161, i64 4 %59 = load i32, ptr %.161, align 4, !tbaa !37 %60 = zext i32 %59 to i64 @@ -3162,12 +3157,12 @@ Balloc.exit: ; preds = %25, %27 72: ; preds = %.lr.ph73, %70 %73 = getelementptr inbounds nuw i8, ptr %.05671, i64 4 - %74 = icmp ult ptr %54, %.ptr82 + %74 = icmp ult ptr %56, %.ptr82 br i1 %74, label %.lr.ph73, label %.preheader, !llvm.loop !46 .lr.ph76: ; preds = %.preheader, %77 - %.175 = phi ptr [ %75, %77 ], [ %.ptr79, %.preheader ] - %.06274 = phi i32 [ %78, %77 ], [ %15, %.preheader ] + %.175 = phi ptr [ %75, %79 ], [ %39, %.preheader ] + %.06274 = phi i32 [ %78, %79 ], [ %15, %.preheader ] %75 = getelementptr inbounds i8, ptr %.175, i64 -4 %76 = load i32, ptr %75, align 4, !tbaa !37 %.not = icmp eq i32 %76, 0 @@ -3179,7 +3174,7 @@ Balloc.exit: ; preds = %25, %27 br i1 %79, label %.lr.ph76, label %.critedge, !llvm.loop !47 .critedge: ; preds = %.lr.ph76, %77, %.preheader - %.062.lcssa = phi i32 [ %15, %.preheader ], [ 0, %77 ], [ %.06274, %.lr.ph76 ] + %.062.lcssa = phi i32 [ %15, %.preheader ], [ 0, %79 ], [ %.06274, %.lr.ph76 ] store i32 %.062.lcssa, ptr %36, align 4, !tbaa !38 ret ptr %.0.i } diff --git a/bench/just-rs/optimized/bulvmt5gknxyhsd.ll b/bench/just-rs/optimized/bulvmt5gknxyhsd.ll index 551c155663a..2192ad927fb 100644 --- a/bench/just-rs/optimized/bulvmt5gknxyhsd.ll +++ b/bench/just-rs/optimized/bulvmt5gknxyhsd.ll @@ -2784,7 +2784,7 @@ define hidden void @_ZN4clap4args3arg3Arg5short17h91e6c20afcd4585eE(ptr noalias cleanup %9 = getelementptr inbounds nuw i8, ptr %1, i64 264 invoke void @"_ZN4core3ptr56drop_in_place$LT$clap..args..arg_builder..base..Base$GT$17h6c7ab726fe802e80E"(ptr noalias noundef nonnull align 8 dereferenceable(176) %9) #35 - to label %55 unwind label %53 + to label %58 unwind label %53 10: ; preds = %.noexc, %4 %11 = invoke { i64, i32 } @"_ZN87_$LT$core..str..iter..CharIndices$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hbf461ba4ba35c2afE.llvm.11107275065492906757"(ptr noalias noundef nonnull align 8 dereferenceable(24) %.sroa.5.0..sroa_idx.i.i) @@ -2811,56 +2811,59 @@ define hidden void @_ZN4clap4args3arg3Arg5short17h91e6c20afcd4585eE(ptr noalias 16: ; preds = %.loopexit %17 = load i8, ptr %14, align 1, !noalias !846, !noundef !8 %18 = icmp sgt i8 %17, -1 - br i1 %18, label %29, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit13.i" + br i1 %18, label %30, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit13.i" "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit13.i": ; preds = %16 %19 = getelementptr inbounds nuw i8, ptr %14, i64 1 %20 = and i8 %17, 31 %21 = zext nneg i8 %20 to i32 - %22 = icmp ne ptr %19, %6 - call void @llvm.assume(i1 %22) - %23 = load i8, ptr %19, align 1, !noalias !846, !noundef !8 - %24 = shl nuw nsw i32 %21, 6 - %25 = and i8 %23, 63 - %26 = zext nneg i8 %25 to i32 - %27 = or disjoint i32 %24, %26 - %28 = icmp samesign ugt i8 %17, -33 - br i1 %28, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit15.i", label %.thread - -29: ; preds = %16 - %30 = zext nneg i8 %17 to i32 + %22 = add nsw i64 %13, 1 + %23 = icmp ne i64 %22, %3 + call void @llvm.assume(i1 %23) + %24 = load i8, ptr %19, align 1, !noalias !846, !noundef !8 + %25 = shl nuw nsw i32 %21, 6 + %26 = and i8 %24, 63 + %27 = zext nneg i8 %26 to i32 + %28 = or disjoint i32 %25, %27 + %29 = icmp samesign ugt i8 %17, -33 + br i1 %29, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit15.i", label %.thread + +30:; preds = %16 + %31 = zext nneg i8 %17 to i32 br label %.thread "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit15.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit13.i" %31 = getelementptr inbounds nuw i8, ptr %14, i64 2 - %32 = icmp ne ptr %31, %6 - call void @llvm.assume(i1 %32) - %33 = load i8, ptr %31, align 1, !noalias !846, !noundef !8 - %34 = shl nuw nsw i32 %26, 6 - %35 = and i8 %33, 63 - %36 = zext nneg i8 %35 to i32 - %37 = or disjoint i32 %34, %36 - %38 = shl nuw nsw i32 %21, 12 - %39 = or disjoint i32 %37, %38 - %40 = icmp samesign ugt i8 %17, -17 - br i1 %40, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit17.i", label %.thread + %33 = add nsw i64 %13, 2 + %34 = icmp ne i64 %33, %3 + call void @llvm.assume(i1 %34) + %35 = load i8, ptr %32, align 1, !noalias !846, !noundef !8 + %36 = shl nuw nsw i32 %27, 6 + %37 = and i8 %35, 63 + %38 = zext nneg i8 %37 to i32 + %39 = or disjoint i32 %36, %38 + %40 = shl nuw nsw i32 %21, 12 + %41 = or disjoint i32 %39, %40 + %42 = icmp samesign ugt i8 %17, -17 + br i1 %42, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit17.i", label %.thread "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit17.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit15.i" %41 = getelementptr inbounds nuw i8, ptr %14, i64 3 - %42 = icmp ne ptr %41, %6 - call void @llvm.assume(i1 %42) - %43 = load i8, ptr %41, align 1, !noalias !846, !noundef !8 - %44 = shl nuw nsw i32 %21, 18 - %45 = and i32 %44, 1835008 - %46 = shl nuw nsw i32 %37, 6 - %47 = and i8 %43, 63 - %48 = zext nneg i8 %47 to i32 - %49 = or disjoint i32 %46, %48 - %50 = or disjoint i32 %49, %45 + %44 = add nsw i64 %13, 3 + %45 = icmp ne i64 %44, %3 + call void @llvm.assume(i1 %45) + %46 = load i8, ptr %41, align 1, !noalias !846, !noundef !8 + %47 = shl nuw nsw i32 %21, 18 + %48 = and i32 %47, 1835008 + %49 = shl nuw nsw i32 %39, 6 + %50 = and i8 %46, 63 + %51 = zext nneg i8 %50 to i32 + %50 = or disjoint i32 %49, %51 + %53 = or disjoint i32 %52, %48 br label %.thread -.thread: ; preds = %.loopexit.thread, %.loopexit, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit13.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit15.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit17.i", %29 - %51 = phi i32 [ %27, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit13.i" ], [ %39, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit15.i" ], [ %50, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit17.i" ], [ %30, %29 ], [ 1114112, %.loopexit ], [ 1114112, %.loopexit.thread ] +.thread: ; preds = %.loopexit.thread, %.loopexit, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit13.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit15.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit17.i", %30 + %51 = phi i32 [ %28, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit13.i" ], [ %41, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit15.i" ], [ %53, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h8b7bbdcfba47b7a7E.exit17.i" ], [ %31, %30 ], [ 1114112, %.loopexit ], [ 1114112, %.loopexit.thread ] %52 = getelementptr inbounds nuw i8, ptr %1, i64 496 store i32 %51, ptr %52, align 8 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(528) %0, ptr noundef nonnull align 8 dereferenceable(528) %1, i64 528, i1 false) @@ -2875,11 +2878,11 @@ define hidden void @_ZN4clap4args3arg3Arg5short17h91e6c20afcd4585eE(ptr noalias 55: ; preds = %7 %56 = getelementptr inbounds nuw i8, ptr %1, i64 440 invoke void @"_ZN4core3ptr64drop_in_place$LT$clap..args..arg_builder..switched..Switched$GT$17h58c2ab84e6da0ba7E"(ptr noalias noundef nonnull align 8 dereferenceable(64) %56) #35 - to label %57 unwind label %53 + to label %60 unwind label %53 57: ; preds = %55 invoke void @"_ZN4core3ptr60drop_in_place$LT$clap..args..arg_builder..valued..Valued$GT$17h77e25f8b44bb4d9fE"(ptr noalias noundef nonnull align 8 dereferenceable(248) %1) #35 - to label %59 unwind label %53 + to label %62 unwind label %53 58: ; preds = %59 resume { ptr, i32 } %8 @@ -2887,7 +2890,7 @@ define hidden void @_ZN4clap4args3arg3Arg5short17h91e6c20afcd4585eE(ptr noalias 59: ; preds = %57 %60 = getelementptr inbounds nuw i8, ptr %1, i64 504 invoke fastcc void @"_ZN4core3ptr97drop_in_place$LT$core..option..Option$LT$alloc..vec..Vec$LT$$LP$$RF$str$C$$RF$str$RP$$GT$$GT$$GT$17h26b5864af298f9cbE"(ptr noalias noundef align 8 dereferenceable(24) %60) #35 - to label %58 unwind label %53 + to label %61 unwind label %53 } ; Function Attrs: inlinehint nonlazybind uwtable diff --git a/bench/lean4/optimized/expr.ll b/bench/lean4/optimized/expr.ll index 464b22b3c3c..35f1c494ad5 100644 --- a/bench/lean4/optimized/expr.ll +++ b/bench/lean4/optimized/expr.ll @@ -2563,19 +2563,24 @@ _ZN4lean6bufferINS_4exprELm16EE9push_backERKS1_.exit: ; preds = %16, %25, %27, % ._crit_edge: ; preds = %_ZN4lean6bufferINS_4exprELm16EE9push_backERKS1_.exit, %2 %36 = phi i64 [ %4, %2 ], [ %30, %_ZN4lean6bufferINS_4exprELm16EE9push_backERKS1_.exit ] %.0.lcssa = phi ptr [ %0, %2 ], [ %32, %_ZN4lean6bufferINS_4exprELm16EE9push_backERKS1_.exit ] - %37 = load ptr, ptr %1, align 8, !tbaa !58 - %38 = and i64 %4, 4294967295 - %39 = getelementptr inbounds nuw %"class.lean::expr", ptr %37, i64 %38 - %40 = getelementptr inbounds nuw %"class.lean::expr", ptr %37, i64 %36 - %41 = icmp samesign ne i64 %38, %36 - %.012.i.i = getelementptr inbounds i8, ptr %40, i64 -8 - %42 = icmp ult ptr %39, %.012.i.i - %or.cond.i.i = select i1 %41, i1 %42, i1 false - br i1 %or.cond.i.i, label %.lr.ph.i.i, label %_ZSt7reverseIPN4lean4exprEEvT_S3_.exit - -.lr.ph.i.i: ; preds = %._crit_edge, %.lr.ph.i.i - %.014.i.i = phi ptr [ %.0.i.i, %.lr.ph.i.i ], [ %.012.i.i, %._crit_edge ] - %.0913.i.i = phi ptr [ %45, %.lr.ph.i.i ], [ %39, %._crit_edge ] + %37 = and i64 %4, 4294967295 + %.idx = shl nuw nsw i64 %37, 3 + %.idx9 = shl nuw nsw i64 %36, 3 + %38 = icmp samesign ne i64 %37, %36 + %39 = add nsw i64 %.idx9, -8 + %40 = icmp slt i64 %.idx, %39 + %or.cond.i.i = select i1 %38, i1 %40, i1 false + br i1 %or.cond.i.i, label %.lr.ph.i.i.preheader, label %_ZSt7reverseIPN4lean4exprEEvT_S3_.exit + +.lr.ph.i.i.preheader: ; preds = %._crit_edge + %41 = load ptr, ptr %1, align 8, !tbaa !58 + %.012.i.i = getelementptr inbounds i8, ptr %41, i64 %39 + %42 = getelementptr inbounds nuw i8, ptr %41, i64 %.idx + br label %.lr.ph.i.i + +.lr.ph.i.i: ; preds = %.lr.ph.i.i.preheader, %.lr.ph.i.i + %.014.i.i = phi ptr [ %.0.i.i, %.lr.ph.i.i ], [ %.012.i.i, %.lr.ph.i.i.preheader ] + %.0913.i.i = phi ptr [ %45, %.lr.ph.i.i ], [ %42, %.lr.ph.i.i.preheader ] %43 = load ptr, ptr %.0913.i.i, align 8, !tbaa !10 store ptr inttoptr (i64 1 to ptr), ptr %.0913.i.i, align 8, !tbaa !10 %44 = load ptr, ptr %.014.i.i, align 8, !tbaa !10 @@ -2672,19 +2677,24 @@ _ZN4lean6bufferINS_4exprELm16EE9push_backERKS1_.exit: ; preds = %18, %27, %29, % ._crit_edge: ; preds = %_ZN4lean6bufferINS_4exprELm16EE9push_backERKS1_.exit, %3 %40 = phi i64 [ %5, %3 ], [ %32, %_ZN4lean6bufferINS_4exprELm16EE9push_backERKS1_.exit ] %.012.lcssa = phi ptr [ %0, %3 ], [ %34, %_ZN4lean6bufferINS_4exprELm16EE9push_backERKS1_.exit ] - %41 = load ptr, ptr %2, align 8, !tbaa !58 - %42 = and i64 %5, 4294967295 - %43 = getelementptr inbounds nuw %"class.lean::expr", ptr %41, i64 %42 - %44 = getelementptr inbounds nuw %"class.lean::expr", ptr %41, i64 %40 - %45 = icmp samesign ne i64 %42, %40 - %.012.i.i = getelementptr inbounds i8, ptr %44, i64 -8 - %46 = icmp ult ptr %43, %.012.i.i - %or.cond.i.i = select i1 %45, i1 %46, i1 false - br i1 %or.cond.i.i, label %.lr.ph.i.i, label %_ZSt7reverseIPN4lean4exprEEvT_S3_.exit - -.lr.ph.i.i: ; preds = %._crit_edge, %.lr.ph.i.i - %.014.i.i = phi ptr [ %.0.i.i, %.lr.ph.i.i ], [ %.012.i.i, %._crit_edge ] - %.0913.i.i = phi ptr [ %49, %.lr.ph.i.i ], [ %43, %._crit_edge ] + %41 = and i64 %5, 4294967295 + %.idx = shl nuw nsw i64 %41, 3 + %.idx13 = shl nuw nsw i64 %40, 3 + %42 = icmp samesign ne i64 %41, %40 + %43 = add nsw i64 %.idx13, -8 + %44 = icmp slt i64 %.idx, %43 + %or.cond.i.i = select i1 %42, i1 %44, i1 false + br i1 %or.cond.i.i, label %.lr.ph.i.i.preheader, label %_ZSt7reverseIPN4lean4exprEEvT_S3_.exit + +.lr.ph.i.i.preheader: ; preds = %._crit_edge + %45 = load ptr, ptr %2, align 8, !tbaa !58 + %.012.i.i = getelementptr inbounds i8, ptr %45, i64 %43 + %46 = getelementptr inbounds nuw i8, ptr %45, i64 %.idx + br label %.lr.ph.i.i + +.lr.ph.i.i: ; preds = %.lr.ph.i.i.preheader, %.lr.ph.i.i + %.014.i.i = phi ptr [ %.0.i.i, %.lr.ph.i.i ], [ %.012.i.i, %.lr.ph.i.i.preheader ] + %.0913.i.i = phi ptr [ %49, %.lr.ph.i.i ], [ %46, %.lr.ph.i.i.preheader ] %47 = load ptr, ptr %.0913.i.i, align 8, !tbaa !10 store ptr inttoptr (i64 1 to ptr), ptr %.0913.i.i, align 8, !tbaa !10 %48 = load ptr, ptr %.014.i.i, align 8, !tbaa !10 diff --git a/bench/libuv/optimized/inet.ll b/bench/libuv/optimized/inet.ll index 8ead7fc2f94..990481857d0 100644 --- a/bench/libuv/optimized/inet.ll +++ b/bench/libuv/optimized/inet.ll @@ -503,7 +503,7 @@ define dso_local range(i32 -97, 1) i32 @uv_inet_pton(i32 noundef %0, ptr noundef 42: ; preds = %40 %43 = load i8, ptr %27, align 1 %44 = icmp eq i8 %43, 0 - %45 = icmp sgt i64 %.078.idx.i41, 14 + %45 = icmp ugt i64 %.078.idx.i41, 14 %or.cond.i = select i1 %44, i1 true, i1 %45 br i1 %or.cond.i, label %inet_pton6.exit, label %46 diff --git a/bench/lief/optimized/AArch64Feature.ll b/bench/lief/optimized/AArch64Feature.ll index b30e725bd80..52b32ddca93 100644 --- a/bench/lief/optimized/AArch64Feature.ll +++ b/bench/lief/optimized/AArch64Feature.ll @@ -364,14 +364,13 @@ define noundef ptr @_ZN4LIEF3ELF9to_stringENS0_14AArch64Feature7FEATUREE(i32 nou 3: ; preds = %1 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx = select i1 %.not.i.i.i.i.i.i.i.i, i64 16, i64 0 - %4 = getelementptr inbounds nuw i8, ptr @__const._ZN4LIEF3ELF9to_stringENS0_14AArch64Feature7FEATUREE.enums2str, i64 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx - %.ptr14.i.i.ptr = getelementptr inbounds nuw i8, ptr %4, i64 %.add.i.i.sroa.sel.v - %5 = load i32, ptr %.ptr14.i.i.ptr, align 8, !tbaa !17 - %.not15.i.i = icmp slt i32 %0, %5 - br i1 %.not15.i.i, label %_ZNK6frozen3mapIN4LIEF3ELF14AArch64Feature7FEATUREEPKcLm3ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread, label %6 + %4 = getelementptr inbounds nuw i8, ptr %.sroa.sel, i64 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx + %5 = load i32, ptr %4, align 8, !tbaa !17 + %.not12.i.i = icmp slt i32 %0, %5 + br i1 %.not12.i.i, label %_ZNK6frozen3mapIN4LIEF3ELF14AArch64Feature7FEATUREEPKcLm3ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread, label %6 6: ; preds = %3 - %7 = getelementptr inbounds nuw i8, ptr %.ptr14.i.i.ptr, i64 8 + %7 = getelementptr inbounds nuw i8, ptr %4, i64 8 %8 = load ptr, ptr %7, align 8, !tbaa !31 br label %_ZNK6frozen3mapIN4LIEF3ELF14AArch64Feature7FEATUREEPKcLm3ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread @@ -897,14 +896,13 @@ define linkonce_odr hidden ptr @_ZNK3fmt3v109formatterIN4LIEF3ELF14AArch64Featur 7: ; preds = %3 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.i = select i1 %.not.i.i.i.i.i.i.i.i.i, i64 16, i64 0 - %8 = getelementptr inbounds nuw i8, ptr @__const._ZN4LIEF3ELF9to_stringENS0_14AArch64Feature7FEATUREE.enums2str, i64 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.i - %.ptr14.i.i.ptr.i = getelementptr inbounds nuw i8, ptr %8, i64 %.add.i.i.sroa.sel.v.i - %9 = load i32, ptr %.ptr14.i.i.ptr.i, align 8, !tbaa !17 - %.not15.i.i.i = icmp slt i32 %5, %9 - br i1 %.not15.i.i.i, label %_ZN3fmt3v106detail5writeIcNS0_8appenderEEET0_S4_PKT_.exit, label %_ZN4LIEF3ELF9to_stringENS0_14AArch64Feature7FEATUREE.exit + %8 = getelementptr inbounds nuw i8, ptr %.sroa.sel.i, i64 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.i + %9 = load i32, ptr %8, align 8, !tbaa !17 + %.not12.i.i.i = icmp slt i32 %5, %9 + br i1 %.not12.i.i.i, label %_ZN3fmt3v106detail5writeIcNS0_8appenderEEET0_S4_PKT_.exit, label %_ZN4LIEF3ELF9to_stringENS0_14AArch64Feature7FEATUREE.exit _ZN4LIEF3ELF9to_stringENS0_14AArch64Feature7FEATUREE.exit: ; preds = %7 - %10 = getelementptr inbounds nuw i8, ptr %.ptr14.i.i.ptr.i, i64 8 + %10 = getelementptr inbounds nuw i8, ptr %8, i64 8 %11 = load ptr, ptr %10, align 8, !tbaa !31 %.not.i = icmp eq ptr %11, null br i1 %.not.i, label %12, label %_ZN3fmt3v106detail5writeIcNS0_8appenderEEET0_S4_PKT_.exit diff --git a/bench/lief/optimized/DyldBindingInfo.ll b/bench/lief/optimized/DyldBindingInfo.ll index 705fcc95f15..7a9ce51bc38 100644 --- a/bench/lief/optimized/DyldBindingInfo.ll +++ b/bench/lief/optimized/DyldBindingInfo.ll @@ -158,14 +158,13 @@ define noundef ptr @_ZN4LIEF5MachO9to_stringENS0_15DyldBindingInfo4TYPEE(i64 nou 3: ; preds = %1 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx = select i1 %.not.i.i.i.i.i.i.i.i, i64 16, i64 0 - %4 = getelementptr inbounds nuw i8, ptr @__const._ZN4LIEF5MachO9to_stringENS0_15DyldBindingInfo4TYPEE.enums2str, i64 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx - %.ptr14.i.i.ptr = getelementptr inbounds nuw i8, ptr %4, i64 %.add.i.i.sroa.sel.v - %5 = load i64, ptr %.ptr14.i.i.ptr, align 8, !tbaa !28 - %.not15.i.i = icmp ult i64 %0, %5 - br i1 %.not15.i.i, label %_ZNK6frozen3mapIN4LIEF5MachO15DyldBindingInfo4TYPEEPKcLm3ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread, label %6 + %4 = getelementptr inbounds nuw i8, ptr %.sroa.sel, i64 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx + %5 = load i64, ptr %4, align 8, !tbaa !28 + %.not12.i.i = icmp ult i64 %0, %5 + br i1 %.not12.i.i, label %_ZNK6frozen3mapIN4LIEF5MachO15DyldBindingInfo4TYPEEPKcLm3ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread, label %6 6: ; preds = %3 - %7 = getelementptr inbounds nuw i8, ptr %.ptr14.i.i.ptr, i64 8 + %7 = getelementptr inbounds nuw i8, ptr %4, i64 8 %8 = load ptr, ptr %7, align 8, !tbaa !36 br label %_ZNK6frozen3mapIN4LIEF5MachO15DyldBindingInfo4TYPEEPKcLm3ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread diff --git a/bench/lief/optimized/DynamicRelocationBase.ll b/bench/lief/optimized/DynamicRelocationBase.ll index 5cefbd5d43c..eb9532cd70a 100644 --- a/bench/lief/optimized/DynamicRelocationBase.ll +++ b/bench/lief/optimized/DynamicRelocationBase.ll @@ -261,7 +261,7 @@ define noundef ptr @_ZN4LIEF2PE9to_stringENS0_17DynamicRelocation24IMAGE_DYNAMIC 3: ; preds = %2 %.not.i.i.i.i.i.i.i.i.not = icmp eq i32 %0, 7 - br i1 %.not.i.i.i.i.i.i.i.i.not, label %.thread26, label %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE11lower_boundIS4_EEPKSt4pairIS4_S6_ERKT_.exit.i.i + br i1 %.not.i.i.i.i.i.i.i.i.not, label %.thread29, label %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE11lower_boundIS4_EEPKSt4pairIS4_S6_ERKT_.exit.i.i 4: ; preds = %1 %.not.i6.i.i.i.i.i.i = icmp sgt i32 %0, 2 @@ -275,27 +275,31 @@ _ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt %.not.i6.i.i.i.i.i.i.i = icmp slt i32 %6, %0 %.idx.i.i.i.i.i.i.i.i = select i1 %.not.i6.i.i.i.i.i.i.i, i64 16, i64 0 %.add15.i.i = add nuw nsw i64 %.idx.i.i.i.i.i.i.i.i, %.sink11.i.i.i.i.i.i - %.not.i.i = icmp eq i64 %.add15.i.i, 136 + %.not.i.i = icmp samesign eq i64 %.add15.i.i, 136 br i1 %.not.i.i, label %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread, label %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit _ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit: ; preds = %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE11lower_boundIS4_EEPKSt4pairIS4_S6_ERKT_.exit.i.i - %.ptr17.i.i = getelementptr inbounds nuw i8, ptr @__const._ZN4LIEF2PE9to_stringENS0_17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONE.enums2str, i64 %.add15.i.i - %.pre.i.i = load i32, ptr %.ptr17.i.i, align 8, !tbaa !22 + %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.sroa.sel.idx = select i1 %.not.i6.i.i.i.i.i.i.i, i64 16, i64 0 + %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.sroa.sel = getelementptr inbounds nuw i8, ptr %.ptr16.i.i, i64 %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.sroa.sel.idx + %.pre.i.i = load i32, ptr %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.sroa.sel, align 8, !tbaa !22 %.pre.i.i.fr = freeze i32 %.pre.i.i %7 = icmp slt i32 %0, %.pre.i.i.fr - br i1 %7, label %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread, label %8 - -8: ; preds = %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit - %.0.i.i.i.i14.i.i.sroa.gep = getelementptr inbounds nuw i8, ptr %.ptr17.i.i, i64 8 - br label %.thread26 - -.thread26: ; preds = %3, %8 - %9 = phi ptr [ %.0.i.i.i.i14.i.i.sroa.gep, %8 ], [ getelementptr inbounds nuw (i8, ptr @__const._ZN4LIEF2PE9to_stringENS0_17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONE.enums2str, i64 112), %3 ] - %10 = load ptr, ptr %9, align 8, !tbaa !24 + %10 = add nuw nsw i64 %.sink11.i.i.i.i.i.i, %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.sroa.sel.idx + %.not = icmp samesign eq i64 %10, 136 + %or.cond = select i1 %9, i1 true, i1 %.not + br i1 %or.cond, label %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread, label %11 + +11: ; preds = %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit + %.0.i.i.i.i14.i.i.sroa.gep = getelementptr inbounds nuw i8, ptr %.idx.i.i.i.i.i.i.i.i.sroa.sel.idx.sroa.sel, i64 8 + br label %.thread29 + +.thread29: ; preds = %3, %11 + %12 = phi ptr [ %.0.i.i.i.i14.i.i.sroa.gep, %11 ], [ getelementptr inbounds nuw (i8, ptr @__const._ZN4LIEF2PE9to_stringENS0_17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONE.enums2str, i64 112), %3 ] + %13 = load ptr, ptr %12, align 8, !tbaa !24 br label %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread -_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread: ; preds = %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit, %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE11lower_boundIS4_EEPKSt4pairIS4_S6_ERKT_.exit.i.i, %.thread26 - %11 = phi ptr [ %10, %.thread26 ], [ @.str.8, %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE11lower_boundIS4_EEPKSt4pairIS4_S6_ERKT_.exit.i.i ], [ @.str.8, %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit ] +_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit.thread: ; preds = %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit, %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE11lower_boundIS4_EEPKSt4pairIS4_S6_ERKT_.exit.i.i, %.thread29 + %11 = phi ptr [ %13, %.thread29 ], [ @.str.8, %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE11lower_boundIS4_EEPKSt4pairIS4_S6_ERKT_.exit.i.i ], [ @.str.8, %_ZNK6frozen3mapIN4LIEF2PE17DynamicRelocation24IMAGE_DYNAMIC_RELOCATIONEPKcLm8ESt4lessIS4_EE4findIS4_EEPKSt4pairIS4_S6_ERKT_.exit ] ret ptr %11 } diff --git a/bench/lightgbm/optimized/network.ll b/bench/lightgbm/optimized/network.ll index 743261aac8f..238073caea8 100644 --- a/bench/lightgbm/optimized/network.ll +++ b/bench/lightgbm/optimized/network.ll @@ -5573,8 +5573,8 @@ define void @_ZN8LightGBM7Network14AllgatherBruckEPcPKiS3_S1_i(ptr noundef reado ._crit_edge73: ; preds = %._crit_edge, %5 %23 = sext i32 %4 to i64 - %24 = getelementptr inbounds i8, ptr %3, i64 %23 - %.012.i.i = getelementptr inbounds i8, ptr %24, i64 -1 + %24 = add nsw i64 %23, -1 + %.012.i.i = getelementptr inbounds i8, ptr %3, i64 %24 %25 = icmp sgt i32 %4, 1 br i1 %25, label %.lr.ph.i.i, label %_ZSt7reverseIPcEvT_S1_.exit @@ -5627,15 +5627,18 @@ _ZSt7reverseIPcEvT_S1_.exit53.loopexit: ; preds = %.lr.ph.i.i49 _ZSt7reverseIPcEvT_S1_.exit53: ; preds = %_ZSt7reverseIPcEvT_S1_.exit53.loopexit, %_ZSt7reverseIPcEvT_S1_.exit %.pre-phi79 = phi i64 [ %.pre78, %_ZSt7reverseIPcEvT_S1_.exit53.loopexit ], [ %34, %_ZSt7reverseIPcEvT_S1_.exit ] %41 = phi i32 [ %.pre77, %_ZSt7reverseIPcEvT_S1_.exit53.loopexit ], [ %33, %_ZSt7reverseIPcEvT_S1_.exit ] - %42 = getelementptr inbounds i8, ptr %3, i64 %.pre-phi79 - %43 = icmp ne i32 %41, %4 - %44 = icmp ult ptr %42, %.012.i.i - %or.cond.i.i55 = select i1 %43, i1 %44, i1 false - br i1 %or.cond.i.i55, label %.lr.ph.i.i56, label %_ZSt7reverseIPcEvT_S1_.exit60 - -.lr.ph.i.i56: ; preds = %_ZSt7reverseIPcEvT_S1_.exit53, %.lr.ph.i.i56 - %.014.i.i57 = phi ptr [ %.0.i.i59, %.lr.ph.i.i56 ], [ %.012.i.i, %_ZSt7reverseIPcEvT_S1_.exit53 ] - %.0913.i.i58 = phi ptr [ %47, %.lr.ph.i.i56 ], [ %42, %_ZSt7reverseIPcEvT_S1_.exit53 ] + %42 = icmp ne i32 %41, %4 + %43 = icmp sgt i64 %24, %.pre-phi79 + %or.cond.i.i55 = select i1 %42, i1 %43, i1 false + br i1 %or.cond.i.i55, label %.lr.ph.i.i56.preheader, label %_ZSt7reverseIPcEvT_S1_.exit60 + +.lr.ph.i.i56.preheader: ; preds = %_ZSt7reverseIPcEvT_S1_.exit53 + %44 = getelementptr inbounds i8, ptr %3, i64 %.pre-phi79 + br label %.lr.ph.i.i56 + +.lr.ph.i.i56: ; preds = %.lr.ph.i.i56.preheader, %.lr.ph.i.i56 + %.014.i.i57 = phi ptr [ %.0.i.i59, %.lr.ph.i.i56 ], [ %.012.i.i, %.lr.ph.i.i56.preheader ] + %.0913.i.i58 = phi ptr [ %47, %.lr.ph.i.i56 ], [ %44, %.lr.ph.i.i56.preheader ] %45 = load i8, ptr %.0913.i.i58, align 1, !tbaa !78 %46 = load i8, ptr %.014.i.i57, align 1, !tbaa !78 store i8 %46, ptr %.0913.i.i58, align 1, !tbaa !78 diff --git a/bench/lightgbm/optimized/sample_strategy.ll b/bench/lightgbm/optimized/sample_strategy.ll index abfba0aa196..b49d67401a4 100644 --- a/bench/lightgbm/optimized/sample_strategy.ll +++ b/bench/lightgbm/optimized/sample_strategy.ll @@ -1837,18 +1837,23 @@ define internal void @_ZN8LightGBM23ParallelPartitionRunnerIiLb0EE3RunILb1EEEiiR call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) %56 = sext i32 %54 to i64 - %57 = getelementptr inbounds i32, ptr %49, i64 %56 + %.idx = shl nsw i64 %56, 2 %58 = zext nneg i32 %.sroa.speculated to i64 - %59 = getelementptr inbounds nuw i32, ptr %49, i64 %58 + %.idx48 = shl nuw nsw i64 %58, 2 %60 = icmp ne i32 %54, %.sroa.speculated - %.012.i.i = getelementptr inbounds i8, ptr %59, i64 -4 - %61 = icmp ult ptr %57, %.012.i.i + %59 = add nsw i64 %.idx48, -4 + %61 = icmp slt i64 %.idx, %59 %or.cond.i.i = select i1 %60, i1 %61, i1 false br i1 %or.cond.i.i, label %.lr.ph.i.i, label %_ZSt7reverseIPiEvT_S1_.exit -.lr.ph.i.i: ; preds = %55, %.lr.ph.i.i - %.014.i.i = phi ptr [ %.0.i.i, %.lr.ph.i.i ], [ %.012.i.i, %55 ] - %.0913.i.i = phi ptr [ %64, %.lr.ph.i.i ], [ %57, %55 ] +.lr.ph.i.i: ; preds = %55 + %.012.i.i = getelementptr inbounds i8, ptr %49, i64 %59 + %61 = getelementptr inbounds i8, ptr %49, i64 %.idx + br label %.lr.ph.i.i + +.lr.ph.i.i: ; preds = %.lr.ph.i.i.preheader, %.lr.ph.i.i + %.014.i.i = phi ptr [ %.0.i.i, %.lr.ph.i.i ], [ %.012.i.i, %.lr.ph.i.i.preheader ] + %.0913.i.i = phi ptr [ %64, %.lr.ph.i.i ], [ %61, %.lr.ph.i.i.preheader ] %62 = load i32, ptr %.0913.i.i, align 4, !tbaa !145 %63 = load i32, ptr %.014.i.i, align 4, !tbaa !145 store i32 %63, ptr %.0913.i.i, align 4, !tbaa !145 @@ -1882,7 +1887,7 @@ _ZSt7reverseIPiEvT_S1_.exit: ; preds = %.lr.ph.i.i, %55 %79 = load ptr, ptr %78, align 8 %80 = call noundef ptr %79(ptr noundef nonnull align 8 dereferenceable(8) %75) #17 invoke void (ptr, ...) @_ZN8LightGBM3Log7WarningEPKcz(ptr noundef %80) - to label %.invoke59 unwind label %92 + to label %.invoke60 unwind label %92 .sink.split: ; preds = %_ZSt7reverseIPiEvT_S1_.exit, %43 %.sink = phi i32 [ 0, %43 ], [ %68, %_ZSt7reverseIPiEvT_S1_.exit ] diff --git a/bench/llvm/optimized/Decl.ll b/bench/llvm/optimized/Decl.ll index e33e598b4eb..029ae3be24c 100644 --- a/bench/llvm/optimized/Decl.ll +++ b/bench/llvm/optimized/Decl.ll @@ -840,18 +840,16 @@ declare i8 @_ZN5clang15LinkageComputer27getTypeLinkageAndVisibilityEPKNS_4TypeE( ; Function Attrs: mustprogress nounwind uwtable define dso_local i8 @_ZN5clang15LinkageComputer29getLVForTemplateParameterListEPKNS_21TemplateParameterListENS_17LVComputationKindE(ptr noundef nonnull align 8 dereferenceable(136) %0, ptr noundef readonly captures(address) %1, i32 %2) local_unnamed_addr #2 align 2 { - %4 = getelementptr inbounds nuw i8, ptr %1, i64 20 - %5 = load i32, ptr %4, align 4 - %6 = and i32 %5, 536870911 - %7 = shl i32 %5, 3 + %4 = getelementptr inbounds nuw i8, ptr %1, i64 24 + %5 = getelementptr inbounds nuw i8, ptr %1, i64 20 + %6 = load i32, ptr %5, align 4 + %7 = shl i32 %6, 3 %.idx = zext i32 %7 to i64 - %8 = getelementptr inbounds nuw i8, ptr %1, i64 %.idx - %.ptr108 = getelementptr inbounds nuw i8, ptr %8, i64 24 - %.not103 = icmp eq i32 %6, 0 + %8 = getelementptr inbounds nuw i8, ptr %4, i64 %.idx + %.not103 = icmp eq i32 %7, 0 br i1 %.not103, label %._crit_edge, label %.lr.ph106 .lr.ph106: ; preds = %3 - %.ptr = getelementptr inbounds nuw i8, ptr %1, i64 24 %9 = and i32 %2, 4 %.not.i = icmp eq i32 %9, 0 br label %10 @@ -861,7 +859,7 @@ define dso_local i8 @_ZN5clang15LinkageComputer29getLVForTemplateParameterListEP ret i8 %.sroa.084.0.lcssa 10: ; preds = %.lr.ph106, %.loopexit - %.0105 = phi ptr [ %.ptr, %.lr.ph106 ], [ %154, %.loopexit ] + %.0105 = phi ptr [ %4, %.lr.ph106 ], [ %154, %.loopexit ] %.sroa.084.0104 = phi i8 [ 22, %.lr.ph106 ], [ %.sroa.084.1, %.loopexit ] %11 = load ptr, ptr %.0105, align 8, !tbaa !420 %12 = getelementptr inbounds nuw i8, ptr %11, i64 28 @@ -1139,7 +1137,7 @@ _ZN5clang11LinkageInfo5mergeES0_.exit78: ; preds = %.thread.i.i.i.i75, .loopexit: ; preds = %93, %_ZN5clang11LinkageInfo5mergeES0_.exit78, %10, %56, %123, %_ZN5clang11LinkageInfo5mergeES0_.exit, %19, %_ZN5clang11LinkageInfo5mergeES0_.exit68 %.sroa.084.1 = phi i8 [ %.sroa.084.0104, %10 ], [ %storemerge.i64, %_ZN5clang11LinkageInfo5mergeES0_.exit68 ], [ %.sroa.084.0104, %19 ], [ %storemerge.i, %_ZN5clang11LinkageInfo5mergeES0_.exit ], [ %.sroa.084.0104, %123 ], [ %.sroa.084.0104, %56 ], [ %storemerge.i74, %_ZN5clang11LinkageInfo5mergeES0_.exit78 ], [ %.sroa.084.4, %93 ] %154 = getelementptr inbounds nuw i8, ptr %.0105, i64 8 - %.not = icmp eq ptr %154, %.ptr108 + %.not = icmp eq ptr %154, %8 br i1 %.not, label %._crit_edge, label %10 } diff --git a/bench/llvm/optimized/LoopLoadElimination.ll b/bench/llvm/optimized/LoopLoadElimination.ll index babd2781111..c91ab7140db 100644 --- a/bench/llvm/optimized/LoopLoadElimination.ll +++ b/bench/llvm/optimized/LoopLoadElimination.ll @@ -2876,17 +2876,22 @@ _ZN12_GLOBAL__N_122LoadEliminationForLoop13getInstrIndexEPN4llvm11InstructionE.e %1143 = getelementptr inbounds nuw i8, ptr %.sroa.0.1.i.i.i.i.i.i, i64 8 %1144 = load i32, ptr %1143, align 8, !tbaa !246 %1145 = zext i32 %1144 to i64 - %1146 = getelementptr inbounds nuw ptr, ptr %1119, i64 %1145 - %1147 = getelementptr inbounds nuw i8, ptr %1146, i64 8 + %.idx.i.i.i.i = shl nuw nsw i64 %1145, 3 + %1146 = add nuw nsw i64 %.idx.i.i.i.i, 8 %1148 = getelementptr inbounds nuw i8, ptr %1117, i64 56 %1149 = load i32, ptr %1148, align 8, !tbaa !26 %1150 = zext i32 %1149 to i64 - %1151 = getelementptr inbounds nuw ptr, ptr %1119, i64 %1150 - %.not4.i.i.i.i.i = icmp eq ptr %1147, %1151 - br i1 %.not4.i.i.i.i.i, label %_ZSt8for_eachIPKPN4llvm11InstructionEZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKNS0_15SmallVectorImplINS5_30StoreToLoadForwardingCandidateEEEEUlS2_E_ET0_T_SE_SD_.exit.i.i.i.i, label %.lr.ph.i.i.i57.i.i + %.idx4.i.i.i.i = shl nuw nsw i64 %1150, 3 + %1150 = getelementptr inbounds nuw i8, ptr %1119, i64 %.idx4.i.i.i.i + %.not4.i.i.i.i.i = icmp samesign eq i64 %1146, %.idx4.i.i.i.i + br i1 %.not4.i.i.i.i.i, label %_ZSt8for_eachIPKPN4llvm11InstructionEZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKNS0_15SmallVectorImplINS5_30StoreToLoadForwardingCandidateEEEEUlS2_E_ET0_T_SE_SD_.exit.i.i.i.i, label %.lr.ph.i.preheader.i.i.i.i -.lr.ph.i.i.i57.i.i: ; preds = %_ZN12_GLOBAL__N_122LoadEliminationForLoop13getInstrIndexEPN4llvm11InstructionE.exit.i.i.i.i, %_ZZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKN4llvm15SmallVectorImplINS_30StoreToLoadForwardingCandidateEEEENKUlPNS1_11InstructionEE_clES8_.exit.i.i.i.i.i - %.05.i.i.i.i.i = phi ptr [ %1171, %_ZZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKN4llvm15SmallVectorImplINS_30StoreToLoadForwardingCandidateEEEENKUlPNS1_11InstructionEE_clES8_.exit.i.i.i.i.i ], [ %1147, %_ZN12_GLOBAL__N_122LoadEliminationForLoop13getInstrIndexEPN4llvm11InstructionE.exit.i.i.i.i ] +.lr.ph.i.preheader.i.i.i.i:; preds = %_ZN12_GLOBAL__N_122LoadEliminationForLoop13getInstrIndexEPN4llvm11InstructionE.exit.i.i.i.i + %1151 = getelementptr inbounds nuw i8, ptr %1119, i64 %1146 + br label %.lr.ph.i.i.i57.i.i + +.lr.ph.i.i.i57.i.i: ; preds = %_ZZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKN4llvm15SmallVectorImplINS_30StoreToLoadForwardingCandidateEEEENKUlPNS1_11InstructionEE_clES8_.exit.i.i.i.i.i, %.lr.ph.i.preheader.i.i.i.i + %.05.i.i.i.i.i = phi ptr [ %1171, %_ZZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKN4llvm15SmallVectorImplINS_30StoreToLoadForwardingCandidateEEEENKUlPNS1_11InstructionEE_clES8_.exit.i.i.i.i.i ], [ %1151, %.lr.ph.i.preheader.i.i.i.i ] %1152 = load ptr, ptr %.05.i.i.i.i.i, align 8, !tbaa !190 %1153 = load i8, ptr %1152, align 8, !tbaa !194 %.not.i.i.i.i58.i.i = icmp eq i8 %1153, 62 @@ -2936,7 +2941,7 @@ _ZN4llvm19SmallPtrSetImplBase10insert_impEPKv.exit.i.i.i.i.i.i.i: ; preds = %._c _ZZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKN4llvm15SmallVectorImplINS_30StoreToLoadForwardingCandidateEEEENKUlPNS1_11InstructionEE_clES8_.exit.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i77.i.i, %_ZN4llvm19SmallPtrSetImplBase10insert_impEPKv.exit.i.i.i.i.i.i.i, %1168, %.lr.ph.i.i.i57.i.i %1171 = getelementptr inbounds nuw i8, ptr %.05.i.i.i.i.i, i64 8 - %.not.i.i.i59.i.i = icmp eq ptr %1171, %1151 + %.not.i.i.i59.i.i = icmp eq ptr %1171, %1150 br i1 %.not.i.i.i59.i.i, label %_ZSt8for_eachIPKPN4llvm11InstructionEZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKNS0_15SmallVectorImplINS5_30StoreToLoadForwardingCandidateEEEEUlS2_E_ET0_T_SE_SD_.exit.loopexit.i.i.i.i, label %.lr.ph.i.i.i57.i.i, !llvm.loop !272 _ZSt8for_eachIPKPN4llvm11InstructionEZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKNS0_15SmallVectorImplINS5_30StoreToLoadForwardingCandidateEEEEUlS2_E_ET0_T_SE_SD_.exit.loopexit.i.i.i.i: ; preds = %_ZZN12_GLOBAL__N_122LoadEliminationForLoop35findPointersWrittenOnForwardingPathERKN4llvm15SmallVectorImplINS_30StoreToLoadForwardingCandidateEEEENKUlPNS1_11InstructionEE_clES8_.exit.i.i.i.i.i diff --git a/bench/llvm/optimized/TemplateName.ll b/bench/llvm/optimized/TemplateName.ll index 73edc64da14..e7855aec738 100644 --- a/bench/llvm/optimized/TemplateName.ll +++ b/bench/llvm/optimized/TemplateName.ll @@ -1581,28 +1581,29 @@ _ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit: ; preds = %11 %79 = call noundef zeroext i8 @_ZNK5clang12TemplateName13getDependenceEv(ptr noundef nonnull align 8 dereferenceable(8) %5) call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #19 %80 = load i32, ptr %9, align 8, !noalias !78 - %81 = lshr i32 %80, 17 - %narrow = mul nuw nsw i32 %81, 24 + %81 = getelementptr inbounds nuw i8, ptr %spec.select94, i64 24 + %82 = lshr i32 %80, 17 + %narrow = mul nuw nsw i32 %82, 24 %.idx = zext nneg i32 %narrow to i64 - %82 = getelementptr inbounds nuw i8, ptr %spec.select95, i64 %.idx + %82 = getelementptr inbounds nuw i8, ptr %81, i64 %.idx %.not81 = icmp ult i32 %80, 131072 br i1 %.not81, label %_ZNK5clang12TemplateName7getKindEv.exit, label %.lr.ph .lr.ph: ; preds = %_ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit, %.lr.ph - %.02183.pn = phi ptr [ %.02183, %.lr.ph ], [ %spec.select95, %_ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit ] - %.05382 = phi i8 [ %85, %.lr.ph ], [ %79, %_ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit ] - %.02183 = getelementptr inbounds nuw i8, ptr %.02183.pn, i64 24 - %83 = tail call noundef zeroext i8 @_ZNK5clang16TemplateArgument13getDependenceEv(ptr noundef nonnull align 8 dereferenceable(24) %.02183) #19 - %84 = and i8 %83, 15 - %85 = or i8 %84, %.05382 - %.not = icmp eq ptr %.02183, %82 + %.02183.pn = phi ptr [ %87, %.lr.ph ], [ %81, %_ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit ] + %.05382 = phi i8 [ %86, %.lr.ph ], [ %79, %_ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit ] + %84 = tail call noundef zeroext i8 @_ZNK5clang16TemplateArgument13getDependenceEv(ptr noundef nonnull align 8 dereferenceable(24) %.02183.pn) #19 + %85 = and i8 %84, 15 + %86 = or i8 %85, %.05382 + %87 = getelementptr inbounds nuw i8, ptr %.02183, i64 24 + %.not = icmp eq ptr %87, %82 br i1 %.not, label %_ZNK5clang12TemplateName7getKindEv.exit, label %.lr.ph _ZNK5clang12TemplateName7getKindEv.exit.fold.split: ; preds = %11 br label %_ZNK5clang12TemplateName7getKindEv.exit _ZNK5clang12TemplateName7getKindEv.exit: ; preds = %.lr.ph, %_ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit, %_ZN5clang4Decl14getDeclContextEv.exit29, %11, %_ZNK5clang12TemplateName7getKindEv.exit.fold.split, %57, %62, %_ZN5clang4Decl14getDeclContextEv.exit, %_ZN5clang4Decl14getDeclContextEv.exit.thread, %_ZNK5clang12TemplateName30getAsSubstTemplateTemplateParmEv.exit, %67 - %.0 = phi i8 [ %73, %67 ], [ %77, %_ZNK5clang12TemplateName30getAsSubstTemplateTemplateParmEv.exit ], [ 6, %11 ], [ %.051, %_ZN5clang4Decl14getDeclContextEv.exit ], [ %.051, %_ZN5clang4Decl14getDeclContextEv.exit.thread ], [ %59, %57 ], [ %66, %62 ], [ 7, %_ZNK5clang12TemplateName7getKindEv.exit.fold.split ], [ %spec.select75, %_ZN5clang4Decl14getDeclContextEv.exit29 ], [ %79, %_ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit ], [ %85, %.lr.ph ] + %.0 = phi i8 [ %73, %67 ], [ %77, %_ZNK5clang12TemplateName30getAsSubstTemplateTemplateParmEv.exit ], [ 6, %11 ], [ %.051, %_ZN5clang4Decl14getDeclContextEv.exit ], [ %.051, %_ZN5clang4Decl14getDeclContextEv.exit.thread ], [ %59, %57 ], [ %66, %62 ], [ 7, %_ZNK5clang12TemplateName7getKindEv.exit.fold.split ], [ %spec.select75, %_ZN5clang4Decl14getDeclContextEv.exit29 ], [ %79, %_ZNK5clang12TemplateName24getAsDeducedTemplateNameEv.exit ], [ %86, %.lr.ph ] ret i8 %.0 } diff --git a/bench/luajit/optimized/lj_opt_mem.ll b/bench/luajit/optimized/lj_opt_mem.ll index b52f1f77225..79a65a0fcec 100644 --- a/bench/luajit/optimized/lj_opt_mem.ll +++ b/bench/luajit/optimized/lj_opt_mem.ll @@ -854,7 +854,8 @@ fwd_aa_tab_clear.exit: ; preds = %86, %73, %62 br i1 %89, label %12, label %._crit_edge ._crit_edge: ; preds = %fwd_aa_tab_clear.exit, %1 - %90 = getelementptr inbounds nuw %union.IRIns, ptr %7, i64 %8 + %.idx = shl nuw nsw i64 %8, 3 + %90 = getelementptr inbounds nuw i8, ptr %7, i64 %.idx %91 = getelementptr inbounds nuw i8, ptr %90, i64 5 %92 = load i8, ptr %91, align 1, !tbaa !4 %93 = icmp eq i8 %92, 82 @@ -867,6 +868,7 @@ fwd_aa_tab_clear.exit: ; preds = %86, %73, %62 br i1 %96, label %.lr.ph.i37, label %fwd_aa_tab_clear.exit53 .lr.ph.i37: ; preds = %94 + %97 = add nuw nsw i64 %.idx, 8 %.0121.i.i.i46 = getelementptr inbounds nuw i8, ptr %90, i64 8 br label %97 @@ -886,18 +888,19 @@ fwd_aa_tab_clear.exit: ; preds = %86, %73, %62 106: ; preds = %103 %107 = zext i16 %104 to i64 - %108 = getelementptr inbounds nuw %union.IRIns, ptr %7, i64 %107 - %109 = getelementptr inbounds nuw i8, ptr %108, i64 5 - %110 = load i8, ptr %109, align 1, !tbaa !4 - %111 = add i8 %110, -83 - %or.cond.i.i41 = icmp ult i8 %111, -2 - %112 = icmp ult ptr %.0121.i.i.i46, %108 - %or.cond = select i1 %or.cond.i.i41, i1 %112, i1 false + %.idx100 = shl nuw nsw i64 %107, 3 + %109 = getelementptr inbounds nuw i8, ptr %7, i64 %.idx100 + %110 = getelementptr inbounds nuw i8, ptr %109, i64 5 + %111 = load i8, ptr %110, align 1, !tbaa !4 + %112 = add i8 %111, -83 + %112 = icmp ult i8 %112, -2 + %113 = icmp samesign ult i64 %97, %.idx100 + %or.cond = select i1 %or.cond.i.i41, i1 %113, i1 false br i1 %or.cond, label %.lr.ph.i.i.i47, label %aa_table.exit.i39 .lr.ph.i.i.i47: ; preds = %106, %119 - %.0123.i.i.i48 = phi ptr [ %.012.i.i.i50, %119 ], [ %.0121.i.i.i46, %106 ] - %.pn2.i.i.i49 = phi ptr [ %.0123.i.i.i48, %119 ], [ %90, %106 ] + %.0123.i.i.i48 = phi ptr [ %.012.i.i.i50, %120 ], [ %.0121.i.i.i46, %107 ] + %.pn2.i.i.i49 = phi ptr [ %.0123.i.i.i48, %120 ], [ %90, %107 ] %113 = getelementptr inbounds nuw i8, ptr %.pn2.i.i.i49, i64 10 %114 = load i16, ptr %113, align 2, !tbaa !4 %115 = icmp eq i16 %3, %114 @@ -912,7 +915,7 @@ fwd_aa_tab_clear.exit: ; preds = %86, %73, %62 119: ; preds = %116, %.lr.ph.i.i.i47 %.012.i.i.i50 = getelementptr inbounds nuw i8, ptr %.0123.i.i.i48, i64 8 - %120 = icmp ult ptr %.012.i.i.i50, %108 + %120 = icmp ult ptr %.012.i.i.i50, %109 br i1 %120, label %.lr.ph.i.i.i47, label %aa_table.exit.i39, !llvm.loop !28 aa_table.exit.i39: ; preds = %119, %106, %97 diff --git a/bench/luajit/optimized/lj_str.ll b/bench/luajit/optimized/lj_str.ll index 980ea365a47..f7d7b47f2cc 100644 --- a/bench/luajit/optimized/lj_str.ll +++ b/bench/luajit/optimized/lj_str.ll @@ -124,40 +124,36 @@ declare ptr @memchr(ptr noundef, i32 noundef, i64 noundef) local_unnamed_addr #2 ; Function Attrs: nofree norecurse nounwind memory(argmem: read) uwtable define hidden range(i32 0, 2) i32 @lj_str_haspattern(ptr noundef readonly captures(address) %0) local_unnamed_addr #3 { - %2 = getelementptr inbounds nuw i8, ptr %0, i64 20 - %3 = load i32, ptr %2, align 4, !tbaa !4 - %4 = zext i32 %3 to i64 - %5 = getelementptr inbounds nuw i8, ptr %0, i64 %4 - %.ptr15 = getelementptr inbounds nuw i8, ptr %5, i64 24 - %.not16 = icmp eq i32 %3, 0 + %2 = getelementptr inbounds nuw i8, ptr %0, i64 24 + %3 = getelementptr inbounds nuw i8, ptr %0, i64 20 + %4 = load i32, ptr %3, align 4, !tbaa !4 + %5 = zext i32 %4 to i64 + %.ptr15 = getelementptr inbounds nuw i8, ptr %2, i64 %5 + %.not16 = icmp eq i32 %4, 0 br i1 %.not16, label %._crit_edge, label %.lr.ph.preheader -.lr.ph.preheader: ; preds = %1 - %.ptr = getelementptr inbounds nuw i8, ptr %0, i64 24 - br label %.lr.ph - -.lr.ph: ; preds = %.lr.ph.preheader, %.critedge - %.01012 = phi ptr [ %6, %.critedge ], [ %.ptr, %.lr.ph.preheader ] - %6 = getelementptr inbounds nuw i8, ptr %.01012, i64 1 - %7 = load i8, ptr %.01012, align 1, !tbaa !14 - %8 = zext i8 %7 to i64 - %9 = getelementptr inbounds nuw i8, ptr getelementptr inbounds nuw (i8, ptr @lj_char_bits, i64 1), i64 %8 - %10 = load i8, ptr %9, align 1, !tbaa !14 - %11 = and i8 %10, 4 - %.not = icmp eq i8 %11, 0 - br i1 %.not, label %.critedge, label %12 - -12: ; preds = %.lr.ph - %13 = zext i8 %7 to i32 - %memchr = tail call ptr @memchr(ptr nonnull dereferenceable(1) @.str, i32 %13, i64 11) +.lr.ph.preheader: ; preds = %1, %.critedge + %.01012 = phi ptr [ %7, %.critedge ], [ %2, %1 ] + %7 = getelementptr inbounds nuw i8, ptr %.01012, i64 1 + %8 = load i8, ptr %.01012, align 1, !tbaa !14 + %9 = zext i8 %8 to i64 + %10 = getelementptr inbounds nuw i8, ptr getelementptr inbounds nuw (i8, ptr @lj_char_bits, i64 1), i64 %9 + %11 = load i8, ptr %10, align 1, !tbaa !14 + %12 = and i8 %11, 4 + %.not = icmp eq i8 %12, 0 + br i1 %.not, label %.critedge, label %13 + +13:; preds = %.lr.ph + %14 = zext i8 %8 to i32 + %memchr = tail call ptr @memchr(ptr nonnull dereferenceable(1) @.str, i32 %14, i64 11) %.not11 = icmp eq ptr %memchr, null br i1 %.not11, label %.critedge, label %._crit_edge13, !llvm.loop !15 -.critedge: ; preds = %12, %.lr.ph - %14 = icmp ult ptr %6, %.ptr15 +.critedge: ; preds = %13, %.lr.ph + %14 = icmp ult ptr %7, %.ptr15 br i1 %14, label %.lr.ph, label %._crit_edge -._crit_edge13: ; preds = %12 +._crit_edge13: ; preds = %13 br label %._crit_edge, !llvm.loop !15 ._crit_edge: ; preds = %.critedge, %._crit_edge13, %1 diff --git a/bench/luau/optimized/lstrlib.ll b/bench/luau/optimized/lstrlib.ll index 9443d57095d..483f8176eb7 100644 --- a/bench/luau/optimized/lstrlib.ll +++ b/bench/luau/optimized/lstrlib.ll @@ -1314,11 +1314,13 @@ define internal noundef i32 @_ZL9str_splitP9lua_State(ptr noundef %0) #0 { %8 = load i64, ptr %3, align 8, !tbaa !4 %9 = icmp eq i64 %8, 0 %spec.select.idx = zext i1 %9 to i64 + %10 = sub i64 %6, %8 + %.not37 = icmp slt i64 %10, %spec.select.idx + br i1 %.not37, label %._crit_edge, label %.lr.ph.preheader + +.lr.ph.preheader: ; preds = %1 %spec.select = getelementptr inbounds nuw i8, ptr %4, i64 %spec.select.idx - %10 = sub i64 0, %8 - %11 = getelementptr inbounds i8, ptr %7, i64 %10 - %.not37 = icmp ugt ptr %spec.select, %11 - br i1 %.not37, label %._crit_edge, label %.lr.ph + br label %.lr.ph ._crit_edge.loopexit: ; preds = %22 %12 = add nsw i32 %.129, 1 @@ -1331,11 +1333,11 @@ define internal noundef i32 @_ZL9str_splitP9lua_State(ptr noundef %0) #0 { %.not34 = icmp eq i64 %.lcssa, 0 br i1 %.not34, label %30, label %26 -.lr.ph: ; preds = %1, %22 - %.pr43 = phi i64 [ %.pr, %22 ], [ %8, %1 ] - %.040 = phi ptr [ %23, %22 ], [ %spec.select, %1 ] - %.02839 = phi i32 [ %.129, %22 ], [ 0, %1 ] - %.03038 = phi ptr [ %.131, %22 ], [ %4, %1 ] +.lr.ph: ; preds = %.lr.ph.preheader, %22 + %.pr43 = phi i64 [ %.pr, %21 ], [ %8, %.lr.ph.preheader ] + %.040 = phi ptr [ %23, %21 ], [ %spec.select, %.lr.ph.preheader ] + %.02839 = phi i32 [ %.129, %21 ], [ 0, %.lr.ph.preheader ] + %.03038 = phi ptr [ %.131, %21 ], [ %4, %.lr.ph.preheader ] %bcmp = call i32 @bcmp(ptr %.040, ptr %5, i64 %.pr43) %13 = icmp eq i32 %bcmp, 0 br i1 %13, label %14, label %22 @@ -1356,10 +1358,10 @@ define internal noundef i32 @_ZL9str_splitP9lua_State(ptr noundef %0) #0 { br label %22 22: ; preds = %14, %.lr.ph - %.pr = phi i64 [ %.pr43, %.lr.ph ], [ %19, %14 ] - %.131 = phi ptr [ %.03038, %.lr.ph ], [ %20, %14 ] - %.129 = phi i32 [ %.02839, %.lr.ph ], [ %15, %14 ] - %.1 = phi ptr [ %.040, %.lr.ph ], [ %spec.select36, %14 ] + %.pr = phi i64 [ %.pr43, %.lr.ph ], [ %19, %13 ] + %.131 = phi ptr [ %.03038, %.lr.ph ], [ %20, %13 ] + %.129 = phi i32 [ %.02839, %.lr.ph ], [ %15, %13 ] + %.1 = phi ptr [ %.040, %.lr.ph ], [ %spec.select36, %13 ] %23 = getelementptr inbounds nuw i8, ptr %.1, i64 1 %24 = sub i64 0, %.pr %25 = getelementptr inbounds i8, ptr %7, i64 %24 diff --git a/bench/meshlab/optimized/GLLogStream.ll b/bench/meshlab/optimized/GLLogStream.ll index f0d3c357852..5c98304313b 100644 --- a/bench/meshlab/optimized/GLLogStream.ll +++ b/bench/meshlab/optimized/GLLogStream.ll @@ -1651,23 +1651,25 @@ _ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit: ; preds = %_ZN5QListI7QStr %29 = phi i64 [ %28, %_ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit.loopexit ], [ 0, %3 ] %30 = phi ptr [ %.pre, %_ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit.loopexit ], [ %12, %3 ] %31 = getelementptr inbounds nuw i8, ptr %30, i64 16 - %32 = getelementptr inbounds ptr, ptr %31, i64 %.pre-phi - %33 = getelementptr inbounds ptr, ptr %32, i64 %29 - %34 = sext i32 %2 to i64 - %35 = getelementptr inbounds ptr, ptr %33, i64 %34 + %32 = sext i32 %2 to i64 + %.idx1721 = add nsw i64 %.pre-phi, %32 + %33 = add nsw i64 %.idx1721, %29 + %34 = shl nsw i64 %33, 3 %36 = getelementptr inbounds nuw i8, ptr %30, i64 12 %37 = load i32, ptr %36, align 4 %38 = sext i32 %37 to i64 - %39 = getelementptr inbounds ptr, ptr %31, i64 %38 - %.not8.i6 = icmp eq ptr %35, %39 + %.idx20 = shl nsw i64 %38, 3 + %38 = getelementptr inbounds i8, ptr %31, i64 %.idx20 + %.not8.i6 = icmp eq i64 %34, %.idx20 br i1 %.not8.i6, label %_ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit13, label %.lr.ph.i7.preheader .lr.ph.i7.preheader: ; preds = %_ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit %40 = getelementptr inbounds %"struct.QList::Node", ptr %10, i64 %29 + %40 = getelementptr inbounds i8, ptr %31, i64 %34 br label %.lr.ph.i7 .lr.ph.i7: ; preds = %.lr.ph.i7.preheader, %_ZN7QStringC2ERKS_.exit.i11 - %.010.i8 = phi ptr [ %46, %_ZN7QStringC2ERKS_.exit.i11 ], [ %35, %.lr.ph.i7.preheader ] + %.010.i8 = phi ptr [ %46, %_ZN7QStringC2ERKS_.exit.i11 ], [ %40, %.lr.ph.i7.preheader ] %.079.i9 = phi ptr [ %47, %_ZN7QStringC2ERKS_.exit.i11 ], [ %40, %.lr.ph.i7.preheader ] %41 = load ptr, ptr %.079.i9, align 8 store ptr %41, ptr %.010.i8, align 8 @@ -1683,7 +1685,7 @@ _ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit: ; preds = %_ZN5QListI7QStr _ZN7QStringC2ERKS_.exit.i11: ; preds = %44, %.lr.ph.i7 %46 = getelementptr inbounds nuw i8, ptr %.010.i8, i64 8 %47 = getelementptr inbounds nuw i8, ptr %.079.i9, i64 8 - %.not.i12 = icmp eq ptr %46, %39 + %.not.i12 = icmp eq ptr %46, %38 br i1 %.not.i12, label %_ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit13, label %.lr.ph.i7, !llvm.loop !34 _ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit13: ; preds = %_ZN7QStringC2ERKS_.exit.i11, %_ZN5QListI7QStringE9node_copyEPNS1_4NodeES3_S3_.exit diff --git a/bench/meshlab/optimized/render_raster.ll b/bench/meshlab/optimized/render_raster.ll index 53e19e9edcf..0778a2a74b9 100644 --- a/bench/meshlab/optimized/render_raster.ll +++ b/bench/meshlab/optimized/render_raster.ll @@ -238,8 +238,9 @@ define void @_ZN19MeshLabRenderRasterC2ERKS_(ptr noundef nonnull align 8 derefer .lr.ph: ; preds = %2 %11 = sext i32 %8 to i64 - %12 = getelementptr inbounds nuw i8, ptr %6, i64 16 - %13 = getelementptr inbounds ptr, ptr %12, i64 %11 + %.idx = shl nsw i64 %11, 3 + %13 = getelementptr i8, ptr %6, i64 %.idx + %13 = getelementptr i8, ptr %12, i64 16 %14 = getelementptr inbounds nuw i8, ptr %1, i64 144 %15 = getelementptr inbounds nuw i8, ptr %0, i64 144 br label %16 diff --git a/bench/mold/optimized/arch-arm32.ll b/bench/mold/optimized/arch-arm32.ll index cf004758092..f6c82fdc505 100644 --- a/bench/mold/optimized/arch-arm32.ll +++ b/bench/mold/optimized/arch-arm32.ll @@ -5702,33 +5702,29 @@ define linkonce_odr dso_local { ptr, i64 } @_ZN4mold9InputFileINS_5ARM32EE8get_d %5 = alloca %"class.mold::Fatal", align 8 %6 = getelementptr inbounds nuw i8, ptr %0, i64 8 %7 = load ptr, ptr %6, align 8, !tbaa !522 - %8 = getelementptr inbounds nuw i8, ptr %7, i64 32 - %9 = load ptr, ptr %8, align 8, !tbaa !523 - %10 = getelementptr inbounds nuw i8, ptr %2, i64 16 - %11 = load i32, ptr %10, align 1 - %12 = zext i32 %11 to i64 - %13 = getelementptr inbounds nuw i8, ptr %9, i64 %12 - %14 = getelementptr inbounds nuw i8, ptr %2, i64 20 - %15 = load i32, ptr %14, align 1 - %16 = zext i32 %15 to i64 - %17 = getelementptr inbounds nuw i8, ptr %13, i64 %16 - %18 = getelementptr inbounds nuw i8, ptr %7, i64 40 - %19 = load i64, ptr %18, align 8, !tbaa !525 - %20 = getelementptr inbounds i8, ptr %9, i64 %19 - %21 = icmp ult ptr %20, %17 - br i1 %21, label %22, label %_ZN4mold9InputFileINS_5ARM32EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit - -22: ; preds = %3 + %8 = getelementptr inbounds nuw i8, ptr %2, i64 16 + %9 = load i32, ptr %8, align 1 + %10 = zext i32 %9 to i64 + %11 = getelementptr inbounds nuw i8, ptr %2, i64 20 + %12 = load i32, ptr %11, align 1 + %13 = zext i32 %12 to i64 + %14 = getelementptr inbounds nuw i8, ptr %7, i64 40 + %15 = load i64, ptr %14, align 8, !tbaa !523 + %16 = add nuw nsw i64 %13, %10 + %17 = icmp slt i64 %15, %16 + br i1 %17, label %18, label %_ZN4mold9InputFileINS_5ARM32EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit + +18: ; preds = %3 call void @llvm.lifetime.start.p0(i64 408, ptr nonnull %4) #20 call void @_ZN4mold5FatalINS_7ContextINS_5ARM32EEEEC2ERS3_(ptr noundef nonnull align 8 dereferenceable(408) %4, ptr noundef nonnull align 8 dereferenceable(4520) %1) %23 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_5ARM32EEEElsIRNS_9InputFileIS2_EEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %4, ptr noundef nonnull align 8 dereferenceable(296) %0) %24 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_5ARM32EEEElsIRA35_KcEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %23, ptr noundef nonnull align 1 dereferenceable(35) @.str.24) - %25 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_5ARM32EEEElsIRKNS_7IntegerIjLb1ELi4EEEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %24, ptr noundef nonnull align 1 dereferenceable(4) %10) + %25 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_5ARM32EEEElsIRKNS_7IntegerIjLb1ELi4EEEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %24, ptr noundef nonnull align 1 dereferenceable(4) %8) call void @_ZN4mold5FatalINS_7ContextINS_5ARM32EEEED2Ev(ptr noundef nonnull align 8 dereferenceable(408) %4) #27 unreachable _ZN4mold9InputFileINS_5ARM32EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit: ; preds = %3 - %26 = and i64 %16, 7 + %26 = and i64 %13, 7 %.not = icmp eq i64 %26, 0 br i1 %.not, label %30, label %27 @@ -5741,9 +5737,12 @@ _ZN4mold9InputFileINS_5ARM32EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE unreachable 30: ; preds = %_ZN4mold9InputFileINS_5ARM32EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit - %31 = lshr exact i64 %16, 3 - %.fca.0.insert = insertvalue { ptr, i64 } poison, ptr %13, 0 - %.fca.1.insert = insertvalue { ptr, i64 } %.fca.0.insert, i64 %31, 1 + %27 = getelementptr inbounds nuw i8, ptr %7, i64 32 + %28 = load ptr, ptr %27, align 8, !tbaa !525 + %29 = getelementptr inbounds nuw i8, ptr %28, i64 %10 + %30 = lshr exact i64 %13, 3 + %.fca.0.insert = insertvalue { ptr, i64 } poison, ptr %29, 0 + %.fca.1.insert = insertvalue { ptr, i64 } %.fca.0.insert, i64 %30, 1 ret { ptr, i64 } %.fca.1.insert } @@ -8160,9 +8159,9 @@ attributes #28 = { builtin nounwind allocsize(0) } !520 = distinct !{!520, !364} !521 = distinct !{!521, !364} !522 = !{!288, !289, i64 8} -!523 = !{!524, !25, i64 32} +!523 = !{!524, !26, i64 40} !524 = !{!"_ZTSN4mold10MappedFileE", !63, i64 0, !25, i64 32, !26, i64 40, !49, i64 48, !289, i64 56, !289, i64 64, !49, i64 72, !48, i64 76} -!525 = !{!524, !26, i64 40} +!525 = !{!524, !25, i64 32} !526 = !{!65, !26, i64 0} !527 = !{!176, !176, i64 0} !528 = !{!171, !172, i64 0} diff --git a/bench/mold/optimized/gc-sections.cc.X86_64.ll b/bench/mold/optimized/gc-sections.cc.X86_64.ll index 9c99d2159d8..10981fdb21b 100644 --- a/bench/mold/optimized/gc-sections.cc.X86_64.ll +++ b/bench/mold/optimized/gc-sections.cc.X86_64.ll @@ -5574,32 +5574,28 @@ define linkonce_odr dso_local { ptr, i64 } @_ZN4mold9InputFileINS_6X86_64EE8get_ %5 = alloca %"class.mold::Fatal", align 8 %6 = getelementptr inbounds nuw i8, ptr %0, i64 8 %7 = load ptr, ptr %6, align 8, !tbaa !315 - %8 = getelementptr inbounds nuw i8, ptr %7, i64 32 - %9 = load ptr, ptr %8, align 8, !tbaa !332 - %10 = getelementptr inbounds nuw i8, ptr %2, i64 24 + %8 = getelementptr inbounds nuw i8, ptr %2, i64 24 + %9 = load i64, ptr %8, align 1 + %10 = getelementptr inbounds nuw i8, ptr %2, i64 32 %11 = load i64, ptr %10, align 1 - %12 = getelementptr inbounds nuw i8, ptr %9, i64 %11 - %13 = getelementptr inbounds nuw i8, ptr %2, i64 32 - %14 = load i64, ptr %13, align 1 - %15 = getelementptr inbounds nuw i8, ptr %12, i64 %14 - %16 = getelementptr inbounds nuw i8, ptr %7, i64 40 - %17 = load i64, ptr %16, align 8, !tbaa !334 - %18 = getelementptr inbounds i8, ptr %9, i64 %17 - %19 = icmp ult ptr %18, %15 - br i1 %19, label %20, label %_ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit - -20: ; preds = %3 + %12 = getelementptr inbounds nuw i8, ptr %7, i64 40 + %13 = load i64, ptr %12, align 8, !tbaa !332 + %14 = add nuw nsw i64 %11, %9 + %15 = icmp slt i64 %13, %14 + br i1 %15, label %16, label %_ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit + +16: ; preds = %3 call void @llvm.lifetime.start.p0(i64 408, ptr nonnull %4) #12 call void @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEEC2ERS3_(ptr noundef nonnull align 8 dereferenceable(408) %4, ptr noundef nonnull align 8 dereferenceable(4520) %1) %21 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEElsIRNS_9InputFileIS2_EEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %4, ptr noundef nonnull align 8 dereferenceable(296) %0) %22 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEElsIRA35_KcEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %21, ptr noundef nonnull align 1 dereferenceable(35) @.str.15) - %23 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEElsIRKNS_7IntegerImLb1ELi8EEEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %22, ptr noundef nonnull align 1 dereferenceable(8) %10) + %23 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEElsIRKNS_7IntegerImLb1ELi8EEEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %22, ptr noundef nonnull align 1 dereferenceable(8) %8) call void @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEED2Ev(ptr noundef nonnull align 8 dereferenceable(408) %4) #26 unreachable _ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit: ; preds = %3 - %24 = urem i64 %14, 24 - %25 = udiv i64 %14, 24 + %24 = urem i64 %11, 24 + %25 = udiv i64 %11, 24 %.not = icmp eq i64 %24, 0 br i1 %.not, label %29, label %26 @@ -5612,8 +5608,11 @@ _ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_E unreachable 29: ; preds = %_ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit - %.fca.0.insert = insertvalue { ptr, i64 } poison, ptr %12, 0 - %.fca.1.insert = insertvalue { ptr, i64 } %.fca.0.insert, i64 %25, 1 + %26 = getelementptr inbounds nuw i8, ptr %7, i64 32 + %27 = load ptr, ptr %26, align 8, !tbaa !334 + %28 = getelementptr inbounds nuw i8, ptr %27, i64 %9 + %.fca.0.insert = insertvalue { ptr, i64 } poison, ptr %28, 0 + %.fca.1.insert = insertvalue { ptr, i64 } %.fca.0.insert, i64 %21, 1 ret { ptr, i64 } %.fca.1.insert } @@ -9510,9 +9509,9 @@ attributes #27 = { nounwind willreturn memory(none) } !329 = !{!"_ZTSSt12_Vector_baseIN4mold6SymbolINS0_6X86_64EEESaIS3_EE", !330, i64 0} !330 = !{!"_ZTSNSt12_Vector_baseIN4mold6SymbolINS0_6X86_64EEESaIS3_EE12_Vector_implE", !331, i64 0} !331 = !{!"_ZTSNSt12_Vector_baseIN4mold6SymbolINS0_6X86_64EEESaIS3_EE17_Vector_impl_dataE", !222, i64 0, !222, i64 8, !222, i64 16} -!332 = !{!333, !13, i64 32} +!332 = !{!333, !16, i64 40} !333 = !{!"_ZTSN4mold10MappedFileE", !15, i64 0, !13, i64 32, !16, i64 40, !33, i64 48, !317, i64 56, !317, i64 64, !33, i64 72, !43, i64 76} -!334 = !{!333, !16, i64 40} +!334 = !{!333, !13, i64 32} !335 = !{!336, !336, i64 0} !336 = !{!"p1 _ZTSSo", !7, i64 0} !337 = !{!338, !336, i64 216} diff --git a/bench/mold/optimized/input-sections.cc.X86_64.ll b/bench/mold/optimized/input-sections.cc.X86_64.ll index 5714d14e14b..c838bfc327f 100644 --- a/bench/mold/optimized/input-sections.cc.X86_64.ll +++ b/bench/mold/optimized/input-sections.cc.X86_64.ll @@ -1438,32 +1438,28 @@ define linkonce_odr dso_local { ptr, i64 } @_ZN4mold9InputFileINS_6X86_64EE8get_ %5 = alloca %"class.mold::Fatal", align 8 %6 = getelementptr inbounds nuw i8, ptr %0, i64 8 %7 = load ptr, ptr %6, align 8, !tbaa !54 - %8 = getelementptr inbounds nuw i8, ptr %7, i64 32 - %9 = load ptr, ptr %8, align 8, !tbaa !75 - %10 = getelementptr inbounds nuw i8, ptr %2, i64 24 + %8 = getelementptr inbounds nuw i8, ptr %2, i64 24 + %9 = load i64, ptr %8, align 1 + %10 = getelementptr inbounds nuw i8, ptr %2, i64 32 %11 = load i64, ptr %10, align 1 - %12 = getelementptr inbounds nuw i8, ptr %9, i64 %11 - %13 = getelementptr inbounds nuw i8, ptr %2, i64 32 - %14 = load i64, ptr %13, align 1 - %15 = getelementptr inbounds nuw i8, ptr %12, i64 %14 - %16 = getelementptr inbounds nuw i8, ptr %7, i64 40 - %17 = load i64, ptr %16, align 8, !tbaa !365 - %18 = getelementptr inbounds i8, ptr %9, i64 %17 - %19 = icmp ult ptr %18, %15 - br i1 %19, label %20, label %_ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit + %12 = getelementptr inbounds nuw i8, ptr %7, i64 40 + %13 = load i64, ptr %12, align 8, !tbaa !365 + %14 = add nuw nsw i64 %11, %9 + %15 = icmp slt i64 %13, %14 + br i1 %15, label %16, label %_ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit 20: ; preds = %3 call void @llvm.lifetime.start.p0(i64 408, ptr nonnull %4) #15 call void @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEEC2ERS3_(ptr noundef nonnull align 8 dereferenceable(408) %4, ptr noundef nonnull align 8 dereferenceable(4520) %1) %21 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEElsIRNS_9InputFileIS2_EEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %4, ptr noundef nonnull align 8 dereferenceable(296) %0) %22 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEElsIRA35_KcEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %21, ptr noundef nonnull align 1 dereferenceable(35) @.str.41) - %23 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEElsIRKNS_7IntegerImLb1ELi8EEEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %22, ptr noundef nonnull align 1 dereferenceable(8) %10) + %23 = call noundef nonnull align 8 dereferenceable(408) ptr @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEElsIRKNS_7IntegerImLb1ELi8EEEEERS4_OT_(ptr noundef nonnull align 8 dereferenceable(408) %22, ptr noundef nonnull align 1 dereferenceable(8) %8) call void @_ZN4mold5FatalINS_7ContextINS_6X86_64EEEED2Ev(ptr noundef nonnull align 8 dereferenceable(408) %4) #27 unreachable _ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit: ; preds = %3 - %24 = urem i64 %14, 24 - %25 = udiv i64 %14, 24 + %24 = urem i64 %11, 24 + %25 = udiv i64 %11, 24 %.not = icmp eq i64 %24, 0 br i1 %.not, label %29, label %26 @@ -1476,8 +1472,11 @@ _ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_E unreachable 29: ; preds = %_ZN4mold9InputFileINS_6X86_64EE10get_stringERNS_7ContextIS1_EERKNS_7ElfShdrIS1_EE.exit - %.fca.0.insert = insertvalue { ptr, i64 } poison, ptr %12, 0 - %.fca.1.insert = insertvalue { ptr, i64 } %.fca.0.insert, i64 %25, 1 + %26 = getelementptr inbounds nuw i8, ptr %7, i64 32 + %27 = load ptr, ptr %26, align 8, !tbaa !75 + %28 = getelementptr inbounds nuw i8, ptr %27, i64 %9 + %.fca.0.insert = insertvalue { ptr, i64 } poison, ptr %28, 0 + %.fca.1.insert = insertvalue { ptr, i64 } %.fca.0.insert, i64 %21, 1 ret { ptr, i64 } %.fca.1.insert } diff --git a/bench/nanobind/optimized/test_functions.ll b/bench/nanobind/optimized/test_functions.ll index 16c4fdf67d1..fe10222d222 100644 --- a/bench/nanobind/optimized/test_functions.ll +++ b/bench/nanobind/optimized/test_functions.ll @@ -7138,36 +7138,32 @@ define internal noundef ptr @"_ZZN8nanobind6detail11func_createILb0ELb1EZL32nano store i64 %14, ptr %9, align 8 store ptr null, ptr %7, align 8, !tbaa !44 call void @llvm.experimental.noalias.scope.decl(metadata !249) - %15 = inttoptr i64 %14 to ptr - %16 = invoke ptr @PyList_New(i64 noundef 0) #28 - to label %.noexc unwind label %29 + %15 = invoke ptr @PyList_New(i64 noundef 0) #28 + to label %.noexc unwind label %28 .noexc: ; preds = %13 - store ptr %16, ptr %8, align 8, !alias.scope !249 - %17 = getelementptr inbounds nuw i8, ptr %15, i64 16 - %18 = load i64, ptr %17, align 8, !tbaa !252, !noalias !249 - %.idx.i = shl nsw i64 %18, 3 - %19 = getelementptr i8, ptr %15, i64 %.idx.i - %.ptr6.i = getelementptr i8, ptr %19, i64 24 - %.not4.i = icmp eq i64 %18, 0 - br i1 %.not4.i, label %"_ZZL32nanobind_init_test_functions_extRN8nanobind7module_EENK4$_28clENS_5tupleE.exit", label %.lr.ph.preheader.i - -.lr.ph.preheader.i: ; preds = %.noexc - %.ptr.i = getelementptr inbounds nuw i8, ptr %15, i64 24 - br label %.lr.ph.i - -.lr.ph.i: ; preds = %21, %.lr.ph.preheader.i - %.sroa.01.05.i = phi ptr [ %22, %21 ], [ %.ptr.i, %.lr.ph.preheader.i ] + %16 = inttoptr i64 %14 to ptr + store ptr %15, ptr %8, align 8, !alias.scope !249 + %17 = getelementptr inbounds nuw i8, ptr %16, i64 24 + %18 = getelementptr inbounds nuw i8, ptr %16, i64 16 + %19 = load i64, ptr %18, align 8, !tbaa !252, !noalias !249 + %.idx.i = shl nsw i64 %19, 3 + %20 = getelementptr inbounds i8, ptr %17, i64 %.idx.i + %.not4.i = icmp eq i64 %19, 0 + br i1 %.not4.i, label %"_ZZL32nanobind_init_test_functions_extRN8nanobind7module_EENK4$_28clENS_5tupleE.exit", label %.lr.ph.i + +.lr.ph.i:; preds = %.noexc, %22 + %.sroa.01.05.i = phi ptr [ %23, %22 ], [ %17, %.noexc ] call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #27, !noalias !249 %20 = load ptr, ptr %.sroa.01.05.i, align 8, !tbaa !158 store ptr %20, ptr %6, align 8, !noalias !249 invoke void @_ZN8nanobind4list6appendIRNS_6handleEEEvOT_(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(8) %6) #28 - to label %21 unwind label %23 + to label %22 unwind label %23 21: ; preds = %.lr.ph.i call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #27, !noalias !249 %22 = getelementptr inbounds nuw i8, ptr %.sroa.01.05.i, i64 8 - %.not.i = icmp eq ptr %22, %.ptr6.i + %.not.i = icmp eq ptr %22, %20 br i1 %.not.i, label %"_ZZL32nanobind_init_test_functions_extRN8nanobind7module_EENK4$_28clENS_5tupleE.exit.loopexit", label %.lr.ph.i 23: ; preds = %.lr.ph.i @@ -7182,7 +7178,7 @@ define internal noundef ptr @"_ZZN8nanobind6detail11func_createILb0ELb1EZL32nano br label %"_ZZL32nanobind_init_test_functions_extRN8nanobind7module_EENK4$_28clENS_5tupleE.exit" "_ZZL32nanobind_init_test_functions_extRN8nanobind7module_EENK4$_28clENS_5tupleE.exit": ; preds = %"_ZZL32nanobind_init_test_functions_extRN8nanobind7module_EENK4$_28clENS_5tupleE.exit.loopexit", %.noexc - %26 = phi ptr [ %.pre, %"_ZZL32nanobind_init_test_functions_extRN8nanobind7module_EENK4$_28clENS_5tupleE.exit.loopexit" ], [ %16, %.noexc ] + %26 = phi ptr [ %.pre, %"_ZZL32nanobind_init_test_functions_extRN8nanobind7module_EENK4$_28clENS_5tupleE.exit.loopexit" ], [ %15, %.noexc ] store ptr null, ptr %8, align 8, !tbaa !44 %27 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKR8nanobind6handle7dec_refEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #31 %28 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKR8nanobind6handle7dec_refEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #31 @@ -7195,7 +7191,7 @@ define internal noundef ptr @"_ZZN8nanobind6detail11func_createILb0ELb1EZL32nano br label %.body .body: ; preds = %23, %29 - %eh.lpad-body = phi { ptr, i32 } [ %30, %29 ], [ %24, %23 ] + %eh.lpad-body = phi { ptr, i32 } [ %30, %30 ], [ %24, %24 ] %31 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKR8nanobind6handle7dec_refEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #31 call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #27 %32 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKR8nanobind6handle7dec_refEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #31 diff --git a/bench/nanobind/optimized/test_stl_bind_vector.ll b/bench/nanobind/optimized/test_stl_bind_vector.ll index 421c9a55bf4..9440238bd52 100644 --- a/bench/nanobind/optimized/test_stl_bind_vector.ll +++ b/bench/nanobind/optimized/test_stl_bind_vector.ll @@ -7556,11 +7556,13 @@ thread-pre-split.i: ; preds = %45, %40 51: ; preds = %thread-pre-split.i %52 = load ptr, ptr %24, align 8, !tbaa !107 - %53 = getelementptr inbounds i32, ptr %52, i64 %47 - %54 = getelementptr inbounds i32, ptr %52, i64 %48 - %55 = getelementptr inbounds nuw i8, ptr %54, i64 4 + %.idx.i = shl nsw i64 %47, 2 + %54 = getelementptr inbounds i8, ptr %52, i64 %.idx.i + %.idx40.i = shl nsw i64 %48, 2 + %54 = add nsw i64 %.idx40.i, 4 + %55 = getelementptr inbounds i8, ptr %52, i64 %54 %56 = ptrtoint ptr %55 to i64 - %.not.i.i.i = icmp eq ptr %53, %55 + %.not.i.i.i = icmp eq i64 %.idx.i, %54 br i1 %.not.i.i.i, label %.loopexit, label %57 57: ; preds = %51 @@ -13743,11 +13745,13 @@ thread-pre-split.i: ; preds = %42, %37 48: ; preds = %thread-pre-split.i %.val31.i = load ptr, ptr %24, align 8, !tbaa !245 - %49 = getelementptr inbounds %struct.El, ptr %.val31.i, i64 %44 - %50 = getelementptr inbounds %struct.El, ptr %.val31.i, i64 %45 - %51 = getelementptr inbounds nuw i8, ptr %50, i64 4 + %.idx.i = shl nsw i64 %44, 2 + %50 = getelementptr inbounds i8, ptr %.val31.i, i64 %.idx.i + %.idx10.i = shl nsw i64 %45, 2 + %50 = add nsw i64 %.idx10.i, 4 + %51 = getelementptr inbounds i8, ptr %.val31.i, i64 %50 %52 = ptrtoint ptr %51 to i64 - %.not.i.i.i = icmp eq ptr %49, %51 + %.not.i.i.i = icmp eq i64 %.idx.i, %51 br i1 %.not.i.i.i, label %.loopexit, label %53 53: ; preds = %48 @@ -16473,11 +16477,13 @@ thread-pre-split.i: ; preds = %42, %37 48: ; preds = %thread-pre-split.i %.val31.i = load ptr, ptr %24, align 8, !tbaa !327 - %49 = getelementptr inbounds %"class.std::vector.435", ptr %.val31.i, i64 %44 - %50 = getelementptr inbounds %"class.std::vector.435", ptr %.val31.i, i64 %45 - %51 = getelementptr inbounds nuw i8, ptr %50, i64 24 + %.idx.i = mul nsw i64 %44, 24 + %50 = getelementptr inbounds i8, ptr %.val31.i, i64 %.idx.i + %.idx10.i = mul nsw i64 %45, 24 + %50 = add nsw i64 %.idx10.i, 24 + %51 = getelementptr inbounds i8, ptr %.val31.i, i64 %50 %52 = ptrtoint ptr %51 to i64 - %.not.i.i.i = icmp eq ptr %49, %51 + %.not.i.i.i = icmp eq i64 %.idx.i, %51 br i1 %.not.i.i.i, label %.loopexit, label %53 53: ; preds = %48 @@ -19542,11 +19548,13 @@ thread-pre-split.i: ; preds = %43, %38 49: ; preds = %thread-pre-split.i %.val31.i = load ptr, ptr %25, align 8, !tbaa !427 - %50 = getelementptr inbounds %"class.std::shared_ptr", ptr %.val31.i, i64 %45 - %51 = getelementptr inbounds %"class.std::shared_ptr", ptr %.val31.i, i64 %46 - %52 = getelementptr inbounds nuw i8, ptr %51, i64 16 + %.idx.i = shl nsw i64 %45, 4 + %51 = getelementptr inbounds i8, ptr %.val31.i, i64 %.idx.i + %.idx10.i = shl nsw i64 %46, 4 + %51 = add nsw i64 %.idx10.i, 16 + %52 = getelementptr inbounds i8, ptr %.val31.i, i64 %51 %53 = ptrtoint ptr %52 to i64 - %.not.i.i.i = icmp eq ptr %50, %52 + %.not.i.i.i = icmp eq i64 %.idx.i, %51 br i1 %.not.i.i.i, label %.loopexit, label %54 54: ; preds = %49 diff --git a/bench/nix/optimized/attr-set.ll b/bench/nix/optimized/attr-set.ll index c1843384399..e270f435dc4 100644 --- a/bench/nix/optimized/attr-set.ll +++ b/bench/nix/optimized/attr-set.ll @@ -1053,15 +1053,14 @@ define void @_ZN3nix8Bindings4sortEv(ptr noundef nonnull align 8 dereferenceable 4: ; preds = %1 %5 = zext i32 %3 to i64 - %.ptr = getelementptr inbounds nuw i8, ptr %0, i64 16 %.idx = shl nuw nsw i64 %5, 4 - %6 = getelementptr inbounds nuw i8, ptr %0, i64 %.idx - %.ptr1 = getelementptr inbounds nuw i8, ptr %6, i64 16 + %6 = getelementptr inbounds nuw i8, ptr %0, i64 16 + %.ptr1 = getelementptr inbounds nuw i8, ptr %6, i64 %.idx %7 = tail call range(i64 0, 65) i64 @llvm.ctlz.i64(i64 %5, i1 true) %8 = shl nuw nsw i64 %7, 1 %9 = xor i64 %8, 126 - tail call void @_ZSt16__introsort_loopIPN3nix4AttrElN9__gnu_cxx5__ops15_Iter_less_iterEEvT_S6_T0_T1_(ptr noundef nonnull %.ptr, ptr noundef nonnull %.ptr1, i64 noundef %9) - tail call void @_ZSt22__final_insertion_sortIPN3nix4AttrEN9__gnu_cxx5__ops15_Iter_less_iterEEvT_S6_T0_(ptr noundef nonnull %.ptr, ptr noundef nonnull %.ptr1) + tail call void @_ZSt16__introsort_loopIPN3nix4AttrElN9__gnu_cxx5__ops15_Iter_less_iterEEvT_S6_T0_T1_(ptr noundef nonnull %6, ptr noundef nonnull %.ptr1, i64 noundef %9) + tail call void @_ZSt22__final_insertion_sortIPN3nix4AttrEN9__gnu_cxx5__ops15_Iter_less_iterEEvT_S6_T0_(ptr noundef nonnull %6, ptr noundef nonnull %.ptr1) br label %_ZSt4sortIPN3nix4AttrEEvT_S3_.exit _ZSt4sortIPN3nix4AttrEEvT_S3_.exit: ; preds = %4, %1 @@ -1078,15 +1077,14 @@ define noundef nonnull align 8 dereferenceable(24) ptr @_ZN3nix5Value7mkAttrsERN 6: ; preds = %2 %7 = zext i32 %5 to i64 - %.ptr.i.i = getelementptr inbounds nuw i8, ptr %3, i64 16 %.idx.i.i = shl nuw nsw i64 %7, 4 - %8 = getelementptr inbounds nuw i8, ptr %3, i64 %.idx.i.i - %.ptr1.i.i = getelementptr inbounds nuw i8, ptr %8, i64 16 + %8 = getelementptr inbounds nuw i8, ptr %3, i64 16 + %.ptr1.i.i = getelementptr inbounds nuw i8, ptr %8, i64 %.idx.i.i %9 = tail call range(i64 0, 65) i64 @llvm.ctlz.i64(i64 %7, i1 true) %10 = shl nuw nsw i64 %9, 1 %11 = xor i64 %10, 126 - tail call void @_ZSt16__introsort_loopIPN3nix4AttrElN9__gnu_cxx5__ops15_Iter_less_iterEEvT_S6_T0_T1_(ptr noundef nonnull %.ptr.i.i, ptr noundef nonnull %.ptr1.i.i, i64 noundef %11) - tail call void @_ZSt22__final_insertion_sortIPN3nix4AttrEN9__gnu_cxx5__ops15_Iter_less_iterEEvT_S6_T0_(ptr noundef nonnull %.ptr.i.i, ptr noundef nonnull %.ptr1.i.i) + tail call void @_ZSt16__introsort_loopIPN3nix4AttrElN9__gnu_cxx5__ops15_Iter_less_iterEEvT_S6_T0_T1_(ptr noundef nonnull %8, ptr noundef nonnull %.ptr1.i.i, i64 noundef %11) + tail call void @_ZSt22__final_insertion_sortIPN3nix4AttrEN9__gnu_cxx5__ops15_Iter_less_iterEEvT_S6_T0_(ptr noundef nonnull %8, ptr noundef nonnull %.ptr1.i.i) %.pre.i = load ptr, ptr %1, align 8 br label %_ZN3nix15BindingsBuilder6finishEv.exit diff --git a/bench/node/optimized/libnode.packet.ll b/bench/node/optimized/libnode.packet.ll index 1a0d24f5bef..34e2125e4b0 100644 --- a/bench/node/optimized/libnode.packet.ll +++ b/bench/node/optimized/libnode.packet.ll @@ -2320,8 +2320,7 @@ entry: %cond.i.i.i.i = select i1 %cmp.i.i.i.i, i64 16, i64 28 %call2.i = tail call i32 @htonl(i32 noundef %generateReservedVersion.val.val) #27 store i32 %call2.i, ptr %ver.i, align 4 - %2 = getelementptr inbounds nuw i8, ptr %generateReservedVersion.val.val9, i64 %cond.i.i.i.i - %add.ptr.ptr.i = getelementptr inbounds nuw i8, ptr %2, i64 8 + %2 = getelementptr inbounds nuw i8, ptr %address_.i.i, i64 %cond.i.i.i.i br label %for.body.i for.body.i: ; preds = %for.body.i, %entry @@ -2332,7 +2331,7 @@ for.body.i: ; preds = %for.body.i, %entry %xor.i = xor i32 %h.02.i, %conv5.i %mul.i = mul i32 %xor.i, 16777619 %incdec.ptr.i = getelementptr inbounds nuw i8, ptr %p.03.i, i64 1 - %cmp.not.i = icmp eq ptr %incdec.ptr.i, %add.ptr.ptr.i + %cmp.not.i = icmp eq ptr %incdec.ptr.i, %add.ptr.i br i1 %cmp.not.i, label %for.body9.i, label %for.body.i, !llvm.loop !41 for.body9.i: ; preds = %for.body.i, %for.body9.i @@ -2380,14 +2379,14 @@ cond.false.i: ; preds = %"_ZZN4node4quic6Pac _ZNK4node4quic6Packetcv10ngtcp2_vecEv.exit: ; preds = %"_ZZN4node4quic6Packet30CreateVersionNegotiationPacketEPNS_11EnvironmentEPNS1_8ListenerERKNS0_14PathDescriptorEENK3$_0clEv.exit", %cond.false.i %retval.sroa.0.0.i = phi ptr [ %11, %cond.false.i ], [ null, %"_ZZN4node4quic6Packet30CreateVersionNegotiationPacketEPNS_11EnvironmentEPNS1_8ListenerERKNS0_14PathDescriptorEENK3$_0clEv.exit" ] + %11 = load ptr, ptr %dcid, align 8 + %call9 = tail call noundef ptr @_ZNK4node4quic3CIDcvPKhEv(ptr noundef nonnull align 8 dereferenceable(48) %11) #23 %12 = load ptr, ptr %dcid, align 8 - %call9 = tail call noundef ptr @_ZNK4node4quic3CIDcvPKhEv(ptr noundef nonnull align 8 dereferenceable(48) %12) #23 - %13 = load ptr, ptr %dcid, align 8 - %call11 = tail call noundef i64 @_ZNK4node4quic3CID6lengthEv(ptr noundef nonnull align 8 dereferenceable(48) %13) #23 + %call9 = tail call noundef i64 @_ZNK4node4quic3CID6lengthEv(ptr noundef nonnull align 8 dereferenceable(48) %12) #23 + %13 = load ptr, ptr %scid, align 8 + %call11 = tail call noundef ptr @_ZNK4node4quic3CIDcvPKhEv(ptr noundef nonnull align 8 dereferenceable(48) %13) #23 %14 = load ptr, ptr %scid, align 8 - %call13 = tail call noundef ptr @_ZNK4node4quic3CIDcvPKhEv(ptr noundef nonnull align 8 dereferenceable(48) %14) #23 - %15 = load ptr, ptr %scid, align 8 - %call15 = tail call noundef i64 @_ZNK4node4quic3CID6lengthEv(ptr noundef nonnull align 8 dereferenceable(48) %15) #23 + %call13 = tail call noundef i64 @_ZNK4node4quic3CID6lengthEv(ptr noundef nonnull align 8 dereferenceable(48) %14) #23 %call17 = call i64 @ngtcp2_pkt_write_version_negotiation(ptr noundef %retval.sroa.0.0.i, i64 noundef %add5, i8 noundef zeroext 0, ptr noundef %call9, i64 noundef %call11, ptr noundef %call13, i64 noundef %call15, ptr noundef nonnull %sv, i64 noundef 3) #23 %cmp = icmp slt i64 %call17, 1 br i1 %cmp, label %if.then.i, label %if.end diff --git a/bench/openblas/optimized/dlaswp_ncopy.ll b/bench/openblas/optimized/dlaswp_ncopy.ll index 432c9fc310e..e1581a6cf81 100644 --- a/bench/openblas/optimized/dlaswp_ncopy.ll +++ b/bench/openblas/optimized/dlaswp_ncopy.ll @@ -213,7 +213,14 @@ define noundef i32 @dlaswp_ncopy(i64 noundef %0, i64 noundef %1, i64 noundef %2, br i1 %.not298, label %90, label %78 .preheader310.split: ; preds = %.preheader310 - br i1 %.not298, label %.preheader310.split.split.us.preheader, label %.preheader310.split.split + br i1 %.not298, label %.preheader310.split.split.us.preheader, label %.preheader310.split.split.preheader + +.preheader310.split.split.preheader: ; preds = %.preheader310.split + %.idx328 = shl nsw i64 %8, 3 + %94 = add nsw i64 %.idx328, 8 + %.idx329 = shl nsw i64 %14, 3 + %95 = icmp eq i64 %94, %.idx329 + br label %.preheader310.split.split .preheader310.split.split.us.preheader: ; preds = %.preheader310.split %94 = shl i64 %13, 4 @@ -222,37 +229,35 @@ define noundef i32 @dlaswp_ncopy(i64 noundef %0, i64 noundef %1, i64 noundef %2, %scevgep = getelementptr i8, ptr %96, i64 -8 br label %.split.us -.preheader310.split.split: ; preds = %.preheader310.split, %111 - %.1286 = phi ptr [ %113, %111 ], [ %12, %.preheader310.split ] - %.1282 = phi ptr [ %112, %111 ], [ %6, %.preheader310.split ] - %.0278 = phi i64 [ %114, %111 ], [ %13, %.preheader310.split ] - %97 = getelementptr inbounds double, ptr %.1286, i64 %8 - %98 = getelementptr inbounds nuw i8, ptr %97, i64 8 - %99 = getelementptr inbounds double, ptr %98, i64 %4 - %100 = getelementptr inbounds double, ptr %.1286, i64 %14 - %101 = load double, ptr %98, align 8, !tbaa !7 - %102 = load double, ptr %99, align 8, !tbaa !7 - %103 = icmp eq ptr %98, %100 - br i1 %103, label %104, label %106 - -104: ; preds = %.preheader310.split.split +.preheader310.split.split: ; preds = %.preheader310.split.split.preheader, %111 + %.1286 = phi ptr [ %113, %111 ], [ %12, %.preheader310.split.split.preheader ] + %.1282 = phi ptr [ %112, %111 ], [ %6, %.preheader310.split.split.preheader ] + %.0278 = phi i64 [ %114, %111 ], [ %13, %.preheader310.split.split.preheader ] + %97 = getelementptr inbounds i8, ptr %.1286, i64 %94 + %98 = getelementptr inbounds double, ptr %97, i64 %4 + %101 = load double, ptr %99, align 8, !tbaa !7 + %102 = load double, ptr %98, align 8, !tbaa !7 + br i1 %95, label %103, label %105 + +103:; preds = %.preheader310.split.split store double %101, ptr %.1282, align 8, !tbaa !7 %105 = getelementptr inbounds nuw i8, ptr %.1282, i64 8 store double %102, ptr %105, align 8, !tbaa !7 br label %111 106: ; preds = %.preheader310.split.split - %107 = getelementptr inbounds double, ptr %100, i64 %4 + %107 = getelementptr inbounds i8, ptr %.1286, i64 %.idx329 + %107 = getelementptr inbounds double, ptr %106, i64 %4 %108 = load double, ptr %107, align 8, !tbaa !7 - %109 = load double, ptr %100, align 8, !tbaa !7 + %109 = load double, ptr %106, align 8, !tbaa !7 store double %109, ptr %.1282, align 8, !tbaa !7 %110 = getelementptr inbounds nuw i8, ptr %.1282, i64 8 store double %108, ptr %110, align 8, !tbaa !7 - store double %101, ptr %100, align 8, !tbaa !7 + store double %101, ptr %106, align 8, !tbaa !7 store double %102, ptr %107, align 8, !tbaa !7 br label %111 -111: ; preds = %106, %104 +111: ; preds = %106, %103 %112 = getelementptr inbounds nuw i8, ptr %.1282, i64 16 %113 = getelementptr inbounds i8, ptr %.1286, i64 %.idx %114 = add nsw i64 %.0278, -1 diff --git a/bench/opencc/optimized/louds-trie.ll b/bench/opencc/optimized/louds-trie.ll index 4c1a7d3d05d..bfcccdab040 100644 --- a/bench/opencc/optimized/louds-trie.ll +++ b/bench/opencc/optimized/louds-trie.ll @@ -2553,19 +2553,22 @@ _ZNK6marisa8grimoire4trie9LoudsTrie8get_linkEm.exit: ; preds = %72, %74 br label %_ZNK6marisa8grimoire4trie9LoudsTrie7restoreERNS_5AgentEm.exit _ZNK6marisa8grimoire4trie9LoudsTrie7restoreERNS_5AgentEm.exit: ; preds = %86, %87 - %88 = load ptr, ptr %42, align 8, !tbaa !133 - %89 = getelementptr inbounds nuw i8, ptr %88, i64 %58 - %90 = load i64, ptr %17, align 8, !tbaa !131 - %91 = getelementptr inbounds nuw i8, ptr %88, i64 %90 - %92 = icmp samesign ne i64 %58, %90 - %.012.i.i = getelementptr inbounds i8, ptr %91, i64 -1 - %93 = icmp ult ptr %89, %.012.i.i - %or.cond.i.i = select i1 %92, i1 %93, i1 false - br i1 %or.cond.i.i, label %.lr.ph.i.i, label %_ZSt7reverseIPcEvT_S1_.exit - -.lr.ph.i.i: ; preds = %_ZNK6marisa8grimoire4trie9LoudsTrie7restoreERNS_5AgentEm.exit, %.lr.ph.i.i - %.014.i.i = phi ptr [ %.0.i.i32, %.lr.ph.i.i ], [ %.012.i.i, %_ZNK6marisa8grimoire4trie9LoudsTrie7restoreERNS_5AgentEm.exit ] - %.0913.i.i = phi ptr [ %96, %.lr.ph.i.i ], [ %89, %_ZNK6marisa8grimoire4trie9LoudsTrie7restoreERNS_5AgentEm.exit ] + %88 = load i64, ptr %17, align 8, !tbaa !131 + %89 = icmp samesign ne i64 %58, %88 + %90 = add nsw i64 %88, -1 + %91 = icmp slt i64 %58, %90 + %or.cond.i.i = select i1 %89, i1 %91, i1 false + br i1 %or.cond.i.i, label %.lr.ph.i.i.preheader, label %_ZSt7reverseIPcEvT_S1_.exit + +.lr.ph.i.i.preheader:; preds = %_ZNK6marisa8grimoire4trie9LoudsTrie7restoreERNS_5AgentEm.exit + %92 = load ptr, ptr %42, align 8, !tbaa !133 + %.012.i.i = getelementptr inbounds i8, ptr %92, i64 %90 + %93 = getelementptr inbounds nuw i8, ptr %92, i64 %58 + br label %.lr.ph.i.i + +.lr.ph.i.i: ; preds = %.lr.ph.i.i.preheader, %.lr.ph.i.i + %.014.i.i = phi ptr [ %.0.i.i32, %.lr.ph.i.i ], [ %.012.i.i, %.lr.ph.i.i.preheader ] + %.0913.i.i = phi ptr [ %96, %.lr.ph.i.i ], [ %93, %.lr.ph.i.i.preheader ] %94 = load i8, ptr %.0913.i.i, align 1, !tbaa !58 %95 = load i8, ptr %.014.i.i, align 1, !tbaa !58 store i8 %95, ptr %.0913.i.i, align 1, !tbaa !58 diff --git a/bench/opencv/optimized/arg_layer.ll b/bench/opencv/optimized/arg_layer.ll index 897afe90fe7..b067ef3ad56 100644 --- a/bench/opencv/optimized/arg_layer.ll +++ b/bench/opencv/optimized/arg_layer.ll @@ -1512,15 +1512,16 @@ _ZNSt6vectorIiSaIiEEC2ERKS1_.exit: ; preds = %.thread, %19 44: ; preds = %34 %.idx = shl nsw i64 %41, 2 - %45 = getelementptr inbounds i8, ptr %26, i64 %.idx - %46 = getelementptr inbounds nuw i8, ptr %45, i64 4 - %.not.i.i.i = icmp eq ptr %46, %24 + %45 = add nsw i64 %.idx, 4 + %.not.i.i.i = icmp eq i64 %45, %13 br i1 %.not.i.i.i, label %_ZNSt6vectorIiSaIiEE5eraseEN9__gnu_cxx17__normal_iteratorIPKiS1_EE.exit.i, label %_ZSt4moveIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i.i.i _ZSt4moveIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i.i.i: ; preds = %44 + %46 = getelementptr inbounds i8, ptr %26, i64 %.idx + %47 = getelementptr inbounds nuw i8, ptr %46, i64 4 %.neg = add nsw i64 %13, -4 %gepdiff = sub i64 %.neg, %.idx - tail call void @llvm.memmove.p0.p0.i64(ptr align 4 %45, ptr nonnull align 4 %46, i64 %gepdiff, i1 false) + tail call void @llvm.memmove.p0.p0.i64(ptr align 4 %46, ptr nonnull align 4 %47, i64 %gepdiff, i1 false) br label %_ZNSt6vectorIiSaIiEE5eraseEN9__gnu_cxx17__normal_iteratorIPKiS1_EE.exit.i _ZNSt6vectorIiSaIiEE5eraseEN9__gnu_cxx17__normal_iteratorIPKiS1_EE.exit.i: ; preds = %_ZSt4moveIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i.i.i, %44 diff --git a/bench/opencv/optimized/gather_layer.ll b/bench/opencv/optimized/gather_layer.ll index d3826074f85..671ccaf5eac 100644 --- a/bench/opencv/optimized/gather_layer.ll +++ b/bench/opencv/optimized/gather_layer.ll @@ -1380,14 +1380,15 @@ _ZNSt6vectorIiSaIiEEC2ERKS1_.exit: ; preds = %.thread, %28 %47 = sext i32 %46 to i64 %.idx = shl nsw i64 %47, 2 %48 = getelementptr inbounds i8, ptr %35, i64 %.idx - %49 = getelementptr inbounds nuw i8, ptr %48, i64 4 - %.not.i.i20 = icmp eq ptr %49, %33 + %49 = add nsw i64 %.idx, 4 + %.not.i.i20 = icmp eq i64 %49, %22 br i1 %.not.i.i20, label %50, label %_ZSt4moveIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i.i _ZSt4moveIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i.i: ; preds = %43 + %50 = getelementptr inbounds nuw i8, ptr %48, i64 4 %.neg = add nsw i64 %22, -4 %gepdiff = sub i64 %.neg, %.idx - tail call void @llvm.memmove.p0.p0.i64(ptr align 4 %48, ptr nonnull align 4 %49, i64 %gepdiff, i1 false) + tail call void @llvm.memmove.p0.p0.i64(ptr align 4 %48, ptr nonnull align 4 %50, i64 %gepdiff, i1 false) br label %50 50: ; preds = %_ZSt4moveIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.exit.i.i, %43 @@ -1413,10 +1414,10 @@ _ZSt4moveIN9__gnu_cxx17__normal_iteratorIPiSt6vectorIiSaIiEEEES6_ET0_T_S8_S7_.ex br label %63 63: ; preds = %58, %55 - %64 = phi ptr [ %.pre, %55 ], [ %60, %58 ] - %.sroa.03.0 = phi ptr [ %57, %55 ], [ %62, %58 ] + %64 = phi ptr [ %.pre, %56 ], [ %60, %59 ] + %.sroa.03.0 = phi ptr [ %57, %56 ], [ %62, %59 ] invoke void @_ZNSt6vectorIiSaIiEE15_M_range_insertIN9__gnu_cxx17__normal_iteratorIPKiS1_EEEEvNS4_IPiS1_EET_SA_St20forward_iterator_tag(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr %48, ptr %64, ptr %.sroa.03.0) - to label %65 unwind label %70 + to label %66 unwind label %70 65: ; preds = %63 invoke void @_ZNSt6vectorIS_IiSaIiEESaIS1_EE14_M_fill_assignEmRKS1_(ptr noundef nonnull align 8 dereferenceable(24) %3, i64 noundef 1, ptr noundef nonnull align 8 dereferenceable(24) %6) @@ -1451,7 +1452,7 @@ _ZNSt6vectorIiSaIiEED2Ev.exit: ; preds = %_ZNSt6vectorIS_IiSa br label %74 74: ; preds = %70, %72, %68 - %.pn.pn = phi { ptr, i32 } [ %69, %68 ], [ %73, %72 ], [ %71, %70 ] + %.pn.pn = phi { ptr, i32 } [ %69, %69 ], [ %73, %73 ], [ %71, %71 ] %75 = load ptr, ptr %6, align 8, !tbaa !87 %.not.i.i.i23 = icmp eq ptr %75, null br i1 %.not.i.i.i23, label %_ZNSt6vectorIiSaIiEED2Ev.exit24, label %76 diff --git a/bench/openjdk/optimized/barrierSetC2.ll b/bench/openjdk/optimized/barrierSetC2.ll index 14f7954eb58..fd06fd80713 100644 --- a/bench/openjdk/optimized/barrierSetC2.ll +++ b/bench/openjdk/optimized/barrierSetC2.ll @@ -488,25 +488,26 @@ define hidden void @_ZN13BarrierStubC28preserveE8Register(ptr noundef nonnull al %7 = sub i32 %6, ptrtoint (ptr getelementptr inbounds nuw (i8, ptr @all_RegisterImpls, i64 1) to i32) %8 = shl i32 %7, 1 %9 = sext i32 %8 to i64 - %10 = getelementptr inbounds %class.VMRegImpl, ptr getelementptr inbounds nuw (i8, ptr @all_VMRegs, i64 1), i64 %9 - %.not.i = icmp ult ptr %10, getelementptr inbounds nuw (i8, ptr @all_VMRegs, i64 617) - %11 = ptrtoint ptr %10 to i64 - %12 = trunc i64 %11 to i32 - br i1 %.not.i, label %15, label %13 - -13: ; preds = %2 - %14 = add i32 %12, add (i32 sub (i32 0, i32 ptrtoint (ptr getelementptr inbounds nuw (i8, ptr @all_VMRegs, i64 617) to i32)), i32 616) + %10 = getelementptr inbounds i8, ptr getelementptr inbounds nuw (i8, ptr @all_VMRegs, i64 1), i64 %9 + %11 = or disjoint i64 %9, 1 + %.not.i = icmp slt i64 %11, 617 + %12 = ptrtoint ptr %10 to i64 + %13 = trunc i64 %12 to i32 + br i1 %.not.i, label %16, label %14 + +14: ; preds = %2 + %15 = add i32 %13, add (i32 sub (i32 0, i32 ptrtoint (ptr getelementptr inbounds nuw (i8, ptr @all_VMRegs, i64 617) to i32)), i32 616) br label %_ZN7OptoReg10as_OptoRegEP9VMRegImpl.exit 15: ; preds = %2 - %16 = sub i32 %12, ptrtoint (ptr getelementptr inbounds nuw (i8, ptr @all_VMRegs, i64 1) to i32) + %16 = sub i32 %13, ptrtoint (ptr getelementptr inbounds nuw (i8, ptr @all_VMRegs, i64 1) to i32) %17 = sext i32 %16 to i64 %18 = getelementptr inbounds [609 x i32], ptr @_ZN7OptoReg7vm2optoE, i64 0, i64 %17 %19 = load i32, ptr %18, align 4 br label %_ZN7OptoReg10as_OptoRegEP9VMRegImpl.exit -_ZN7OptoReg10as_OptoRegEP9VMRegImpl.exit: ; preds = %13, %15 - %.0.i = phi i32 [ %14, %13 ], [ %19, %15 ] +_ZN7OptoReg10as_OptoRegEP9VMRegImpl.exit: ; preds = %14, %15 + %.0.i = phi i32 [ %15, %14 ], [ %19, %16 ] %20 = lshr i32 %.0.i, 6 %21 = getelementptr inbounds nuw i8, ptr %0, i64 180 %22 = load i32, ptr %21, align 4 diff --git a/bench/openjdk/optimized/bytecodeStream.ll b/bench/openjdk/optimized/bytecodeStream.ll index 57810393ccb..6408d90f8cb 100644 --- a/bench/openjdk/optimized/bytecodeStream.ll +++ b/bench/openjdk/optimized/bytecodeStream.ll @@ -49,18 +49,19 @@ define hidden noundef i32 @_ZN17RawBytecodeStream16raw_next_specialEN9Bytecodes4 br i1 %30, label %31, label %36 31: ; preds = %27 - %32 = getelementptr inbounds nuw i8, ptr %11, i64 1 - %.not17 = icmp ult ptr %32, %15 + %32 = add nsw i64 %10, 1 + %.not17 = icmp slt i64 %32, %14 br i1 %.not17, label %33, label %36 33: ; preds = %31 - %34 = load i8, ptr %32, align 1 - %35 = zext i8 %34 to i32 + %34 = getelementptr inbounds nuw i8, ptr %11, i64 1 + %35 = load i8, ptr %34, align 1 + %36 = zext i8 %35 to i32 store i8 1, ptr %29, align 8 br label %36 36: ; preds = %31, %2, %18, %23, %27, %33 - %.0 = phi i32 [ %35, %33 ], [ %1, %27 ], [ -1, %23 ], [ -1, %18 ], [ -1, %2 ], [ -1, %31 ] + %.0 = phi i32 [ %36, %33 ], [ %1, %27 ], [ -1, %23 ], [ -1, %18 ], [ -1, %2 ], [ -1, %31 ] %37 = getelementptr inbounds nuw i8, ptr %0, i64 36 store i32 %.0, ptr %37, align 4 ret i32 %.0 diff --git a/bench/openjdk/optimized/handles.ll b/bench/openjdk/optimized/handles.ll index 4c3aac9be89..f47d7fb6d0b 100644 --- a/bench/openjdk/optimized/handles.ll +++ b/bench/openjdk/optimized/handles.ll @@ -586,25 +586,21 @@ _ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit: ; preds = %_ZL13chunk_oops_doP .lr.ph: ; preds = %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit, %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit14 %15 = phi ptr [ %24, %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit14 ], [ %13, %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit ] %.019 = phi ptr [ %.0, %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit14 ], [ %.017, %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit ] - %16 = getelementptr inbounds nuw i8, ptr %.019, i64 8 - %17 = load i64, ptr %16, align 8 - %18 = getelementptr i8, ptr %.019, i64 %17 - %.ptr15 = getelementptr i8, ptr %18, i64 16 - %19 = icmp sgt i64 %17, 0 + %16 = getelementptr inbounds nuw i8, ptr %.019, i64 16 + %17 = getelementptr inbounds nuw i8, ptr %.018, i64 8 + %18 = load i64, ptr %17, align 8 + %.ptr15 = getelementptr inbounds i8, ptr %16, i64 %18 + %19 = icmp sgt i64 %18, 0 br i1 %19, label %.lr.ph.i12.preheader, label %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit14 -.lr.ph.i12.preheader: ; preds = %.lr.ph - %.ptr = getelementptr inbounds nuw i8, ptr %.019, i64 16 - br label %.lr.ph.i12 - -.lr.ph.i12: ; preds = %.lr.ph.i12.preheader, %.lr.ph.i12 - %.08.i13 = phi ptr [ %20, %.lr.ph.i12 ], [ %.ptr, %.lr.ph.i12.preheader ] - %20 = getelementptr inbounds nuw i8, ptr %.08.i13, i64 8 - %21 = load ptr, ptr %1, align 8 - %22 = load ptr, ptr %21, align 8 - tail call void %22(ptr noundef nonnull align 8 dereferenceable(8) %1, ptr noundef nonnull %.08.i13) #7 - %23 = icmp ult ptr %20, %.ptr15 - br i1 %23, label %.lr.ph.i12, label %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit14.loopexit, !llvm.loop !9 +.lr.ph.i12.preheader: ; preds = %.lr.ph, %.lr.ph.i12 + %.08.i13 = phi ptr [ %21, %.lr.ph.i12 ], [ %16, %.lr.ph ] + %21 = getelementptr inbounds nuw i8, ptr %.08.i13, i64 8 + %22 = load ptr, ptr %1, align 8 + %23 = load ptr, ptr %22, align 8 + tail call void %23(ptr noundef nonnull align 8 dereferenceable(8) %1, ptr noundef nonnull %.08.i13) #7 + %24 = icmp ult ptr %21, %19 + br i1 %24, label %.lr.ph.i12.preheader, label %_ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit14.loopexit, !llvm.loop !9 _ZL13chunk_oops_doP10OopClosureP5ChunkPc.exit14.loopexit: ; preds = %.lr.ph.i12 %.pre20 = load ptr, ptr %3, align 8 diff --git a/bench/openjdk/optimized/shenandoahMark.ll b/bench/openjdk/optimized/shenandoahMark.ll index 46f55ae621e..4869e4ef6e7 100644 --- a/bench/openjdk/optimized/shenandoahMark.ll +++ b/bench/openjdk/optimized/shenandoahMark.ll @@ -9866,31 +9866,33 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s 14: ; preds = %3 %15 = load i32, ptr @_ZN23InstanceStackChunkKlass16_offset_of_stackE, align 4 - %16 = sext i32 %15 to i64 - %17 = add nsw i64 %16, %8 - %18 = inttoptr i64 %17 to ptr - %19 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk10_sp_offsetE, align 4 - %20 = sext i32 %19 to i64 - %21 = add nsw i64 %20, %8 - %22 = inttoptr i64 %21 to ptr - %23 = load volatile i32, ptr %22, align 4 + %16 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk10_sp_offsetE, align 4 + %17 = sext i32 %16 to i64 + %18 = add nsw i64 %17, %8 + %19 = inttoptr i64 %18 to ptr + %20 = load volatile i32, ptr %19, align 4 + %21 = sext i32 %20 to i64 + %.idx9 = shl nsw i64 %21, 3 + %22 = add nsw i64 %.idx9, -16 + %23 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk12_size_offsetE, align 4 %24 = sext i32 %23 to i64 - %25 = getelementptr inbounds i64, ptr %18, i64 %24 - %26 = getelementptr inbounds i8, ptr %25, i64 -16 - %27 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk12_size_offsetE, align 4 + %25 = add nsw i64 %24, %8 + %26 = inttoptr i64 %25 to ptr + %27 = load i32, ptr %26, align 4 %28 = sext i32 %27 to i64 - %29 = add nsw i64 %28, %8 - %30 = inttoptr i64 %29 to ptr - %31 = load i32, ptr %30, align 4 - %32 = sext i32 %31 to i64 - %33 = getelementptr inbounds i64, ptr %18, i64 %32 + %.idx = shl nsw i64 %28, 3 call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) tail call void @_ZN23InstanceStackChunkKlass10do_methodsEP17stackChunkOopDescP17OopIterateClosure(ptr noundef nonnull align 8 dereferenceable(464) %0, ptr noundef nonnull %1, ptr noundef %2) #10 - %34 = icmp ugt ptr %33, %26 + %34 = icmp sgt i64 %.idx, %22 br i1 %34, label %35, label %_ZN23InstanceStackChunkKlass33oop_oop_iterate_stack_with_bitmapI9narrowOop31ShenandoahMarkUpdateRefsClosureIL24ShenandoahGenerationType0EEEEvP17stackChunkOopDescPT0_PlS9_.exit 35: ; preds = %14 + %31 = sext i32 %15 to i64 + %32 = add nsw i64 %31, %8 + %33 = inttoptr i64 %32 to ptr + %34 = getelementptr inbounds i8, ptr %33, i64 %22 + %35 = getelementptr inbounds i8, ptr %33, i64 %.idx store ptr %1, ptr %5, align 8 %36 = getelementptr inbounds nuw i8, ptr %5, i64 8 store ptr %2, ptr %36, align 8 @@ -9915,10 +9917,10 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s store ptr %47, ptr %6, align 8, !alias.scope !60 %54 = getelementptr inbounds nuw i8, ptr %6, i64 8 store i64 %53, ptr %54, align 8, !alias.scope !60 - %55 = ptrtoint ptr %26 to i64 + %55 = ptrtoint ptr %34 to i64 %56 = sub i64 %55, %44 %57 = ashr exact i64 %56, 2 - %58 = ptrtoint ptr %33 to i64 + %58 = ptrtoint ptr %35 to i64 %59 = sub i64 %58, %44 %60 = ashr exact i64 %59, 2 call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) @@ -10279,31 +10281,33 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s 14: ; preds = %3 %15 = load i32, ptr @_ZN23InstanceStackChunkKlass16_offset_of_stackE, align 4 - %16 = sext i32 %15 to i64 - %17 = add nsw i64 %16, %8 - %18 = inttoptr i64 %17 to ptr - %19 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk10_sp_offsetE, align 4 - %20 = sext i32 %19 to i64 - %21 = add nsw i64 %20, %8 - %22 = inttoptr i64 %21 to ptr - %23 = load volatile i32, ptr %22, align 4 + %16 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk10_sp_offsetE, align 4 + %17 = sext i32 %16 to i64 + %18 = add nsw i64 %17, %8 + %19 = inttoptr i64 %18 to ptr + %20 = load volatile i32, ptr %19, align 4 + %21 = sext i32 %20 to i64 + %.idx9 = shl nsw i64 %21, 3 + %22 = add nsw i64 %.idx9, -16 + %23 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk12_size_offsetE, align 4 %24 = sext i32 %23 to i64 - %25 = getelementptr inbounds i64, ptr %18, i64 %24 - %26 = getelementptr inbounds i8, ptr %25, i64 -16 - %27 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk12_size_offsetE, align 4 + %25 = add nsw i64 %24, %8 + %26 = inttoptr i64 %25 to ptr + %27 = load i32, ptr %26, align 4 %28 = sext i32 %27 to i64 - %29 = add nsw i64 %28, %8 - %30 = inttoptr i64 %29 to ptr - %31 = load i32, ptr %30, align 4 - %32 = sext i32 %31 to i64 - %33 = getelementptr inbounds i64, ptr %18, i64 %32 + %.idx = shl nsw i64 %28, 3 call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %5) call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) tail call void @_ZN23InstanceStackChunkKlass10do_methodsEP17stackChunkOopDescP17OopIterateClosure(ptr noundef nonnull align 8 dereferenceable(464) %0, ptr noundef nonnull %1, ptr noundef %2) #10 - %34 = icmp ugt ptr %33, %26 + %34 = icmp sgt i64 %.idx, %22 br i1 %34, label %35, label %_ZN23InstanceStackChunkKlass33oop_oop_iterate_stack_with_bitmapIP7oopDesc31ShenandoahMarkUpdateRefsClosureIL24ShenandoahGenerationType0EEEEvP17stackChunkOopDescPT0_PlSA_.exit 35: ; preds = %14 + %31 = sext i32 %15 to i64 + %32 = add nsw i64 %31, %8 + %33 = inttoptr i64 %32 to ptr + %34 = getelementptr inbounds i8, ptr %33, i64 %22 + %35 = getelementptr inbounds i8, ptr %33, i64 %.idx store ptr %1, ptr %5, align 8 %36 = getelementptr inbounds nuw i8, ptr %5, i64 8 store ptr %2, ptr %36, align 8 @@ -10328,10 +10332,10 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s store ptr %47, ptr %6, align 8, !alias.scope !65 %54 = getelementptr inbounds nuw i8, ptr %6, i64 8 store i64 %53, ptr %54, align 8, !alias.scope !65 - %55 = ptrtoint ptr %26 to i64 + %55 = ptrtoint ptr %34 to i64 %56 = sub i64 %55, %44 %57 = ashr exact i64 %56, 3 - %58 = ptrtoint ptr %33 to i64 + %58 = ptrtoint ptr %35 to i64 %59 = sub i64 %58, %44 %60 = ashr exact i64 %59, 3 call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) diff --git a/bench/openjdk/optimized/zMark.ll b/bench/openjdk/optimized/zMark.ll index b34ff262fac..eb68a4acd2b 100644 --- a/bench/openjdk/optimized/zMark.ll +++ b/bench/openjdk/optimized/zMark.ll @@ -9387,15 +9387,17 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s %19 = inttoptr i64 %18 to ptr %20 = load volatile i32, ptr %19, align 4 %21 = sext i32 %20 to i64 - %22 = getelementptr inbounds i64, ptr %15, i64 %21 - %23 = getelementptr inbounds i8, ptr %22, i64 -16 + %.idx9 = shl nsw i64 %21, 3 + %22 = add nsw i64 %.idx9, -16 + %23 = getelementptr inbounds i8, ptr %15, i64 %22 %24 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk12_size_offsetE, align 4 %25 = sext i32 %24 to i64 %26 = add nsw i64 %25, %5 %27 = inttoptr i64 %26 to ptr %28 = load i32, ptr %27, align 4 %29 = sext i32 %28 to i64 - %30 = getelementptr inbounds i64, ptr %15, i64 %29 + %.idx = shl nsw i64 %29, 3 + %30 = getelementptr inbounds i8, ptr %15, i64 %.idx %31 = getelementptr i8, ptr %2, i64 16 %.val.i.i = load i8, ptr %31, align 8 %32 = trunc i8 %.val.i.i to i1 @@ -9406,7 +9408,7 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s br label %34 34: ; preds = %33, %11 - %35 = icmp ugt ptr %30, %23 + %35 = icmp sgt i64 %.idx, %22 br i1 %35, label %36, label %_ZN23InstanceStackChunkKlass33oop_oop_iterate_stack_with_bitmapI9narrowOop28ZMarkBarrierFollowOopClosureILb0EL21ZGenerationIdOptional1EEEEvP17stackChunkOopDescPT0_PlS9_.exit 36: ; preds = %34 @@ -11121,15 +11123,17 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s %19 = inttoptr i64 %18 to ptr %20 = load volatile i32, ptr %19, align 4 %21 = sext i32 %20 to i64 - %22 = getelementptr inbounds i64, ptr %15, i64 %21 - %23 = getelementptr inbounds i8, ptr %22, i64 -16 + %.idx9 = shl nsw i64 %21, 3 + %22 = add nsw i64 %.idx9, -16 + %23 = getelementptr inbounds i8, ptr %15, i64 %22 %24 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk12_size_offsetE, align 4 %25 = sext i32 %24 to i64 %26 = add nsw i64 %25, %5 %27 = inttoptr i64 %26 to ptr %28 = load i32, ptr %27, align 4 %29 = sext i32 %28 to i64 - %30 = getelementptr inbounds i64, ptr %15, i64 %29 + %.idx = shl nsw i64 %29, 3 + %30 = getelementptr inbounds i8, ptr %15, i64 %.idx %31 = getelementptr i8, ptr %2, i64 16 %.val.i.i = load i8, ptr %31, align 8 %32 = trunc i8 %.val.i.i to i1 @@ -11140,7 +11144,7 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s br label %34 34: ; preds = %33, %11 - %35 = icmp ugt ptr %30, %23 + %35 = icmp sgt i64 %.idx, %22 br i1 %35, label %36, label %_ZN23InstanceStackChunkKlass33oop_oop_iterate_stack_with_bitmapI9narrowOop28ZMarkBarrierFollowOopClosureILb1EL21ZGenerationIdOptional1EEEEvP17stackChunkOopDescPT0_PlS9_.exit 36: ; preds = %34 @@ -13340,15 +13344,17 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s %19 = inttoptr i64 %18 to ptr %20 = load volatile i32, ptr %19, align 4 %21 = sext i32 %20 to i64 - %22 = getelementptr inbounds i64, ptr %15, i64 %21 - %23 = getelementptr inbounds i8, ptr %22, i64 -16 + %.idx9 = shl nsw i64 %21, 3 + %22 = add nsw i64 %.idx9, -16 + %23 = getelementptr inbounds i8, ptr %15, i64 %22 %24 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk12_size_offsetE, align 4 %25 = sext i32 %24 to i64 %26 = add nsw i64 %25, %5 %27 = inttoptr i64 %26 to ptr %28 = load i32, ptr %27, align 4 %29 = sext i32 %28 to i64 - %30 = getelementptr inbounds i64, ptr %15, i64 %29 + %.idx = shl nsw i64 %29, 3 + %30 = getelementptr inbounds i8, ptr %15, i64 %.idx %31 = getelementptr i8, ptr %2, i64 16 %.val.i.i = load i8, ptr %31, align 8 %32 = trunc i8 %.val.i.i to i1 @@ -13359,7 +13365,7 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s br label %34 34: ; preds = %33, %11 - %35 = icmp ugt ptr %30, %23 + %35 = icmp sgt i64 %.idx, %22 br i1 %35, label %36, label %_ZN23InstanceStackChunkKlass33oop_oop_iterate_stack_with_bitmapI9narrowOop28ZMarkBarrierFollowOopClosureILb0EL21ZGenerationIdOptional0EEEEvP17stackChunkOopDescPT0_PlS9_.exit 36: ; preds = %34 @@ -13543,15 +13549,17 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s %19 = inttoptr i64 %18 to ptr %20 = load volatile i32, ptr %19, align 4 %21 = sext i32 %20 to i64 - %22 = getelementptr inbounds i64, ptr %15, i64 %21 - %23 = getelementptr inbounds i8, ptr %22, i64 -16 + %.idx9 = shl nsw i64 %21, 3 + %22 = add nsw i64 %.idx9, -16 + %23 = getelementptr inbounds i8, ptr %15, i64 %22 %24 = load i32, ptr @_ZN26jdk_internal_vm_StackChunk12_size_offsetE, align 4 %25 = sext i32 %24 to i64 %26 = add nsw i64 %25, %5 %27 = inttoptr i64 %26 to ptr %28 = load i32, ptr %27, align 4 %29 = sext i32 %28 to i64 - %30 = getelementptr inbounds i64, ptr %15, i64 %29 + %.idx = shl nsw i64 %29, 3 + %30 = getelementptr inbounds i8, ptr %15, i64 %.idx %31 = getelementptr i8, ptr %2, i64 16 %.val.i.i = load i8, ptr %31, align 8 %32 = trunc i8 %.val.i.i to i1 @@ -13562,7 +13570,7 @@ define linkonce_odr hidden void @_ZN23InstanceStackChunkKlass21oop_oop_iterate_s br label %34 34: ; preds = %33, %11 - %35 = icmp ugt ptr %30, %23 + %35 = icmp sgt i64 %.idx, %22 br i1 %35, label %36, label %_ZN23InstanceStackChunkKlass33oop_oop_iterate_stack_with_bitmapIP7oopDesc28ZMarkBarrierFollowOopClosureILb0EL21ZGenerationIdOptional0EEEEvP17stackChunkOopDescPT0_PlSA_.exit 36: ; preds = %34 diff --git a/bench/openspiel/optimized/leduc_poker.ll b/bench/openspiel/optimized/leduc_poker.ll index bd59dc47758..0465dc5d1ba 100644 --- a/bench/openspiel/optimized/leduc_poker.ll +++ b/bench/openspiel/optimized/leduc_poker.ll @@ -4219,8 +4219,8 @@ _ZNSt6vectorIlSaIlEE17_M_realloc_insertIJlEEEvN9__gnu_cxx17__normal_iteratorIPlS br label %.loopexit.split-lp .loopexit.split-lp.loopexit.split-lp: ; preds = %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i80, %180, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i70, %158, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i60, %_ZNSt6vectorIlSaIlEE9push_backEOl.exit48, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i40, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i30, %94, %47, %8 - %61 = phi ptr [ %171, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i80 ], [ %171, %180 ], [ %151, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i70 ], [ %151, %158 ], [ null, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i60 ], [ %129, %_ZNSt6vectorIlSaIlEE9push_backEOl.exit48 ], [ %124, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i40 ], [ null, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i30 ], [ %80, %94 ], [ %30, %47 ], [ null, %8 ] - %62 = phi ptr [ %165, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i80 ], [ %165, %180 ], [ %150, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i70 ], [ %150, %158 ], [ null, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i60 ], [ %125, %_ZNSt6vectorIlSaIlEE9push_backEOl.exit48 ], [ %123, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i40 ], [ null, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i30 ], [ %82, %94 ], [ %32, %47 ], [ null, %8 ] + %61 = phi ptr [ %171, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i80 ], [ %171, %181 ], [ %151, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i70 ], [ %151, %158 ], [ null, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i60 ], [ %129, %_ZNSt6vectorIlSaIlEE9push_backEOl.exit48 ], [ %124, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i40 ], [ null, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i30 ], [ %80, %94 ], [ %30, %47 ], [ null, %8 ] + %62 = phi ptr [ %165, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i80 ], [ %165, %181 ], [ %150, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i70 ], [ %150, %158 ], [ null, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i60 ], [ %125, %_ZNSt6vectorIlSaIlEE9push_backEOl.exit48 ], [ %123, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i40 ], [ null, %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i30 ], [ %82, %94 ], [ %32, %47 ], [ null, %8 ] %lpad.loopexit.split-lp107 = landingpad { ptr, i32 } cleanup br label %.loopexit.split-lp @@ -4470,7 +4470,8 @@ _ZNSt6vectorIlSaIlEE11_S_relocateEPlS2_S2_RS0_.exit16.i.i.i73: ; preds = %168, % _ZNSt6vectorIlSaIlEE9push_backEOl.exit78: ; preds = %_ZNSt6vectorIlSaIlEE11_S_relocateEPlS2_S2_RS0_.exit16.i.i.i73, %170 store ptr %165, ptr %0, align 8 store ptr %169, ptr %152, align 8 - %171 = getelementptr inbounds nuw i64, ptr %165, i64 %163 + %.idx = shl nuw nsw i64 %163, 3 + %171 = getelementptr inbounds nuw i8, ptr %165, i64 %.idx store ptr %171, ptr %153, align 8 %172 = getelementptr inbounds nuw i8, ptr %1, i64 68 %173 = load i32, ptr %172, align 4 @@ -4478,8 +4479,9 @@ _ZNSt6vectorIlSaIlEE9push_backEOl.exit78: ; preds = %_ZNSt6vectorIlSaIlE br i1 %174, label %175, label %_ZNSt6vectorIlSaIlEE9push_backEOl.exit58 175: ; preds = %_ZNSt6vectorIlSaIlEE9push_backEOl.exit78 - %.not.i.i79 = icmp eq ptr %169, %171 - br i1 %.not.i.i79, label %178, label %176 + %176 = add nsw i64 %156, 8 + %.not.i.i79 = icmp eq i64 %176, %.idx + br i1 %.not.i.i79, label %179, label %177 176: ; preds = %175 store i64 2, ptr %169, align 8 @@ -4488,9 +4490,8 @@ _ZNSt6vectorIlSaIlEE9push_backEOl.exit78: ; preds = %_ZNSt6vectorIlSaIlE br label %_ZNSt6vectorIlSaIlEE9push_backEOl.exit58 178: ; preds = %175 - %.idx = shl nuw nsw i64 %163, 3 - %179 = icmp eq i64 %163, 1152921504606846975 - br i1 %179, label %180, label %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i80 + %180 = icmp eq i64 %163, 1152921504606846975 + br i1 %180, label %181, label %_ZNKSt6vectorIlSaIlEE12_M_check_lenEmPKc.exit.i.i.i80 180: ; preds = %178 invoke void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str.82) #27 diff --git a/bench/openssl/optimized/v3_utl.ll b/bench/openssl/optimized/v3_utl.ll index 136cabb91f2..6be030607a1 100644 --- a/bench/openssl/optimized/v3_utl.ll +++ b/bench/openssl/optimized/v3_utl.ll @@ -2810,8 +2810,8 @@ equal_nocase.exit76.i: ; preds = %128, %equal_nocase. 143: ; preds = %140, %138, %.thread.i %.not5483.i = phi i1 [ %.not52.i, %.thread.i ], [ false, %140 ], [ false, %138 ] - %144 = getelementptr inbounds nuw i8, ptr %116, i64 1 - %145 = icmp eq ptr %118, %144 + %144 = add nuw nsw i64 %95, 1 + %145 = icmp samesign eq i64 %117, %144 br i1 %145, label %146, label %149 146: ; preds = %143 diff --git a/bench/openvdb/optimized/Filter.ll b/bench/openvdb/optimized/Filter.ll index 51be5af7383..64d8f82aaf3 100644 --- a/bench/openvdb/optimized/Filter.ll +++ b/bench/openvdb/optimized/Filter.ll @@ -43911,8 +43911,8 @@ if.then3.i: ; preds = %if.then.i %6 = select i1 %3, i64 -1, i64 %5 %call.i = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %6) #26 store i64 %mul.i, ptr %call.i, align 16 - %.ptr.i = getelementptr inbounds nuw i8, ptr %call.i, i64 8 - tail call void @llvm.memset.p0.i64(ptr nonnull align 8 %.ptr.i, i8 0, i64 %4, i1 false) + %.ptr.i = getelementptr i8, ptr %call.i, i64 8 + tail call void @llvm.memset.p0.i64(ptr align 8 %.ptr.i, i8 0, i64 %4, i1 false) %mAuxBufferPtrs.i = getelementptr inbounds nuw i8, ptr %this, i64 48 %7 = load ptr, ptr %mAuxBufferPtrs.i, align 8 store ptr %.ptr.i, ptr %mAuxBufferPtrs.i, align 8 @@ -122407,7 +122407,6 @@ if.then3: ; preds = %if.then %call = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %6) #26 store i64 %mul, ptr %call, align 16 %.ptr = getelementptr inbounds nuw i8, ptr %call, i64 8 - %arrayctor.end = getelementptr inbounds %"class.openvdb::v11_0::tree::LeafBuffer", ptr %.ptr, i64 %mul br label %arrayctor.loop arrayctor.loop: ; preds = %invoke.cont, %if.then3 @@ -122423,8 +122422,8 @@ invoke.cont: ; preds = %arrayctor.loop %mOutOfCore2.i = getelementptr inbounds nuw i8, ptr %arrayctor.cur.ptr.ptr, i64 8 store atomic i32 0, ptr %mOutOfCore2.i seq_cst, align 4 %arrayctor.cur.add = add nuw nsw i64 %arrayctor.cur.idx, 16 - %arrayctor.next.ptr = getelementptr inbounds nuw i8, ptr %call, i64 %arrayctor.cur.add - %arrayctor.done = icmp eq ptr %arrayctor.next.ptr, %arrayctor.end + %7 = add nuw nsw i64 %arrayctor.cur.idx, 8 + %arrayctor.done = icmp eq i64 %7, %4 br i1 %arrayctor.done, label %arrayctor.cont, label %arrayctor.loop arrayctor.cont: ; preds = %invoke.cont @@ -158806,7 +158805,6 @@ if.then3: ; preds = %if.then %call = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %6) #26 store i64 %mul, ptr %call, align 16 %.ptr = getelementptr inbounds nuw i8, ptr %call, i64 8 - %arrayctor.end = getelementptr inbounds %"class.openvdb::v11_0::tree::LeafBuffer.287", ptr %.ptr, i64 %mul br label %arrayctor.loop arrayctor.loop: ; preds = %invoke.cont, %if.then3 @@ -158822,8 +158820,8 @@ invoke.cont: ; preds = %arrayctor.loop %mOutOfCore2.i = getelementptr inbounds nuw i8, ptr %arrayctor.cur.ptr.ptr, i64 8 store atomic i32 0, ptr %mOutOfCore2.i seq_cst, align 4 %arrayctor.cur.add = add nuw nsw i64 %arrayctor.cur.idx, 16 - %arrayctor.next.ptr = getelementptr inbounds nuw i8, ptr %call, i64 %arrayctor.cur.add - %arrayctor.done = icmp eq ptr %arrayctor.next.ptr, %arrayctor.end + %7 = add nuw nsw i64 %arrayctor.cur.idx, 8 + %arrayctor.done = icmp eq i64 %7, %4 br i1 %arrayctor.done, label %arrayctor.cont, label %arrayctor.loop arrayctor.cont: ; preds = %invoke.cont diff --git a/bench/openvdb/optimized/TopologyToLevelSet.ll b/bench/openvdb/optimized/TopologyToLevelSet.ll index b5c76119bd9..7217c6a1cf5 100644 --- a/bench/openvdb/optimized/TopologyToLevelSet.ll +++ b/bench/openvdb/optimized/TopologyToLevelSet.ll @@ -27094,8 +27094,8 @@ if.then3.i: ; preds = %if.then.i %6 = select i1 %3, i64 -1, i64 %5 %call.i = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %6) #26 store i64 %mul.i, ptr %call.i, align 16 - %.ptr.i = getelementptr inbounds nuw i8, ptr %call.i, i64 8 - tail call void @llvm.memset.p0.i64(ptr nonnull align 8 %.ptr.i, i8 0, i64 %4, i1 false) + %.ptr.i = getelementptr i8, ptr %call.i, i64 8 + tail call void @llvm.memset.p0.i64(ptr align 8 %.ptr.i, i8 0, i64 %4, i1 false) %mAuxBufferPtrs.i = getelementptr inbounds nuw i8, ptr %this, i64 48 %7 = load ptr, ptr %mAuxBufferPtrs.i, align 8 store ptr %.ptr.i, ptr %mAuxBufferPtrs.i, align 8 @@ -101288,7 +101288,6 @@ if.then3: ; preds = %if.then %call = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %6) #26 store i64 %mul, ptr %call, align 16 %.ptr = getelementptr inbounds nuw i8, ptr %call, i64 8 - %arrayctor.end = getelementptr inbounds %"class.openvdb::v11_0::tree::LeafBuffer.936", ptr %.ptr, i64 %mul br label %arrayctor.loop arrayctor.loop: ; preds = %invoke.cont, %if.then3 @@ -101304,8 +101303,8 @@ invoke.cont: ; preds = %arrayctor.loop %mOutOfCore2.i = getelementptr inbounds nuw i8, ptr %arrayctor.cur.ptr.ptr, i64 8 store atomic i32 0, ptr %mOutOfCore2.i seq_cst, align 4 %arrayctor.cur.add = add nuw nsw i64 %arrayctor.cur.idx, 16 - %arrayctor.next.ptr = getelementptr inbounds nuw i8, ptr %call, i64 %arrayctor.cur.add - %arrayctor.done = icmp eq ptr %arrayctor.next.ptr, %arrayctor.end + %7 = add nuw nsw i64 %arrayctor.cur.idx, 8 + %arrayctor.done = icmp eq i64 %7, %4 br i1 %arrayctor.done, label %arrayctor.cont, label %arrayctor.loop arrayctor.cont: ; preds = %invoke.cont diff --git a/bench/php/optimized/ftp_fopen_wrapper.ll b/bench/php/optimized/ftp_fopen_wrapper.ll index a7379411cd4..2c046b6e675 100644 --- a/bench/php/optimized/ftp_fopen_wrapper.ll +++ b/bench/php/optimized/ftp_fopen_wrapper.ll @@ -1017,10 +1017,9 @@ get_ftp_result.exit215: ; preds = %201, %.backedge.i21 %222 = getelementptr inbounds nuw i8, ptr %221, i64 16 store i64 %220, ptr %222, align 8, !tbaa !45 %.ptr = getelementptr inbounds nuw i8, ptr %221, i64 24 - %223 = getelementptr inbounds nuw i8, ptr %221, i64 %220 - %.ptr31 = getelementptr inbounds nuw i8, ptr %223, i64 24 - %224 = icmp sgt i64 %220, 0 - br i1 %224, label %.lr.ph, label %._crit_edge + %223 = getelementptr inbounds nuw i8, ptr %223, i64 %220 + %.not31 = icmp eq i64 %220, 0 + br i1 %.not31, label %._crit_edge, label %.lr.ph .lr.ph: ; preds = %216 %225 = tail call ptr @__ctype_b_loc() #18 @@ -1029,7 +1028,7 @@ get_ftp_result.exit215: ; preds = %201, %.backedge.i21 227: ; preds = %230 %228 = getelementptr inbounds nuw i8, ptr %.013726, i64 1 - %229 = icmp ult ptr %228, %.ptr31 + %229 = icmp ult ptr %228, %.ptr br i1 %229, label %230, label %._crit_edge 230: ; preds = %.lr.ph, %227 @@ -1136,10 +1135,9 @@ get_ftp_result.exit224: ; preds = %258, %.backedge.i22 %282 = getelementptr inbounds nuw i8, ptr %281, i64 16 store i64 %280, ptr %282, align 8, !tbaa !45 %.ptr32 = getelementptr inbounds nuw i8, ptr %281, i64 24 - %283 = getelementptr inbounds nuw i8, ptr %281, i64 %280 - %.ptr33 = getelementptr inbounds nuw i8, ptr %283, i64 24 - %284 = icmp sgt i64 %280, 0 - br i1 %284, label %.lr.ph29, label %._crit_edge30 + %283 = getelementptr inbounds nuw i8, ptr %283, i64 %280 + %.not32 = icmp eq i64 %280, 0 + br i1 %.not32, label %._crit_edge30, label %.lr.ph29 .lr.ph29: ; preds = %276 %285 = tail call ptr @__ctype_b_loc() #18 @@ -1148,7 +1146,7 @@ get_ftp_result.exit224: ; preds = %258, %.backedge.i22 287: ; preds = %290 %288 = getelementptr inbounds nuw i8, ptr %.013527, i64 1 - %289 = icmp ult ptr %288, %.ptr33 + %289 = icmp ult ptr %288, %.ptr32 br i1 %289, label %290, label %._crit_edge30 290: ; preds = %.lr.ph29, %287 diff --git a/bench/php/optimized/zend_inheritance.ll b/bench/php/optimized/zend_inheritance.ll index 522fa415a14..0b234b3226b 100644 --- a/bench/php/optimized/zend_inheritance.ll +++ b/bench/php/optimized/zend_inheritance.ll @@ -12970,20 +12970,16 @@ zend_arena_alloc.exit.i: ; preds = %23, %21 %34 = and i32 %33, -30408705 %35 = or disjoint i32 %34, 5242880 store i32 %35, ptr %2, align 8, !tbaa !9 - %36 = load i32, ptr %.0.i.i, align 8, !tbaa !4 - %37 = zext i32 %36 to i64 - %.idx = shl nuw nsw i64 %37, 4 - %38 = getelementptr inbounds nuw i8, ptr %.0.i.i, i64 %.idx - %.ptr8 = getelementptr inbounds nuw i8, ptr %38, i64 8 - %.not9 = icmp eq i32 %36, 0 + %36 = getelementptr inbounds nuw i8, ptr %.0.i.i, i64 8 + %37 = load i32, ptr %.0.i.i, align 8, !tbaa !4 + %38 = zext i32 %37 to i64 + %.idx = shl nuw nsw i64 %38, 4 + %.ptr8 = getelementptr inbounds nuw i8, ptr %36, i64 %.idx + %.not9 = icmp eq i32 %37, 0 br i1 %.not9, label %zend_type_list_copy_ctor.exit, label %.lr.ph.preheader -.lr.ph.preheader: ; preds = %zend_arena_alloc.exit.i - %.ptr = getelementptr inbounds nuw i8, ptr %.0.i.i, i64 8 - br label %.lr.ph - -.lr.ph: ; preds = %.lr.ph.preheader, %.lr.ph - %.0.i67 = phi ptr [ %39, %.lr.ph ], [ %.ptr, %.lr.ph.preheader ] +.lr.ph.preheader: ; preds = %zend_arena_alloc.exit.i, %.lr.ph + %.0.i67 = phi ptr [ %40, %.lr.ph ], [ %36, %zend_arena_alloc.exit.i ] tail call fastcc void @zend_type_copy_ctor(ptr noundef nonnull %.0.i67) %39 = getelementptr inbounds nuw i8, ptr %.0.i67, i64 16 %40 = icmp ult ptr %39, %.ptr8 diff --git a/bench/php/optimized/zend_ini.ll b/bench/php/optimized/zend_ini.ll index fdd5aa25c23..5091de95b95 100644 --- a/bench/php/optimized/zend_ini.ll +++ b/bench/php/optimized/zend_ini.ll @@ -1459,16 +1459,15 @@ define internal fastcc i64 @zend_ini_parse_quantity_internal(ptr noundef %0, i32 %.ptr = getelementptr inbounds nuw i8, ptr %0, i64 24 %9 = getelementptr inbounds nuw i8, ptr %0, i64 16 %10 = load i64, ptr %9, align 8, !tbaa !64 - %11 = getelementptr inbounds nuw i8, ptr %0, i64 %10 - %.ptr217 = getelementptr inbounds nuw i8, ptr %11, i64 24 + %11 = getelementptr inbounds nuw i8, ptr %9, i64 %10 call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #18 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %6, i8 0, i64 16, i1 false) call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %7) #18 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %7, i8 0, i64 16, i1 false) call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %8) #18 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %8, i8 0, i64 16, i1 false) - %12 = icmp sgt i64 %10, 0 - br i1 %12, label %.lr.ph, label %.critedge + %12 = icmp eq i64 %10, 0 + br i1 %12, label %.critedge, label %.lr.ph .lr.ph: ; preds = %3, %14 %.0109202 = phi ptr [ %15, %14 ], [ %.ptr, %3 ] @@ -1484,12 +1483,12 @@ define internal fastcc i64 @zend_ini_parse_quantity_internal(ptr noundef %0, i32 14: ; preds = %.lr.ph, %.lr.ph, %.lr.ph, %.lr.ph, %.lr.ph, %.lr.ph %15 = getelementptr inbounds nuw i8, ptr %.0109202, i64 1 - %16 = icmp ult ptr %15, %.ptr217 + %16 = icmp ult ptr %15, %12 br i1 %16, label %.lr.ph, label %.critedge .critedge: ; preds = %14, %.lr.ph, %3 %.0109.lcssa = phi ptr [ %.ptr, %3 ], [ %.0109202, %.lr.ph ], [ %15, %14 ] - %17 = icmp ult ptr %.0109.lcssa, %.ptr217 + %17 = icmp ult ptr %.0109.lcssa, %12 br i1 %17, label %.lr.ph206.preheader, label %.critedge2 .lr.ph206.preheader: ; preds = %.critedge @@ -1499,7 +1498,7 @@ define internal fastcc i64 @zend_ini_parse_quantity_internal(ptr noundef %0, i32 br label %.lr.ph206 .lr.ph206: ; preds = %.lr.ph206.preheader, %zend_is_whitespace.exit193 - %.0112205 = phi ptr [ %19, %zend_is_whitespace.exit193 ], [ %.ptr217, %.lr.ph206.preheader ] + %.0112205 = phi ptr [ %19, %zend_is_whitespace.exit193 ], [ %12, %.lr.ph206.preheader ] %19 = getelementptr inbounds i8, ptr %.0112205, i64 -1 %20 = load i8, ptr %19, align 1, !tbaa !43 switch i8 %20, label %.critedge2 [ @@ -1516,7 +1515,7 @@ zend_is_whitespace.exit193: ; preds = %.lr.ph206, %.lr.ph2 br i1 %21, label %.lr.ph206, label %.critedge2 .critedge2: ; preds = %zend_is_whitespace.exit193, %.lr.ph206, %.critedge - %.0112.lcssa = phi ptr [ %.ptr217, %.critedge ], [ %.0112205, %.lr.ph206 ], [ %scevgep, %zend_is_whitespace.exit193 ] + %.0112.lcssa = phi ptr [ %12, %.critedge ], [ %.0112205, %.lr.ph206 ], [ %scevgep, %zend_is_whitespace.exit193 ] %.0112.lcssa221 = ptrtoint ptr %.0112.lcssa to i64 %22 = icmp eq ptr %.0109.lcssa, %.0112.lcssa br i1 %22, label %23, label %24 diff --git a/bench/pola-rs/optimized/1qyqkb8vgycy6h5akbtqppixy.ll b/bench/pola-rs/optimized/1qyqkb8vgycy6h5akbtqppixy.ll index dcccfb8bb9c..07f13722c35 100644 --- a/bench/pola-rs/optimized/1qyqkb8vgycy6h5akbtqppixy.ll +++ b/bench/pola-rs/optimized/1qyqkb8vgycy6h5akbtqppixy.ll @@ -34872,26 +34872,22 @@ define hidden void @_ZN12polars_arrow2io3ipc5write9serialize7binview13write_binv %15 = load ptr, ptr %14, align 8, !nonnull !10, !noundef !10 %16 = getelementptr inbounds nuw i8, ptr %0, i64 64 %17 = load i64, ptr %16, align 8, !noundef !10 + %18 = getelementptr inbounds nuw i8, ptr %15, i64 16 %.idx = mul nuw nsw i64 %17, 24 - %18 = getelementptr inbounds nuw i8, ptr %15, i64 %.idx - %.ptr4 = getelementptr inbounds nuw i8, ptr %18, i64 16 - %19 = icmp eq i64 %17, 0 - br i1 %19, label %._crit_edge, label %.lr.ph.preheader - -.lr.ph.preheader: ; preds = %6 - %.ptr = getelementptr inbounds nuw i8, ptr %15, i64 16 - br label %.lr.ph - -.lr.ph: ; preds = %.lr.ph.preheader, %.lr.ph - %.sroa.02.03 = phi ptr [ %20, %.lr.ph ], [ %.ptr, %.lr.ph.preheader ] - %20 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 24 - %21 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 8 - %22 = load ptr, ptr %21, align 8, !noundef !10 - %23 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 16 - %24 = load i64, ptr %23, align 8, !noundef !10 - tail call void @_ZN12polars_arrow2io3ipc5write9serialize11write_bytes17h8cad35ef6b156f9cE(ptr noalias noundef nonnull readonly align 1 %22, i64 noundef %24, ptr noalias noundef nonnull align 8 dereferenceable(24) %1, ptr noalias noundef nonnull align 8 dereferenceable(24) %2, ptr noalias noundef nonnull align 8 dereferenceable(8) %3, i8 noundef %5) - %25 = icmp eq ptr %20, %.ptr4 - br i1 %25, label %._crit_edge, label %.lr.ph + %18 = getelementptr inbounds nuw i8, ptr %18, i64 %.idx + %20 = icmp eq i64 %17, 0 + br i1 %20, label %._crit_edge, label %.lr.ph + +.lr.ph: ; preds = %6, %.lr.ph + %.sroa.02.03 = phi ptr [ %21, %.lr.ph ], [ %18, %6 ] + %.ptr = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 24 + %22 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 8 + %23 = load ptr, ptr %22, align 8, !noundef !10 + %24 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 16 + %25 = load i64, ptr %24, align 8, !noundef !10 + tail call void @_ZN12polars_arrow2io3ipc5write9serialize11write_bytes17h8cad35ef6b156f9cE(ptr noalias noundef nonnull readonly align 1 %23, i64 noundef %25, ptr noalias noundef nonnull align 8 dereferenceable(24) %1, ptr noalias noundef nonnull align 8 dereferenceable(24) %2, ptr noalias noundef nonnull align 8 dereferenceable(8) %3, i8 noundef %5) + %26 = icmp eq ptr %.ptr, %18 + br i1 %26, label %._crit_edge, label %.lr.ph ._crit_edge: ; preds = %.lr.ph, %6 ret void @@ -34914,26 +34910,22 @@ define hidden void @_ZN12polars_arrow2io3ipc5write9serialize7binview13write_binv %15 = load ptr, ptr %14, align 8, !nonnull !10, !noundef !10 %16 = getelementptr inbounds nuw i8, ptr %0, i64 64 %17 = load i64, ptr %16, align 8, !noundef !10 + %18 = getelementptr inbounds nuw i8, ptr %15, i64 16 %.idx = mul nuw nsw i64 %17, 24 - %18 = getelementptr inbounds nuw i8, ptr %15, i64 %.idx - %.ptr4 = getelementptr inbounds nuw i8, ptr %18, i64 16 - %19 = icmp eq i64 %17, 0 - br i1 %19, label %._crit_edge, label %.lr.ph.preheader - -.lr.ph.preheader: ; preds = %6 - %.ptr = getelementptr inbounds nuw i8, ptr %15, i64 16 - br label %.lr.ph - -.lr.ph: ; preds = %.lr.ph.preheader, %.lr.ph - %.sroa.02.03 = phi ptr [ %20, %.lr.ph ], [ %.ptr, %.lr.ph.preheader ] - %20 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 24 - %21 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 8 - %22 = load ptr, ptr %21, align 8, !noundef !10 - %23 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 16 - %24 = load i64, ptr %23, align 8, !noundef !10 - tail call void @_ZN12polars_arrow2io3ipc5write9serialize11write_bytes17h8cad35ef6b156f9cE(ptr noalias noundef nonnull readonly align 1 %22, i64 noundef %24, ptr noalias noundef nonnull align 8 dereferenceable(24) %1, ptr noalias noundef nonnull align 8 dereferenceable(24) %2, ptr noalias noundef nonnull align 8 dereferenceable(8) %3, i8 noundef %5) - %25 = icmp eq ptr %20, %.ptr4 - br i1 %25, label %._crit_edge, label %.lr.ph + %18 = getelementptr inbounds nuw i8, ptr %18, i64 %.idx + %20 = icmp eq i64 %17, 0 + br i1 %20, label %._crit_edge, label %.lr.ph + +.lr.ph: ; preds = %6, %.lr.ph + %.sroa.02.03 = phi ptr [ %21, %.lr.ph ], [ %18, %6 ] + %.ptr = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 24 + %22 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 8 + %23 = load ptr, ptr %22, align 8, !noundef !10 + %24 = getelementptr inbounds nuw i8, ptr %.sroa.02.03, i64 16 + %25 = load i64, ptr %24, align 8, !noundef !10 + tail call void @_ZN12polars_arrow2io3ipc5write9serialize11write_bytes17h8cad35ef6b156f9cE(ptr noalias noundef nonnull readonly align 1 %23, i64 noundef %25, ptr noalias noundef nonnull align 8 dereferenceable(24) %1, ptr noalias noundef nonnull align 8 dereferenceable(24) %2, ptr noalias noundef nonnull align 8 dereferenceable(8) %3, i8 noundef %5) + %26 = icmp eq ptr %.ptr, %18 + br i1 %26, label %._crit_edge, label %.lr.ph ._crit_edge: ; preds = %.lr.ph, %6 ret void diff --git a/bench/pola-rs/optimized/4uf3zemqcz1kz37kef2sjlzv9.ll b/bench/pola-rs/optimized/4uf3zemqcz1kz37kef2sjlzv9.ll index 479bef2a63d..41e7419288b 100644 --- a/bench/pola-rs/optimized/4uf3zemqcz1kz37kef2sjlzv9.ll +++ b/bench/pola-rs/optimized/4uf3zemqcz1kz37kef2sjlzv9.ll @@ -1316,28 +1316,24 @@ define hidden void @"_ZN102_$LT$core..iter..adapters..map..Map$LT$I$C$F$GT$$u20$ store i64 0, ptr %20, align 8, !noalias !293 %33 = load ptr, ptr %21, align 8, !noalias !293, !nonnull !8, !noundef !8 %34 = load i64, ptr %22, align 8, !noalias !293, !noundef !8 + %35 = getelementptr inbounds nuw i8, ptr %33, i64 16 %.idx.i.i.i = mul nuw nsw i64 %34, 48 - %35 = getelementptr inbounds nuw i8, ptr %33, i64 %.idx.i.i.i - %.ptr5.i.i.i = getelementptr inbounds nuw i8, ptr %35, i64 16 - %36 = icmp eq i64 %34, 0 - br i1 %36, label %"_ZN4core4iter8adapters3map8map_fold28_$u7b$$u7b$closure$u7d$$u7d$17h7d0eb1dadc2c9277E.exit.i", label %.lr.ph.preheader.i.i.i - -.lr.ph.preheader.i.i.i: ; preds = %"_ZN5alloc7raw_vec20RawVecInner$LT$A$GT$16with_capacity_in17h2633a07d41beddf7E.exit.i.i.i" - %.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %33, i64 16 - br label %.lr.ph.i.i.i - -.lr.ph.i.i.i: ; preds = %53, %.lr.ph.preheader.i.i.i - %.sroa.02.04.i.i.i = phi ptr [ %37, %53 ], [ %.ptr.i.i.i, %.lr.ph.preheader.i.i.i ] - %37 = getelementptr inbounds nuw i8, ptr %.sroa.02.04.i.i.i, i64 48 + %35 = getelementptr inbounds nuw i8, ptr %35, i64 %.idx.i.i.i + %37 = icmp eq i64 %34, 0 + br i1 %37, label %"_ZN4core4iter8adapters3map8map_fold28_$u7b$$u7b$closure$u7d$$u7d$17h7d0eb1dadc2c9277E.exit.i", label %.lr.ph.i.i.i + +.lr.ph.i.i.i: ; preds = %"_ZN5alloc7raw_vec20RawVecInner$LT$A$GT$16with_capacity_in17h2633a07d41beddf7E.exit.i.i.i", %54 + %.sroa.02.04.i.i.i = phi ptr [ %.ptr.i.i.i, %54 ], [ %35, %"_ZN5alloc7raw_vec20RawVecInner$LT$A$GT$16with_capacity_in17h2633a07d41beddf7E.exit.i.i.i" ] + %.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %.sroa.02.04.i.i.i, i64 48 call void @llvm.lifetime.start.p0(i64 192, ptr nonnull %6), !noalias !293 call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %5), !noalias !293 invoke void @_ZN11polars_core9datatypes5dtype8DataType11to_physical17h0cdda09962ceb56aE(ptr noalias noundef nonnull sret([48 x i8]) align 16 captures(none) dereferenceable(48) %5, ptr noalias noundef nonnull readonly align 16 dereferenceable(48) %.sroa.02.04.i.i.i) - to label %40 unwind label %38, !noalias !293 + to label %41 unwind label %38, !noalias !293 .body.i.i.i: ; preds = %58, %49, %41, %38 - %.pn.i.i.i = phi { ptr, i32 } [ %59, %58 ], [ %42, %41 ], [ %39, %38 ], [ %50, %49 ] + %.pn.i.i.i = phi { ptr, i32 } [ %59, %59 ], [ %42, %42 ], [ %39, %39 ], [ %50, %50 ] invoke void @"_ZN4core3ptr101drop_in_place$LT$alloc..vec..Vec$LT$polars_core..frame..row..av_buffer..AnyValueBufferTrusted$GT$$GT$17h8ad8d8b9c75453aeE"(ptr noalias noundef nonnull align 8 dereferenceable(24) %7) #28 - to label %64 unwind label %60, !noalias !293 + to label %65 unwind label %60, !noalias !293 38: ; preds = %.lr.ph.i.i.i %39 = landingpad { ptr, i32 } @@ -1346,7 +1342,7 @@ define hidden void @"_ZN102_$LT$core..iter..adapters..map..Map$LT$I$C$F$GT$$u20$ 40: ; preds = %.lr.ph.i.i.i invoke void @_ZN11polars_core5frame3row9av_buffer21AnyValueBufferTrusted3new17h44072b76c30ce832E(ptr noalias noundef nonnull sret([192 x i8]) align 16 captures(none) dereferenceable(192) %6, ptr noalias noundef nonnull readonly align 16 dereferenceable(48) %5, i64 noundef 2048) - to label %43 unwind label %41, !noalias !293 + to label %44 unwind label %41, !noalias !293 41: ; preds = %40 %42 = landingpad { ptr, i32 } @@ -1356,7 +1352,7 @@ define hidden void @"_ZN102_$LT$core..iter..adapters..map..Map$LT$I$C$F$GT$$u20$ 43: ; preds = %40 invoke fastcc void @"_ZN4core3ptr60drop_in_place$LT$polars_core..datatypes..dtype..DataType$GT$17h0fed66dd9d11ad99E"(ptr noalias noundef align 16 dereferenceable(48) %5) - to label %44 unwind label %58, !noalias !293 + to label %45 unwind label %58, !noalias !293 44: ; preds = %43 call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %5), !noalias !293 @@ -1369,7 +1365,7 @@ define hidden void @"_ZN102_$LT$core..iter..adapters..map..Map$LT$I$C$F$GT$$u20$ 48: ; preds = %44 invoke void @"_ZN5alloc7raw_vec19RawVec$LT$T$C$A$GT$8grow_one17hdba395edf9811869E"(ptr noalias noundef nonnull align 8 dereferenceable(24) %7, ptr noalias noundef readonly align 8 dereferenceable(24) @anon.a8bceeb47690a2fcf8f8d022b0e6f8bb.189) - to label %53 unwind label %49, !noalias !307 + to label %54 unwind label %49, !noalias !307 49: ; preds = %48 %50 = landingpad { ptr, i32 } @@ -1391,7 +1387,7 @@ define hidden void @"_ZN102_$LT$core..iter..adapters..map..Map$LT$I$C$F$GT$$u20$ store i64 %56, ptr %20, align 8, !alias.scope !304, !noalias !307 call void @llvm.lifetime.end.p0(i64 192, ptr nonnull %4), !noalias !293 call void @llvm.lifetime.end.p0(i64 192, ptr nonnull %6), !noalias !293 - %57 = icmp eq ptr %37, %.ptr5.i.i.i + %57 = icmp eq ptr %.ptr.i.i.i, %35 br i1 %57, label %"_ZN4core4iter8adapters3map8map_fold28_$u7b$$u7b$closure$u7d$$u7d$17h7d0eb1dadc2c9277E.exit.i", label %.lr.ph.i.i.i 58: ; preds = %43 diff --git a/bench/pola-rs/optimized/5igj4k372mlhkf3aildnxq1ta.ll b/bench/pola-rs/optimized/5igj4k372mlhkf3aildnxq1ta.ll index 19d75918eb8..94abc0ef798 100644 --- a/bench/pola-rs/optimized/5igj4k372mlhkf3aildnxq1ta.ll +++ b/bench/pola-rs/optimized/5igj4k372mlhkf3aildnxq1ta.ll @@ -157004,15 +157004,11 @@ define internal fastcc void @"_ZN11polars_plan5plans10conversion9dsl_to_ir11to_a store ptr %21, ptr %12, align 8 %26 = getelementptr inbounds nuw i8, ptr %12, i64 8 store i64 %23, ptr %26, align 8 + %27 = getelementptr inbounds nuw i8, ptr %21, i64 16 %.idx = mul nuw nsw i64 %23, 24 - %27 = getelementptr inbounds nuw i8, ptr %21, i64 %.idx - %.ptr50 = getelementptr inbounds nuw i8, ptr %27, i64 16 - %28 = icmp eq i64 %23, 0 - br i1 %28, label %._crit_edge, label %.lr.ph.preheader - -.lr.ph.preheader: ; preds = %25 - %.ptr = getelementptr inbounds nuw i8, ptr %21, i64 16 - br label %.lr.ph + %27 = getelementptr inbounds nuw i8, ptr %27, i64 %.idx + %29 = icmp eq i64 %23, 0 + br i1 %29, label %._crit_edge, label %.lr.ph ._crit_edge.loopexit: ; preds = %62 %.pre = load ptr, ptr %12, align 8 @@ -157040,7 +157036,7 @@ define internal fastcc void @"_ZN11polars_plan5plans10conversion9dsl_to_ir11to_a br label %.body .body: ; preds = %.loopexit, %.loopexit.split-lp, %51 - %eh.lpad-body = phi { ptr, i32 } [ %52, %51 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] + %eh.lpad-body = phi { ptr, i32 } [ %52, %52 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] call void @llvm.experimental.noalias.scope.decl(metadata !16807) call void @llvm.experimental.noalias.scope.decl(metadata !16810) %33 = load ptr, ptr %12, align 8, !alias.scope !16813, !nonnull !7, !noundef !7 @@ -157053,8 +157049,8 @@ define internal fastcc void @"_ZN11polars_plan5plans10conversion9dsl_to_ir11to_a invoke void @"_ZN5alloc4sync16Arc$LT$T$C$A$GT$9drop_slow17h287f2578538a449eE"(ptr noalias noundef nonnull align 8 dereferenceable(16) %12) to label %"_ZN4core3ptr87drop_in_place$LT$alloc..sync..Arc$LT$$u5b$polars_utils..pl_str..PlSmallStr$u5d$$GT$$GT$17h91fc4b3ad394aa84E.exit" unwind label %64 -.lr.ph: ; preds = %.lr.ph.preheader, %62 - %.sroa.040.049 = phi ptr [ %37, %62 ], [ %.ptr, %.lr.ph.preheader ] +.lr.ph: ; preds = %25, %62 + %.sroa.040.049 = phi ptr [ %37, %63 ], [ %27, %25 ] %37 = getelementptr inbounds nuw i8, ptr %.sroa.040.049, i64 24 store ptr %.sroa.040.049, ptr %10, align 8 %38 = load ptr, ptr %.sroa.018.0, align 8, !nonnull !7, !noundef !7 @@ -157071,7 +157067,7 @@ define internal fastcc void @"_ZN11polars_plan5plans10conversion9dsl_to_ir11to_a %.sroa.01.0.i = select i1 %41, i64 %46, i64 %.sroa.0.0.sroa.speculated.i.i %47 = getelementptr inbounds nuw i8, ptr %38, i64 16 invoke void @"_ZN13polars_schema6schema15Schema$LT$D$GT$7try_get17hf8887abe3af6aee8E"(ptr noalias noundef nonnull sret([64 x i8]) align 8 captures(none) dereferenceable(64) %9, ptr noalias noundef nonnull readonly align 8 dereferenceable(64) %47, ptr noalias noundef nonnull readonly align 1 %spec.select.i, i64 noundef %.sroa.01.0.i) - to label %48 unwind label %.loopexit + to label %49 unwind label %.loopexit 48: ; preds = %.lr.ph %49 = load i64, ptr %9, align 8, !range !869, !noundef !7 @@ -157099,7 +157095,7 @@ define internal fastcc void @"_ZN11polars_plan5plans10conversion9dsl_to_ir11to_a %.sroa.7.0..sroa_idx.i = getelementptr inbounds nuw i8, ptr %4, i64 32 store ptr null, ptr %.sroa.7.0..sroa_idx.i, align 8, !noalias !16830 invoke void @_ZN5alloc3fmt6format12format_inner17h1e07221face03266E(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %6, ptr noalias noundef nonnull align 8 captures(none) dereferenceable(48) %4) - to label %53 unwind label %51, !noalias !16831 + to label %54 unwind label %51, !noalias !16831 51: ; preds = %53, %50 %52 = landingpad { ptr, i32 } @@ -157111,13 +157107,13 @@ define internal fastcc void @"_ZN11polars_plan5plans10conversion9dsl_to_ir11to_a call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4), !noalias !16822 call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %5), !noalias !16817 invoke void @"_ZN72_$LT$polars_error..ErrString$u20$as$u20$core..convert..From$LT$T$GT$$GT$4from17h2d0c90ec046fd40aE"(ptr noalias noundef nonnull sret([24 x i8]) align 8 captures(none) dereferenceable(24) %7, ptr noalias noundef nonnull align 8 captures(none) dereferenceable(24) %6) - to label %54 unwind label %51, !noalias !16831 + to label %55 unwind label %51, !noalias !16831 54: ; preds = %53 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.448, ptr noundef nonnull align 8 dereferenceable(24) %7, i64 24, i1 false), !noalias !16833 call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7), !noalias !16817 invoke void @"_ZN4core3ptr46drop_in_place$LT$polars_error..PolarsError$GT$17h2a38457a7cd22fc5E"(ptr noalias noundef nonnull align 8 dereferenceable(64) %8) - to label %57 unwind label %.loopexit.split-lp + to label %58 unwind label %.loopexit.split-lp 55: ; preds = %51 %56 = landingpad { ptr, i32 } @@ -157152,7 +157148,7 @@ define internal fastcc void @"_ZN11polars_plan5plans10conversion9dsl_to_ir11to_a br label %"_ZN4core3ptr87drop_in_place$LT$alloc..sync..Arc$LT$$u5b$polars_utils..pl_str..PlSmallStr$u5d$$GT$$GT$17h91fc4b3ad394aa84E.exit47" 62: ; preds = %48 - %63 = icmp eq ptr %37, %.ptr50 + %63 = icmp eq ptr %37, %28 br i1 %63, label %._crit_edge.loopexit, label %.lr.ph 64: ; preds = %36 diff --git a/bench/postgres/optimized/guc.ll b/bench/postgres/optimized/guc.ll index d93bf41258a..41dbe801fca 100644 --- a/bench/postgres/optimized/guc.ll +++ b/bench/postgres/optimized/guc.ll @@ -10503,8 +10503,8 @@ can_skip_gucvar.exit.thread: ; preds = %.lr.ph, %can_skip_g select.unfold._crit_edge: ; preds = %can_skip_gucvar.exit.thread, %1 %.0.copyload = load i64, ptr %0, align 1 - %76 = getelementptr inbounds nuw i8, ptr %0, i64 %.0.copyload - %.ptr158 = getelementptr inbounds nuw i8, ptr %76, i64 8 + %76 = getelementptr inbounds nuw i8, ptr %0, i64 8 + %.ptr158 = getelementptr inbounds nuw i8, ptr %76, i64 %.0.copyload %77 = getelementptr inbounds nuw i8, ptr %2, i64 8 store ptr @guc_restore_error_context_callback, ptr %77, align 8 %78 = load ptr, ptr @error_context_stack, align 8 @@ -10512,16 +10512,15 @@ select.unfold._crit_edge: ; preds = %can_skip_gucvar.exi %79 = getelementptr inbounds nuw i8, ptr %2, i64 16 store ptr null, ptr %79, align 8 store ptr %2, ptr @error_context_stack, align 8 - %80 = icmp sgt i64 %.0.copyload, 0 - br i1 %80, label %.lr.ph157, label %._crit_edge + %80 = icmp eq i64 %.0.copyload, 0 + br i1 %80, label %._crit_edge, label %.lr.ph157 .lr.ph157: ; preds = %select.unfold._crit_edge - %.ptr = getelementptr inbounds nuw i8, ptr %0, i64 8 %81 = getelementptr inbounds nuw i8, ptr %3, i64 8 br label %82 82: ; preds = %.lr.ph157, %140 - %.0156 = phi ptr [ %.ptr, %.lr.ph157 ], [ %124, %140 ] + %.0156 = phi ptr [ %76, %.lr.ph157 ], [ %124, %140 ] call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %3) #29 br label %.preheader.i @@ -10639,7 +10638,7 @@ read_gucstate_binary.exit: ; preds = %105 read_gucstate_binary.exit119: ; preds = %112 %118 = load i32, ptr %.1, align 1 %119 = getelementptr inbounds nuw i8, ptr %.1, i64 8 - %120 = icmp ugt ptr %.1, %76 + %120 = icmp ugt ptr %119, %77 br i1 %120, label %121, label %read_gucstate_binary.exit120 121: ; preds = %read_gucstate_binary.exit119 diff --git a/bench/postgres/optimized/ruleutils.ll b/bench/postgres/optimized/ruleutils.ll index d1e7d3ebd8d..182ccf726cf 100644 --- a/bench/postgres/optimized/ruleutils.ll +++ b/bench/postgres/optimized/ruleutils.ll @@ -19223,7 +19223,8 @@ define internal fastcc ptr @find_param_referent(ptr noundef readonly captures(no 22: ; preds = %.lr.ph265, %.thread135 %.090208264 = phi ptr [ %20, %.lr.ph265 ], [ %.191.ph, %.thread135 ] %indvars.iv230262 = phi i64 [ 0, %.lr.ph265 ], [ %indvars.iv.next231, %.thread135 ] - %23 = getelementptr inbounds nuw %union.ListCell, ptr %21, i64 %indvars.iv230262 + %.idx = shl nuw nsw i64 %indvars.iv230262, 3 + %23 = getelementptr inbounds nuw i8, ptr %21, i64 %.idx %24 = load ptr, ptr %23, align 8 %25 = load i32, ptr %24, align 4 switch i32 %25, label %.thread135 [ @@ -19271,7 +19272,7 @@ define internal fastcc ptr @find_param_referent(ptr noundef readonly captures(no br i1 %.not113, label %.split, label %39 .split: ; preds = %40 - %45 = getelementptr inbounds nuw %union.ListCell, ptr %21, i64 %indvars.iv230262 + %45 = getelementptr inbounds nuw i8, ptr %21, i64 %.idx store ptr %12, ptr %2, align 8 store ptr %45, ptr %3, align 8 %46 = getelementptr inbounds nuw i8, ptr %42, i64 8 @@ -19305,7 +19306,7 @@ thread-pre-split: ; preds = %39 br label %61 61: ; preds = %100, %.split190.split - %indvars.iv225 = phi i64 [ %indvars.iv.next226, %100 ], [ 0, %.split190.split ] + %indvars.iv225 = phi i64 [ %indvars.iv.next226, %101 ], [ 0, %.split190.split ] %62 = icmp slt i64 %indvars.iv225, %60 br i1 %62, label %63, label %66 @@ -19333,26 +19334,27 @@ thread-pre-split: ; preds = %39 br i1 %76, label %for_each_cell_setup.exit.split, label %100 for_each_cell_setup.exit.split: ; preds = %73 - %77 = getelementptr inbounds nuw %union.ListCell, ptr %21, i64 %indvars.iv230262 + %77 = getelementptr inbounds nuw i8, ptr %21, i64 %.idx %78 = and i64 %indvars.iv225, 4294967295 %79 = getelementptr inbounds nuw %union.ListCell, ptr %69, i64 %78 %80 = load ptr, ptr %79, align 8 %81 = getelementptr inbounds nuw i8, ptr %77, i64 8 %82 = zext nneg i32 %16 to i64 - %83 = getelementptr inbounds nuw %union.ListCell, ptr %21, i64 %82 - %.not177 = icmp ult ptr %81, %83 - %..i = select i1 %.not177, ptr %81, ptr null - %84 = ptrtoint ptr %..i to i64 - %85 = ptrtoint ptr %21 to i64 - %86 = sub i64 %84, %85 - %87 = lshr exact i64 %86, 3 - %88 = trunc i64 %87 to i32 - %89 = select i1 %.not177, i32 %88, i32 %16 - %90 = icmp slt i32 %89, %16 - br i1 %90, label %.lr.ph214, label %._crit_edge + %.idx241 = shl nuw nsw i64 %82, 3 + %83 = add nuw nsw i64 %.idx, 8 + %.not177 = icmp samesign ult i64 %83, %.idx241 + %84 = ptrtoint ptr %81 to i64 + %85 = select i1 %.not177, i64 %84, i64 0 + %86 = ptrtoint ptr %21 to i64 + %87 = sub i64 %85, %86 + %88 = lshr exact i64 %87, 3 + %89 = trunc i64 %88 to i32 + %90 = select i1 %.not177, i32 %89, i32 %16 + %91 = icmp slt i32 %90, %16 + br i1 %91, label %.lr.ph214, label %._crit_edge .lr.ph214: ; preds = %for_each_cell_setup.exit.split - %91 = sext i32 %89 to i64 + %91 = sext i32 %90 to i64 br label %93 92: ; preds = %93 @@ -19361,7 +19363,7 @@ for_each_cell_setup.exit.split: ; preds = %73 br i1 %exitcond240.not, label %._crit_edge, label %93, !llvm.loop !62 93: ; preds = %.lr.ph214, %92 - %indvars.iv236 = phi i64 [ %91, %.lr.ph214 ], [ %indvars.iv.next237, %92 ] + %indvars.iv236 = phi i64 [ %91, %.lr.ph214 ], [ %indvars.iv.next237, %93 ] %94 = getelementptr inbounds %union.ListCell, ptr %21, i64 %indvars.iv236 %95 = load ptr, ptr %94, align 8 %96 = load i32, ptr %95, align 4 @@ -19392,7 +19394,7 @@ for_each_cell_setup.exit.split: ; preds = %73 br i1 %exitcond235.not, label %.thread174, label %22 .thread174: ; preds = %.thread135, %.lr.ph209, %8, %4, %.split, %101 - %.14 = phi ptr [ %80, %101 ], [ %47, %.split ], [ null, %4 ], [ null, %8 ], [ null, %.lr.ph209 ], [ null, %.thread135 ] + %.14 = phi ptr [ %80, %102 ], [ %47, %.split ], [ null, %4 ], [ null, %8 ], [ null, %.lr.ph209 ], [ null, %.thread135 ] ret ptr %.14 } diff --git a/bench/proj/optimized/horner.ll b/bench/proj/optimized/horner.ll index 459f8d567bd..6c1937a1822 100644 --- a/bench/proj/optimized/horner.ll +++ b/bench/proj/optimized/horner.ll @@ -682,68 +682,73 @@ _ZL19coords_out_of_rangeP8PJconstsPKN12_GLOBAL__N_16hornerEdd.exit.i: ; preds = br label %22 22: ; preds = %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i, %_ZL19coords_out_of_rangeP8PJconstsPKN12_GLOBAL__N_16hornerEdd.exit.i - %23 = phi i32 [ 31, %_ZL19coords_out_of_rangeP8PJconstsPKN12_GLOBAL__N_16hornerEdd.exit.i ], [ %56, %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i ] + %23 = phi i32 [ 31, %_ZL19coords_out_of_rangeP8PJconstsPKN12_GLOBAL__N_16hornerEdd.exit.i ], [ %53, %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i ] %.sroa.7.048.i = phi double [ 0.000000e+00, %_ZL19coords_out_of_rangeP8PJconstsPKN12_GLOBAL__N_16hornerEdd.exit.i ], [ %48, %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i ] %.sroa.038.047.i = phi double [ 0.000000e+00, %_ZL19coords_out_of_rangeP8PJconstsPKN12_GLOBAL__N_16hornerEdd.exit.i ], [ %47, %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i ] %24 = load ptr, ptr %14, align 8, !tbaa !46 %25 = load i32, ptr %21, align 8, !tbaa !43 %26 = shl i32 %25, 1 %27 = add i32 %26, 2 - %28 = getelementptr inbounds nuw i8, ptr %24, i64 16 - %29 = zext i32 %27 to i64 - %.idx.i = shl nuw nsw i64 %29, 3 - %.ptr.i = getelementptr i8, ptr %24, i64 %.idx.i - %30 = getelementptr inbounds i8, ptr %.ptr.i, i64 -8 - %31 = load double, ptr %30, align 8, !tbaa !62 - %.ptr45.i = getelementptr i8, ptr %.ptr.i, i64 -16 + %28 = zext i32 %27 to i64 + %.idx.i = shl nuw nsw i64 %28, 3 + %.ptr45.i = getelementptr inbounds nuw i8, ptr %24, i64 %.idx.i.i + %.ptr.i = getelementptr inbounds i8, ptr %.ptr45.i, i64 -8 + %30 = load double, ptr %.ptr.i, align 8, !tbaa !62 + %.add.i = add nsw i64 %.idx.i, -16 + %.ptr45.i = getelementptr inbounds i8, ptr %24, i64 %.add.i %32 = load double, ptr %.ptr45.i, align 8, !tbaa !62 %33 = icmp ugt i32 %27, 4 br i1 %33, label %.lr.ph.i.i, label %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i -.lr.ph.i.i: ; preds = %22, %.lr.ph.i.i - %.027.i.i = phi ptr [ %42, %.lr.ph.i.i ], [ %.ptr45.i, %22 ] - %.02326.i.i = phi double [ %44, %.lr.ph.i.i ], [ %32, %22 ] - %.02425.i.i = phi double [ %38, %.lr.ph.i.i ], [ %31, %22 ] - %34 = fmul double %.sroa.7.048.i, %.02326.i.i - %35 = tail call double @llvm.fmuladd.f64(double %.sroa.038.047.i, double %.02425.i.i, double %34) - %36 = getelementptr inbounds i8, ptr %.027.i.i, i64 -8 - %37 = load double, ptr %36, align 8, !tbaa !62 - %38 = fadd double %35, %37 - %39 = fneg double %.02425.i.i - %40 = fmul double %.sroa.7.048.i, %39 - %41 = tail call double @llvm.fmuladd.f64(double %.sroa.038.047.i, double %.02326.i.i, double %40) - %42 = getelementptr inbounds i8, ptr %.027.i.i, i64 -16 - %43 = load double, ptr %42, align 8, !tbaa !62 - %44 = fadd double %41, %43 - %45 = icmp ugt ptr %42, %28 - br i1 %45, label %.lr.ph.i.i, label %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i, !llvm.loop !68 +.lr.ph.i.i: ; preds = %22 + %invariant.gep.i = getelementptr i8, ptr %24, i64 -8 + br label %.lr.ph.i.i + +.lr.ph.i.i:; preds = %.lr.ph.i.i, %.lr.ph.i.i + %.027.i.idx.i = phi i64 [ %.027.i.add.i, %.lr.ph.i.i ], [ %.add.i, %.lr.ph.i.preheader.i ] + %.02326.i.i = phi double [ %41, %.lr.ph.i.i ], [ %31, %.lr.ph.i.preheader.i ] + %.02425.i.i = phi double [ %36, %.lr.ph.i.i ], [ %30, %.lr.ph.i.preheader.i ] + %33 = fmul double %.sroa.7.049.i, %.02326.i.i + %34 = tail call double @llvm.fmuladd.f64(double %.sroa.038.048.i, double %.02425.i.i, double %33) + %gep.i = getelementptr i8, ptr %invariant.gep.i, i64 %.027.i.idx.i + %35 = load double, ptr %gep.i, align 8, !tbaa !62 + %36 = fadd double %34, %35 + %37 = fneg double %.02425.i.i + %38 = fmul double %.sroa.7.049.i, %37 + %39 = tail call double @llvm.fmuladd.f64(double %.sroa.038.048.i, double %.02326.i.i, double %38) + %.027.i.add.i = add nsw i64 %.027.i.idx.i, -16 + %.ptr.i = getelementptr inbounds i8, ptr %24, i64 %.027.i.add.i + %40 = load double, ptr %.ptr.i, align 8, !tbaa !62 + %41 = fadd double %39, %40 + %42 = icmp sgt i64 %.027.i.idx.i, 32 + br i1 %42, label %.lr.ph.i.i, label %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i, !llvm.loop !68 _ZL19complex_horner_evaljPKd5PJ_UVj.exit.i: ; preds = %.lr.ph.i.i, %22 - %.024.lcssa.i.i = phi double [ %31, %22 ], [ %38, %.lr.ph.i.i ] - %.023.lcssa.i.i = phi double [ %32, %22 ], [ %44, %.lr.ph.i.i ] + %.024.lcssa.i.i = phi double [ %30, %22 ], [ %36, %.lr.ph.i.i ] + %.023.lcssa.i.i = phi double [ %32, %22 ], [ %41, %.lr.ph.i.i ] %46 = tail call noundef { double, double } @__divdc3(double noundef %17, double noundef %20, double noundef %.023.lcssa.i.i, double noundef %.024.lcssa.i.i) #10 %47 = extractvalue { double, double } %46, 0 %48 = extractvalue { double, double } %46, 1 %49 = fsub double %47, %.sroa.038.047.i + %47 = tail call double @llvm.fabs.f64(double %46) + %48 = fcmp olt double %47, %13 + %49 = fsub double %45, %.sroa.7.049.i %50 = tail call double @llvm.fabs.f64(double %49) %51 = fcmp olt double %50, %13 - %52 = fsub double %48, %.sroa.7.048.i - %53 = tail call double @llvm.fabs.f64(double %52) - %54 = fcmp olt double %53, %13 - %55 = and i1 %51, %54 - %56 = add nsw i32 %23, -1 - %57 = icmp eq i32 %23, 0 - %.not35.i = select i1 %57, i1 true, i1 %55 - br i1 %.not35.i, label %58, label %22, !llvm.loop !70 - -58: ; preds = %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i - br i1 %55, label %61, label %59 - -59: ; preds = %58 - %60 = tail call i32 @proj_errno_set(ptr noundef %1, i32 noundef 2048) + %52 = and i1 %48, %51 + %53 = add nsw i32 %23, -1 + %54 = icmp eq i32 %23, 0 + %.not35.i = select i1 %54, i1 true, i1 %52 + br i1 %.not35.i, label %55, label %22, !llvm.loop !70 + +55:; preds = %_ZL19complex_horner_evaljPKd5PJ_UVj.exit.i + br i1 %52, label %58, label %56 + +58: ; preds = %55 + %57 = tail call i32 @proj_errno_set(ptr noundef %1, i32 noundef 2048) br label %_ZL30complex_iterative_inverse_implP8PJconstsPKN12_GLOBAL__N_16hornerE5PJ_UV.exit -61: ; preds = %58 +61: ; preds = %55 %62 = load i32, ptr %4, align 8, !tbaa !58 %.not.i = icmp eq i32 %62, 0 %63 = fneg double %48 @@ -762,9 +767,9 @@ _ZL19complex_horner_evaljPKd5PJ_UVj.exit.i: ; preds = %.lr.ph.i.i, %22 %73 = fadd double %.0.i, %72 br label %_ZL30complex_iterative_inverse_implP8PJconstsPKN12_GLOBAL__N_16hornerE5PJ_UV.exit -_ZL30complex_iterative_inverse_implP8PJconstsPKN12_GLOBAL__N_16hornerE5PJ_UV.exit: ; preds = %10, %59, %61 - %.sroa.030.0.i = phi double [ 0x7FF0000000000000, %10 ], [ %70, %61 ], [ 0x7FF0000000000000, %59 ] - %.sroa.3.0.i = phi double [ 0x7FF0000000000000, %10 ], [ %73, %61 ], [ 0x7FF0000000000000, %59 ] +_ZL30complex_iterative_inverse_implP8PJconstsPKN12_GLOBAL__N_16hornerE5PJ_UV.exit: ; preds = %10, %56, %61 + %.sroa.030.0.i = phi double [ 0x7FF0000000000000, %10 ], [ %70, %58 ], [ 0x7FF0000000000000, %56 ] + %.sroa.3.0.i = phi double [ 0x7FF0000000000000, %10 ], [ %73, %58 ], [ 0x7FF0000000000000, %56 ] store double %.sroa.030.0.i, ptr %0, align 8, !tbaa !62 store double %.sroa.3.0.i, ptr %.sroa.2.0..sroa_idx, align 8, !tbaa !62 ret void diff --git a/bench/protobuf/optimized/arena.ll b/bench/protobuf/optimized/arena.ll index ef9db72c558..a754420f048 100644 --- a/bench/protobuf/optimized/arena.ll +++ b/bench/protobuf/optimized/arena.ll @@ -1594,13 +1594,16 @@ entry: %bf.lshr.i.i = lshr i32 %bf.load.i.i, 1 %conv.i.i = zext nneg i32 %bf.lshr.i.i to i64 %add.ptr2.i.i = getelementptr i8, ptr %string_block, i64 %conv.i.i - %add.ptr.i = getelementptr inbounds nuw i8, ptr %string_block, i64 16 - %add.ptr2.i = getelementptr inbounds i8, ptr %add.ptr.i, i64 %unused_bytes - %cmp.not28 = icmp eq ptr %add.ptr2.i, %add.ptr2.i.i - br i1 %cmp.not28, label %for.end, label %for.body + %1 = add nsw i64 %unused_bytes, 16 + %cmp.not28 = icmp eq i64 %1, %conv.i.i + br i1 %cmp.not28, label %for.end, label %for.body.preheader -for.body: ; preds = %entry, %for.body - %s.029 = phi ptr [ %incdec.ptr, %for.body ], [ %add.ptr2.i, %entry ] +for.body: ; preds = %entry + %add.ptr2.i = getelementptr inbounds i8, ptr %string_block, i64 %1 + br label %for.body + +for.body: ; preds = %for.body.preheader, %for.body + %s.029 = phi ptr [ %incdec.ptr, %for.body ], [ %add.ptr2.i, %for.body.preheader ] tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(32) %s.029) #27 %incdec.ptr = getelementptr inbounds nuw i8, ptr %s.029, i64 32 %cmp.not = icmp eq ptr %incdec.ptr, %add.ptr2.i.i @@ -2891,13 +2894,16 @@ if.then.i.i: ; preds = %for.body.i.i %bf.lshr.i.i.i.i.i = lshr i32 %bf.load.i.i.i.i.i, 1 %conv.i.i.i.i.i = zext nneg i32 %bf.lshr.i.i.i.i.i to i64 %add.ptr2.i.i.i.i.i = getelementptr i8, ptr %atomic-temp.i.0.i.i3.i, i64 %conv.i.i.i.i.i - %add.ptr.i.i.i.i = getelementptr inbounds nuw i8, ptr %atomic-temp.i.0.i.i3.i, i64 16 - %add.ptr2.i.i.i.i = getelementptr inbounds i8, ptr %add.ptr.i.i.i.i, i64 %10 - %cmp.not28.i.i.i = icmp eq ptr %add.ptr2.i.i.i.i, %add.ptr2.i.i.i.i.i - br i1 %cmp.not28.i.i.i, label %for.end.i.i.i, label %for.body.i.i.i + %13 = add nsw i64 %10, 16 + %cmp.not28.i.i.i = icmp eq i64 %13, %conv.i.i.i.i.i + br i1 %cmp.not28.i.i.i, label %for.end.i.i.i, label %for.body.preheader.i.i.i + +for.body.preheader.i.i.i: ; preds = %if.then.i.i + %add.ptr2.i.i.i.i = getelementptr inbounds i8, ptr %atomic-temp.i.0.i.i3.i, i64 %13 + br label %for.body.i.i.i -for.body.i.i.i: ; preds = %if.then.i.i, %for.body.i.i.i - %s.029.i.i.i = phi ptr [ %incdec.ptr.i.i.i, %for.body.i.i.i ], [ %add.ptr2.i.i.i.i, %if.then.i.i ] +for.body.i.i.i: ; preds = %for.body.i.i.i, %for.body.preheader.i.i.i + %s.029.i.i.i = phi ptr [ %incdec.ptr.i.i.i, %for.body.i.i.i ], [ %add.ptr2.i.i.i.i, %for.body.preheader.i.i.i ] tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(32) %s.029.i.i.i) #27 %incdec.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %s.029.i.i.i, i64 32 %cmp.not.i.i.i = icmp eq ptr %incdec.ptr.i.i.i, %add.ptr2.i.i.i.i.i @@ -3115,13 +3121,16 @@ if.then: ; preds = %entry %bf.lshr.i.i.i = lshr i32 %bf.load.i.i.i, 1 %conv.i.i.i = zext nneg i32 %bf.lshr.i.i.i to i64 %add.ptr2.i.i.i = getelementptr i8, ptr %atomic-temp.i.0.i, i64 %conv.i.i.i - %add.ptr.i.i = getelementptr inbounds nuw i8, ptr %atomic-temp.i.0.i, i64 16 - %add.ptr2.i.i = getelementptr inbounds i8, ptr %add.ptr.i.i, i64 %0 - %cmp.not28.i = icmp eq ptr %add.ptr2.i.i, %add.ptr2.i.i.i - br i1 %cmp.not28.i, label %for.end.i, label %for.body.i + %3 = add nsw i64 %0, 16 + %cmp.not28.i = icmp eq i64 %3, %conv.i.i.i + br i1 %cmp.not28.i, label %for.end.i, label %for.body.preheader.i + +for.body.preheader.i: ; preds = %if.then + %add.ptr2.i.i = getelementptr inbounds i8, ptr %atomic-temp.i.0.i, i64 %3 + br label %for.body.i -for.body.i: ; preds = %if.then, %for.body.i - %s.029.i = phi ptr [ %incdec.ptr.i, %for.body.i ], [ %add.ptr2.i.i, %if.then ] +for.body.i: ; preds = %for.body.i, %for.body.preheader.i + %s.029.i = phi ptr [ %incdec.ptr.i, %for.body.i ], [ %add.ptr2.i.i, %for.body.preheader.i ] tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(32) %s.029.i) #27 %incdec.ptr.i = getelementptr inbounds nuw i8, ptr %s.029.i, i64 32 %cmp.not.i = icmp eq ptr %incdec.ptr.i, %add.ptr2.i.i.i @@ -3788,7 +3797,7 @@ for.body.i.i: ; preds = %entry, %"_ZZNK6goog %.sroa.speculated.i.i.i.i.i = tail call noundef i32 @llvm.umin.i32(i32 %5, i32 %3) %conv6.i.i.i.i = zext i32 %.sroa.speculated.i.i.i.i.i to i64 %add.ptr.i.idx.i.i.i = shl nuw nsw i64 %conv6.i.i.i.i, 3 - %add.ptr.i.ptr.i.i.i = getelementptr i8, ptr %add.ptr.i.i.i.i.i.i, i64 %add.ptr.i.idx.i.i.i + %add.ptr.i.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %add.ptr.i.i.i.i.i.i, i64 %add.ptr.i.idx.i.i.i %cmp.not6.i.i.i = icmp eq i32 %5, 0 br i1 %cmp.not6.i.i.i, label %"_ZZNK6google8protobuf8internal15ThreadSafeArena26PerConstSerialArenaInChunkIZNKS2_14SpaceAllocatedEvE3$_0EEvT_ENKUlPKNS2_16SerialArenaChunkEE_clES8_.exit.i.i", label %for.body.i.i.i @@ -3891,7 +3900,7 @@ for.body.i.i: ; preds = %_ZNK6google8protobu %.sroa.speculated.i.i.i.i.i = tail call noundef i32 @llvm.umin.i32(i32 %10, i32 %8) %conv6.i.i.i.i = zext i32 %.sroa.speculated.i.i.i.i.i to i64 %add.ptr.i.idx.i.i.i = shl nuw nsw i64 %conv6.i.i.i.i, 3 - %add.ptr.i.ptr.i.i.i = getelementptr i8, ptr %add.ptr.i.i.i.i.i.i, i64 %add.ptr.i.idx.i.i.i + %add.ptr.i.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %add.ptr.i.i.i.i.i.i, i64 %add.ptr.i.idx.i.i.i %cmp.not9.i.i.i = icmp eq i32 %10, 0 br i1 %cmp.not9.i.i.i, label %"_ZZNK6google8protobuf8internal15ThreadSafeArena26PerConstSerialArenaInChunkIZNKS2_9SpaceUsedEvE3$_0EEvT_ENKUlPKNS2_16SerialArenaChunkEE_clES8_.exit.i.i", label %for.body.i.i.i diff --git a/bench/protobuf/optimized/descriptor.ll b/bench/protobuf/optimized/descriptor.ll index 9ad8dc405d6..1ea1f2ba7a9 100644 --- a/bench/protobuf/optimized/descriptor.ll +++ b/bench/protobuf/optimized/descriptor.ll @@ -61049,15 +61049,13 @@ _ZNK9__gnu_cxx5__ops19_Iter_equal_to_iterclIPSt17basic_string_viewIcSt11char_tra br i1 %cmp1.not.i.i.i.i, label %invoke.cont32.i, label %while.body.i.i.i.i, !llvm.loop !884 _ZSt15__adjacent_findIPSt17basic_string_viewIcSt11char_traitsIcEEN9__gnu_cxx5__ops19_Iter_equal_to_iterEET_S8_S8_T0_.exit.i.i.i: ; preds = %_ZNSt11char_traitsIcE7compareEPKcS2_m.exit.i.i.i.i.i.i.i, %land.rhs.i.i.i.i.i.i - %cmp.i.i.i = icmp eq i64 %__next.011.i.i.i.idx.i, 64 - br i1 %cmp.i.i.i, label %invoke.cont32.i, label %if.end.i.i.i + switch i64 %__next.011.i.i.i.idx.i, label %while.body.preheader.i.i.i [ + i64 64, label %invoke.cont32.i + i64 32, label %while.end.i.i.i + ] if.end.i.i.i: ; preds = %_ZSt15__adjacent_findIPSt17basic_string_viewIcSt11char_traitsIcEEN9__gnu_cxx5__ops19_Iter_equal_to_iterEET_S8_S8_T0_.exit.i.i.i %__next.011.i.i.i.ptr.add.i = add nuw nsw i64 %__next.011.i.i.i.idx.i, 32 - %cmp2.not17.i.i.i = icmp eq i64 %__next.011.i.i.i.ptr.add.i, 64 - br i1 %cmp2.not17.i.i.i, label %while.end.i.i.i, label %while.body.preheader.i.i.i - -while.body.preheader.i.i.i: ; preds = %if.end.i.i.i %incdec.ptr.i.i18.i = getelementptr inbounds nuw i8, ptr %__next.011.i.i.i.ptr.ptr.i, i64 16 br label %while.body.i.i.i @@ -61095,8 +61093,8 @@ if.end6.i.i.i: ; preds = %if.then4.i.i.i, %_Z %cmp2.not.i.i.i = icmp eq i64 %incdec.ptr120.i.i.add.i, 64 br i1 %cmp2.not.i.i.i, label %while.end.i.i.i, label %while.body.i.i.i, !llvm.loop !885 -while.end.i.i.i: ; preds = %if.end6.i.i.i, %if.end.i.i.i - %__dest.0.lcssa.i.i.i = phi ptr [ %__next.011.i.i.i.ptr.ptr.i, %if.end.i.i.i ], [ %__dest.1.i.i.i, %if.end6.i.i.i ] +while.end.i.i.i: ; preds = %if.end6.i.i.i, %_ZSt15__adjacent_findIPSt17basic_string_viewIcSt11char_traitsIcEEN9__gnu_cxx5__ops19_Iter_equal_to_iterEET_S8_S8_T0_.exit.i.i.i + %__dest.0.lcssa.i.i.i = phi ptr [ %__next.011.i.i.i.ptr.ptr.i, %_ZSt15__adjacent_findIPSt17basic_string_viewIcSt11char_traitsIcEEN9__gnu_cxx5__ops19_Iter_equal_to_iterEET_S8_S8_T0_.exit.i.i.i ], [ %__dest.1.i.i.i, %if.end6.i.i.i ] %incdec.ptr7.i.i.i = getelementptr inbounds nuw i8, ptr %__dest.0.lcssa.i.i.i, i64 16 br label %invoke.cont32.i diff --git a/bench/proxygen/optimized/HTTPConnectorWithFizz.ll b/bench/proxygen/optimized/HTTPConnectorWithFizz.ll index 39539c0e9ab..ac6b004f56e 100644 --- a/bench/proxygen/optimized/HTTPConnectorWithFizz.ll +++ b/bench/proxygen/optimized/HTTPConnectorWithFizz.ll @@ -15733,8 +15733,7 @@ if.else: ; preds = %entry %and.i.i = and i64 %0, 4611686018427387903 %u.i.i.ptr = getelementptr inbounds nuw i8, ptr %o, i64 16 %add.ptr.i.idx = mul nuw nsw i64 %and.i.i, 208 - %5 = getelementptr inbounds nuw i8, ptr %o, i64 %add.ptr.i.idx - %add.ptr.i.ptr = getelementptr inbounds nuw i8, ptr %5, i64 16 + %5 = getelementptr inbounds nuw i8, ptr %u.i.i, i64 %add.ptr.i.idx %cmp.i.i.not8.i.i.i = icmp eq i64 %and.i.i, 0 br i1 %cmp.i.i.not8.i.i.i, label %_ZSt18uninitialized_copyISt13move_iteratorIPN4fizz6client6ActionEES4_ET0_T_S7_S6_.exit, label %for.body.i.i.i @@ -15748,7 +15747,7 @@ for.body.i.i.i: ; preds = %if.else, %for.inc.i for.inc.i.i.i: ; preds = %for.body.i.i.i %incdec.ptr.i.i.i.i = getelementptr inbounds nuw i8, ptr %__first.sroa.0.09.i.i.i, i64 208 %__cur.010.i.i.i.add = add nuw nsw i64 %__cur.010.i.i.i.idx, 208 - %cmp.i.i.not.i.i.i = icmp eq ptr %incdec.ptr.i.i.i.i, %add.ptr.i.ptr + %cmp.i.i.not.i.i.i = icmp eq ptr %incdec.ptr.i.i.i.i, %add.ptr.i br i1 %cmp.i.i.not.i.i.i, label %_ZSt18uninitialized_copyISt13move_iteratorIPN4fizz6client6ActionEES4_ET0_T_S7_S6_.exit.loopexit, label %for.body.i.i.i, !llvm.loop !84 lpad.i.i.i: ; preds = %for.body.i.i.i @@ -16698,8 +16697,7 @@ invoke.cont19: ; preds = %invoke.cont %and.i.i = and i64 %0, 4611686018427387903 %u.i.i.ptr = getelementptr inbounds nuw i8, ptr %o, i64 8 %add.ptr.i.idx = shl nuw nsw i64 %and.i.i, 4 - %5 = getelementptr inbounds nuw i8, ptr %o, i64 %add.ptr.i.idx - %add.ptr.i.ptr = getelementptr inbounds nuw i8, ptr %5, i64 8 + %5 = getelementptr inbounds nuw i8, ptr %u.i.i, i64 %add.ptr.i.idx %cmp.i.i.not7.i.i.i = icmp eq i64 %and.i.i, 0 br i1 %cmp.i.i.not7.i.i.i, label %invoke.cont25, label %for.body.i.i.i @@ -16715,7 +16713,7 @@ for.body.i.i.i: ; preds = %invoke.cont19, %for store i64 %7, ptr %contentType.i.i.i.i.i, align 8 %incdec.ptr.i.i.i.i = getelementptr inbounds nuw i8, ptr %__first.sroa.0.08.i.i.i, i64 16 %incdec.ptr.i.i.i = getelementptr inbounds nuw i8, ptr %__cur.09.i.i.i, i64 16 - %cmp.i.i.not.i.i.i = icmp eq ptr %incdec.ptr.i.i.i.i, %add.ptr.i.ptr + %cmp.i.i.not.i.i.i = icmp eq ptr %incdec.ptr.i.i.i.i, %add.ptr.i br i1 %cmp.i.i.not.i.i.i, label %invoke.cont25.loopexit, label %for.body.i.i.i, !llvm.loop !90 invoke.cont25.loopexit: ; preds = %for.body.i.i.i diff --git a/bench/qemu/optimized/tcg.ll b/bench/qemu/optimized/tcg.ll index 40f91f47bef..8ba54186ab1 100644 --- a/bench/qemu/optimized/tcg.ll +++ b/bench/qemu/optimized/tcg.ll @@ -3632,7 +3632,8 @@ tcg_temp_alloc.exit: ; preds = %switch.lookup %switch.masked = trunc i6 %switch.downshift to i1 %43 = getelementptr inbounds nuw i8, ptr %4, i64 672 %44 = sext i32 %39 to i64 - %45 = getelementptr inbounds [512 x %struct.TCGTemp], ptr %43, i64 0, i64 %44 + %.idx61 = mul nsw i64 %44, 56 + %45 = getelementptr inbounds i8, ptr %43, i64 %.idx61 tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(56) %45, i8 noundef 0, i64 noundef 56, i1 noundef false) #30 %46 = zext nneg i32 %0 to i64 %47 = shl nuw nsw i64 %46, 16 @@ -3664,10 +3665,11 @@ tcg_temp_alloc.exit: ; preds = %switch.lookup tcg_temp_alloc.exit50: ; preds = %.critedge %61 = sext i32 %57 to i64 - %62 = getelementptr inbounds [512 x %struct.TCGTemp], ptr %43, i64 0, i64 %61 + %.idx = mul nsw i64 %61, 56 + %62 = getelementptr inbounds i8, ptr %43, i64 %.idx tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(56) %62, i8 noundef 0, i64 noundef 56, i1 noundef false) #30 - %63 = getelementptr inbounds nuw i8, ptr %45, i64 56 - %64 = icmp eq ptr %62, %63 + %63 = add nsw i64 %.idx61, 56 + %64 = icmp eq i64 %.idx, %63 tail call void @llvm.assume(i1 %64) %65 = or disjoint i64 %47, %50 %66 = or disjoint i64 %65, 1649284218880 @@ -4006,7 +4008,8 @@ define dso_local ptr @tcg_temp_new_i128() local_unnamed_addr #0 { tcg_temp_alloc.exit.i: ; preds = %0 %8 = getelementptr inbounds nuw i8, ptr %2, i64 672 %9 = sext i32 %4 to i64 - %10 = getelementptr inbounds [512 x %struct.TCGTemp], ptr %8, i64 0, i64 %9 + %.idx1 = mul nsw i64 %9, 56 + %10 = getelementptr inbounds i8, ptr %8, i64 %.idx1 tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(56) %10, i8 noundef 0, i64 noundef 56, i1 noundef false) #30 store i64 554067689472, ptr %10, align 8 %11 = load i32, ptr %3, align 8 @@ -4021,10 +4024,11 @@ tcg_temp_alloc.exit.i: ; preds = %0 tcg_temp_new_internal.exit: ; preds = %tcg_temp_alloc.exit.i %15 = sext i32 %11 to i64 - %16 = getelementptr inbounds [512 x %struct.TCGTemp], ptr %8, i64 0, i64 %15 + %.idx = mul nsw i64 %15, 56 + %16 = getelementptr inbounds i8, ptr %8, i64 %.idx tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 1 dereferenceable(56) %16, i8 noundef 0, i64 noundef 56, i1 noundef false) #30 - %17 = getelementptr inbounds nuw i8, ptr %10, i64 56 - %18 = icmp eq ptr %16, %17 + %17 = add nsw i64 %.idx1, 56 + %18 = icmp eq i64 %.idx, %17 tail call void @llvm.assume(i1 %18) store i64 1653579317248, ptr %16, align 8 %19 = load ptr, ptr %1, align 8 diff --git a/bench/redis/optimized/ziplist.ll b/bench/redis/optimized/ziplist.ll index 7b8423e3150..dd092bc9053 100644 --- a/bench/redis/optimized/ziplist.ll +++ b/bench/redis/optimized/ziplist.ll @@ -2115,18 +2115,16 @@ define dso_local noundef ptr @ziplistIndex(ptr noundef %0, i32 noundef %1) local ] 14: ; preds = %8 - %15 = getelementptr inbounds nuw i8, ptr %.ptr67, i64 1 - %16 = getelementptr inbounds nuw i8, ptr %0, i64 %6 - %17 = getelementptr inbounds i8, ptr %16, i64 -1 - %18 = icmp ult ptr %15, %17 - br i1 %18, label %24, label %23, !prof !14 + %15 = add nsw i64 %6, -1 + %16 = add nuw nsw i64 %12, 1 + %17 = icmp slt i64 %16, %15 + br i1 %17, label %22, label %21, !prof !14 .thread: ; preds = %8 - %19 = getelementptr inbounds nuw i8, ptr %.ptr67, i64 5 - %20 = getelementptr inbounds nuw i8, ptr %0, i64 %6 - %21 = getelementptr inbounds i8, ptr %20, i64 -1 - %22 = icmp ult ptr %19, %21 - br i1 %22, label %.thread70, label %23, !prof !14 + %18 = add nsw i64 %6, -1 + %19 = add nuw nsw i64 %12, 5 + %20 = icmp slt i64 %19, %18 + br i1 %20, label %.thread70, label %21, !prof !14 23: ; preds = %.thread, %14 tail call void @_serverAssert(ptr noundef nonnull @.str.11, ptr noundef nonnull @.str.1, i32 noundef 1163) #17 @@ -2143,15 +2141,15 @@ define dso_local noundef ptr @ziplistIndex(ptr noundef %0, i32 noundef %1) local br label %28 28: ; preds = %.thread70, %24 - %29 = phi ptr [ %17, %24 ], [ %21, %.thread70 ] - %.048 = phi i32 [ %25, %24 ], [ %27, %.thread70 ] + %29 = phi i64 [ %15, %22 ], [ %18, %.thread70 ] + %.048 = phi i32 [ %25, %22 ], [ %27, %.thread70 ] %.not6574 = icmp eq i32 %.048, 0 br i1 %.not6574, label %.critedge.loopexit, label %.lr.ph .lr.ph: ; preds = %28, %45 - %.177 = phi i32 [ %.2, %45 ], [ %.048, %28 ] - %.052.idx76 = phi i64 [ %.052.add, %45 ], [ %12, %28 ] - %.05575 = phi i32 [ %30, %45 ], [ %9, %28 ] + %.177 = phi i32 [ %.2, %43 ], [ %.048, %26 ] + %.052.idx76 = phi i64 [ %.052.add, %43 ], [ %12, %26 ] + %.05575 = phi i32 [ %30, %43 ], [ %9, %26 ] %30 = add nsw i32 %.05575, -1 %.not66 = icmp eq i32 %.05575, 0 br i1 %.not66, label %.critedge.loopexit, label %31 @@ -2161,9 +2159,9 @@ define dso_local noundef ptr @ziplistIndex(ptr noundef %0, i32 noundef %1) local %.052.add = sub nsw i64 %.052.idx76, %32 %.ptr = getelementptr inbounds i8, ptr %0, i64 %.052.add %33 = icmp sgt i64 %.052.add, 9 - %34 = icmp ult ptr %.ptr, %29 - %35 = select i1 %33, i1 %34, i1 false, !prof !14 - br i1 %35, label %37, label %36, !prof !14 + %34 = icmp slt i64 %.052.add, %29 + %33 = and i1 %33, %34 + br i1 %33, label %37, label %36, !prof !14 36: ; preds = %31 tail call void @_serverAssert(ptr noundef nonnull @.str.12, ptr noundef nonnull @.str.1, i32 noundef 1167) #17 @@ -2185,7 +2183,7 @@ define dso_local noundef ptr @ziplistIndex(ptr noundef %0, i32 noundef %1) local br label %45 45: ; preds = %42, %40 - %.2 = phi i32 [ %41, %40 ], [ %44, %42 ] + %.2 = phi i32 [ %41, %38 ], [ %44, %40 ] %.not65 = icmp eq i32 %.2, 0 br i1 %.not65, label %.critedge.loopexit, label %.lr.ph, !llvm.loop !33 @@ -2196,8 +2194,8 @@ define dso_local noundef ptr @ziplistIndex(ptr noundef %0, i32 noundef %1) local br label %50 50: ; preds = %zipRawEntryLengthSafe.exit, %46 - %.257 = phi i32 [ %1, %46 ], [ %51, %zipRawEntryLengthSafe.exit ] - %.254 = phi ptr [ %47, %46 ], [ %59, %zipRawEntryLengthSafe.exit ] + %.257 = phi i32 [ %1, %44 ], [ %51, %zipRawEntryLengthSafe.exit ] + %.254 = phi ptr [ %47, %44 ], [ %59, %zipRawEntryLengthSafe.exit ] %51 = add nsw i32 %.257, -1 %.not = icmp eq i32 %.257, 0 br i1 %.not, label %.critedge, label %52 @@ -2225,14 +2223,14 @@ zipRawEntryLengthSafe.exit: ; preds = %52 br i1 %61, label %.critedge, label %50, !llvm.loop !34 .critedge.loopexit: ; preds = %45, %.lr.ph, %28 - %.052.idx.lcssa = phi i64 [ %12, %28 ], [ %.052.idx76, %.lr.ph ], [ %.052.add, %45 ] - %.156.ph = phi i32 [ %9, %28 ], [ -1, %.lr.ph ], [ %30, %45 ] + %.052.idx.lcssa = phi i64 [ %12, %26 ], [ %.052.idx76, %.lr.ph ], [ %.052.add, %43 ] + %.156.ph = phi i32 [ %9, %26 ], [ -1, %.lr.ph ], [ %30, %43 ] %.052.ptr.le = getelementptr inbounds i8, ptr %0, i64 %.052.idx.lcssa br label %.critedge .critedge: ; preds = %50, %zipRawEntryLengthSafe.exit, %.critedge.loopexit, %8 - %.156 = phi i32 [ %9, %8 ], [ %.156.ph, %.critedge.loopexit ], [ -1, %50 ], [ %51, %zipRawEntryLengthSafe.exit ] - %.153 = phi ptr [ %.ptr67, %8 ], [ %.052.ptr.le, %.critedge.loopexit ], [ %.254, %50 ], [ %59, %zipRawEntryLengthSafe.exit ] + %.156 = phi i32 [ %9, %8 ], [ %.156.ph, %.critedge.loopexit ], [ -1, %48 ], [ %51, %zipRawEntryLengthSafe.exit ] + %.153 = phi ptr [ %.ptr67, %8 ], [ %.052.ptr.le, %.critedge.loopexit ], [ %.254, %48 ], [ %59, %zipRawEntryLengthSafe.exit ] %62 = load i8, ptr %.153, align 1, !tbaa !9 %63 = icmp eq i8 %62, -1 %64 = icmp sgt i32 %.156, 0 diff --git a/bench/redis/optimized/zipmap.ll b/bench/redis/optimized/zipmap.ll index a7eb8180d73..51e07bd14bf 100644 --- a/bench/redis/optimized/zipmap.ll +++ b/bench/redis/optimized/zipmap.ll @@ -1025,8 +1025,8 @@ define dso_local range(i32 0, 2) i32 @zipmapValidateIntegrity(ptr noundef readon br i1 %.not59, label %.loopexit, label %.preheader .preheader: ; preds = %9, %zipmapDecodeLength.exit77 - %.049 = phi i32 [ %35, %zipmapDecodeLength.exit77 ], [ 0, %9 ] - %.0.idx = phi i64 [ %.add65, %zipmapDecodeLength.exit77 ], [ 1, %9 ] + %.049 = phi i32 [ %35, %zipmapDecodeLength.exit78 ], [ 0, %9 ] + %.0.idx = phi i64 [ %.add65, %zipmapDecodeLength.exit78 ], [ 1, %9 ] %.0.ptr = getelementptr inbounds nuw i8, ptr %0, i64 %.0.idx %10 = load i8, ptr %.0.ptr, align 1, !tbaa !5 %.not60 = icmp eq i8 %10, -1 @@ -1036,11 +1036,10 @@ define dso_local range(i32 0, 2) i32 @zipmapValidateIntegrity(ptr noundef readon %.not79 = icmp eq i8 %10, -2 %12 = select i1 %.not79, i64 5, i64 1 %.0.add = add nuw nsw i64 %12, %.0.idx - %13 = icmp slt i64 %.0.add, 2 - %.ptr = getelementptr inbounds nuw i8, ptr %0, i64 %.0.add - %14 = icmp ugt ptr %.ptr, %7 - %or.cond78 = select i1 %13, i1 true, i1 %14 - br i1 %or.cond78, label %.loopexit, label %15 + %13 = icmp sgt i64 %.0.add, 1 + %.not71 = icmp slt i64 %.0.add, %1 + %or.cond79 = and i1 %13, %.not71 + br i1 %or.cond79, label %15, label %.loopexit 15: ; preds = %11 br i1 %.not79, label %18, label %16 @@ -1055,7 +1054,7 @@ define dso_local range(i32 0, 2) i32 @zipmapValidateIntegrity(ptr noundef readon br label %zipmapDecodeLength.exit zipmapDecodeLength.exit: ; preds = %16, %18 - %.0.i = phi i32 [ %17, %16 ], [ %.0.copyload.i, %18 ] + %.0.i = phi i32 [ %17, %15 ], [ %.0.copyload.i, %17 ] %20 = zext i32 %.0.i to i64 %.add = add nuw nsw i64 %.0.add, %20 %.ptr66 = getelementptr inbounds nuw i8, ptr %0, i64 %.add @@ -1084,7 +1083,7 @@ zipmapDecodeLength.exit: ; preds = %16, %18 br label %zipmapDecodeLength.exit77 zipmapDecodeLength.exit77: ; preds = %27, %29 - %.0.i76 = phi i32 [ %28, %27 ], [ %.0.copyload.i75, %29 ] + %.0.i76 = phi i32 [ %28, %26 ], [ %.0.copyload.i75, %28 ] %.add64 = add nuw nsw i64 %.add63, 1 %31 = load i8, ptr %.ptr67, align 1, !tbaa !5 %32 = zext i8 %31 to i32 @@ -1110,7 +1109,7 @@ zipmapDecodeLength.exit77: ; preds = %27, %29 br label %.loopexit .loopexit: ; preds = %11, %zipmapDecodeLength.exit, %22, %zipmapDecodeLength.exit77, %39, %37, %9, %5, %3 - %.050 = phi i32 [ 0, %3 ], [ 0, %5 ], [ 1, %9 ], [ 0, %37 ], [ %spec.select, %39 ], [ 0, %zipmapDecodeLength.exit77 ], [ 0, %22 ], [ 0, %zipmapDecodeLength.exit ], [ 0, %11 ] + %.050 = phi i32 [ 0, %3 ], [ 0, %5 ], [ 1, %9 ], [ 0, %36 ], [ %spec.select, %38 ], [ 0, %zipmapDecodeLength.exit78 ], [ 0, %21 ], [ 0, %zipmapDecodeLength.exit ], [ 0, %11 ] ret i32 %.050 } diff --git a/bench/ripgrep-rs/optimized/3bctup5kmnkujhz5.ll b/bench/ripgrep-rs/optimized/3bctup5kmnkujhz5.ll index 67329d5b96c..be64cadc7db 100644 --- a/bench/ripgrep-rs/optimized/3bctup5kmnkujhz5.ll +++ b/bench/ripgrep-rs/optimized/3bctup5kmnkujhz5.ll @@ -1107,10 +1107,6 @@ define hidden void @_ZN10grep_regex12non_matching21remove_matching_bytes17h9d607 %7 = alloca { { { i64, ptr, {} }, i64 } }, align 8 %8 = alloca { { { i64, ptr, {} }, i64 } }, align 8 %9 = alloca { { { ptr, ptr, {} } } }, align 8 - %.sroa.5.0.i.sroa.gep = getelementptr inbounds nuw i8, ptr %5, i64 4 - %.sroa.5.0.i.sroa.gep93 = getelementptr inbounds nuw i8, ptr %5, i64 6 - %.sroa.5.0.i.sroa.gep94 = getelementptr inbounds nuw i8, ptr %5, i64 8 - %.sroa.5.0.i.sroa.gep95 = getelementptr inbounds nuw i8, ptr %5, i64 2 br label %tailrecurse tailrecurse: ; preds = %tailrecurse.backedge, %2 @@ -1130,7 +1126,7 @@ tailrecurse: ; preds = %tailrecurse.backedg i64 7, label %35 ] -default.unreachable96: ; preds = %87, %24 +default.unreachable96: ; preds = %24 unreachable 14: ; preds = %tailrecurse @@ -1157,7 +1153,7 @@ default.unreachable96: ; preds = %87, %24 %25 = getelementptr inbounds nuw i8, ptr %.tr, i64 8 %26 = load i32, ptr %25, align 8, !range !186, !noundef !7 %27 = tail call range(i32 0, 33) i32 @llvm.cttz.i32(i32 %26, i1 true) - switch i32 %27, label %default.unreachable96 [ + switch i32 %27, label %default.unreachable93 [ i32 0, label %128 i32 1, label %128 i32 2, label %131 @@ -1278,7 +1274,7 @@ tailrecurse.backedge: ; preds = %tailrecurse, %28 %76 = landingpad { ptr, i32 } cleanup invoke void @"_ZN4core3ptr54drop_in_place$LT$regex_syntax..utf8..Utf8Sequences$GT$17h8f0a5217b1abce39E"(ptr noalias noundef nonnull align 8 dereferenceable(24) %7) #23 - to label %110 unwind label %108 + to label %109 unwind label %108 77: ; preds = %74 %78 = load i8, ptr %6, align 1, !range !187, !noundef !7 @@ -1310,25 +1306,9 @@ tailrecurse.backedge: ; preds = %tailrecurse, %28 call void @llvm.lifetime.start.p0(i64 9, ptr nonnull %5) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 1 dereferenceable(9) %5, ptr noundef nonnull align 1 dereferenceable(9) %6, i64 9, i1 false) %88 = load i8, ptr %5, align 1, !range !197, !alias.scope !198, !noundef !7 - switch i8 %88, label %default.unreachable96 [ - i8 0, label %.lr.ph68.preheader - i8 1, label %89 - i8 2, label %90 - i8 3, label %91 - ] - -89: ; preds = %87 - br label %.lr.ph68.preheader - -90: ; preds = %87 - br label %.lr.ph68.preheader - -91: ; preds = %87 - br label %.lr.ph68.preheader - -.lr.ph68.preheader: ; preds = %87, %89, %90, %91 - %.sroa.5.0.i.sroa.phi = phi ptr [ %.sroa.5.0.i.sroa.gep, %89 ], [ %.sroa.5.0.i.sroa.gep93, %90 ], [ %.sroa.5.0.i.sroa.gep94, %91 ], [ %.sroa.5.0.i.sroa.gep95, %87 ] - %.ptr = getelementptr inbounds nuw i8, ptr %.sroa.5.0.i.sroa.phi, i64 1 + %88 = shl nuw nsw i8 %88, 1 + %89 = zext nneg i8 %88 to i64 + %90 = getelementptr inbounds nuw i8, ptr %.sroa.0.0.i, i64 %89 br label %.lr.ph68 ._crit_edge69: ; preds = %_ZN12grep_matcher7ByteSet10remove_all17hd0eef1246d773bc5E.exit @@ -1336,8 +1316,8 @@ tailrecurse.backedge: ; preds = %tailrecurse, %28 call void @llvm.lifetime.end.p0(i64 9, ptr nonnull %6) br label %74 -.lr.ph68: ; preds = %.lr.ph68.preheader, %_ZN12grep_matcher7ByteSet10remove_all17hd0eef1246d773bc5E.exit - %.sroa.032.066 = phi ptr [ %92, %_ZN12grep_matcher7ByteSet10remove_all17hd0eef1246d773bc5E.exit ], [ %.sroa.0.0.i.ptr, %.lr.ph68.preheader ] +.lr.ph68: ; preds = %87, %_ZN12grep_matcher7ByteSet10remove_all17hd0eef1246d773bc5E.exit + %.sroa.032.066 = phi ptr [ %92, %_ZN12grep_matcher7ByteSet10remove_all17hd0eef1246d773bc5E.exit ], [ %.sroa.0.0.i.ptr, %switch.lookup ] %92 = getelementptr inbounds nuw i8, ptr %.sroa.032.066, i64 2 %93 = load i8, ptr %.sroa.032.066, align 1, !noundef !7 %94 = getelementptr inbounds nuw i8, ptr %.sroa.032.066, i64 1 @@ -1366,7 +1346,7 @@ tailrecurse.backedge: ; preds = %tailrecurse, %28 br i1 %or.cond.i, label %_ZN12grep_matcher7ByteSet10remove_all17hd0eef1246d773bc5E.exit, label %.lr.ph.i _ZN12grep_matcher7ByteSet10remove_all17hd0eef1246d773bc5E.exit: ; preds = %.lr.ph.i, %.lr.ph68 - %107 = icmp eq ptr %92, %.ptr + %107 = icmp eq ptr %.sroa.032.066, %90 br i1 %107, label %._crit_edge69, label %.lr.ph68 108: ; preds = %75 diff --git a/bench/rocksdb/optimized/compression_context_cache.ll b/bench/rocksdb/optimized/compression_context_cache.ll index 5e1c7dbe47b..75f523b69d9 100644 --- a/bench/rocksdb/optimized/compression_context_cache.ll +++ b/bench/rocksdb/optimized/compression_context_cache.ll @@ -322,12 +322,10 @@ define linkonce_odr void @_ZN7rocksdb14CoreLocalArrayINS_17compression_cache14ZS 15: ; preds = %7 %16 = shl nuw i64 1, %9 store i64 %16, ptr %14, align 16 - %.ptr7 = getelementptr inbounds nuw i8, ptr %14, i64 8 - %17 = getelementptr inbounds %"struct.rocksdb::compression_cache::ZSTDCachedData", ptr %.ptr7, i64 %16 br label %18 18: ; preds = %15, %18 - %.idx = phi i64 [ 8, %15 ], [ %.add, %18 ] + %.idx = phi i64 [ 8, %15 ], [ %.add, %17 ] %.ptr.ptr = getelementptr inbounds nuw i8, ptr %14, i64 %.idx store ptr null, ptr %.ptr.ptr, align 8, !tbaa !28 %19 = getelementptr inbounds nuw i8, ptr %.ptr.ptr, i64 8 @@ -335,11 +333,12 @@ define linkonce_odr void @_ZN7rocksdb14CoreLocalArrayINS_17compression_cache14ZS %20 = getelementptr inbounds nuw i8, ptr %.ptr.ptr, i64 16 store ptr %.ptr.ptr, ptr %20, align 8, !tbaa !36 %.add = add nuw nsw i64 %.idx, 64 - %.ptr6 = getelementptr inbounds nuw i8, ptr %14, i64 %.add - %21 = icmp eq ptr %.ptr6, %17 + %20 = add nuw nsw i64 %.idx, 56 + %21 = icmp eq i64 %20, %11 br i1 %21, label %22, label %18 22: ; preds = %18 + %.ptr7 = getelementptr inbounds nuw i8, ptr %14, i64 8 %23 = load ptr, ptr %0, align 8, !tbaa !24 store ptr %.ptr7, ptr %0, align 8, !tbaa !24 %.not.i.i = icmp eq ptr %23, null diff --git a/bench/ruff-rs/optimized/3962cj1utxtdqcwyobmnzow9t.ll b/bench/ruff-rs/optimized/3962cj1utxtdqcwyobmnzow9t.ll index 7ec3efbcb68..d934a417ad9 100644 --- a/bench/ruff-rs/optimized/3962cj1utxtdqcwyobmnzow9t.ll +++ b/bench/ruff-rs/optimized/3962cj1utxtdqcwyobmnzow9t.ll @@ -8268,48 +8268,51 @@ _ZN21ruff_python_formatter8comments6format20strip_comment_prefix17h2e2c2de330183 %103 = getelementptr inbounds nuw i8, ptr %98, i64 1 %104 = and i8 %101, 31 %105 = zext nneg i8 %104 to i32 - %106 = icmp ne ptr %103, %94 - call void @llvm.assume(i1 %106) - %107 = getelementptr inbounds nuw i8, ptr %98, i64 2 - %108 = load i8, ptr %103, align 1, !alias.scope !1055, !noalias !1058, !noundef !3 - %109 = shl nuw nsw i32 %105, 6 - %110 = and i8 %108, 63 - %111 = zext nneg i8 %110 to i32 - %112 = or disjoint i32 %109, %111 - %113 = icmp samesign ugt i8 %101, -33 - br i1 %113, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17h9270fe57bce9436eE.exit.i.i" + %106 = add nuw nsw i64 %97, 1 + %107 = icmp samesign ne i64 %106, %35 + call void @llvm.assume(i1 %107) + %108 = getelementptr inbounds nuw i8, ptr %98, i64 2 + %109 = load i8, ptr %103, align 1, !alias.scope !1055, !noalias !1058, !noundef !3 + %110 = shl nuw nsw i32 %105, 6 + %111 = and i8 %109, 63 + %112 = zext nneg i8 %111 to i32 + %113 = or disjoint i32 %110, %112 + %114 = icmp samesign ugt i8 %101, -33 + br i1 %114, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17h9270fe57bce9436eE.exit.i.i" "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit12.i.i.i.i55" - %114 = icmp ne ptr %107, %94 - call void @llvm.assume(i1 %114) - %115 = getelementptr inbounds nuw i8, ptr %98, i64 3 - %116 = load i8, ptr %107, align 1, !alias.scope !1055, !noalias !1058, !noundef !3 - %117 = shl nuw nsw i32 %111, 6 - %118 = and i8 %116, 63 - %119 = zext nneg i8 %118 to i32 - %120 = or disjoint i32 %117, %119 - %121 = shl nuw nsw i32 %105, 12 - %122 = or disjoint i32 %120, %121 - %123 = icmp samesign ugt i8 %101, -17 - br i1 %123, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit16.i.i.i.i58", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17h9270fe57bce9436eE.exit.i.i" + %115 = add nuw nsw i64 %97, 2 + %116 = icmp samesign ne i64 %115, %35 + call void @llvm.assume(i1 %116) + %117 = getelementptr inbounds nuw i8, ptr %98, i64 3 + %118 = load i8, ptr %108, align 1, !alias.scope !1055, !noalias !1058, !noundef !3 + %119 = shl nuw nsw i32 %112, 6 + %120 = and i8 %118, 63 + %121 = zext nneg i8 %120 to i32 + %122 = or disjoint i32 %119, %121 + %123 = shl nuw nsw i32 %105, 12 + %124 = or disjoint i32 %122, %123 + %125 = icmp samesign ugt i8 %101, -17 + br i1 %125, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit16.i.i.i.i58", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17h9270fe57bce9436eE.exit.i.i" "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit16.i.i.i.i58": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57" - %124 = icmp ne ptr %115, %94 - call void @llvm.assume(i1 %124) - %125 = getelementptr inbounds nuw i8, ptr %98, i64 4 - %126 = load i8, ptr %115, align 1, !alias.scope !1055, !noalias !1058, !noundef !3 - %127 = shl nuw nsw i32 %105, 18 - %128 = and i32 %127, 1835008 - %129 = shl nuw nsw i32 %120, 6 - %130 = and i8 %126, 63 - %131 = zext nneg i8 %130 to i32 - %132 = or disjoint i32 %129, %131 - %133 = or disjoint i32 %132, %128 + %126 = add nuw nsw i64 %97, 3 + %127 = icmp samesign ne i64 %126, %35 + call void @llvm.assume(i1 %127) + %128 = getelementptr inbounds nuw i8, ptr %98, i64 4 + %129 = load i8, ptr %117, align 1, !alias.scope !1055, !noalias !1058, !noundef !3 + %130 = shl nuw nsw i32 %105, 18 + %131 = and i32 %130, 1835008 + %132 = shl nuw nsw i32 %122, 6 + %133 = and i8 %129, 63 + %134 = zext nneg i8 %133 to i32 + %133 = or disjoint i32 %132, %134 + %136 = or disjoint i32 %135, %131 br label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17h9270fe57bce9436eE.exit.i.i" "_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17h9270fe57bce9436eE.exit.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit16.i.i.i.i58", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit12.i.i.i.i55" - %.sroa.0.0.ph.i.i.i = phi ptr [ %107, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit12.i.i.i.i55" ], [ %115, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57" ], [ %125, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit16.i.i.i.i58" ] - %.sroa.4.0.i.ph.i.i.i56 = phi i32 [ %112, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit12.i.i.i.i55" ], [ %122, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57" ], [ %133, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit16.i.i.i.i58" ] + %.sroa.0.0.ph.i.i.i = phi ptr [ %108, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit12.i.i.i.i55" ], [ %117, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57" ], [ %128, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit16.i.i.i.i58" ] + %.sroa.4.0.i.ph.i.i.i56 = phi i32 [ %113, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit12.i.i.i.i55" ], [ %124, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit14.i.i.i.i57" ], [ %136, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h223e5af2d791cb36E.exit16.i.i.i.i58" ] %134 = icmp samesign ult i32 %.sroa.4.0.i.ph.i.i.i56, 1114112 call void @llvm.assume(i1 %134) %135 = ptrtoint ptr %.sroa.0.0.ph.i.i.i to i64 diff --git a/bench/ruff-rs/optimized/9ccn8a2meujd26g9852zxayje.ll b/bench/ruff-rs/optimized/9ccn8a2meujd26g9852zxayje.ll index 78b999f9940..100acfcb818 100644 --- a/bench/ruff-rs/optimized/9ccn8a2meujd26g9852zxayje.ll +++ b/bench/ruff-rs/optimized/9ccn8a2meujd26g9852zxayje.ll @@ -757,45 +757,48 @@ _ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i: ; br i1 %71, label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i.preheader, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit12.i.i.i7.i" _ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i.preheader: ; preds = %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.i, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit14.i.i.i9.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit12.i.i.i7.i", %68 - %.ph = phi ptr [ %86, %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.i ], [ %78, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit14.i.i.i9.i" ], [ %74, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit12.i.i.i7.i" ], [ %69, %68 ] + %.ph = phi ptr [ %89, %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.i ], [ %80, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit14.i.i.i9.i" ], [ %75, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit12.i.i.i7.i" ], [ %69, %68 ] br label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit12.i.i.i7.i": ; preds = %68 %72 = zext i8 %70 to i32 - %73 = icmp ne ptr %69, %67 - call void @llvm.assume(i1 %73) - %74 = getelementptr inbounds nuw i8, ptr %66, i64 2 - %75 = icmp samesign ugt i8 %70, -33 - br i1 %75, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit14.i.i.i9.i", label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i.preheader + %73 = add nuw nsw i64 %7, 1 + %74 = icmp samesign ne i64 %73, %8 + call void @llvm.assume(i1 %74) + %75 = getelementptr inbounds nuw i8, ptr %66, i64 2 + %76 = icmp samesign ugt i8 %70, -33 + br i1 %76, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit14.i.i.i9.i", label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i.preheader "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit14.i.i.i9.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit12.i.i.i7.i" %76 = load i8, ptr %69, align 1, !noalias !60, !noundef !3 - %77 = icmp ne ptr %74, %67 - call void @llvm.assume(i1 %77) - %78 = getelementptr inbounds nuw i8, ptr %66, i64 3 - %79 = icmp samesign ugt i8 %70, -17 - br i1 %79, label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.i, label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i.preheader + %78 = add nuw nsw i64 %7, 2 + %79 = icmp samesign ne i64 %78, %8 + call void @llvm.assume(i1 %79) + %80 = getelementptr inbounds nuw i8, ptr %66, i64 3 + %81 = icmp samesign ugt i8 %70, -17 + br i1 %81, label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.i, label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i.preheader _ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.i: ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17haff5eb24e43505d5E.exit14.i.i.i9.i" %80 = and i8 %76, 63 %81 = zext nneg i8 %80 to i32 - %82 = load i8, ptr %74, align 1, !noalias !60, !noundef !3 + %82 = load i8, ptr %75, align 1, !noalias !60, !noundef !3 %83 = and i8 %82, 63 %84 = zext nneg i8 %83 to i32 - %85 = icmp ne ptr %78, %67 - call void @llvm.assume(i1 %85) - %86 = getelementptr inbounds nuw i8, ptr %66, i64 4 - %87 = load i8, ptr %78, align 1, !noalias !60, !noundef !3 - %88 = shl nuw nsw i32 %72, 18 - %89 = and i32 %88, 1835008 - %90 = shl nuw nsw i32 %81, 12 - %91 = shl nuw nsw i32 %84, 6 - %92 = or disjoint i32 %91, %90 - %93 = and i8 %87, 63 - %94 = zext nneg i8 %93 to i32 - %95 = or disjoint i32 %92, %94 - %96 = or disjoint i32 %95, %89 - %.not5.i4 = icmp eq i32 %96, 1114112 + %87 = add nuw nsw i64 %7, 3 + %88 = icmp samesign ne i64 %87, %8 + call void @llvm.assume(i1 %88) + %89 = getelementptr inbounds nuw i8, ptr %66, i64 4 + %90 = load i8, ptr %80, align 1, !noalias !60, !noundef !3 + %91 = shl nuw nsw i32 %72, 18 + %92 = and i32 %91, 1835008 + %91 = shl nuw nsw i32 %83, 12 + %94 = shl nuw nsw i32 %86, 6 + %95 = or disjoint i32 %94, %93 + %96 = and i8 %90, 63 + %97 = zext nneg i8 %96 to i32 + %96 = or disjoint i32 %95, %97 + %99 = or disjoint i32 %96, %92 + %.not5.i4 = icmp eq i32 %99, 1114112 br i1 %.not5.i4, label %"_ZN100_$LT$core..iter..adapters..skip..Skip$LT$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$8try_fold17h06eed86deddc6ff7E.exit", label %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i.preheader "_ZN100_$LT$core..iter..adapters..skip..Skip$LT$I$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$8try_fold17h06eed86deddc6ff7E.exit": ; preds = %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.thread.i, %"_ZN81_$LT$core..str..iter..Chars$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h3176e5866117e3aaE.exit.i.i", %"_ZN81_$LT$core..str..iter..Chars$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h3176e5866117e3aaE.exit.thread.i.i", %.loopexit.i.i.i.thread, %_ZN4core4iter6traits8iterator8Iterator3nth17h1c23de89e735c169E.exit.i diff --git a/bench/rust-analyzer-rs/optimized/1213fy5h08xh684z.ll b/bench/rust-analyzer-rs/optimized/1213fy5h08xh684z.ll index 19b1f014f0a..a0564593efd 100644 --- a/bench/rust-analyzer-rs/optimized/1213fy5h08xh684z.ll +++ b/bench/rust-analyzer-rs/optimized/1213fy5h08xh684z.ll @@ -548,14 +548,13 @@ _ZN12tracing_core8callsite15DefaultCallsite8interest17hccd71802e1b704feE.exit83. 134: ; preds = %_ZN12tracing_core8callsite15DefaultCallsite8interest17hccd71802e1b704feE.exit83.thread127 %135 = load ptr, ptr %0, align 8, !nonnull !4, !noundef !4 + %136 = getelementptr inbounds nuw i8, ptr %135, i64 132 %.idx = shl nuw nsw i64 %130, 2 - %136 = getelementptr inbounds nuw i8, ptr %135, i64 %.idx - %.ptr134 = getelementptr inbounds nuw i8, ptr %136, i64 132 - %137 = icmp eq i8 %.val72, 0 - br i1 %137, label %._crit_edge, label %.lr.ph.preheader + %136 = getelementptr inbounds nuw i8, ptr %136, i64 %.idx + %138 = icmp eq i8 %.val72, 0 + br i1 %138, label %._crit_edge, label %.lr.ph.preheader .lr.ph.preheader: ; preds = %134 - %.ptr = getelementptr inbounds nuw i8, ptr %135, i64 132 %.pre = load i32, ptr %11, align 4, !range !67 br label %.lr.ph @@ -571,10 +570,10 @@ _ZN12tracing_core8callsite15DefaultCallsite8interest17hccd71802e1b704feE.exit83. to label %"_ZN4core3ptr108drop_in_place$LT$lock_api..rwlock..RwLockWriteGuard$LT$parking_lot..raw_rwlock..RawRwLock$C$$LP$$RP$$GT$$GT$17ha5f839cf6183303aE.exit96" unwind label %81 .lr.ph: ; preds = %.lr.ph.preheader, %.lr.ph - %.sroa.0117.0133 = phi ptr [ %141, %.lr.ph ], [ %.ptr, %.lr.ph.preheader ] + %.sroa.0117.0133 = phi ptr [ %141, %.lr.ph ], [ %136, %.lr.ph.preheader ] %141 = getelementptr inbounds nuw i8, ptr %.sroa.0117.0133, i64 4 store atomic i32 %.pre, ptr %.sroa.0117.0133 seq_cst, align 4 - %142 = icmp eq ptr %141, %.ptr134 + %142 = icmp eq ptr %141, %137 br i1 %142, label %._crit_edge, label %.lr.ph "_ZN4core3ptr108drop_in_place$LT$lock_api..rwlock..RwLockWriteGuard$LT$parking_lot..raw_rwlock..RawRwLock$C$$LP$$RP$$GT$$GT$17ha5f839cf6183303aE.exit96": ; preds = %._crit_edge, %140 diff --git a/bench/rust-analyzer-rs/optimized/59xtetyz59tgy0g8.ll b/bench/rust-analyzer-rs/optimized/59xtetyz59tgy0g8.ll index c0a89888cf2..d97cd4057d8 100644 --- a/bench/rust-analyzer-rs/optimized/59xtetyz59tgy0g8.ll +++ b/bench/rust-analyzer-rs/optimized/59xtetyz59tgy0g8.ll @@ -22330,7 +22330,7 @@ common.resume: ; preds = %34, %30 to label %45 unwind label %43 "_ZN4core3ptr103drop_in_place$LT$triomphe..arc..Arc$LT$$u5b$la_arena..Idx$LT$base_db..input..CrateData$GT$$u5d$$GT$$GT$17h7ce0306dc6bff4f0E.exit": ; preds = %"_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit", %57, %43 - %.pn14 = phi { ptr, i32 } [ %44, %43 ], [ %.pn, %57 ], [ %.pn, %"_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit" ] + %.pn14 = phi { ptr, i32 } [ %44, %43 ], [ %.pn, %58 ], [ %.pn, %"_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit" ] invoke void @"_ZN4core3ptr85drop_in_place$LT$smallvec..SmallVec$LT$$u5b$hir_def..ModuleId$u3b$$u20$1$u5d$$GT$$GT$17h06ff603eae2a2cb5E"(ptr noalias noundef nonnull align 8 dereferenceable(24) %8) #37 to label %34 unwind label %92 @@ -22345,21 +22345,20 @@ common.resume: ; preds = %34, %30 store ptr %46, ptr %7, align 8 %48 = getelementptr inbounds nuw i8, ptr %7, i64 8 store i64 %47, ptr %48, align 8 + %49 = getelementptr inbounds nuw i8, ptr %46, i64 8 %.idx = shl nsw i64 %47, 2 - %49 = getelementptr i8, ptr %46, i64 %.idx - %.ptr35 = getelementptr i8, ptr %49, i64 8 - %50 = icmp eq i64 %47, 0 - br i1 %50, label %._crit_edge, label %.lr.ph + %49 = getelementptr inbounds i8, ptr %49, i64 %.idx + %51 = icmp eq i64 %47, 0 + br i1 %51, label %._crit_edge, label %.lr.ph .lr.ph: ; preds = %45 - %.ptr = getelementptr inbounds nuw i8, ptr %46, i64 8 - %51 = getelementptr inbounds nuw i8, ptr %39, i64 952 - %52 = load ptr, ptr %51, align 8, !invariant.load !212, !nonnull !212 - %53 = getelementptr inbounds nuw i8, ptr %5, i64 32 - br label %68 - -"_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit": ; preds = %75, %80, %60 - %.pn = phi { ptr, i32 } [ %61, %60 ], [ %76, %80 ], [ %76, %75 ] + %.ptr = getelementptr inbounds nuw i8, ptr %39, i64 952 + %53 = load ptr, ptr %.ptr, align 8, !invariant.load !212, !nonnull !212 + %54 = getelementptr inbounds nuw i8, ptr %5, i64 32 + br label %69 + +"_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit": ; preds = %76, %81, %61 + %.pn = phi { ptr, i32 } [ %62, %61 ], [ %77, %81 ], [ %77, %76 ] call void @llvm.experimental.noalias.scope.decl(metadata !7238) call void @llvm.experimental.noalias.scope.decl(metadata !7241) %54 = load ptr, ptr %7, align 8, !alias.scope !7244, !nonnull !212, !noundef !212 @@ -22394,15 +22393,15 @@ common.resume: ; preds = %34, %30 %66 = load ptr, ptr %7, align 8, !alias.scope !7245, !nonnull !212, !noundef !212 %67 = load atomic i64, ptr %66 acquire, align 8, !noalias !7245 invoke void @"_ZN8triomphe3arc12Arc$LT$T$GT$9drop_slow17he94c18f51f403c2aE"(ptr noalias noundef nonnull align 8 dereferenceable(16) %7) - to label %72 unwind label %43 + to label %73 unwind label %43 68: ; preds = %.lr.ph, %"_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit23" - %.sroa.0.034 = phi ptr [ %.ptr, %.lr.ph ], [ %69, %"_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit23" ] + %.sroa.0.034 = phi ptr [ %49, %.lr.ph ], [ %69, %"_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit23" ] %69 = getelementptr inbounds nuw i8, ptr %.sroa.0.034, i64 4 %70 = load i32, ptr %.sroa.0.034, align 4, !noundef !212 call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) - %71 = invoke noundef nonnull ptr %52(ptr noundef nonnull align 1 %37, i32 noundef %70) - to label %73 unwind label %60 + %71 = invoke noundef nonnull ptr %53(ptr noundef nonnull align 1 %37, i32 noundef %70) + to label %74 unwind label %60 72: ; preds = %65, %._crit_edge call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) @@ -22418,7 +22417,7 @@ common.resume: ; preds = %34, %30 call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) %74 = getelementptr inbounds nuw i8, ptr %71, i64 8 invoke void @_ZN7hir_def7nameres6DefMap16modules_for_file17h1321208f990b1096E(ptr noalias noundef nonnull sret({ { { { { ptr, ptr, {} }, i64 }, {} }, i32, [1 x i32] }, {} }) align 8 captures(none) dereferenceable(32) %4, ptr noalias noundef nonnull readonly align 8 dereferenceable(192) %74, i32 noundef %2) - to label %83 unwind label %75 + to label %84 unwind label %75 75: ; preds = %83, %73 %76 = landingpad { ptr, i32 } @@ -22438,10 +22437,10 @@ common.resume: ; preds = %34, %30 83: ; preds = %73 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(32) %5, ptr noundef nonnull align 8 dereferenceable(32) %4, i64 32, i1 false) - store ptr %6, ptr %53, align 8 + store ptr %6, ptr %54, align 8 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) invoke void @"_ZN133_$LT$smallvec..SmallVec$LT$A$GT$$u20$as$u20$core..iter..traits..collect..Extend$LT$$LT$A$u20$as$u20$smallvec..Array$GT$..Item$GT$$GT$6extend17he72cbb7c94980cabE"(ptr noalias noundef nonnull align 8 dereferenceable(24) %8, ptr noalias noundef nonnull align 8 captures(none) dereferenceable(40) %5) - to label %84 unwind label %75 + to label %85 unwind label %75 84: ; preds = %83 call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) @@ -22460,7 +22459,7 @@ common.resume: ; preds = %34, %30 "_ZN4core3ptr71drop_in_place$LT$triomphe..arc..Arc$LT$hir_def..nameres..DefMap$GT$$GT$17hd4920a138c5a3337E.exit23": ; preds = %84, %88 call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) - %91 = icmp eq ptr %69, %.ptr35 + %91 = icmp eq ptr %69, %50 br i1 %91, label %._crit_edge.loopexit, label %68 92: ; preds = %80, %57, %"_ZN4core3ptr103drop_in_place$LT$triomphe..arc..Arc$LT$$u5b$la_arena..Idx$LT$base_db..input..CrateData$GT$$u5d$$GT$$GT$17h7ce0306dc6bff4f0E.exit", %34 diff --git a/bench/salsa-rs/optimized/94dtk09x8ywmkbr4cvij0wkfj.ll b/bench/salsa-rs/optimized/94dtk09x8ywmkbr4cvij0wkfj.ll index bf36483a2cb..04215d7c37f 100644 --- a/bench/salsa-rs/optimized/94dtk09x8ywmkbr4cvij0wkfj.ll +++ b/bench/salsa-rs/optimized/94dtk09x8ywmkbr4cvij0wkfj.ll @@ -382,24 +382,23 @@ define noundef i64 @"_ZN65_$LT$thin_vec..ThinVec$LT$T$GT$$u20$as$u20$core..clone %6 = tail call fastcc noundef nonnull ptr @_ZN8thin_vec20header_with_capacity17h1296694849377d37E(i64 noundef %3) %7 = ptrtoint ptr %6 to i64 %.pre = load i64, ptr %2, align 8 + %8 = getelementptr inbounds nuw i8, ptr %2, i64 16 %.idx = mul nuw nsw i64 %.pre, 12 - %8 = getelementptr inbounds nuw i8, ptr %2, i64 %.idx - %.ptr11 = getelementptr inbounds nuw i8, ptr %8, i64 16 - %9 = icmp eq i64 %.pre, 0 + %8 = getelementptr inbounds nuw i8, ptr %8, i64 %.idx + %10 = icmp eq i64 %.pre, 0 br i1 %9, label %._crit_edge, label %.lr.ph.preheader .lr.ph.preheader: ; preds = %5 - %.ptr = getelementptr inbounds nuw i8, ptr %2, i64 16 - %10 = getelementptr inbounds nuw i8, ptr %6, i64 16 + %.ptr = getelementptr inbounds nuw i8, ptr %6, i64 16 br label %.lr.ph .lr.ph: ; preds = %.lr.ph.preheader, %.lr.ph - %.sroa.04.010 = phi ptr [ %11, %.lr.ph ], [ %.ptr, %.lr.ph.preheader ] + %.sroa.04.010 = phi ptr [ %11, %.lr.ph ], [ %.ptr5, %.lr.ph.preheader ] %.sroa.02.09 = phi ptr [ %12, %.lr.ph ], [ %10, %.lr.ph.preheader ] %11 = getelementptr inbounds nuw i8, ptr %.sroa.04.010, i64 12 tail call void @llvm.memmove.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %.sroa.02.09, ptr noundef nonnull align 4 dereferenceable(12) %.sroa.04.010, i64 12, i1 false) %12 = getelementptr inbounds nuw i8, ptr %.sroa.02.09, i64 12 - %13 = icmp eq ptr %11, %.ptr11 + %13 = icmp eq ptr %11, %9 br i1 %13, label %._crit_edge, label %.lr.ph ._crit_edge: ; preds = %.lr.ph, %5 @@ -885,8 +884,7 @@ define noundef zeroext i1 @_ZN5salsa5cycle10CycleHeads6remove17h9a9d9e05821c4125 %.ptr = getelementptr inbounds nuw i8, ptr %4, i64 16 %5 = load i64, ptr %4, align 8, !noundef !3 %.idx = mul nuw nsw i64 %5, 12 - %6 = getelementptr inbounds nuw i8, ptr %4, i64 %.idx - %.ptr4 = getelementptr inbounds nuw i8, ptr %6, i64 16 + %6 = getelementptr inbounds nuw i8, ptr %5, i64 %.idx tail call void @llvm.experimental.noalias.scope.decl(metadata !117) %7 = icmp eq i64 %5, 0 br i1 %7, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$8position17h5ee8b080077d93c6E.exit.thread", label %.lr.ph.i @@ -911,7 +909,7 @@ define noundef zeroext i1 @_ZN5salsa5cycle10CycleHeads6remove17h9a9d9e05821c4125 "_ZN5salsa5cycle10CycleHeads6remove28_$u7b$$u7b$closure$u7d$$u7d$17h3c05a81754297105E.exit.thread.i": ; preds = %11 %16 = getelementptr inbounds nuw i8, ptr %12, i64 12 %17 = add nuw nsw i64 %.sroa.02.016.i, 1 - %18 = icmp eq ptr %16, %.ptr4 + %18 = icmp eq ptr %16, %7 br i1 %18, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$8position17h5ee8b080077d93c6E.exit.thread", label %11 "_ZN8thin_vec16ThinVec$LT$T$GT$11swap_remove17ha6740ebf36556f59E.exit": ; preds = %11 @@ -936,37 +934,33 @@ define noundef zeroext i1 @_ZN5salsa5cycle10CycleHeads6remove17h9a9d9e05821c4125 ; Function Attrs: nofree norecurse nosync nounwind nonlazybind memory(readwrite, inaccessiblemem: none) uwtable define void @_ZN5salsa5cycle10CycleHeads22update_iteration_count17hfd9c951a23bebb06E(ptr noalias noundef readonly align 8 captures(none) dereferenceable(8) %0, i32 noundef range(i32 1, 0) %1, i32 noundef %2, i32 noundef %3) unnamed_addr #8 personality ptr @rust_eh_personality { %5 = load ptr, ptr %0, align 8, !alias.scope !126, !nonnull !3, !noundef !3 - %6 = load i64, ptr %5, align 8, !noundef !3 - %.idx = mul nuw nsw i64 %6, 12 - %7 = getelementptr inbounds nuw i8, ptr %5, i64 %.idx - %.ptr5 = getelementptr inbounds nuw i8, ptr %7, i64 16 + %6 = getelementptr inbounds nuw i8, ptr %5, i64 16 + %7 = load i64, ptr %5, align 8, !noundef !3 + %.idx = mul nuw nsw i64 %7, 12 + %.ptr5 = getelementptr inbounds nuw i8, ptr %6, i64 %.idx %8 = icmp eq i64 %6, 0 br i1 %8, label %"_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit.thread", label %.lr.ph.i.preheader -.lr.ph.i.preheader: ; preds = %4 - %.ptr = getelementptr inbounds nuw i8, ptr %5, i64 16 - br label %.lr.ph.i - -.lr.ph.i: ; preds = %.lr.ph.i.preheader, %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i" - %9 = phi ptr [ %10, %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i" ], [ %.ptr, %.lr.ph.i.preheader ] - %10 = getelementptr inbounds nuw i8, ptr %9, i64 12 - %11 = getelementptr inbounds nuw i8, ptr %9, i64 4 - %12 = load i32, ptr %11, align 4, !noalias !129, !noundef !3 - %13 = icmp eq i32 %12, %2 - br i1 %13, label %14, label %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i" - -14: ; preds = %.lr.ph.i - %15 = load i32, ptr %9, align 4, !range !70, !noalias !129, !noundef !3 - %16 = icmp eq i32 %15, %1 - br i1 %16, label %"_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit", label %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i" - -"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i": ; preds = %14, %.lr.ph.i - %17 = icmp eq ptr %10, %.ptr5 - br i1 %17, label %"_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit.thread", label %.lr.ph.i - -"_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit": ; preds = %14 - %18 = getelementptr inbounds nuw i8, ptr %9, i64 8 - store i32 %3, ptr %18, align 4 +.lr.ph.i.preheader: ; preds = %4, %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i" + %9 = phi ptr [ %11, %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i" ], [ %6, %4 ] + %11 = getelementptr inbounds nuw i8, ptr %9, i64 12 + %12 = getelementptr inbounds nuw i8, ptr %10, i64 4 + %12 = load i32, ptr %12, align 4, !noalias !129, !noundef !3 + %14 = icmp eq i32 %13, %2 + br i1 %14, label %15, label %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i" + +15:; preds = %.lr.ph.i.preheader + %16 = load i32, ptr %10, align 4, !range !70, !noalias !129, !noundef !3 + %17 = icmp eq i32 %16, %1 + br i1 %17, label %"_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit", label %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i" + +"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i":; preds = %15, %.lr.ph.i + %16 = icmp eq ptr %11, %8 + br i1 %16, label %"_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit.thread", label %.lr.ph.i + +"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i": ; preds = %14 + %19 = getelementptr inbounds nuw i8, ptr %10, i64 8 + store i32 %3, ptr %19, align 4 br label %"_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit.thread" "_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit.thread": ; preds = %"_ZN5salsa5cycle10CycleHeads22update_iteration_count28_$u7b$$u7b$closure$u7d$$u7d$17h0500b3d3b3a47d05E.exit.backedge.i", %4, %"_ZN94_$LT$core..slice..iter..IterMut$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4find17h21cf458abca1d394E.exit" diff --git a/bench/sentencepiece/optimized/arena.ll b/bench/sentencepiece/optimized/arena.ll index ee56f07509e..6f55aef0482 100644 --- a/bench/sentencepiece/optimized/arena.ll +++ b/bench/sentencepiece/optimized/arena.ll @@ -930,19 +930,17 @@ _ZN6google8protobuf8internal11SerialArena15AllocateAlignedEm.exit: ; preds = %22 store ptr %.0.i, ptr %4, align 8, !tbaa !53 %.ptr = getelementptr inbounds nuw i8, ptr %.0.i, i64 16 store ptr %.ptr, ptr %7, align 8, !tbaa !54 - %28 = getelementptr inbounds nuw i8, ptr %.0.i, i64 %14 - %.ptr15 = getelementptr inbounds nuw i8, ptr %28, i64 16 - store ptr %.ptr15, ptr %8, align 8, !tbaa !69 - %29 = icmp eq i64 %13, 0 - br i1 %29, label %tailrecurse, label %_ZN6google8protobuf8internal11SerialArena10AddCleanupEPvPFvS3_E.exit, !prof !39 + %28 = getelementptr inbounds nuw i8, ptr %.ptr, i64 %14 + store ptr %29, ptr %8, align 8, !tbaa !69 + %30 = icmp eq i64 %13, 0 + br i1 %30, label %tailrecurse, label %_ZN6google8protobuf8internal11SerialArena10AddCleanupEPvPFvS3_E.exit, !prof !39 _ZN6google8protobuf8internal11SerialArena10AddCleanupEPvPFvS3_E.exit: ; preds = %_ZN6google8protobuf8internal11SerialArena15AllocateAlignedEm.exit - %.ptr.le = getelementptr inbounds nuw i8, ptr %.0.i, i64 16 - store ptr %1, ptr %.ptr.le, align 8, !tbaa !59 - %30 = getelementptr inbounds nuw i8, ptr %.0.i, i64 24 - store ptr %2, ptr %30, align 8, !tbaa !57 - %31 = getelementptr inbounds nuw i8, ptr %.0.i, i64 32 - store ptr %31, ptr %7, align 8, !tbaa !54 + store ptr %1, ptr %.ptr, align 8, !tbaa !59 + %31 = getelementptr inbounds nuw i8, ptr %.0.i, i64 24 + store ptr %2, ptr %31, align 8, !tbaa !57 + %32 = getelementptr inbounds nuw i8, ptr %.0.i, i64 32 + store ptr %32, ptr %7, align 8, !tbaa !54 ret void } diff --git a/bench/slurm/optimized/numa.ll b/bench/slurm/optimized/numa.ll index 9e3c01b58e3..2361902b51a 100644 --- a/bench/slurm/optimized/numa.ll +++ b/bench/slurm/optimized/numa.ll @@ -361,13 +361,13 @@ define dso_local range(i32 0, 2) i32 @get_memset(ptr noundef %0, ptr noundef rea %90 = trunc i64 %89 to i32 %sext.i = shl i64 %89, 32 %91 = ashr exact i64 %sext.i, 32 - %92 = getelementptr inbounds i8, ptr %9, i64 %91 - %93 = call i32 @numa_max_node() #8 - %94 = icmp sgt i32 %90, 1 + %92 = call i32 @numa_max_node() #8 + %93 = icmp sgt i32 %90, 1 %lhsv = load i16, ptr %9, align 16 %.not103 = icmp eq i16 %lhsv, 30768 - %95 = select i1 %94, i1 %.not103, i1 false + %95 = select i1 %93, i1 %.not103, i1 false %.050.i.idx.sroa.sel.idx.sroa.sel.idx = select i1 %95, i64 2, i64 0 + %.050.i.idx.sroa.sel.idx.sroa.sel.idx = select i1 %94, i64 2, i64 0 %.050.i.idx.sroa.sel.idx.sroa.sel = getelementptr inbounds nuw i8, ptr %9, i64 %.050.i.idx.sroa.sel.idx.sroa.sel.idx call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #8 %96 = getelementptr inbounds nuw i8, ptr %6, i64 8 @@ -375,12 +375,13 @@ define dso_local range(i32 0, 2) i32 @get_memset(ptr noundef %0, ptr noundef rea store i64 128, ptr %6, align 8 %97 = call ptr @numa_bitmask_clearall(ptr noundef nonnull %6) #8 call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #8 - %.05386.i = getelementptr inbounds i8, ptr %92, i64 -1 - %.not5987.i = icmp ult ptr %.05386.i, %.050.i.idx.sroa.sel.idx.sroa.sel - br i1 %.not5987.i, label %_str_to_memset.exit, label %.lr.ph.preheader.i + %.not5987.i.not = icmp sgt i64 %91, %.050.i.idx + br i1 %.not5987.i.not, label %.lr.ph.preheader.i, label %_str_to_memset.exit .lr.ph.preheader.i: ; preds = %88 - %98 = sext i32 %93 to i64 + %97 = getelementptr i8, ptr %9, i64 %91 + %.05386.i = getelementptr i8, ptr %97, i64 -1 + %98 = sext i32 %92 to i64 br label %.lr.ph.i .lr.ph.i: ; preds = %154, %.lr.ph.preheader.i diff --git a/bench/typst-rs/optimized/1ru1rhojhbz2vfey.ll b/bench/typst-rs/optimized/1ru1rhojhbz2vfey.ll index 7c6d01a3188..a8abdb61d37 100644 --- a/bench/typst-rs/optimized/1ru1rhojhbz2vfey.ll +++ b/bench/typst-rs/optimized/1ru1rhojhbz2vfey.ll @@ -43840,12 +43840,11 @@ define internal fastcc void @_ZN5alloc6string6String6retain17hdc7618b11ce95eceE( .lr.ph: ; preds = %1 %4 = getelementptr inbounds nuw i8, ptr %0, i64 8 %5 = load ptr, ptr %4, align 8, !nonnull !5, !noundef !5 - %6 = getelementptr inbounds i8, ptr %5, i64 %3 - br label %7 + br label %6 7: ; preds = %.lr.ph, %56 - %.sroa.7.091 = phi i64 [ 0, %.lr.ph ], [ %57, %56 ] - %.sroa.14.090 = phi i64 [ 0, %.lr.ph ], [ %.sroa.14.1, %56 ] + %.sroa.7.091 = phi i64 [ 0, %.lr.ph ], [ %57, %58 ] + %.sroa.14.090 = phi i64 [ 0, %.lr.ph ], [ %.sroa.14.1, %58 ] %8 = getelementptr inbounds i8, ptr %5, i64 %.sroa.7.091 %9 = load i8, ptr %8, align 1, !noalias !9140, !noundef !5 %10 = icmp sgt i8 %9, -1 @@ -43855,7 +43854,8 @@ define internal fastcc void @_ZN5alloc6string6String6retain17hdc7618b11ce95eceE( %11 = getelementptr inbounds nuw i8, ptr %8, i64 1 %12 = and i8 %9, 31 %13 = zext nneg i8 %12 to i32 - %14 = icmp ne ptr %11, %6 + %13 = add nuw nsw i64 %.sroa.7.091, 1 + %14 = icmp ne i64 %13, %3 tail call void @llvm.assume(i1 %14) %15 = load i8, ptr %11, align 1, !noalias !9140, !noundef !5 %16 = shl nuw nsw i32 %13, 6 @@ -43871,31 +43871,33 @@ define internal fastcc void @_ZN5alloc6string6String6retain17hdc7618b11ce95eceE( "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit15.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit13.i" %22 = getelementptr inbounds nuw i8, ptr %8, i64 2 - %23 = icmp ne ptr %22, %6 - tail call void @llvm.assume(i1 %23) - %24 = load i8, ptr %22, align 1, !noalias !9140, !noundef !5 - %25 = shl nuw nsw i32 %18, 6 - %26 = and i8 %24, 63 - %27 = zext nneg i8 %26 to i32 - %28 = or disjoint i32 %25, %27 - %29 = shl nuw nsw i32 %13, 12 - %30 = or disjoint i32 %28, %29 - %31 = icmp samesign ugt i8 %9, -17 - br i1 %31, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit17.i", label %44 + %23 = add nsw i64 %.sroa.7.091, 2 + %24 = icmp ne i64 %23, %3 + tail call void @llvm.assume(i1 %24) + %25 = load i8, ptr %22, align 1, !noalias !9140, !noundef !5 + %26 = shl nuw nsw i32 %18, 6 + %27 = and i8 %25, 63 + %28 = zext nneg i8 %27 to i32 + %29 = or disjoint i32 %26, %28 + %30 = shl nuw nsw i32 %12, 12 + %31 = or disjoint i32 %29, %30 + %32 = icmp samesign ugt i8 %8, -17 + br i1 %32, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit17.i", label %46 "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit17.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit15.i" %32 = getelementptr inbounds nuw i8, ptr %8, i64 3 - %33 = icmp ne ptr %32, %6 - tail call void @llvm.assume(i1 %33) - %34 = load i8, ptr %32, align 1, !noalias !9140, !noundef !5 - %35 = shl nuw nsw i32 %13, 18 - %36 = and i32 %35, 1835008 - %37 = shl nuw nsw i32 %28, 6 - %38 = and i8 %34, 63 - %39 = zext nneg i8 %38 to i32 - %40 = or disjoint i32 %37, %39 - %41 = or disjoint i32 %40, %36 - br label %44 + %34 = add nsw i64 %.sroa.7.091, 3 + %35 = icmp ne i64 %34, %3 + tail call void @llvm.assume(i1 %35) + %36 = load i8, ptr %33, align 1, !noalias !9140, !noundef !5 + %37 = shl nuw nsw i32 %13, 18 + %38 = and i32 %37, 1835008 + %39 = shl nuw nsw i32 %29, 6 + %40 = and i8 %36, 63 + %41 = zext nneg i8 %40 to i32 + %41 = or disjoint i32 %39, %41 + %43 = or disjoint i32 %42, %38 + br label %46 ._crit_edge.loopexit: ; preds = %56 %42 = sub i64 %57, %.sroa.14.1 @@ -43907,7 +43909,7 @@ define internal fastcc void @_ZN5alloc6string6String6retain17hdc7618b11ce95eceE( ret void 44: ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit17.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit15.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit13.i" - %.sroa.4.0.i.ph = phi i32 [ %19, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit13.i" ], [ %30, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit15.i" ], [ %41, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit17.i" ] + %.sroa.4.0.i.ph = phi i32 [ %19, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit13.i" ], [ %31, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit15.i" ], [ %43, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h56b22c765953e12eE.exit17.i" ] %.sroa.4.0.i.ph.fr = freeze i32 %.sroa.4.0.i.ph %45 = icmp ne i32 %.sroa.4.0.i.ph.fr, 1114112 tail call void @llvm.assume(i1 %45) @@ -43924,10 +43926,10 @@ define internal fastcc void @_ZN5alloc6string6String6retain17hdc7618b11ce95eceE( br label %51 51: ; preds = %49, %.thread47, %47, %44 - %52 = phi i1 [ true, %44 ], [ false, %47 ], [ true, %.thread47 ], [ false, %49 ] - %53 = phi i32 [ %.sroa.4.0.i.ph.fr, %44 ], [ %.sroa.4.0.i.ph.fr, %47 ], [ %21, %.thread47 ], [ %.sroa.4.0.i.ph.fr, %49 ] - %.027 = phi i64 [ 1, %44 ], [ 2, %47 ], [ 1, %.thread47 ], [ %spec.select, %49 ] - switch i32 %53, label %55 [ + %52 = phi i1 [ true, %46 ], [ false, %49 ], [ true, %.thread47 ], [ false, %51 ] + %53 = phi i32 [ %.sroa.4.0.i.ph.fr, %46 ], [ %.sroa.4.0.i.ph.fr, %49 ], [ %21, %.thread47 ], [ %.sroa.4.0.i.ph.fr, %51 ] + %.027 = phi i64 [ 1, %46 ], [ 2, %49 ], [ 1, %.thread47 ], [ %spec.select, %51 ] + switch i32 %53, label %57 [ i32 9, label %"_ZN5plist6stream10xml_reader20ReaderState$LT$R$GT$9read_next28_$u7b$$u7b$closure$u7d$$u7d$17hf1466f004c11eb6dE.exit" i32 10, label %"_ZN5plist6stream10xml_reader20ReaderState$LT$R$GT$9read_next28_$u7b$$u7b$closure$u7d$$u7d$17hf1466f004c11eb6dE.exit" i32 12, label %"_ZN5plist6stream10xml_reader20ReaderState$LT$R$GT$9read_next28_$u7b$$u7b$closure$u7d$$u7d$17hf1466f004c11eb6dE.exit" @@ -43944,7 +43946,7 @@ define internal fastcc void @_ZN5alloc6string6String6retain17hdc7618b11ce95eceE( br i1 %.not, label %56, label %59 56: ; preds = %66, %55, %"_ZN5plist6stream10xml_reader20ReaderState$LT$R$GT$9read_next28_$u7b$$u7b$closure$u7d$$u7d$17hf1466f004c11eb6dE.exit" - %.sroa.14.1 = phi i64 [ 0, %55 ], [ %.sroa.14.090, %66 ], [ %54, %"_ZN5plist6stream10xml_reader20ReaderState$LT$R$GT$9read_next28_$u7b$$u7b$closure$u7d$$u7d$17hf1466f004c11eb6dE.exit" ] + %.sroa.14.1 = phi i64 [ 0, %57 ], [ %.sroa.14.090, %68 ], [ %54, %"_ZN5plist6stream10xml_reader20ReaderState$LT$R$GT$9read_next28_$u7b$$u7b$closure$u7d$$u7d$17hf1466f004c11eb6dE.exit" ] %57 = add i64 %.027, %.sroa.7.091 %58 = icmp ult i64 %57, %3 br i1 %58, label %7, label %._crit_edge.loopexit @@ -43956,7 +43958,7 @@ define internal fastcc void @_ZN5alloc6string6String6retain17hdc7618b11ce95eceE( 62: ; preds = %59 %63 = icmp samesign ult i32 %53, 2048 - br i1 %63, label %66, label %64 + br i1 %63, label %66, label %67 64: ; preds = %62 %65 = icmp ult i32 %53, 65536 @@ -43964,9 +43966,9 @@ define internal fastcc void @_ZN5alloc6string6String6retain17hdc7618b11ce95eceE( br label %66 66: ; preds = %64, %62, %59 - %.029 = phi i64 [ 1, %59 ], [ 2, %62 ], [ %spec.select87, %64 ] + %.029 = phi i64 [ 1, %61 ], [ 2, %64 ], [ %spec.select87, %66 ] invoke fastcc void @_ZN4core4char7methods15encode_utf8_raw17hb4a1fb525f58c43bE(i32 noundef %53, ptr noalias noundef nonnull align 1 %61, i64 noundef %.029) - to label %56 unwind label %67 + to label %58 unwind label %67 67: ; preds = %66 %68 = landingpad { ptr, i32 } diff --git a/bench/uv-rs/optimized/32ql9ocq6kkdl5jg2dnp7csot.ll b/bench/uv-rs/optimized/32ql9ocq6kkdl5jg2dnp7csot.ll index 5b484f0fd1b..b352ce2f4e7 100644 --- a/bench/uv-rs/optimized/32ql9ocq6kkdl5jg2dnp7csot.ll +++ b/bench/uv-rs/optimized/32ql9ocq6kkdl5jg2dnp7csot.ll @@ -13915,8 +13915,8 @@ define hidden void @"_ZN5alloc11collections5btree6search142_$LT$impl$u20$alloc.. br i1 %5, label %.split.us.i.us, label %.split.i.preheader .split.us.i.us: ; preds = %4, %12 - %.sroa.3.0.us = phi i64 [ %15, %12 ], [ %2, %4 ] - %.sroa.0.0.us = phi ptr [ %14, %12 ], [ %1, %4 ] + %.sroa.3.0.us = phi i64 [ %15, %13 ], [ %2, %4 ] + %.sroa.0.0.us = phi ptr [ %14, %13 ], [ %1, %4 ] %7 = getelementptr inbounds nuw i8, ptr %.sroa.0.0.us, i64 98 %8 = load i16, ptr %7, align 2, !noundef !12 %9 = icmp eq i16 %8, 0 @@ -13939,27 +13939,28 @@ define hidden void @"_ZN5alloc11collections5btree6search142_$LT$impl$u20$alloc.. br label %.split.us.i.us .split.i.preheader: ; preds = %4, %38 - %.sroa.3.0 = phi i64 [ %43, %38 ], [ %2, %4 ] - %.sroa.0.0 = phi ptr [ %42, %38 ], [ %1, %4 ] - %16 = getelementptr inbounds nuw i8, ptr %.sroa.0.0, i64 98 - %17 = load i16, ptr %16, align 2, !noundef !12 - %18 = zext i16 %17 to i64 - %.idx.i = shl nuw nsw i64 %18, 3 - %19 = getelementptr inbounds nuw i8, ptr %.sroa.0.0, i64 %.idx.i + %.sroa.3.0 = phi i64 [ %43, %41 ], [ %2, %4 ] + %.sroa.0.0 = phi ptr [ %42, %41 ], [ %1, %4 ] + %16 = getelementptr inbounds nuw i8, ptr %.sroa.0.0, i64 8 + %18 = getelementptr inbounds nuw i8, ptr %.sroa.0.0, i64 98 + %19 = load i16, ptr %18, align 2, !noundef !12 + %20 = zext i16 %19 to i64 + %.idx.i = shl nuw nsw i64 %20, 3 + %21 = getelementptr inbounds nuw i8, ptr %17, i64 %.idx.i br label %.split.i .split.i: ; preds = %.split.i.preheader, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" - %.sroa.03.0.i.pn = phi ptr [ %.sroa.03.0.i, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ %.sroa.0.0, %.split.i.preheader ] - %.sroa.8.0.i = phi i64 [ %22, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ 0, %.split.i.preheader ] - %.sroa.03.0.i = getelementptr inbounds nuw i8, ptr %.sroa.03.0.i.pn, i64 8 - %20 = icmp eq ptr %.sroa.03.0.i.pn, %19 - br i1 %20, label %.loopexit, label %21 + %.sroa.03.0.i.pn = phi ptr [ %24, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ %17, %.split.i.preheader ] + %.sroa.8.0.i = phi i64 [ %25, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ 0, %.split.i.preheader ] + %22 = icmp eq ptr %.sroa.03.0.i.pn, %21 + br i1 %22, label %.loopexit, label %21 default.unreachable.i: ; preds = %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" unreachable 21: ; preds = %.split.i - %22 = add nuw nsw i64 %.sroa.8.0.i, 1 + %24 = getelementptr inbounds nuw i8, ptr %.sroa.03.0.i, i64 8 + %25 = add nuw nsw i64 %.sroa.8.0.i, 1 %.val7.i = load ptr, ptr %.sroa.03.0.i, align 8 %23 = icmp eq ptr %.val7.i, null br i1 %23, label %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i", label %24 @@ -13968,15 +13969,15 @@ default.unreachable.i: ; preds = %"_ZN64_$LT$core..op tail call void @llvm.experimental.noalias.scope.decl(metadata !1896) tail call void @llvm.experimental.noalias.scope.decl(metadata !1899) %25 = load i8, ptr %6, align 1, !alias.scope !1896, !noalias !1899, !noundef !12 - %26 = icmp eq i8 %25, 0 - %27 = getelementptr inbounds nuw i8, ptr %.val7.i, i64 9 - %28 = load i8, ptr %27, align 1, !alias.scope !1899, !noalias !1896 %29 = icmp eq i8 %28, 0 - %or.cond.i.i.i.i = select i1 %26, i1 true, i1 %29 - br i1 %or.cond.i.i.i.i, label %30, label %32 - -30: ; preds = %24 - %31 = tail call noundef i8 @_ZN9uv_pep4407version7Version8cmp_slow17h0f231608b8457a21E(ptr noalias noundef nonnull readonly align 8 dereferenceable(16) %.0.val1.fr.i, ptr noalias noundef nonnull readonly align 8 dereferenceable(16) %.val7.i) + %30 = getelementptr inbounds nuw i8, ptr %.val7.i, i64 9 + %31 = load i8, ptr %30, align 1, !alias.scope !1899, !noalias !1896 + %32 = icmp eq i8 %31, 0 + %or.cond.i.i.i.i = select i1 %29, i1 true, i1 %32 + br i1 %or.cond.i.i.i.i, label %33, label %35 + +33: ; preds = %27 + %34 = tail call noundef i8 @_ZN9uv_pep4407version7Version8cmp_slow17h0f231608b8457a21E(ptr noalias noundef nonnull readonly align 8 dereferenceable(16) %.0.val1.fr.i, ptr noalias noundef nonnull readonly align 8 dereferenceable(16) %.val7.i) br label %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" 32: ; preds = %24 @@ -13985,8 +13986,8 @@ default.unreachable.i: ; preds = %"_ZN64_$LT$core..op %35 = tail call i8 @llvm.ucmp.i8.i64(i64 %33, i64 %34) br label %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" -"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i": ; preds = %32, %30, %21 - %.sroa.0.0.i8.i = phi i8 [ 1, %21 ], [ %31, %30 ], [ %35, %32 ] +"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i": ; preds = %32, %33, %21 + %.sroa.0.0.i8.i = phi i8 [ 1, %23 ], [ %34, %33 ], [ %35, %35 ] switch i8 %.sroa.0.0.i8.i, label %default.unreachable.i [ i8 -1, label %.loopexit i8 0, label %.split73.us @@ -13994,15 +13995,15 @@ default.unreachable.i: ; preds = %"_ZN64_$LT$core..op ] .loopexit: ; preds = %.split.i, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" - %.sroa.4.0.i.ph.ph = phi i64 [ %.sroa.8.0.i, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ %18, %.split.i ] + %.sroa.4.0.i.ph.ph = phi i64 [ %.sroa.8.0.i, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ %20, %.split.i ] %36 = icmp eq i64 %.sroa.3.0, 0 br i1 %36, label %.split73.us, label %38 .split73.us: ; preds = %.loopexit, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i", %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us", %10 - %.us-phi75.sink = phi ptr [ %.sroa.0.0.us, %10 ], [ %.sroa.0.0.us, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us" ], [ %.sroa.0.0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ %.sroa.0.0, %.loopexit ] - %.sink = phi i64 [ %.sroa.3.0.us, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us" ], [ 0, %10 ], [ %.sroa.3.0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ 0, %.loopexit ] - %.us-phi74.sink = phi i64 [ 0, %10 ], [ 0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us" ], [ %.sroa.8.0.i, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ %.sroa.4.0.i.ph.ph, %.loopexit ] - %.sroa.0.0.i57 = phi i64 [ 0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us" ], [ 1, %10 ], [ 0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ 1, %.loopexit ] + %.us-phi75.sink = phi ptr [ %.sroa.0.0.us, %11 ], [ %.sroa.0.0.us, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us" ], [ %.sroa.0.0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ %.sroa.0.0, %.loopexit ] + %.sink = phi i64 [ %.sroa.3.0.us, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us" ], [ 0, %11 ], [ %.sroa.3.0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ 0, %.loopexit ] + %.us-phi74.sink = phi i64 [ 0, %11 ], [ 0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us" ], [ %.sroa.8.0.i, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ %.sroa.4.0.i.ph.ph, %.loopexit ] + %.sroa.0.0.i57 = phi i64 [ 0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.us.i.us" ], [ 1, %11 ], [ 0, %"_ZN64_$LT$core..option..Option$LT$T$GT$$u20$as$u20$core..cmp..Ord$GT$3cmp17ha382ee7fcb653d49E.exit.i" ], [ 1, %.loopexit ] %37 = getelementptr inbounds nuw i8, ptr %0, i64 8 store ptr %.us-phi75.sink, ptr %37, align 8 %.sroa.242.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 16 diff --git a/bench/uv-rs/optimized/53w83c036esehszikh9jad1ng.ll b/bench/uv-rs/optimized/53w83c036esehszikh9jad1ng.ll index f4bd25f2302..db28f26640d 100644 --- a/bench/uv-rs/optimized/53w83c036esehszikh9jad1ng.ll +++ b/bench/uv-rs/optimized/53w83c036esehszikh9jad1ng.ll @@ -8782,57 +8782,60 @@ define hidden void @"_ZN16uv_install_wheel5wheel16read_record_file28_$u7b$$u7b$c %23 = getelementptr inbounds nuw i8, ptr %21, i64 1 %24 = load i8, ptr %21, align 1, !alias.scope !3288, !noalias !3291, !noundef !17 %25 = icmp sgt i8 %24, -1 - br i1 %25, label %36, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" + br i1 %25, label %37, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i": ; preds = %22 %26 = and i8 %24, 31 %27 = zext nneg i8 %26 to i32 - %28 = icmp ne ptr %23, %16 - tail call void @llvm.assume(i1 %28) - %29 = getelementptr inbounds nuw i8, ptr %21, i64 2 - %30 = load i8, ptr %23, align 1, !alias.scope !3288, !noalias !3291, !noundef !17 - %31 = shl nuw nsw i32 %27, 6 - %32 = and i8 %30, 63 - %33 = zext nneg i8 %32 to i32 - %34 = or disjoint i32 %31, %33 - %35 = icmp samesign ugt i8 %24, -33 - br i1 %35, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i" - -36: ; preds = %22 - %37 = zext nneg i8 %24 to i32 + %28 = add nsw i64 %20, 1 + %29 = icmp ne i64 %28, %15 + tail call void @llvm.assume(i1 %29) + %30 = getelementptr inbounds nuw i8, ptr %21, i64 2 + %31 = load i8, ptr %23, align 1, !alias.scope !3288, !noalias !3291, !noundef !17 + %32 = shl nuw nsw i32 %27, 6 + %33 = and i8 %31, 63 + %34 = zext nneg i8 %33 to i32 + %35 = or disjoint i32 %32, %34 + %36 = icmp samesign ugt i8 %24, -33 + br i1 %36, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i" + +37:; preds = %22 + %38 = zext nneg i8 %24 to i32 br label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i" "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" - %38 = icmp ne ptr %29, %16 - tail call void @llvm.assume(i1 %38) - %39 = getelementptr inbounds nuw i8, ptr %21, i64 3 - %40 = load i8, ptr %29, align 1, !alias.scope !3288, !noalias !3291, !noundef !17 - %41 = shl nuw nsw i32 %33, 6 - %42 = and i8 %40, 63 - %43 = zext nneg i8 %42 to i32 - %44 = or disjoint i32 %41, %43 - %45 = shl nuw nsw i32 %27, 12 - %46 = or disjoint i32 %44, %45 - %47 = icmp samesign ugt i8 %24, -17 - br i1 %47, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i" + %39 = add nsw i64 %20, 2 + %40 = icmp ne i64 %39, %15 + tail call void @llvm.assume(i1 %40) + %41 = getelementptr inbounds nuw i8, ptr %21, i64 3 + %42 = load i8, ptr %30, align 1, !alias.scope !3288, !noalias !3291, !noundef !17 + %43 = shl nuw nsw i32 %34, 6 + %44 = and i8 %42, 63 + %45 = zext nneg i8 %44 to i32 + %46 = or disjoint i32 %43, %45 + %47 = shl nuw nsw i32 %27, 12 + %48 = or disjoint i32 %46, %47 + %49 = icmp samesign ugt i8 %24, -17 + br i1 %49, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i", label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i" "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i" - %48 = icmp ne ptr %39, %16 - tail call void @llvm.assume(i1 %48) - %49 = getelementptr inbounds nuw i8, ptr %21, i64 4 - %50 = load i8, ptr %39, align 1, !alias.scope !3288, !noalias !3291, !noundef !17 - %51 = shl nuw nsw i32 %27, 18 - %52 = and i32 %51, 1835008 - %53 = shl nuw nsw i32 %44, 6 - %54 = and i8 %50, 63 - %55 = zext nneg i8 %54 to i32 - %56 = or disjoint i32 %53, %55 - %57 = or disjoint i32 %56, %52 + %50 = add nsw i64 %20, 3 + %51 = icmp ne i64 %50, %15 + tail call void @llvm.assume(i1 %51) + %52 = getelementptr inbounds nuw i8, ptr %21, i64 4 + %53 = load i8, ptr %41, align 1, !alias.scope !3288, !noalias !3291, !noundef !17 + %54 = shl nuw nsw i32 %27, 18 + %55 = and i32 %54, 1835008 + %56 = shl nuw nsw i32 %46, 6 + %57 = and i8 %53, 63 + %58 = zext nneg i8 %57 to i32 + %57 = or disjoint i32 %56, %58 + %60 = or disjoint i32 %59, %55 br label %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i" -"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i", %36, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" - %.sroa.0.0.ph.i.i.i = phi ptr [ %29, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" ], [ %39, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i" ], [ %49, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i" ], [ %23, %36 ] - %.sroa.4.0.i.ph.i.i.i = phi i32 [ %34, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" ], [ %46, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i" ], [ %57, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i" ], [ %37, %36 ] +"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i", %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i", %37, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" + %.sroa.0.0.ph.i.i.i = phi ptr [ %30, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" ], [ %41, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i" ], [ %52, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i" ], [ %23, %37 ] + %.sroa.4.0.i.ph.i.i.i = phi i32 [ %35, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit12.i.i.i.i" ], [ %48, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit14.i.i.i.i" ], [ %60, %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17h79d57ab947f0ae04E.exit16.i.i.i.i" ], [ %38, %37 ] %58 = icmp samesign ult i32 %.sroa.4.0.i.ph.i.i.i, 1114112 tail call void @llvm.assume(i1 %58) %59 = ptrtoint ptr %.sroa.0.0.ph.i.i.i to i64 @@ -8850,7 +8853,7 @@ define hidden void @"_ZN16uv_install_wheel5wheel16read_record_file28_$u7b$$u7b$c %64 = landingpad { ptr, i32 } cleanup invoke void @"_ZN4core3ptr58drop_in_place$LT$uv_install_wheel..record..RecordEntry$GT$17hbe0eb8567d4c3ff7E"(ptr noalias noundef nonnull align 8 dereferenceable(64) %6) #57 - to label %89 unwind label %87 + to label %92 unwind label %87 65: ; preds = %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i", %19 %.lcssa.i = phi i64 [ %20, %"_ZN81_$LT$core..str..pattern..CharSearcher$u20$as$u20$core..str..pattern..Searcher$GT$4next17hbab75857ba3b407dE.exit.i.i" ], [ %15, %19 ] diff --git a/bench/wireshark/optimized/decode_as_model.ll b/bench/wireshark/optimized/decode_as_model.ll index 1d31216f20c..78fecda3bf9 100644 --- a/bench/wireshark/optimized/decode_as_model.ll +++ b/bench/wireshark/optimized/decode_as_model.ll @@ -4011,8 +4011,8 @@ _ZN17QArrayDataPointerIP12DecodeAsItemE6detachEPS2_.exit.i: ; preds = %_ZNK17QAr %31 = getelementptr inbounds nuw i8, ptr %0, i64 16 %32 = load i64, ptr %31, align 8 %.idx3.i = shl i64 %32, 3 - %33 = getelementptr i8, ptr %27, i64 %.idx3.i - %.not.i.i = icmp eq ptr %29, %33 + %33 = add i64 %.idx.i, 8 + %.not.i.i = icmp eq i64 %33, %.idx4.i %or.cond.i.i = select i1 %30, i1 true, i1 %.not.i.i br i1 %or.cond.i.i, label %._crit_edge.i.i, label %34 @@ -4024,8 +4024,7 @@ _ZN17QArrayDataPointerIP12DecodeAsItemE6detachEPS2_.exit.i: ; preds = %_ZNK17QAr br i1 %.not.i.i, label %_ZN5QListIP12DecodeAsItemE6removeExx.exit, label %35 35: ; preds = %._crit_edge.i.i - %reass.sub = sub i64 %.idx3.i, %.idx.i - %gepdiff.i = add i64 %reass.sub, -8 + %reass.sub = sub i64 %.idx3.i, %33 tail call void @llvm.memmove.p0.p0.i64(ptr noundef align 1 %28, ptr noundef align 1 %29, i64 noundef %gepdiff.i, i1 noundef false) #23 %.pre12.i.i = load i64, ptr %31, align 8 br label %_ZN5QListIP12DecodeAsItemE6removeExx.exit diff --git a/bench/z3/optimized/ddnf.ll b/bench/z3/optimized/ddnf.ll index 71150041cc1..90d687bcd3e 100644 --- a/bench/z3/optimized/ddnf.ll +++ b/bench/z3/optimized/ddnf.ll @@ -2066,31 +2066,33 @@ _ZNK15ref_vector_coreIN7datalog9ddnf_nodeE19ref_manager_wrapperIS1_NS0_8ddnf_mgr br i1 %11, label %12, label %8 12: ; preds = %.lr.ph - %13 = getelementptr inbounds nuw ptr, ptr %4, i64 %indvars.iv - %14 = getelementptr inbounds i8, ptr %4, i64 -4 - %15 = load i32, ptr %14, align 4, !tbaa !57 - %16 = zext i32 %15 to i64 - %17 = getelementptr inbounds nuw ptr, ptr %4, i64 %16 - %.010.i.i = getelementptr inbounds nuw i8, ptr %13, i64 8 - %.not11.i.i = icmp eq ptr %.010.i.i, %17 + %.idx.i = shl nuw nsw i64 %indvars.iv, 3 + %14 = getelementptr inbounds nuw i8, ptr %4, i64 %.idx.i + %15 = load ptr, ptr %14, align 8, !tbaa !58 + %15 = getelementptr inbounds i8, ptr %4, i64 -4 + %16 = load i32, ptr %15, align 4, !tbaa !57 + %17 = zext i32 %16 to i64 + %.idx3.i = shl nuw nsw i64 %17, 3 + %18 = add nuw nsw i64 %.idx.i, 8 + %.not11.i.i = icmp samesign eq i64 %18, %.idx3.i br i1 %.not11.i.i, label %_ZN6vectorIPN7datalog9ddnf_nodeELb0EjE5eraseEPS2_.exit.i, label %.lr.ph.preheader.i.i .lr.ph.preheader.i.i: ; preds = %12 - %18 = ptrtoint ptr %4 to i64 - %19 = ptrtoint ptr %13 to i64 - %20 = shl nuw nsw i64 %16, 3 - %21 = add i64 %18, -16 - %22 = sub i64 %21, %19 - %23 = add i64 %22, %20 + %.010.i.i = getelementptr inbounds nuw i8, ptr %14, i64 8 + %19 = ptrtoint ptr %4 to i64 + %20 = ptrtoint ptr %13 to i64 + %21 = add i64 %19, -16 + %22 = sub i64 %21, %20 + %23 = add i64 %22, %.idx3.i %24 = and i64 %23, -8 %25 = add i64 %24, 8 tail call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %13, ptr nonnull align 8 %.010.i.i, i64 %25, i1 false), !tbaa !58 br label %_ZN6vectorIPN7datalog9ddnf_nodeELb0EjE5eraseEPS2_.exit.i _ZN6vectorIPN7datalog9ddnf_nodeELb0EjE5eraseEPS2_.exit.i: ; preds = %.lr.ph.preheader.i.i, %12 - %26 = add i32 %15, -1 - store i32 %26, ptr %14, align 4, !tbaa !57 - %27 = getelementptr inbounds nuw i8, ptr %10, i64 32 + %26 = add i32 %16, -1 + store i32 %26, ptr %15, align 4, !tbaa !57 + %27 = getelementptr inbounds nuw i8, ptr %14, i64 32 %28 = load i32, ptr %27, align 8, !tbaa !53 %29 = add i32 %28, -1 store i32 %29, ptr %27, align 8, !tbaa !53 @@ -2098,7 +2100,7 @@ _ZN6vectorIPN7datalog9ddnf_nodeELb0EjE5eraseEPS2_.exit.i: ; preds = %.lr.ph.preh br i1 %30, label %31, label %_ZN15ref_vector_coreIN7datalog9ddnf_nodeE19ref_manager_wrapperIS1_NS0_8ddnf_mgrEEE5eraseEj.exit 31: ; preds = %_ZN6vectorIPN7datalog9ddnf_nodeELb0EjE5eraseEPS2_.exit.i - %32 = getelementptr inbounds nuw i8, ptr %10, i64 72 + %32 = getelementptr inbounds nuw i8, ptr %14, i64 72 %33 = load ptr, ptr %32, align 8, !tbaa !47 %34 = icmp eq ptr %33, null br i1 %34, label %_Z7deallocIN7datalog9ddnf_nodeEEvPT_.exit.i.i.i, label %35 @@ -2116,9 +2118,9 @@ _ZN6vectorIPN7datalog9ddnf_nodeELb0EjE5eraseEPS2_.exit.i: ; preds = %.lr.ph.preh _Z7deallocIN7datalog9ddnf_nodeEEvPT_.exit.i.i.i: ; preds = %35, %31 store ptr null, ptr %32, align 8, !tbaa !47 - %39 = getelementptr inbounds nuw i8, ptr %10, i64 16 + %39 = getelementptr inbounds nuw i8, ptr %14, i64 16 tail call void @_ZN15ref_vector_coreIN7datalog9ddnf_nodeE19ref_manager_wrapperIS1_NS0_8ddnf_mgrEEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %39) #26 - tail call void @_ZN6memory10deallocateEPv(ptr noundef nonnull align 8 dereferenceable(96) %10) + tail call void @_ZN6memory10deallocateEPv(ptr noundef nonnull align 8 dereferenceable(96) %14) br label %_ZN15ref_vector_coreIN7datalog9ddnf_nodeE19ref_manager_wrapperIS1_NS0_8ddnf_mgrEEE5eraseEj.exit _ZN15ref_vector_coreIN7datalog9ddnf_nodeE19ref_manager_wrapperIS1_NS0_8ddnf_mgrEEE5eraseEj.exit: ; preds = %8, %2, %_ZNK15ref_vector_coreIN7datalog9ddnf_nodeE19ref_manager_wrapperIS1_NS0_8ddnf_mgrEEE4sizeEv.exit, %_Z7deallocIN7datalog9ddnf_nodeEEvPT_.exit.i.i.i, %_ZN6vectorIPN7datalog9ddnf_nodeELb0EjE5eraseEPS2_.exit.i diff --git a/bench/z3/optimized/fix_dl_var_tactic.ll b/bench/z3/optimized/fix_dl_var_tactic.ll index e3bfc536f9e..722adb67389 100644 --- a/bench/z3/optimized/fix_dl_var_tactic.ll +++ b/bench/z3/optimized/fix_dl_var_tactic.ll @@ -3256,21 +3256,17 @@ _ZN17fix_dl_var_tactic9is_target8is_arithEP4expr.exit.thread.i: ; preds = %_ZN17 unreachable _Z11is_uninterpPK4expr.exit.thread.i: ; preds = %_ZNK3app13get_family_idEv.exit10, %.thread, %_ZN17fix_dl_var_tactic9is_target8is_arithEP4expr.exit.i - %120 = getelementptr inbounds nuw i8, ptr %93, i64 24 - %121 = load i32, ptr %120, align 8, !tbaa !145 - %122 = zext i32 %121 to i64 - %.idx.i = shl nuw nsw i64 %122, 3 - %123 = getelementptr inbounds nuw i8, ptr %93, i64 %.idx.i - %.ptr15.i = getelementptr inbounds nuw i8, ptr %123, i64 32 - %.not13.i = icmp eq i32 %121, 0 - br i1 %.not13.i, label %_ZN17fix_dl_var_tactic9is_target11process_appEP3app.exit, label %.lr.ph.preheader.i - -.lr.ph.preheader.i: ; preds = %_Z11is_uninterpPK4expr.exit.thread.i - %.ptr.i = getelementptr inbounds nuw i8, ptr %93, i64 32 - br label %.lr.ph.i + %120 = getelementptr inbounds nuw i8, ptr %93, i64 32 + %121 = getelementptr inbounds nuw i8, ptr %93, i64 24 + %122 = load i32, ptr %121, align 8, !tbaa !145 + %123 = zext i32 %122 to i64 + %.idx.i = shl nuw nsw i64 %123, 3 + %.ptr15.i = getelementptr inbounds nuw i8, ptr %120, i64 %.idx.i + %.not13.i = icmp eq i32 %122, 0 + br i1 %.not13.i, label %_ZN17fix_dl_var_tactic9is_target11process_appEP3app.exit, label %.lr.ph.i -.lr.ph.i: ; preds = %.lr.ph.i, %.lr.ph.preheader.i - %.014.i = phi ptr [ %125, %.lr.ph.i ], [ %.ptr.i, %.lr.ph.preheader.i ] +.lr.ph.i: ; preds = %_Z11is_uninterpPK4expr.exit.thread.i, %.lr.ph.i + %.014.i = phi ptr [ %125, %.lr.ph.i ], [ %120, %_Z11is_uninterpPK4expr.exit.thread.i ] %124 = load ptr, ptr %.014.i, align 8, !tbaa !118 tail call void @_ZN17fix_dl_var_tactic9is_target5visitEP4exprb(ptr noundef nonnull align 8 dereferenceable(80) %0, ptr noundef %124, i1 noundef zeroext false) %125 = getelementptr inbounds nuw i8, ptr %.014.i, i64 8 @@ -3506,8 +3502,7 @@ _Z11is_uninterpPK4expr.exit.thread.i: ; preds = %_ZN17fix_dl_var_tac %32 = load i32, ptr %31, align 8, !tbaa !145 %33 = zext i32 %32 to i64 %.idx.i = shl nuw nsw i64 %33, 3 - %34 = getelementptr inbounds nuw i8, ptr %1, i64 %.idx.i - %.ptr15.i = getelementptr inbounds nuw i8, ptr %34, i64 32 + %34 = getelementptr inbounds nuw i8, ptr %4, i64 %.idx.i %.not13.i = icmp eq i32 %32, 0 br i1 %.not13.i, label %_ZN17fix_dl_var_tactic9is_target11process_appEP3app.exit, label %.lr.ph.i @@ -3516,7 +3511,7 @@ _Z11is_uninterpPK4expr.exit.thread.i: ; preds = %_ZN17fix_dl_var_tac %35 = load ptr, ptr %.014.i, align 8, !tbaa !118 tail call void @_ZN17fix_dl_var_tactic9is_target5visitEP4exprb(ptr noundef nonnull align 8 dereferenceable(80) %0, ptr noundef %35, i1 noundef zeroext false) %36 = getelementptr inbounds nuw i8, ptr %.014.i, i64 8 - %.not.i = icmp eq ptr %36, %.ptr15.i + %.not.i = icmp eq ptr %36, %34 br i1 %.not.i, label %_ZN17fix_dl_var_tactic9is_target11process_appEP3app.exit, label %.lr.ph.i 37: ; preds = %_ZN17fix_dl_var_tactic9is_target8is_arithEP4expr.exit diff --git a/bench/z3/optimized/nnf.ll b/bench/z3/optimized/nnf.ll index 90e416910d6..f1a9e269cc5 100644 --- a/bench/z3/optimized/nnf.ll +++ b/bench/z3/optimized/nnf.ll @@ -451,7 +451,8 @@ _ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit2 .critedge: ; preds = %.critedge.loopexit, %_ZNK15ref_vector_coreI3app19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit %34 = phi ptr [ %.pre, %.critedge.loopexit ], [ %10, %_ZNK15ref_vector_coreI3app19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit ] - %35 = getelementptr inbounds nuw ptr, ptr %34, i64 %.0.i.i + %.idx = shl nuw nsw i64 %.0.i.i, 3 + %35 = getelementptr inbounds nuw i8, ptr %34, i64 %.idx %36 = icmp eq ptr %34, null br i1 %36, label %_ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit29, label %37 @@ -463,16 +464,20 @@ _ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit2 _ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit29: ; preds = %.critedge, %37 %.0.i.i28 = phi i64 [ %40, %37 ], [ 0, %.critedge ] - %41 = getelementptr inbounds nuw ptr, ptr %34, i64 %.0.i.i28 + %.idx45 = shl nuw nsw i64 %.0.i.i28, 3 %42 = icmp samesign ne i64 %.0.i.i, %.0.i.i28 - %.012.i.i = getelementptr inbounds i8, ptr %41, i64 -8 - %43 = icmp ult ptr %35, %.012.i.i + %42 = add nsw i64 %.idx45, -8 + %43 = icmp slt i64 %.idx, %42 %or.cond.i.i = select i1 %42, i1 %43, i1 false br i1 %or.cond.i.i, label %.lr.ph.i.i, label %_ZSt7reverseIPP4exprEvT_S3_.exit -.lr.ph.i.i: ; preds = %_ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit29, %.lr.ph.i.i - %.014.i.i = phi ptr [ %.0.i.i30, %.lr.ph.i.i ], [ %.012.i.i, %_ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit29 ] - %.0913.i.i = phi ptr [ %46, %.lr.ph.i.i ], [ %35, %_ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit29 ] +.lr.ph.i.i: ; preds = %_ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit29 + %.012.i.i = getelementptr inbounds i8, ptr %34, i64 %42 + br label %.lr.ph.i.i + +.lr.ph.i.i: ; preds = %.lr.ph.i.i.preheader, %.lr.ph.i.i + %.014.i.i = phi ptr [ %.0.i.i30, %.lr.ph.i.i ], [ %.012.i.i, %.lr.ph.i.i.preheader ] + %.0913.i.i = phi ptr [ %46, %.lr.ph.i.i ], [ %35, %.lr.ph.i.i.preheader ] %44 = load ptr, ptr %.0913.i.i, align 8, !tbaa !152 %45 = load ptr, ptr %.014.i.i, align 8, !tbaa !152 store ptr %45, ptr %.0913.i.i, align 8, !tbaa !152 @@ -484,7 +489,8 @@ _ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit2 _ZSt7reverseIPP4exprEvT_S3_.exit: ; preds = %.lr.ph.i.i, %_ZNK15ref_vector_coreI4expr19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit29 %48 = load ptr, ptr %16, align 8, !tbaa !18 - %49 = getelementptr inbounds nuw ptr, ptr %48, i64 %.0.i.i25 + %.idx46 = shl nuw nsw i64 %.0.i.i25, 3 + %49 = getelementptr inbounds nuw i8, ptr %48, i64 %.idx46 %50 = icmp eq ptr %48, null br i1 %50, label %_ZNK15ref_vector_coreI3app19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit32, label %51 @@ -496,16 +502,20 @@ _ZSt7reverseIPP4exprEvT_S3_.exit: ; preds = %.lr.ph.i.i, %_ZNK15 _ZNK15ref_vector_coreI3app19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit32: ; preds = %_ZSt7reverseIPP4exprEvT_S3_.exit, %51 %.0.i.i31 = phi i64 [ %54, %51 ], [ 0, %_ZSt7reverseIPP4exprEvT_S3_.exit ] - %55 = getelementptr inbounds nuw ptr, ptr %48, i64 %.0.i.i31 + %.idx47 = shl nuw nsw i64 %.0.i.i31, 3 %56 = icmp samesign ne i64 %.0.i.i25, %.0.i.i31 - %.012.i.i33 = getelementptr inbounds i8, ptr %55, i64 -8 - %57 = icmp ult ptr %49, %.012.i.i33 + %56 = add nsw i64 %.idx47, -8 + %57 = icmp slt i64 %.idx46, %56 %or.cond.i.i34 = select i1 %56, i1 %57, i1 false br i1 %or.cond.i.i34, label %.lr.ph.i.i35, label %_ZSt7reverseIPP3appEvT_S3_.exit -.lr.ph.i.i35: ; preds = %_ZNK15ref_vector_coreI3app19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit32, %.lr.ph.i.i35 - %.014.i.i36 = phi ptr [ %.0.i.i38, %.lr.ph.i.i35 ], [ %.012.i.i33, %_ZNK15ref_vector_coreI3app19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit32 ] - %.0913.i.i37 = phi ptr [ %60, %.lr.ph.i.i35 ], [ %49, %_ZNK15ref_vector_coreI3app19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit32 ] +.lr.ph.i.i35: ; preds = %_ZNK15ref_vector_coreI3app19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit32 + %.012.i.i33 = getelementptr inbounds i8, ptr %48, i64 %56 + br label %.lr.ph.i.i35 + +.lr.ph.i.i35: ; preds = %.lr.ph.i.i35.preheader, %.lr.ph.i.i35 + %.014.i.i36 = phi ptr [ %.0.i.i38, %.lr.ph.i.i35 ], [ %.012.i.i33, %.lr.ph.i.i35.preheader ] + %.0913.i.i37 = phi ptr [ %60, %.lr.ph.i.i35 ], [ %49, %.lr.ph.i.i35.preheader ] %58 = load ptr, ptr %.0913.i.i37, align 8, !tbaa !154 %59 = load ptr, ptr %.014.i.i36, align 8, !tbaa !154 store ptr %59, ptr %.0913.i.i37, align 8, !tbaa !154 diff --git a/bench/z3/optimized/rlimit.ll b/bench/z3/optimized/rlimit.ll index 21533a8cc6d..8d378c04df7 100644 --- a/bench/z3/optimized/rlimit.ll +++ b/bench/z3/optimized/rlimit.ll @@ -393,36 +393,37 @@ _ZNK6vectorIP8reslimitLb0EjE4sizeEv.exit: ; preds = %_ZNSt10lock_guardIS br i1 %exitcond.not, label %.critedge, label %_ZNSt10lock_guardISt5mutexEC2ERS0_.exit _ZNSt10lock_guardISt5mutexEC2ERS0_.exit: ; preds = %_ZNSt10lock_guardISt5mutexEC2ERS0_.exit.preheader20, %_ZNK6vectorIP8reslimitLb0EjE4sizeEv.exit - %indvars.iv = phi i64 [ 0, %_ZNSt10lock_guardISt5mutexEC2ERS0_.exit.preheader20 ], [ %indvars.iv.next, %_ZNK6vectorIP8reslimitLb0EjE4sizeEv.exit ] - %11 = getelementptr inbounds nuw ptr, ptr %6, i64 %indvars.iv + %indvars.iv = phi i64 [ 0, %_ZNSt10lock_guardISt5mutexEC2ERS0_.exit.preheader22 ], [ %indvars.iv.next, %_ZNK6vectorIP8reslimitLb0EjE4sizeEv.exit ] + %.idx = shl nuw nsw i64 %indvars.iv, 3 + %11 = getelementptr inbounds nuw i8, ptr %6, i64 %.idx %12 = load ptr, ptr %11, align 8, !tbaa !31 %13 = icmp eq ptr %12, %1 br i1 %13, label %_ZN6vectorIP8reslimitLb0EjE3endEv.exit.i, label %_ZNK6vectorIP8reslimitLb0EjE4sizeEv.exit _ZN6vectorIP8reslimitLb0EjE3endEv.exit.i: ; preds = %_ZNSt10lock_guardISt5mutexEC2ERS0_.exit - %14 = getelementptr inbounds nuw ptr, ptr %6, i64 %indvars.iv - %15 = getelementptr inbounds nuw i8, ptr %1, i64 8 - %16 = load i64, ptr %15, align 8, !tbaa !23 - %17 = getelementptr inbounds nuw i8, ptr %0, i64 8 - %18 = load i64, ptr %17, align 8, !tbaa !23 - %19 = add i64 %18, %16 - store i64 %19, ptr %17, align 8, !tbaa !23 - store i64 0, ptr %15, align 8, !tbaa !23 - %20 = getelementptr inbounds nuw ptr, ptr %6, i64 %wide.trip.count - %.010.i = getelementptr inbounds nuw i8, ptr %14, i64 8 - %.not11.i = icmp eq ptr %.010.i, %20 + %14 = getelementptr inbounds nuw i8, ptr %1, i64 8 + %15 = load i64, ptr %14, align 8, !tbaa !23 + %16 = getelementptr inbounds nuw i8, ptr %0, i64 8 + %17 = load i64, ptr %16, align 8, !tbaa !23 + %18 = add i64 %17, %15 + store i64 %18, ptr %16, align 8, !tbaa !23 + store i64 0, ptr %14, align 8, !tbaa !23 + %.idx13 = shl nuw nsw i64 %wide.trip.count, 3 + %19 = add nuw nsw i64 %.idx, 8 + %.not11.i = icmp samesign eq i64 %19, %.idx13 br i1 %.not11.i, label %_ZN6vectorIP8reslimitLb0EjE5eraseEPS1_.exit, label %.lr.ph.preheader.i .lr.ph.preheader.i: ; preds = %_ZN6vectorIP8reslimitLb0EjE3endEv.exit.i + %20 = getelementptr inbounds nuw i8, ptr %6, i64 %.idx + %.010.i = getelementptr inbounds nuw i8, ptr %20, i64 8 %21 = ptrtoint ptr %6 to i64 - %22 = ptrtoint ptr %14 to i64 - %23 = shl nuw nsw i64 %wide.trip.count, 3 - %24 = add i64 %21, -16 - %25 = sub i64 %24, %22 - %26 = add i64 %25, %23 - %27 = and i64 %26, -8 - %28 = add i64 %27, 8 - tail call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %14, ptr nonnull align 8 %.010.i, i64 %28, i1 false), !tbaa !31 + %22 = ptrtoint ptr %20 to i64 + %23 = add i64 %21, -16 + %24 = sub i64 %23, %22 + %25 = add i64 %24, %.idx13 + %26 = and i64 %25, -8 + %27 = add i64 %26, 8 + tail call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %20, ptr nonnull align 8 %.010.i, i64 %27, i1 false), !tbaa !31 br label %_ZN6vectorIP8reslimitLb0EjE5eraseEPS1_.exit _ZN6vectorIP8reslimitLb0EjE5eraseEPS1_.exit: ; preds = %_ZN6vectorIP8reslimitLb0EjE3endEv.exit.i, %.lr.ph.preheader.i diff --git a/bench/z3/optimized/substitution_tree.ll b/bench/z3/optimized/substitution_tree.ll index f70fc8eeba8..71973be66a9 100644 --- a/bench/z3/optimized/substitution_tree.ll +++ b/bench/z3/optimized/substitution_tree.ll @@ -3143,40 +3143,46 @@ _ZNK15ref_vector_coreI3var19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit.i br i1 %31, label %32, label %28 32: ; preds = %.lr.ph.i - %33 = getelementptr inbounds nuw ptr, ptr %24, i64 %indvars.iv.i - %34 = getelementptr inbounds nuw ptr, ptr %24, i64 %wide.trip.count.i - %.010.i.i.i = getelementptr inbounds nuw i8, ptr %33, i64 8 - %.not11.i.i.i = icmp eq ptr %.010.i.i.i, %34 - br i1 %.not11.i.i.i, label %43, label %.lr.ph.preheader.i.i.i + %.idx.i.i = shl nuw nsw i64 %indvars.iv.i, 3 + %34 = getelementptr inbounds nuw i8, ptr %24, i64 %.idx.i.i + %34 = load ptr, ptr %33, align 8, !tbaa !95 + %.idx3.i.i = shl nuw nsw i64 %wide.trip.count.i, 3 + %35 = add nuw nsw i64 %.idx.i.i, 8 + %.not11.i.i.i = icmp samesign eq i64 %35, %.idx3.i.i + br i1 %.not11.i.i.i, label %_ZN6vectorIP3varLb0EjE5eraseEPS1_.exit.i.i, label %.lr.ph.preheader.i.i.i .lr.ph.preheader.i.i.i: ; preds = %32 - %35 = ptrtoint ptr %24 to i64 - %36 = ptrtoint ptr %33 to i64 - %37 = shl nuw nsw i64 %wide.trip.count.i, 3 - %38 = add i64 %35, -16 - %39 = add i64 %38, %37 - %40 = sub i64 %39, %36 + %.010.i.i.i = getelementptr inbounds nuw i8, ptr %34, i64 8 + %36 = ptrtoint ptr %24 to i64 + %37 = ptrtoint ptr %33 to i64 + %38 = add i64 %36, -16 + %39 = add i64 %38, %.idx3.i.i + %40 = sub i64 %39, %37 %41 = and i64 %40, -8 %42 = add i64 %41, 8 tail call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %33, ptr nonnull align 8 %.010.i.i.i, i64 %42, i1 false), !tbaa !95 br label %43 -43: ; preds = %32, %.lr.ph.preheader.i.i.i +43: ; preds = %.lr.ph.preheader.i.i.i, %32 %44 = add i32 %27, -1 store i32 %44, ptr %26, align 4, !tbaa !33 %45 = load ptr, ptr %20, align 8, !tbaa !109 - %46 = getelementptr inbounds nuw i8, ptr %30, i64 8 + %.not.i.i.i.i.i = icmp eq ptr %34, null + br i1 %.not.i.i.i.i.i, label %_ZN15ref_vector_coreI3var19ref_manager_wrapperIS0_11ast_managerEE5eraseEPS0_.exit, label %45 + +45: ; preds = %_ZN6vectorIP3varLb0EjE5eraseEPS1_.exit.i.i + %46 = getelementptr inbounds nuw i8, ptr %34, i64 8 %47 = load i32, ptr %46, align 4, !tbaa !44 %48 = add i32 %47, -1 store i32 %48, ptr %46, align 4, !tbaa !44 %49 = icmp eq i32 %48, 0 br i1 %49, label %50, label %_ZN15ref_vector_coreI3var19ref_manager_wrapperIS0_11ast_managerEE5eraseEPS0_.exit -50: ; preds = %43 - tail call void @_ZN11ast_manager11delete_nodeEP3ast(ptr noundef nonnull align 8 dereferenceable(976) %45, ptr noundef nonnull %30) +50: ; preds = %45 + tail call void @_ZN11ast_manager11delete_nodeEP3ast(ptr noundef nonnull align 8 dereferenceable(976) %45, ptr noundef nonnull %34) br label %_ZN15ref_vector_coreI3var19ref_manager_wrapperIS0_11ast_managerEE5eraseEPS0_.exit -_ZN15ref_vector_coreI3var19ref_manager_wrapperIS0_11ast_managerEE5eraseEPS0_.exit: ; preds = %28, %8, %50, %43, %_ZNK15ref_vector_coreI3var19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit.i, %22, %17, %_ZNK6vectorIP10ref_vectorI3var11ast_managerELb0EjE4sizeEv.exit, %7 +_ZN15ref_vector_coreI3var19ref_manager_wrapperIS0_11ast_managerEE5eraseEPS0_.exit: ; preds = %28, %8, %50, %45, %43, %_ZNK15ref_vector_coreI3var19ref_manager_wrapperIS0_11ast_managerEE4sizeEv.exit.i, %22, %17, %_ZNK6vectorIP10ref_vectorI3var11ast_managerELb0EjE4sizeEv.exit, %7 ret void } diff --git a/bench/zed-rs/optimized/0x2swxz4m93xo6c0jggy1zzvx.ll b/bench/zed-rs/optimized/0x2swxz4m93xo6c0jggy1zzvx.ll index 2e301bcc3ee..49d65f7c3c8 100644 --- a/bench/zed-rs/optimized/0x2swxz4m93xo6c0jggy1zzvx.ll +++ b/bench/zed-rs/optimized/0x2swxz4m93xo6c0jggy1zzvx.ll @@ -6989,23 +6989,22 @@ define hidden void @"_ZN80_$LT$arrayvec..arrayvec..ArrayVec$LT$T$C$_$GT$$u20$as$ %3 = alloca [200 x i8], align 8 %4 = load i32, ptr %1, align 8, !noundef !36 %5 = zext i32 %4 to i64 + %6 = getelementptr inbounds nuw i8, ptr %1, i64 8 %.idx = shl nuw nsw i64 %5, 4 - %6 = getelementptr inbounds nuw i8, ptr %1, i64 %.idx - %.ptr1 = getelementptr inbounds nuw i8, ptr %6, i64 8 + %6 = getelementptr inbounds nuw i8, ptr %6, i64 %.idx call void @llvm.lifetime.start.p0(i64 200, ptr nonnull %3), !noalias !1562 tail call void @llvm.experimental.noalias.scope.decl(metadata !1565) %.not.not.i4.i = icmp eq i32 %4, 0 br i1 %.not.not.i4.i, label %"_ZN112_$LT$arrayvec..arrayvec..ArrayVec$LT$T$C$_$GT$$u20$as$u20$core..iter..traits..collect..FromIterator$LT$T$GT$$GT$9from_iter17h404df5440167f9c3E.llvm.5450736876007502420.exit", label %.lr.ph.preheader.i .lr.ph.preheader.i: ; preds = %2 - %.ptr = getelementptr inbounds nuw i8, ptr %1, i64 8 %.sroa.0.0.ptr.i3.i = getelementptr inbounds nuw i8, ptr %3, i64 8 br label %.lr.ph.i .lr.ph.i: ; preds = %10, %.lr.ph.preheader.i - %.sroa.0.0.ptr.i8.i = phi ptr [ %.sroa.0.0.ptr.i.i, %10 ], [ %.sroa.0.0.ptr.i3.i, %.lr.ph.preheader.i ] - %.sroa.0.0.idx.i7.i = phi i64 [ %.sroa.0.0.add.i.i, %10 ], [ 8, %.lr.ph.preheader.i ] - %.sroa.016.0.i6.i = phi ptr [ %7, %10 ], [ %.ptr, %.lr.ph.preheader.i ] + %.sroa.0.0.ptr.i8.i = phi ptr [ %.sroa.0.0.ptr.i.i, %11 ], [ %.sroa.0.0.ptr.i3.i, %.lr.ph.preheader.i ] + %.sroa.0.0.idx.i7.i = phi i64 [ %.sroa.0.0.add.i.i, %11 ], [ 8, %.lr.ph.preheader.i ] + %.sroa.016.0.i6.i = phi ptr [ %7, %11 ], [ %6, %.lr.ph.preheader.i ] %7 = getelementptr inbounds nuw i8, ptr %.sroa.016.0.i6.i, i64 16 %8 = icmp eq i64 %.sroa.0.0.idx.i7.i, 200 br i1 %8, label %9, label %10 @@ -7018,7 +7017,7 @@ define hidden void @"_ZN80_$LT$arrayvec..arrayvec..ArrayVec$LT$T$C$_$GT$$u20$as$ call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.sroa.0.0.ptr.i8.i, ptr noundef nonnull align 8 dereferenceable(16) %.sroa.016.0.i6.i, i64 16, i1 false) %.sroa.0.0.add.i.i = add nuw nsw i64 %.sroa.0.0.idx.i7.i, 16 %.sroa.0.0.ptr.i.i = getelementptr inbounds nuw i8, ptr %3, i64 %.sroa.0.0.add.i.i - %.not.not.i.i = icmp eq ptr %7, %.ptr1 + %.not.not.i.i = icmp eq ptr %7, %7 br i1 %.not.not.i.i, label %"_ZN112_$LT$arrayvec..arrayvec..ArrayVec$LT$T$C$_$GT$$u20$as$u20$core..iter..traits..collect..FromIterator$LT$T$GT$$GT$9from_iter17h404df5440167f9c3E.llvm.5450736876007502420.exit", label %.lr.ph.i "_ZN112_$LT$arrayvec..arrayvec..ArrayVec$LT$T$C$_$GT$$u20$as$u20$core..iter..traits..collect..FromIterator$LT$T$GT$$GT$9from_iter17h404df5440167f9c3E.llvm.5450736876007502420.exit": ; preds = %10, %2 diff --git a/bench/zed-rs/optimized/4q1bnadqr1o107uase7gmrd0k.ll b/bench/zed-rs/optimized/4q1bnadqr1o107uase7gmrd0k.ll index bddee9cb23f..1759dbc186c 100644 --- a/bench/zed-rs/optimized/4q1bnadqr1o107uase7gmrd0k.ll +++ b/bench/zed-rs/optimized/4q1bnadqr1o107uase7gmrd0k.ll @@ -145615,22 +145615,20 @@ define hidden void @"_ZN3vim3Vim13input_ignored28_$u7b$$u7b$closure$u7d$$u7d$17h "_ZN78_$LT$gpui..app..GlobalLease$LT$G$GT$$u20$as$u20$core..ops..deref..DerefMut$GT$9deref_mut17h921d586cd3fabec7E.exit.i": ; preds = %.noexc.i %29 = icmp ne ptr %.val, null tail call void @llvm.assume(i1 %29) - %30 = getelementptr i8, ptr %.val, i64 %.val4 - %.ptr4.i.i = getelementptr i8, ptr %30, i64 16 - %31 = icmp eq i64 %.val4, 0 - br i1 %31, label %_ZN4core3str11validations15next_code_point17h0603fe6d9162d691E.exit.thread.i.i, label %32 - -32: ; preds = %"_ZN78_$LT$gpui..app..GlobalLease$LT$G$GT$$u20$as$u20$core..ops..deref..DerefMut$GT$9deref_mut17h921d586cd3fabec7E.exit.i" - %.ptr.i.i = getelementptr inbounds nuw i8, ptr %.val, i64 16 - %33 = load i8, ptr %.ptr.i.i, align 1, !noalias !30409, !noundef !4 + %30 = icmp eq i64 %.val4, 0 + br i1 %30, label %_ZN4core3str11validations15next_code_point17h0603fe6d9162d691E.exit.thread.i.i, label %31 + +31:; preds = %"_ZN78_$LT$gpui..app..GlobalLease$LT$G$GT$$u20$as$u20$core..ops..deref..DerefMut$GT$9deref_mut17h921d586cd3fabec7E.exit.i" + %32 = getelementptr inbounds nuw i8, ptr %.val, i64 16 + %33 = load i8, ptr %32, align 1, !noalias !30409, !noundef !4 %34 = icmp sgt i8 %33, -1 br i1 %34, label %45, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hddaaca7a7ac86ca4E.exit12.i.i.i" -"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hddaaca7a7ac86ca4E.exit12.i.i.i": ; preds = %32 +"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hddaaca7a7ac86ca4E.exit12.i.i.i": ; preds = %31 %35 = getelementptr inbounds nuw i8, ptr %.val, i64 17 %36 = and i8 %33, 31 %37 = zext nneg i8 %36 to i32 - %38 = icmp ne ptr %35, %.ptr4.i.i + %38 = icmp ne i64 %.val4, 1 tail call void @llvm.assume(i1 %38) %39 = load i8, ptr %35, align 1, !noalias !30409, !noundef !4 %40 = shl nuw nsw i32 %37, 6 @@ -145640,13 +145638,13 @@ define hidden void @"_ZN3vim3Vim13input_ignored28_$u7b$$u7b$closure$u7d$$u7d$17h %44 = icmp samesign ugt i8 %33, -33 br i1 %44, label %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hddaaca7a7ac86ca4E.exit14.i.i.i", label %_ZN4core3str11validations15next_code_point17h0603fe6d9162d691E.exit.thread.i.i -45: ; preds = %32 +45: ; preds = %31 %46 = zext nneg i8 %33 to i32 br label %_ZN4core3str11validations15next_code_point17h0603fe6d9162d691E.exit.thread.i.i "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hddaaca7a7ac86ca4E.exit14.i.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hddaaca7a7ac86ca4E.exit12.i.i.i" %47 = getelementptr inbounds nuw i8, ptr %.val, i64 18 - %48 = icmp ne ptr %47, %.ptr4.i.i + %48 = icmp ne i64 %.val4, 2 tail call void @llvm.assume(i1 %48) %49 = load i8, ptr %47, align 1, !noalias !30409, !noundef !4 %50 = shl nuw nsw i32 %42, 6 @@ -145660,7 +145658,7 @@ define hidden void @"_ZN3vim3Vim13input_ignored28_$u7b$$u7b$closure$u7d$$u7d$17h "_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hddaaca7a7ac86ca4E.exit16.i.i.i": ; preds = %"_ZN91_$LT$core..slice..iter..Iter$LT$T$GT$$u20$as$u20$core..iter..traits..iterator..Iterator$GT$4next17hddaaca7a7ac86ca4E.exit14.i.i.i" %57 = getelementptr inbounds nuw i8, ptr %.val, i64 19 - %58 = icmp ne ptr %57, %.ptr4.i.i + %58 = icmp ne i64 %.val4, 3 tail call void @llvm.assume(i1 %58) %59 = load i8, ptr %57, align 1, !noalias !30409, !noundef !4 %60 = shl nuw nsw i32 %37, 18 diff --git a/bench/zxing/optimized/BinaryBitmap.ll b/bench/zxing/optimized/BinaryBitmap.ll index b3cd4d2aa7e..cba7d8d6ef5 100644 --- a/bench/zxing/optimized/BinaryBitmap.ll +++ b/bench/zxing/optimized/BinaryBitmap.ll @@ -493,21 +493,21 @@ define void @_ZN5ZXing12BinaryBitmap5closeEv(ptr noundef nonnull align 8 capture %13 = load ptr, ptr %12, align 8, !tbaa !15 %14 = load i32, ptr %2, align 8, !tbaa !26 %15 = sext i32 %14 to i64 - %16 = getelementptr inbounds i8, ptr %13, i64 %15 - %17 = getelementptr inbounds nuw i8, ptr %2, i64 4 - %18 = load i32, ptr %17, align 4, !tbaa !20 - %19 = add nsw i32 %18, -1 - %20 = mul nsw i32 %19, %14 - %21 = sext i32 %20 to i64 + %16 = getelementptr inbounds nuw i8, ptr %2, i64 4 + %17 = load i32, ptr %16, align 4, !tbaa !20 + %18 = add nsw i32 %17, -1 + %19 = mul nsw i32 %18, %14 + %20 = sext i32 %19 to i64 + %21 = add nsw i64 %20, -1 %22 = getelementptr inbounds i8, ptr %13, i64 %21 - %23 = getelementptr inbounds i8, ptr %22, i64 -1 - %.02412.i = getelementptr inbounds nuw i8, ptr %16, i64 1 - %.not13.i = icmp eq ptr %.02412.i, %23 + %23 = add nsw i64 %15, 1 + %.not13.i = icmp eq i64 %23, %21 br i1 %.not13.i, label %"_ZN5ZXing9SumFilterIZNS_12BinaryBitmap5closeEvE3$_0EEvRKNS_9BitMatrixERS3_T_.exit", label %.preheader.preheader.i .preheader.preheader.i: ; preds = %7 %.val6 = load ptr, ptr %11, align 8, !tbaa !15 %.val = load i32, ptr %6, align 8, !tbaa !26 + %.02412.i = getelementptr inbounds i8, ptr %13, i64 %23 %24 = shl nsw i32 %.val, 1 %25 = sext i32 %24 to i64 %26 = getelementptr inbounds i8, ptr %.val6, i64 %25 @@ -530,7 +530,7 @@ define void @_ZN5ZXing12BinaryBitmap5closeEv(ptr noundef nonnull align 8 capture %32 = getelementptr inbounds nuw i8, ptr %.02614.i, i64 1 %33 = getelementptr inbounds nuw i8, ptr %.02515.i, i64 1 %.024.i = getelementptr inbounds nuw i8, ptr %.02417.i, i64 1 - %.not.i = icmp eq ptr %.024.i, %23 + %.not.i = icmp eq ptr %.024.i, %22 br i1 %.not.i, label %"_ZN5ZXing9SumFilterIZNS_12BinaryBitmap5closeEvE3$_0EEvRKNS_9BitMatrixERS3_T_.exit.loopexit", label %.preheader.i, !llvm.loop !64 34: ; preds = %34, %.preheader.i @@ -561,19 +561,19 @@ define void @_ZN5ZXing12BinaryBitmap5closeEv(ptr noundef nonnull align 8 capture %47 = load ptr, ptr %11, align 8, !tbaa !15 %48 = load i32, ptr %6, align 8, !tbaa !26 %49 = sext i32 %48 to i64 - %50 = getelementptr inbounds i8, ptr %47, i64 %49 - %51 = load i32, ptr %9, align 4, !tbaa !20 - %52 = add nsw i32 %51, -1 - %53 = mul nsw i32 %52, %48 - %54 = sext i32 %53 to i64 + %50 = load i32, ptr %9, align 4, !tbaa !20 + %51 = add nsw i32 %50, -1 + %52 = mul nsw i32 %51, %48 + %53 = sext i32 %52 to i64 + %54 = add nsw i64 %53, -1 %55 = getelementptr inbounds i8, ptr %47, i64 %54 - %56 = getelementptr inbounds i8, ptr %55, i64 -1 - %.02411.i = getelementptr inbounds nuw i8, ptr %50, i64 1 - %.not12.i = icmp eq ptr %.02411.i, %56 + %56 = add nsw i64 %49, 1 + %.not12.i = icmp eq i64 %56, %54 br i1 %.not12.i, label %"_ZN5ZXing9SumFilterIZNS_12BinaryBitmap5closeEvE3$_1EEvRKNS_9BitMatrixERS3_T_.exit", label %.preheader.preheader.i9 .preheader.preheader.i9: ; preds = %"_ZN5ZXing9SumFilterIZNS_12BinaryBitmap5closeEvE3$_0EEvRKNS_9BitMatrixERS3_T_.exit" %.val7 = load i32, ptr %2, align 8, !tbaa !26 + %.02411.i = getelementptr inbounds i8, ptr %47, i64 %56 %57 = shl nsw i32 %.val7, 1 %58 = sext i32 %57 to i64 %59 = getelementptr inbounds i8, ptr %.pre20, i64 %58 @@ -596,7 +596,7 @@ define void @_ZN5ZXing12BinaryBitmap5closeEv(ptr noundef nonnull align 8 capture %66 = getelementptr inbounds nuw i8, ptr %.02613.i, i64 1 %67 = getelementptr inbounds nuw i8, ptr %.02514.i, i64 1 %.024.i14 = getelementptr inbounds nuw i8, ptr %.02416.i, i64 1 - %.not.i15 = icmp eq ptr %.024.i14, %56 + %.not.i15 = icmp eq ptr %.024.i14, %55 br i1 %.not.i15, label %"_ZN5ZXing9SumFilterIZNS_12BinaryBitmap5closeEvE3$_1EEvRKNS_9BitMatrixERS3_T_.exit.loopexit", label %.preheader.i10, !llvm.loop !66 68: ; preds = %68, %.preheader.i10 diff --git a/scripts/setup_pre_commit_patch.sh b/scripts/setup_pre_commit_patch.sh index c5409e09ef4..86c5ab487d3 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/pull/146714 export COMPTIME_MODE=0 # Please rebase manually