; LLVM IR from ERGO-Code/HiGHS :: src/util/HFactor.ll (ZNK7HFactor7btranFTER11HVectorBaseIdE)

; Unoptimized IR (clang -disable-llvm-passes):
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-unknown-linux-gnu"

%class.HVectorBase = type { i32, i32, %"class.std::vector", %"class.std::vector.10", double, %"class.std::vector.15", %"class.std::vector", ptr, i8, i32, %"class.std::vector", %"class.std::vector.10" }
%"class.std::vector.15" = type { %"struct.std::_Vector_base.16" }
%"struct.std::_Vector_base.16" = type { %"struct.std::_Vector_base<char, std::allocator<char>>::_Vector_impl" }
%"struct.std::_Vector_base<char, std::allocator<char>>::_Vector_impl" = type { %"struct.std::_Vector_base<char, std::allocator<char>>::_Vector_impl_data" }
%"struct.std::_Vector_base<char, std::allocator<char>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.10" = type { %"struct.std::_Vector_base.11" }
%"struct.std::_Vector_base.11" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.HFactor = type { double, double, i32, %"class.std::vector", %"class.std::vector", %"class.std::vector", %struct.RefactorInfo, i32, i32, i32, i32, i32, i32, i32, double, i8, ptr, ptr, ptr, ptr, double, double, i32, double, %"class.std::unique_ptr", %struct.HighsLogOptions, i8, i8, i32, i32, ptr, i32, %"class.std::vector", %"class.std::vector.10", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector.10", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector.10", %"class.std::vector.10", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector.15", %"class.std::vector.10", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector.10", %"class.std::vector", %"class.std::vector", %"class.std::vector.10", %"class.std::vector", %"class.std::vector", %"class.std::vector.10", i32, i32, %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector.10", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector.10", %"class.std::vector.10", %"class.std::vector", %"class.std::vector", %"class.std::vector", %"class.std::vector.10", %class.HVectorBase }
%struct.RefactorInfo = type { i8, %"class.std::vector", %"class.std::vector", %"class.std::vector.3", double }
%"class.std::vector.3" = type { %"struct.std::_Vector_base.4" }
%"struct.std::_Vector_base.4" = type { %"struct.std::_Vector_base<signed char, std::allocator<signed char>>::_Vector_impl" }
%"struct.std::_Vector_base<signed char, std::allocator<signed char>>::_Vector_impl" = type { %"struct.std::_Vector_base<signed char, std::allocator<signed char>>::_Vector_impl_data" }
%"struct.std::_Vector_base<signed char, std::allocator<signed char>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.9" }
%"struct.std::_Head_base.9" = type { ptr }
%struct.HighsLogOptions = type <{ ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::function", ptr, i8, [7 x i8] }>
%"class.std::function" = type { %"class.std::_Function_base", ptr }
%"class.std::_Function_base" = type { %"union.std::_Any_data", ptr }
%"union.std::_Any_data" = type { %"union.std::_Nocopy_types" }
%"union.std::_Nocopy_types" = type { { i64, i64 } }

@.str.52 = external hidden unnamed_addr constant [70 x i8], align 1
@.str.81 = external hidden unnamed_addr constant [18 x i8], align 1
@__PRETTY_FUNCTION__._ZNK7HFactor7btranFTER11HVectorBaseIdE = external hidden unnamed_addr constant [39 x i8], align 1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNKSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNKSt6vectorIdSaIdEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #2

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fabs.f64(double) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNSt6vectorIdSaIdEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
define dso_local void @_ZNK7HFactor7btranFTER11HVectorBaseIdE(ptr noundef nonnull align 8 dereferenceable(1912) %0, ptr noundef nonnull align 8 dereferenceable(176) %1) #1 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca double, align 8
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca double, align 8
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca double, align 8
  %23 = alloca double, align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  %24 = load ptr, ptr %3, align 8
  %25 = load ptr, ptr %4, align 8, !tbaa !5
  %26 = getelementptr inbounds %class.HVectorBase, ptr %25, i32 0, i32 1
  %27 = load i32, ptr %26, align 4, !tbaa !9
  %28 = icmp sge i32 %27, 0
  br i1 %28, label %29, label %30

29:                                               ; preds = %2
  br label %32

30:                                               ; preds = %2
  call void @__assert_fail(ptr noundef @.str.81, ptr noundef @.str.52, i32 noundef 1884, ptr noundef @__PRETTY_FUNCTION__._ZNK7HFactor7btranFTER11HVectorBaseIdE) #4
  unreachable

31:                                               ; No predecessors!
  br label %32

32:                                               ; preds = %31, %29
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  %33 = load ptr, ptr %4, align 8, !tbaa !5
  %34 = getelementptr inbounds %class.HVectorBase, ptr %33, i32 0, i32 1
  %35 = load i32, ptr %34, align 4, !tbaa !9
  store i32 %35, ptr %5, align 4, !tbaa !26
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %36 = load ptr, ptr %4, align 8, !tbaa !5
  %37 = getelementptr inbounds %class.HVectorBase, ptr %36, i32 0, i32 2
  %38 = call noundef ptr @_ZNSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %37) #5
  store ptr %38, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %39 = load ptr, ptr %4, align 8, !tbaa !5
  %40 = getelementptr inbounds %class.HVectorBase, ptr %39, i32 0, i32 3
  %41 = call noundef ptr @_ZNSt6vectorIdSaIdEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %40) #5
  store ptr %41, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  %42 = getelementptr inbounds %class.HFactor, ptr %24, i32 0, i32 84
  %43 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %42) #5
  %44 = trunc i64 %43 to i32
  store i32 %44, ptr %8, align 4, !tbaa !26
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %45 = getelementptr inbounds %class.HFactor, ptr %24, i32 0, i32 84
  %46 = call noundef ptr @_ZNKSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %45) #5
  store ptr %46, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %47 = getelementptr inbounds %class.HFactor, ptr %24, i32 0, i32 85
  %48 = call noundef ptr @_ZNKSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %47) #5
  store ptr %48, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  %49 = getelementptr inbounds %class.HFactor, ptr %24, i32 0, i32 86
  %50 = call noundef ptr @_ZNKSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %49) #5
  store ptr %50, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %51 = getelementptr inbounds %class.HFactor, ptr %24, i32 0, i32 87
  %52 = call noundef ptr @_ZNKSt6vectorIdSaIdEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %51) #5
  store ptr %52, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  store double 0.000000e+00, ptr %13, align 8, !tbaa !27
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  %53 = load i32, ptr %8, align 4, !tbaa !26
  %54 = sub nsw i32 %53, 1
  store i32 %54, ptr %14, align 4, !tbaa !26
  br label %55

55:                                               ; preds = %143, %32
  %56 = load i32, ptr %14, align 4, !tbaa !26
  %57 = icmp sge i32 %56, 0
  br i1 %57, label %59, label %58

58:                                               ; preds = %55
  store i32 2, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %146

59:                                               ; preds = %55
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  %60 = load ptr, ptr %9, align 8, !tbaa !5
  %61 = load i32, ptr %14, align 4, !tbaa !26
  %62 = sext i32 %61 to i64
  %63 = getelementptr inbounds i32, ptr %60, i64 %62
  %64 = load i32, ptr %63, align 4, !tbaa !26
  store i32 %64, ptr %16, align 4, !tbaa !26
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  %65 = load ptr, ptr %7, align 8, !tbaa !5
  %66 = load i32, ptr %16, align 4, !tbaa !26
  %67 = sext i32 %66 to i64
  %68 = getelementptr inbounds double, ptr %65, i64 %67
  %69 = load double, ptr %68, align 8, !tbaa !27
  store double %69, ptr %17, align 8, !tbaa !27
  %70 = load double, ptr %17, align 8, !tbaa !27
  %71 = fcmp une double %70, 0.000000e+00
  br i1 %71, label %72, label %142

72:                                               ; preds = %59
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  %73 = load ptr, ptr %10, align 8, !tbaa !5
  %74 = load i32, ptr %14, align 4, !tbaa !26
  %75 = sext i32 %74 to i64
  %76 = getelementptr inbounds i32, ptr %73, i64 %75
  %77 = load i32, ptr %76, align 4, !tbaa !26
  store i32 %77, ptr %18, align 4, !tbaa !26
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #5
  %78 = load ptr, ptr %10, align 8, !tbaa !5
  %79 = load i32, ptr %14, align 4, !tbaa !26
  %80 = add nsw i32 %79, 1
  %81 = sext i32 %80 to i64
  %82 = getelementptr inbounds i32, ptr %78, i64 %81
  %83 = load i32, ptr %82, align 4, !tbaa !26
  store i32 %83, ptr %19, align 4, !tbaa !26
  %84 = load i32, ptr %19, align 4, !tbaa !26
  %85 = load i32, ptr %18, align 4, !tbaa !26
  %86 = sub nsw i32 %84, %85
  %87 = sitofp i32 %86 to double
  %88 = load double, ptr %13, align 8, !tbaa !27
  %89 = fadd double %88, %87
  store double %89, ptr %13, align 8, !tbaa !27
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #5
  %90 = load i32, ptr %18, align 4, !tbaa !26
  store i32 %90, ptr %20, align 4, !tbaa !26
  br label %91

91:                                               ; preds = %138, %72
  %92 = load i32, ptr %20, align 4, !tbaa !26
  %93 = load i32, ptr %19, align 4, !tbaa !26
  %94 = icmp slt i32 %92, %93
  br i1 %94, label %96, label %95

95:                                               ; preds = %91
  store i32 5, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #5
  br label %141

96:                                               ; preds = %91
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #5
  %97 = load ptr, ptr %11, align 8, !tbaa !5
  %98 = load i32, ptr %20, align 4, !tbaa !26
  %99 = sext i32 %98 to i64
  %100 = getelementptr inbounds i32, ptr %97, i64 %99
  %101 = load i32, ptr %100, align 4, !tbaa !26
  store i32 %101, ptr %21, align 4, !tbaa !26
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #5
  %102 = load ptr, ptr %7, align 8, !tbaa !5
  %103 = load i32, ptr %21, align 4, !tbaa !26
  %104 = sext i32 %103 to i64
  %105 = getelementptr inbounds double, ptr %102, i64 %104
  %106 = load double, ptr %105, align 8, !tbaa !27
  store double %106, ptr %22, align 8, !tbaa !27
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #5
  %107 = load double, ptr %22, align 8, !tbaa !27
  %108 = load double, ptr %17, align 8, !tbaa !27
  %109 = load ptr, ptr %12, align 8, !tbaa !5
  %110 = load i32, ptr %20, align 4, !tbaa !26
  %111 = sext i32 %110 to i64
  %112 = getelementptr inbounds double, ptr %109, i64 %111
  %113 = load double, ptr %112, align 8, !tbaa !27
  %114 = fneg double %108
  %115 = call double @llvm.fmuladd.f64(double %114, double %113, double %107)
  store double %115, ptr %23, align 8, !tbaa !27
  %116 = load double, ptr %22, align 8, !tbaa !27
  %117 = fcmp oeq double %116, 0.000000e+00
  br i1 %117, label %118, label %125

118:                                              ; preds = %96
  %119 = load i32, ptr %21, align 4, !tbaa !26
  %120 = load ptr, ptr %6, align 8, !tbaa !5
  %121 = load i32, ptr %5, align 4, !tbaa !26
  %122 = add nsw i32 %121, 1
  store i32 %122, ptr %5, align 4, !tbaa !26
  %123 = sext i32 %121 to i64
  %124 = getelementptr inbounds i32, ptr %120, i64 %123
  store i32 %119, ptr %124, align 4, !tbaa !26
  br label %125

125:                                              ; preds = %118, %96
  %126 = load double, ptr %23, align 8, !tbaa !27
  %127 = call double @llvm.fabs.f64(double %126)
  %128 = fcmp olt double %127, 0x3D06849B86A12B9B
  br i1 %128, label %129, label %130

129:                                              ; preds = %125
  br label %132

130:                                              ; preds = %125
  %131 = load double, ptr %23, align 8, !tbaa !27
  br label %132

132:                                              ; preds = %130, %129
  %133 = phi double [ 1.000000e-50, %129 ], [ %131, %130 ]
  %134 = load ptr, ptr %7, align 8, !tbaa !5
  %135 = load i32, ptr %21, align 4, !tbaa !26
  %136 = sext i32 %135 to i64
  %137 = getelementptr inbounds double, ptr %134, i64 %136
  store double %133, ptr %137, align 8, !tbaa !27
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #5
  br label %138

138:                                              ; preds = %132
  %139 = load i32, ptr %20, align 4, !tbaa !26
  %140 = add nsw i32 %139, 1
  store i32 %140, ptr %20, align 4, !tbaa !26
  br label %91, !llvm.loop !28

141:                                              ; preds = %95
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  br label %142

142:                                              ; preds = %141, %59
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  br label %143

143:                                              ; preds = %142
  %144 = load i32, ptr %14, align 4, !tbaa !26
  %145 = add nsw i32 %144, -1
  store i32 %145, ptr %14, align 4, !tbaa !26
  br label %55, !llvm.loop !30

146:                                              ; preds = %58
  %147 = load double, ptr %13, align 8, !tbaa !27
  %148 = load i32, ptr %8, align 4, !tbaa !26
  %149 = mul nsw i32 %148, 10
  %150 = sitofp i32 %149 to double
  %151 = call double @llvm.fmuladd.f64(double %147, double 1.500000e+01, double %150)
  %152 = load ptr, ptr %4, align 8, !tbaa !5
  %153 = getelementptr inbounds %class.HVectorBase, ptr %152, i32 0, i32 4
  %154 = load double, ptr %153, align 8, !tbaa !31
  %155 = fadd double %154, %151
  store double %155, ptr %153, align 8, !tbaa !31
  %156 = load i32, ptr %5, align 4, !tbaa !26
  %157 = load ptr, ptr %4, align 8, !tbaa !5
  %158 = getelementptr inbounds %class.HVectorBase, ptr %157, i32 0, i32 1
  store i32 %156, ptr %158, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  ret void
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { noreturn nounwind }
attributes #5 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !11, i64 4}
!10 = !{!"_ZTS11HVectorBaseIdE", !11, i64 0, !11, i64 4, !12, i64 8, !16, i64 32, !20, i64 56, !21, i64 64, !12, i64 88, !6, i64 112, !25, i64 120, !11, i64 124, !12, i64 128, !16, i64 152}
!11 = !{!"int", !7, i64 0}
!12 = !{!"_ZTSSt6vectorIiSaIiEE", !13, i64 0}
!13 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !14, i64 0}
!14 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !15, i64 0}
!15 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!16 = !{!"_ZTSSt6vectorIdSaIdEE", !17, i64 0}
!17 = !{!"_ZTSSt12_Vector_baseIdSaIdEE", !18, i64 0}
!18 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE12_Vector_implE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!20 = !{!"double", !7, i64 0}
!21 = !{!"_ZTSSt6vectorIcSaIcEE", !22, i64 0}
!22 = !{!"_ZTSSt12_Vector_baseIcSaIcEE", !23, i64 0}
!23 = !{!"_ZTSNSt12_Vector_baseIcSaIcEE12_Vector_implE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseIcSaIcEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!25 = !{!"bool", !7, i64 0}
!26 = !{!11, !11, i64 0}
!27 = !{!20, !20, i64 0}
!28 = distinct !{!28, !29}
!29 = !{!"llvm.loop.mustprogress"}
!30 = distinct !{!30, !29}
!31 = !{!10, !20, i64 56}


; Optimized IR (opt -passes='default<O3>'):
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-unknown-linux-gnu"

@.str.52 = external hidden unnamed_addr constant [70 x i8], align 1
@.str.81 = external hidden unnamed_addr constant [18 x i8], align 1
@__PRETTY_FUNCTION__._ZNK7HFactor7btranFTER11HVectorBaseIdE = external hidden unnamed_addr constant [39 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNKSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNKSt6vectorIdSaIdEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #2

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fabs.f64(double) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNSt6vectorIdSaIdEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
define dso_local void @_ZNK7HFactor7btranFTER11HVectorBaseIdE(ptr noundef nonnull align 8 dereferenceable(1912) %0, ptr noundef nonnull align 8 dereferenceable(176) %1) local_unnamed_addr #0 align 2 {
  %3 = getelementptr inbounds i8, ptr %1, i64 4
  %4 = load i32, ptr %3, align 4, !tbaa !5
  %5 = icmp sgt i32 %4, -1
  br i1 %5, label %7, label %6

6:                                                ; preds = %2
  tail call void @__assert_fail(ptr noundef nonnull @.str.81, ptr noundef nonnull @.str.52, i32 noundef 1884, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK7HFactor7btranFTER11HVectorBaseIdE) #3
  unreachable

7:                                                ; preds = %2
  %8 = getelementptr inbounds i8, ptr %1, i64 8
  %9 = tail call noundef ptr @_ZNSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #4
  %10 = getelementptr inbounds i8, ptr %1, i64 32
  %11 = tail call noundef ptr @_ZNSt6vectorIdSaIdEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %10) #4
  %12 = getelementptr inbounds i8, ptr %0, i64 1640
  %13 = tail call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #4
  %14 = trunc i64 %13 to i32
  %15 = tail call noundef ptr @_ZNKSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #4
  %16 = getelementptr inbounds i8, ptr %0, i64 1664
  %17 = tail call noundef ptr @_ZNKSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #4
  %18 = getelementptr inbounds i8, ptr %0, i64 1688
  %19 = tail call noundef ptr @_ZNKSt6vectorIiSaIiEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %18) #4
  %20 = getelementptr inbounds i8, ptr %0, i64 1712
  %21 = tail call noundef ptr @_ZNKSt6vectorIdSaIdEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %20) #4
  %22 = icmp sgt i32 %14, 0
  br i1 %22, label %.lr.ph57.preheader, label %._crit_edge

.lr.ph57.preheader:                               ; preds = %7
  %23 = and i64 %13, 2147483647
  br label %.lr.ph57

._crit_edge:                                      ; preds = %.loopexit, %7
  %.044.lcssa = phi double [ 0.000000e+00, %7 ], [ %.145, %.loopexit ]
  %.0.lcssa = phi i32 [ %4, %7 ], [ %.3, %.loopexit ]
  %24 = mul nsw i32 %14, 10
  %25 = sitofp i32 %24 to double
  %26 = tail call double @llvm.fmuladd.f64(double %.044.lcssa, double 1.500000e+01, double %25)
  %27 = getelementptr inbounds i8, ptr %1, i64 56
  %28 = load double, ptr %27, align 8, !tbaa !25
  %29 = fadd double %26, %28
  store double %29, ptr %27, align 8, !tbaa !25
  store i32 %.0.lcssa, ptr %3, align 4, !tbaa !5
  ret void

.lr.ph57:                                         ; preds = %.lr.ph57.preheader, %.loopexit
  %indvars.iv61 = phi i64 [ %23, %.lr.ph57.preheader ], [ %indvars.iv.next62, %.loopexit ]
  %.055 = phi i32 [ %4, %.lr.ph57.preheader ], [ %.3, %.loopexit ]
  %.04454 = phi double [ 0.000000e+00, %.lr.ph57.preheader ], [ %.145, %.loopexit ]
  %indvars.iv.next62 = add nsw i64 %indvars.iv61, -1
  %30 = getelementptr inbounds i32, ptr %15, i64 %indvars.iv.next62
  %31 = load i32, ptr %30, align 4, !tbaa !26
  %32 = sext i32 %31 to i64
  %33 = getelementptr inbounds double, ptr %11, i64 %32
  %34 = load double, ptr %33, align 8, !tbaa !27
  %35 = fcmp une double %34, 0.000000e+00
  br i1 %35, label %36, label %.loopexit

36:                                               ; preds = %.lr.ph57
  %37 = getelementptr inbounds i32, ptr %17, i64 %indvars.iv.next62
  %38 = load i32, ptr %37, align 4, !tbaa !26
  %39 = getelementptr inbounds i32, ptr %17, i64 %indvars.iv61
  %40 = load i32, ptr %39, align 4, !tbaa !26
  %41 = sub nsw i32 %40, %38
  %42 = sitofp i32 %41 to double
  %43 = fadd double %.04454, %42
  %44 = icmp slt i32 %38, %40
  br i1 %44, label %.lr.ph, label %.loopexit

.lr.ph:                                           ; preds = %36
  %45 = fneg double %34
  %46 = sext i32 %38 to i64
  %wide.trip.count = sext i32 %40 to i64
  br label %47

47:                                               ; preds = %.lr.ph, %61
  %indvars.iv = phi i64 [ %46, %.lr.ph ], [ %indvars.iv.next, %61 ]
  %.151 = phi i32 [ %.055, %.lr.ph ], [ %.2, %61 ]
  %48 = getelementptr inbounds i32, ptr %19, i64 %indvars.iv
  %49 = load i32, ptr %48, align 4, !tbaa !26
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds double, ptr %11, i64 %50
  %52 = load double, ptr %51, align 8, !tbaa !27
  %53 = getelementptr inbounds double, ptr %21, i64 %indvars.iv
  %54 = load double, ptr %53, align 8, !tbaa !27
  %55 = tail call double @llvm.fmuladd.f64(double %45, double %54, double %52)
  %56 = fcmp oeq double %52, 0.000000e+00
  br i1 %56, label %57, label %61

57:                                               ; preds = %47
  %58 = add nuw nsw i32 %.151, 1
  %59 = zext nneg i32 %.151 to i64
  %60 = getelementptr inbounds i32, ptr %9, i64 %59
  store i32 %49, ptr %60, align 4, !tbaa !26
  br label %61

61:                                               ; preds = %57, %47
  %.2 = phi i32 [ %58, %57 ], [ %.151, %47 ]
  %62 = tail call double @llvm.fabs.f64(double %55)
  %63 = fcmp olt double %62, 0x3D06849B86A12B9B
  %64 = select i1 %63, double 1.000000e-50, double %55
  store double %64, ptr %51, align 8, !tbaa !27
  %indvars.iv.next = add nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %.loopexit, label %47, !llvm.loop !28

.loopexit:                                        ; preds = %61, %36, %.lr.ph57
  %.145 = phi double [ %.04454, %.lr.ph57 ], [ %43, %36 ], [ %43, %61 ]
  %.3 = phi i32 [ %.055, %.lr.ph57 ], [ %.055, %36 ], [ %.2, %61 ]
  %65 = icmp sgt i64 %indvars.iv61, 1
  br i1 %65, label %.lr.ph57, label %._crit_edge, !llvm.loop !30
}

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { noreturn nounwind }
attributes #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 4}
!6 = !{!"_ZTS11HVectorBaseIdE", !7, i64 0, !7, i64 4, !10, i64 8, !15, i64 32, !19, i64 56, !20, i64 64, !10, i64 88, !14, i64 112, !24, i64 120, !7, i64 124, !10, i64 128, !15, i64 152}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTSSt6vectorIiSaIiEE", !11, i64 0}
!11 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !12, i64 0}
!12 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !13, i64 0}
!13 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !14, i64 0, !14, i64 8, !14, i64 16}
!14 = !{!"any pointer", !8, i64 0}
!15 = !{!"_ZTSSt6vectorIdSaIdEE", !16, i64 0}
!16 = !{!"_ZTSSt12_Vector_baseIdSaIdEE", !17, i64 0}
!17 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE12_Vector_implE", !18, i64 0}
!18 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE17_Vector_impl_dataE", !14, i64 0, !14, i64 8, !14, i64 16}
!19 = !{!"double", !8, i64 0}
!20 = !{!"_ZTSSt6vectorIcSaIcEE", !21, i64 0}
!21 = !{!"_ZTSSt12_Vector_baseIcSaIcEE", !22, i64 0}
!22 = !{!"_ZTSNSt12_Vector_baseIcSaIcEE12_Vector_implE", !23, i64 0}
!23 = !{!"_ZTSNSt12_Vector_baseIcSaIcEE17_Vector_impl_dataE", !14, i64 0, !14, i64 8, !14, i64 16}
!24 = !{!"bool", !8, i64 0}
!25 = !{!6, !19, i64 56}
!26 = !{!7, !7, i64 0}
!27 = !{!19, !19, i64 0}
!28 = distinct !{!28, !29}
!29 = !{!"llvm.loop.mustprogress"}
!30 = distinct !{!30, !29}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass