; LLVM IR from Tian-Xie/NLS :: NestedLogitSolverDisjoint.ll (ZN17NestedLogitSolver13SolveDisjointESt6vectorIiSaIiEEb)

; 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"

%struct.TDelta = type { double, double, double }
%struct.NestedLogitSolver = type { ptr, %"class.std::vector", double }
%"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 }
%struct.NestedLogitModel = type { i32, %"class.std::vector.0", double }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<TNest, std::allocator<TNest>>::_Vector_impl" }
%"struct.std::_Vector_base<TNest, std::allocator<TNest>>::_Vector_impl" = type { %"struct.std::_Vector_base<TNest, std::allocator<TNest>>::_Vector_impl_data" }
%"struct.std::_Vector_base<TNest, std::allocator<TNest>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%struct.TNest = type <{ i32, [4 x i8], double, %"class.std::vector.5", ptr, ptr, i32, [4 x i8], ptr, ptr, i32, [4 x i8] }>
%"class.std::vector.5" = type { %"struct.std::_Vector_base.6" }
%"struct.std::_Vector_base.6" = type { %"struct.std::_Vector_base<TProduct, std::allocator<TProduct>>::_Vector_impl" }
%"struct.std::_Vector_base<TProduct, std::allocator<TProduct>>::_Vector_impl" = type { %"struct.std::_Vector_base<TProduct, std::allocator<TProduct>>::_Vector_impl_data" }
%"struct.std::_Vector_base<TProduct, std::allocator<TProduct>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::pair" = type { i32, double }
%struct.TCandidate = type { double, double, double, double }

; Function Attrs: mustprogress uwtable
define dso_local noundef double @_ZN17NestedLogitSolver13SolveDisjointESt6vectorIiSaIiEEb(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef %1, i1 noundef zeroext %2) #0 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i8, align 1
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca double, align 8
  %17 = alloca double, align 8
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca ptr, align 8
  %21 = alloca i32, align 4
  %22 = alloca ptr, align 8
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca %struct.TDelta, align 8
  %26 = alloca double, align 8
  %27 = alloca double, align 8
  %28 = alloca i32, align 4
  %29 = alloca double, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  %30 = zext i1 %2 to i8
  store i8 %30, ptr %6, align 1, !tbaa !9
  %31 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #10
  %32 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %33 = load ptr, ptr %32, align 8, !tbaa !11
  %34 = getelementptr inbounds %struct.NestedLogitModel, ptr %33, i32 0, i32 0
  %35 = load i32, ptr %34, align 8, !tbaa !18
  store i32 %35, ptr %7, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #10
  store i32 0, ptr %8, align 4, !tbaa !25
  br label %36

36:                                               ; preds = %65, %3
  %37 = load i32, ptr %8, align 4, !tbaa !25
  %38 = load i32, ptr %7, align 4, !tbaa !25
  %39 = icmp slt i32 %37, %38
  br i1 %39, label %41, label %40

40:                                               ; preds = %36
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #10
  br label %68

41:                                               ; preds = %36
  %42 = load i32, ptr %8, align 4, !tbaa !25
  %43 = sext i32 %42 to i64
  %44 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %43) #10
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #10
  store i32 0, ptr %9, align 4, !tbaa !25
  %45 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %44, ptr noundef nonnull align 4 dereferenceable(4) %9)
  %46 = load i32, ptr %45, align 4, !tbaa !25
  %47 = load i32, ptr %8, align 4, !tbaa !25
  %48 = sext i32 %47 to i64
  %49 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %48) #10
  store i32 %46, ptr %49, align 4, !tbaa !25
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #10
  %50 = load i32, ptr %8, align 4, !tbaa !25
  %51 = sext i32 %50 to i64
  %52 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %51) #10
  %53 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %54 = load ptr, ptr %53, align 8, !tbaa !11
  %55 = getelementptr inbounds %struct.NestedLogitModel, ptr %54, i32 0, i32 1
  %56 = load i32, ptr %8, align 4, !tbaa !25
  %57 = sext i32 %56 to i64
  %58 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %55, i64 noundef %57) #10
  %59 = getelementptr inbounds %struct.TNest, ptr %58, i32 0, i32 0
  %60 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %52, ptr noundef nonnull align 4 dereferenceable(4) %59)
  %61 = load i32, ptr %60, align 4, !tbaa !25
  %62 = load i32, ptr %8, align 4, !tbaa !25
  %63 = sext i32 %62 to i64
  %64 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %63) #10
  store i32 %61, ptr %64, align 4, !tbaa !25
  br label %65

65:                                               ; preds = %41
  %66 = load i32, ptr %8, align 4, !tbaa !25
  %67 = add nsw i32 %66, 1
  store i32 %67, ptr %8, align 4, !tbaa !25
  br label %36, !llvm.loop !26

68:                                               ; preds = %40
  %69 = load i8, ptr %6, align 1, !tbaa !9, !range !28, !noundef !29
  %70 = trunc i8 %69 to i1
  br i1 %70, label %71, label %92

71:                                               ; preds = %68
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #10
  store i32 0, ptr %10, align 4, !tbaa !25
  br label %72

72:                                               ; preds = %88, %71
  %73 = load i32, ptr %10, align 4, !tbaa !25
  %74 = load i32, ptr %7, align 4, !tbaa !25
  %75 = icmp slt i32 %73, %74
  br i1 %75, label %77, label %76

76:                                               ; preds = %72
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #10
  br label %91

77:                                               ; preds = %72
  %78 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %79 = load ptr, ptr %78, align 8, !tbaa !11
  %80 = getelementptr inbounds %struct.NestedLogitModel, ptr %79, i32 0, i32 1
  %81 = load i32, ptr %10, align 4, !tbaa !25
  %82 = sext i32 %81 to i64
  %83 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %80, i64 noundef %82) #10
  %84 = load i32, ptr %10, align 4, !tbaa !25
  %85 = sext i32 %84 to i64
  %86 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %85) #10
  %87 = load i32, ptr %86, align 4, !tbaa !25
  call void @_ZN5TNest23GeneratePiecewiseLinearEi(ptr noundef nonnull align 8 dereferenceable(84) %83, i32 noundef %87)
  br label %88

88:                                               ; preds = %77
  %89 = load i32, ptr %10, align 4, !tbaa !25
  %90 = add nsw i32 %89, 1
  store i32 %90, ptr %10, align 4, !tbaa !25
  br label %72, !llvm.loop !30

91:                                               ; preds = %76
  br label %92

92:                                               ; preds = %91, %68
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #10
  store i32 0, ptr %11, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #10
  store i32 0, ptr %12, align 4, !tbaa !25
  br label %93

93:                                               ; preds = %117, %92
  %94 = load i32, ptr %12, align 4, !tbaa !25
  %95 = load i32, ptr %7, align 4, !tbaa !25
  %96 = icmp slt i32 %94, %95
  br i1 %96, label %98, label %97

97:                                               ; preds = %93
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #10
  br label %120

98:                                               ; preds = %93
  %99 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %100 = load ptr, ptr %99, align 8, !tbaa !11
  %101 = getelementptr inbounds %struct.NestedLogitModel, ptr %100, i32 0, i32 1
  %102 = load i32, ptr %12, align 4, !tbaa !25
  %103 = sext i32 %102 to i64
  %104 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %101, i64 noundef %103) #10
  %105 = getelementptr inbounds %struct.TNest, ptr %104, i32 0, i32 9
  %106 = load ptr, ptr %105, align 8, !tbaa !31
  %107 = load i32, ptr %12, align 4, !tbaa !25
  %108 = sext i32 %107 to i64
  %109 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %108) #10
  %110 = load i32, ptr %109, align 4, !tbaa !25
  %111 = sext i32 %110 to i64
  %112 = getelementptr inbounds i32, ptr %106, i64 %111
  %113 = load i32, ptr %112, align 4, !tbaa !25
  %114 = sub nsw i32 %113, 1
  %115 = load i32, ptr %11, align 4, !tbaa !25
  %116 = add nsw i32 %115, %114
  store i32 %116, ptr %11, align 4, !tbaa !25
  br label %117

117:                                              ; preds = %98
  %118 = load i32, ptr %12, align 4, !tbaa !25
  %119 = add nsw i32 %118, 1
  store i32 %119, ptr %12, align 4, !tbaa !25
  br label %93, !llvm.loop !37

120:                                              ; preds = %97
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #10
  %121 = load i32, ptr %11, align 4, !tbaa !25
  %122 = sext i32 %121 to i64
  %123 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %122, i64 24)
  %124 = extractvalue { i64, i1 } %123, 1
  %125 = extractvalue { i64, i1 } %123, 0
  %126 = select i1 %124, i64 -1, i64 %125
  %127 = call noalias noundef nonnull ptr @_Znam(i64 noundef %126) #11
  %128 = icmp eq i64 %122, 0
  br i1 %128, label %136, label %129

129:                                              ; preds = %120
  %130 = getelementptr inbounds %struct.TDelta, ptr %127, i64 %122
  br label %131

131:                                              ; preds = %133, %129
  %132 = phi ptr [ %127, %129 ], [ %134, %133 ]
  invoke void @_ZN6TDeltaC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %132)
          to label %133 unwind label %146

133:                                              ; preds = %131
  %134 = getelementptr inbounds %struct.TDelta, ptr %132, i64 1
  %135 = icmp eq ptr %134, %130
  br i1 %135, label %136, label %131

136:                                              ; preds = %133, %120
  store ptr %127, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #10
  store double 0.000000e+00, ptr %16, align 8, !tbaa !38
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #10
  %137 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %138 = load ptr, ptr %137, align 8, !tbaa !11
  %139 = getelementptr inbounds %struct.NestedLogitModel, ptr %138, i32 0, i32 2
  %140 = load double, ptr %139, align 8, !tbaa !39
  store double %140, ptr %17, align 8, !tbaa !38
  store i32 0, ptr %11, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #10
  store i32 0, ptr %18, align 4, !tbaa !25
  br label %141

141:                                              ; preds = %302, %136
  %142 = load i32, ptr %18, align 4, !tbaa !25
  %143 = load i32, ptr %7, align 4, !tbaa !25
  %144 = icmp slt i32 %142, %143
  br i1 %144, label %150, label %145

145:                                              ; preds = %141
  store i32 11, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #10
  br label %305

146:                                              ; preds = %131
  %147 = landingpad { ptr, i32 }
          cleanup
  %148 = extractvalue { ptr, i32 } %147, 0
  store ptr %148, ptr %14, align 8
  %149 = extractvalue { ptr, i32 } %147, 1
  store i32 %149, ptr %15, align 4
  call void @_ZdaPvm(ptr noundef %127, i64 noundef %126) #12
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #10
  br label %367

150:                                              ; preds = %141
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #10
  %151 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %152 = load ptr, ptr %151, align 8, !tbaa !11
  %153 = getelementptr inbounds %struct.NestedLogitModel, ptr %152, i32 0, i32 1
  %154 = load i32, ptr %18, align 4, !tbaa !25
  %155 = sext i32 %154 to i64
  %156 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %153, i64 noundef %155) #10
  %157 = getelementptr inbounds %struct.TNest, ptr %156, i32 0, i32 4
  %158 = load ptr, ptr %157, align 8, !tbaa !40
  %159 = load i32, ptr %18, align 4, !tbaa !25
  %160 = sext i32 %159 to i64
  %161 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %160) #10
  %162 = load i32, ptr %161, align 4, !tbaa !25
  %163 = sext i32 %162 to i64
  %164 = getelementptr inbounds ptr, ptr %158, i64 %163
  %165 = load ptr, ptr %164, align 8, !tbaa !5
  store ptr %165, ptr %20, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #10
  %166 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %167 = load ptr, ptr %166, align 8, !tbaa !11
  %168 = getelementptr inbounds %struct.NestedLogitModel, ptr %167, i32 0, i32 1
  %169 = load i32, ptr %18, align 4, !tbaa !25
  %170 = sext i32 %169 to i64
  %171 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %168, i64 noundef %170) #10
  %172 = getelementptr inbounds %struct.TNest, ptr %171, i32 0, i32 5
  %173 = load ptr, ptr %172, align 8, !tbaa !41
  %174 = load i32, ptr %18, align 4, !tbaa !25
  %175 = sext i32 %174 to i64
  %176 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %175) #10
  %177 = load i32, ptr %176, align 4, !tbaa !25
  %178 = sext i32 %177 to i64
  %179 = getelementptr inbounds i32, ptr %173, i64 %178
  %180 = load i32, ptr %179, align 4, !tbaa !25
  store i32 %180, ptr %21, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #10
  %181 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %182 = load ptr, ptr %181, align 8, !tbaa !11
  %183 = getelementptr inbounds %struct.NestedLogitModel, ptr %182, i32 0, i32 1
  %184 = load i32, ptr %18, align 4, !tbaa !25
  %185 = sext i32 %184 to i64
  %186 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %183, i64 noundef %185) #10
  %187 = getelementptr inbounds %struct.TNest, ptr %186, i32 0, i32 8
  %188 = load ptr, ptr %187, align 8, !tbaa !42
  %189 = load i32, ptr %18, align 4, !tbaa !25
  %190 = sext i32 %189 to i64
  %191 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %190) #10
  %192 = load i32, ptr %191, align 4, !tbaa !25
  %193 = sext i32 %192 to i64
  %194 = getelementptr inbounds ptr, ptr %188, i64 %193
  %195 = load ptr, ptr %194, align 8, !tbaa !5
  store ptr %195, ptr %22, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #10
  %196 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 0
  %197 = load ptr, ptr %196, align 8, !tbaa !11
  %198 = getelementptr inbounds %struct.NestedLogitModel, ptr %197, i32 0, i32 1
  %199 = load i32, ptr %18, align 4, !tbaa !25
  %200 = sext i32 %199 to i64
  %201 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %198, i64 noundef %200) #10
  %202 = getelementptr inbounds %struct.TNest, ptr %201, i32 0, i32 9
  %203 = load ptr, ptr %202, align 8, !tbaa !31
  %204 = load i32, ptr %18, align 4, !tbaa !25
  %205 = sext i32 %204 to i64
  %206 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %205) #10
  %207 = load i32, ptr %206, align 4, !tbaa !25
  %208 = sext i32 %207 to i64
  %209 = getelementptr inbounds i32, ptr %203, i64 %208
  %210 = load i32, ptr %209, align 4, !tbaa !25
  store i32 %210, ptr %23, align 4, !tbaa !25
  %211 = load ptr, ptr %20, align 8, !tbaa !5
  %212 = load ptr, ptr %22, align 8, !tbaa !5
  %213 = getelementptr inbounds %"struct.std::pair", ptr %212, i64 0
  %214 = getelementptr inbounds %"struct.std::pair", ptr %213, i32 0, i32 0
  %215 = load i32, ptr %214, align 8, !tbaa !43
  %216 = sext i32 %215 to i64
  %217 = getelementptr inbounds %struct.TCandidate, ptr %211, i64 %216
  %218 = getelementptr inbounds %struct.TCandidate, ptr %217, i32 0, i32 2
  %219 = load double, ptr %218, align 8, !tbaa !45
  %220 = load double, ptr %16, align 8, !tbaa !38
  %221 = fadd double %220, %219
  store double %221, ptr %16, align 8, !tbaa !38
  %222 = load ptr, ptr %20, align 8, !tbaa !5
  %223 = load ptr, ptr %22, align 8, !tbaa !5
  %224 = getelementptr inbounds %"struct.std::pair", ptr %223, i64 0
  %225 = getelementptr inbounds %"struct.std::pair", ptr %224, i32 0, i32 0
  %226 = load i32, ptr %225, align 8, !tbaa !43
  %227 = sext i32 %226 to i64
  %228 = getelementptr inbounds %struct.TCandidate, ptr %222, i64 %227
  %229 = getelementptr inbounds %struct.TCandidate, ptr %228, i32 0, i32 3
  %230 = load double, ptr %229, align 8, !tbaa !47
  %231 = load double, ptr %17, align 8, !tbaa !38
  %232 = fadd double %231, %230
  store double %232, ptr %17, align 8, !tbaa !38
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #10
  store i32 1, ptr %24, align 4, !tbaa !25
  br label %233

233:                                              ; preds = %298, %150
  %234 = load i32, ptr %24, align 4, !tbaa !25
  %235 = load i32, ptr %23, align 4, !tbaa !25
  %236 = icmp slt i32 %234, %235
  br i1 %236, label %238, label %237

237:                                              ; preds = %233
  store i32 14, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #10
  br label %301

238:                                              ; preds = %233
  call void @llvm.lifetime.start.p0(i64 24, ptr %25) #10
  %239 = load ptr, ptr %22, align 8, !tbaa !5
  %240 = load i32, ptr %24, align 4, !tbaa !25
  %241 = sext i32 %240 to i64
  %242 = getelementptr inbounds %"struct.std::pair", ptr %239, i64 %241
  %243 = getelementptr inbounds %"struct.std::pair", ptr %242, i32 0, i32 1
  %244 = load double, ptr %243, align 8, !tbaa !48
  %245 = load ptr, ptr %20, align 8, !tbaa !5
  %246 = load ptr, ptr %22, align 8, !tbaa !5
  %247 = load i32, ptr %24, align 4, !tbaa !25
  %248 = sext i32 %247 to i64
  %249 = getelementptr inbounds %"struct.std::pair", ptr %246, i64 %248
  %250 = getelementptr inbounds %"struct.std::pair", ptr %249, i32 0, i32 0
  %251 = load i32, ptr %250, align 8, !tbaa !43
  %252 = sext i32 %251 to i64
  %253 = getelementptr inbounds %struct.TCandidate, ptr %245, i64 %252
  %254 = getelementptr inbounds %struct.TCandidate, ptr %253, i32 0, i32 2
  %255 = load double, ptr %254, align 8, !tbaa !45
  %256 = load ptr, ptr %20, align 8, !tbaa !5
  %257 = load ptr, ptr %22, align 8, !tbaa !5
  %258 = load i32, ptr %24, align 4, !tbaa !25
  %259 = sub nsw i32 %258, 1
  %260 = sext i32 %259 to i64
  %261 = getelementptr inbounds %"struct.std::pair", ptr %257, i64 %260
  %262 = getelementptr inbounds %"struct.std::pair", ptr %261, i32 0, i32 0
  %263 = load i32, ptr %262, align 8, !tbaa !43
  %264 = sext i32 %263 to i64
  %265 = getelementptr inbounds %struct.TCandidate, ptr %256, i64 %264
  %266 = getelementptr inbounds %struct.TCandidate, ptr %265, i32 0, i32 2
  %267 = load double, ptr %266, align 8, !tbaa !45
  %268 = fsub double %255, %267
  %269 = load ptr, ptr %20, align 8, !tbaa !5
  %270 = load ptr, ptr %22, align 8, !tbaa !5
  %271 = load i32, ptr %24, align 4, !tbaa !25
  %272 = sext i32 %271 to i64
  %273 = getelementptr inbounds %"struct.std::pair", ptr %270, i64 %272
  %274 = getelementptr inbounds %"struct.std::pair", ptr %273, i32 0, i32 0
  %275 = load i32, ptr %274, align 8, !tbaa !43
  %276 = sext i32 %275 to i64
  %277 = getelementptr inbounds %struct.TCandidate, ptr %269, i64 %276
  %278 = getelementptr inbounds %struct.TCandidate, ptr %277, i32 0, i32 3
  %279 = load double, ptr %278, align 8, !tbaa !47
  %280 = load ptr, ptr %20, align 8, !tbaa !5
  %281 = load ptr, ptr %22, align 8, !tbaa !5
  %282 = load i32, ptr %24, align 4, !tbaa !25
  %283 = sub nsw i32 %282, 1
  %284 = sext i32 %283 to i64
  %285 = getelementptr inbounds %"struct.std::pair", ptr %281, i64 %284
  %286 = getelementptr inbounds %"struct.std::pair", ptr %285, i32 0, i32 0
  %287 = load i32, ptr %286, align 8, !tbaa !43
  %288 = sext i32 %287 to i64
  %289 = getelementptr inbounds %struct.TCandidate, ptr %280, i64 %288
  %290 = getelementptr inbounds %struct.TCandidate, ptr %289, i32 0, i32 3
  %291 = load double, ptr %290, align 8, !tbaa !47
  %292 = fsub double %279, %291
  call void @_ZN6TDeltaC2Eddd(ptr noundef nonnull align 8 dereferenceable(24) %25, double noundef %244, double noundef %268, double noundef %292)
  %293 = load ptr, ptr %13, align 8, !tbaa !5
  %294 = load i32, ptr %11, align 4, !tbaa !25
  %295 = add nsw i32 %294, 1
  store i32 %295, ptr %11, align 4, !tbaa !25
  %296 = sext i32 %294 to i64
  %297 = getelementptr inbounds %struct.TDelta, ptr %293, i64 %296
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %297, ptr align 8 %25, i64 24, i1 false), !tbaa.struct !49
  call void @llvm.lifetime.end.p0(i64 24, ptr %25) #10
  br label %298

298:                                              ; preds = %238
  %299 = load i32, ptr %24, align 4, !tbaa !25
  %300 = add nsw i32 %299, 1
  store i32 %300, ptr %24, align 4, !tbaa !25
  br label %233, !llvm.loop !50

301:                                              ; preds = %237
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #10
  br label %302

302:                                              ; preds = %301
  %303 = load i32, ptr %18, align 4, !tbaa !25
  %304 = add nsw i32 %303, 1
  store i32 %304, ptr %18, align 4, !tbaa !25
  br label %141, !llvm.loop !51

305:                                              ; preds = %145
  %306 = load ptr, ptr %13, align 8, !tbaa !5
  %307 = load ptr, ptr %13, align 8, !tbaa !5
  %308 = load i32, ptr %11, align 4, !tbaa !25
  %309 = sext i32 %308 to i64
  %310 = getelementptr inbounds %struct.TDelta, ptr %307, i64 %309
  call void @_ZSt4sortIP6TDeltaEvT_S2_(ptr noundef %306, ptr noundef %310)
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #10
  store double -1.000000e+100, ptr %26, align 8, !tbaa !38
  %311 = load double, ptr %17, align 8, !tbaa !38
  %312 = call double @llvm.fabs.f64(double %311)
  %313 = fcmp ogt double %312, 1.000000e-08
  br i1 %313, label %314, label %320

314:                                              ; preds = %305
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #10
  %315 = load double, ptr %16, align 8, !tbaa !38
  %316 = load double, ptr %17, align 8, !tbaa !38
  %317 = fdiv double %315, %316
  store double %317, ptr %27, align 8, !tbaa !38
  %318 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %26, ptr noundef nonnull align 8 dereferenceable(8) %27)
  %319 = load double, ptr %318, align 8, !tbaa !38
  store double %319, ptr %26, align 8, !tbaa !38
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #10
  br label %320

320:                                              ; preds = %314, %305
  call void @llvm.lifetime.start.p0(i64 4, ptr %28) #10
  store i32 0, ptr %28, align 4, !tbaa !25
  br label %321

321:                                              ; preds = %353, %320
  %322 = load i32, ptr %28, align 4, !tbaa !25
  %323 = load i32, ptr %11, align 4, !tbaa !25
  %324 = icmp slt i32 %322, %323
  br i1 %324, label %326, label %325

325:                                              ; preds = %321
  store i32 17, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #10
  br label %356

326:                                              ; preds = %321
  %327 = load ptr, ptr %13, align 8, !tbaa !5
  %328 = load i32, ptr %28, align 4, !tbaa !25
  %329 = sext i32 %328 to i64
  %330 = getelementptr inbounds %struct.TDelta, ptr %327, i64 %329
  %331 = getelementptr inbounds %struct.TDelta, ptr %330, i32 0, i32 1
  %332 = load double, ptr %331, align 8, !tbaa !52
  %333 = load double, ptr %16, align 8, !tbaa !38
  %334 = fadd double %333, %332
  store double %334, ptr %16, align 8, !tbaa !38
  %335 = load ptr, ptr %13, align 8, !tbaa !5
  %336 = load i32, ptr %28, align 4, !tbaa !25
  %337 = sext i32 %336 to i64
  %338 = getelementptr inbounds %struct.TDelta, ptr %335, i64 %337
  %339 = getelementptr inbounds %struct.TDelta, ptr %338, i32 0, i32 2
  %340 = load double, ptr %339, align 8, !tbaa !54
  %341 = load double, ptr %17, align 8, !tbaa !38
  %342 = fadd double %341, %340
  store double %342, ptr %17, align 8, !tbaa !38
  %343 = load double, ptr %17, align 8, !tbaa !38
  %344 = call double @llvm.fabs.f64(double %343)
  %345 = fcmp ogt double %344, 1.000000e-08
  br i1 %345, label %346, label %352

346:                                              ; preds = %326
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #10
  %347 = load double, ptr %16, align 8, !tbaa !38
  %348 = load double, ptr %17, align 8, !tbaa !38
  %349 = fdiv double %347, %348
  store double %349, ptr %29, align 8, !tbaa !38
  %350 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %26, ptr noundef nonnull align 8 dereferenceable(8) %29)
  %351 = load double, ptr %350, align 8, !tbaa !38
  store double %351, ptr %26, align 8, !tbaa !38
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #10
  br label %352

352:                                              ; preds = %346, %326
  br label %353

353:                                              ; preds = %352
  %354 = load i32, ptr %28, align 4, !tbaa !25
  %355 = add nsw i32 %354, 1
  store i32 %355, ptr %28, align 4, !tbaa !25
  br label %321, !llvm.loop !55

356:                                              ; preds = %325
  %357 = load ptr, ptr %13, align 8, !tbaa !5
  %358 = icmp eq ptr %357, null
  br i1 %358, label %360, label %359

359:                                              ; preds = %356
  call void @_ZdlPvm(ptr noundef %357, i64 noundef 24) #12
  br label %360

360:                                              ; preds = %359, %356
  %361 = load double, ptr %26, align 8, !tbaa !38
  %362 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 2
  store double %361, ptr %362, align 8, !tbaa !56
  %363 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 1
  %364 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIiSaIiEEaSERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %363, ptr noundef nonnull align 8 dereferenceable(24) %1)
  %365 = getelementptr inbounds %struct.NestedLogitSolver, ptr %31, i32 0, i32 2
  %366 = load double, ptr %365, align 8, !tbaa !56
  store i32 1, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #10
  ret double %366

367:                                              ; preds = %146
  %368 = load ptr, ptr %14, align 8
  %369 = load i32, ptr %15, align 4
  %370 = insertvalue { ptr, i32 } poison, ptr %368, 0
  %371 = insertvalue { ptr, i32 } %370, i32 %369, 1
  resume { ptr, i32 } %371
}

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #3 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #3 align 2

declare void @_ZN5TNest23GeneratePiecewiseLinearEi(ptr noundef nonnull align 8 dereferenceable(84), i32 noundef) #4

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #5

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6TDeltaC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPvm(ptr noundef, i64 noundef) #7

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6TDeltaC2Eddd(ptr noundef nonnull align 8 dereferenceable(24), double noundef, double noundef, double noundef) unnamed_addr #3 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #8

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIP6TDeltaEvT_S2_(ptr noundef, ptr noundef) #9

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #2

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) #7

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

attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { inlinehint 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 #3 = { 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 #4 = { "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 #5 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { nobuiltin allocsize(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 #7 = { nobuiltin 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 #8 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #9 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #10 = { nounwind }
attributes #11 = { builtin allocsize(0) }
attributes #12 = { builtin 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, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = !{!12, !6, i64 0}
!12 = !{!"_ZTS17NestedLogitSolver", !6, i64 0, !13, i64 8, !17, i64 32}
!13 = !{!"_ZTSSt6vectorIiSaIiEE", !14, i64 0}
!14 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !15, i64 0}
!15 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !16, i64 0}
!16 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!17 = !{!"double", !7, i64 0}
!18 = !{!19, !20, i64 0}
!19 = !{!"_ZTS16NestedLogitModel", !20, i64 0, !21, i64 8, !17, i64 32}
!20 = !{!"int", !7, i64 0}
!21 = !{!"_ZTSSt6vectorI5TNestSaIS0_EE", !22, i64 0}
!22 = !{!"_ZTSSt12_Vector_baseI5TNestSaIS0_EE", !23, i64 0}
!23 = !{!"_ZTSNSt12_Vector_baseI5TNestSaIS0_EE12_Vector_implE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseI5TNestSaIS0_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!25 = !{!20, !20, i64 0}
!26 = distinct !{!26, !27}
!27 = !{!"llvm.loop.mustprogress"}
!28 = !{i8 0, i8 2}
!29 = !{}
!30 = distinct !{!30, !27}
!31 = !{!32, !6, i64 72}
!32 = !{!"_ZTS5TNest", !20, i64 0, !17, i64 8, !33, i64 16, !6, i64 40, !6, i64 48, !20, i64 56, !6, i64 64, !6, i64 72, !20, i64 80}
!33 = !{!"_ZTSSt6vectorI8TProductSaIS0_EE", !34, i64 0}
!34 = !{!"_ZTSSt12_Vector_baseI8TProductSaIS0_EE", !35, i64 0}
!35 = !{!"_ZTSNSt12_Vector_baseI8TProductSaIS0_EE12_Vector_implE", !36, i64 0}
!36 = !{!"_ZTSNSt12_Vector_baseI8TProductSaIS0_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!37 = distinct !{!37, !27}
!38 = !{!17, !17, i64 0}
!39 = !{!19, !17, i64 32}
!40 = !{!32, !6, i64 40}
!41 = !{!32, !6, i64 48}
!42 = !{!32, !6, i64 64}
!43 = !{!44, !20, i64 0}
!44 = !{!"_ZTSSt4pairIidE", !20, i64 0, !17, i64 8}
!45 = !{!46, !17, i64 16}
!46 = !{!"_ZTS10TCandidate", !17, i64 0, !17, i64 8, !17, i64 16, !17, i64 24}
!47 = !{!46, !17, i64 24}
!48 = !{!44, !17, i64 8}
!49 = !{i64 0, i64 8, !38, i64 8, i64 8, !38, i64 16, i64 8, !38}
!50 = distinct !{!50, !27}
!51 = distinct !{!51, !27}
!52 = !{!53, !17, i64 8}
!53 = !{!"_ZTS6TDelta", !17, i64 0, !17, i64 8, !17, i64 16}
!54 = !{!53, !17, i64 16}
!55 = distinct !{!55, !27}
!56 = !{!12, !17, i64 32}


; 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"

%struct.TDelta = type { double, double, double }
%struct.TCandidate = type { double, double, double, double }
%"struct.std::pair" = type { i32, double }

; Function Attrs: mustprogress uwtable
define dso_local noundef double @_ZN17NestedLogitSolver13SolveDisjointESt6vectorIiSaIiEEb(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef %1, i1 noundef zeroext %2) local_unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca i32, align 4
  %5 = alloca %struct.TDelta, align 8
  %6 = alloca double, align 8
  %7 = alloca double, align 8
  %8 = alloca double, align 8
  %9 = load ptr, ptr %0, align 8, !tbaa !5
  %10 = load i32, ptr %9, align 8, !tbaa !15
  %11 = icmp sgt i32 %10, 0
  br i1 %11, label %.lr.ph.preheader, label %._crit_edge96

.lr.ph.preheader:                                 ; preds = %3
  %wide.trip.count = zext nneg i32 %10 to i64
  br label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph
  %or.cond = and i1 %11, %2
  br i1 %or.cond, label %.lr.ph91.preheader, label %.loopexit88

.lr.ph91.preheader:                               ; preds = %._crit_edge
  %wide.trip.count126 = zext nneg i32 %10 to i64
  br label %.lr.ph91

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %12 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv) #10
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #10
  store i32 0, ptr %4, align 4, !tbaa !22
  %13 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %12, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %14 = load i32, ptr %13, align 4, !tbaa !22
  %15 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv) #10
  store i32 %14, ptr %15, align 4, !tbaa !22
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #10
  %16 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv) #10
  %17 = load ptr, ptr %0, align 8, !tbaa !5
  %18 = getelementptr inbounds i8, ptr %17, i64 8
  %19 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %18, i64 noundef %indvars.iv) #10
  %20 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %16, ptr noundef nonnull align 4 dereferenceable(4) %19)
  %21 = load i32, ptr %20, align 4, !tbaa !22
  %22 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv) #10
  store i32 %21, ptr %22, align 4, !tbaa !22
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !23

.lr.ph91:                                         ; preds = %.lr.ph91.preheader, %.lr.ph91
  %indvars.iv123 = phi i64 [ 0, %.lr.ph91.preheader ], [ %indvars.iv.next124, %.lr.ph91 ]
  %23 = load ptr, ptr %0, align 8, !tbaa !5
  %24 = getelementptr inbounds i8, ptr %23, i64 8
  %25 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %24, i64 noundef %indvars.iv123) #10
  %26 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv123) #10
  %27 = load i32, ptr %26, align 4, !tbaa !22
  call void @_ZN5TNest23GeneratePiecewiseLinearEi(ptr noundef nonnull align 8 dereferenceable(84) %25, i32 noundef %27)
  %indvars.iv.next124 = add nuw nsw i64 %indvars.iv123, 1
  %exitcond127.not = icmp eq i64 %indvars.iv.next124, %wide.trip.count126
  br i1 %exitcond127.not, label %.loopexit88, label %.lr.ph91, !llvm.loop !25

.loopexit88:                                      ; preds = %.lr.ph91, %._crit_edge
  br i1 %11, label %.lr.ph95.preheader, label %._crit_edge96

.lr.ph95.preheader:                               ; preds = %.loopexit88
  %wide.trip.count131 = zext nneg i32 %10 to i64
  br label %.lr.ph95

._crit_edge96:                                    ; preds = %.lr.ph95, %3, %.loopexit88
  %.079.lcssa = phi i32 [ 0, %.loopexit88 ], [ 0, %3 ], [ %46, %.lr.ph95 ]
  %28 = sext i32 %.079.lcssa to i64
  %29 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %28, i64 24)
  %30 = extractvalue { i64, i1 } %29, 1
  %31 = extractvalue { i64, i1 } %29, 0
  %32 = select i1 %30, i64 -1, i64 %31
  %33 = call noalias noundef nonnull ptr @_Znam(i64 noundef %32) #11
  %34 = icmp eq i32 %.079.lcssa, 0
  br i1 %34, label %.loopexit, label %47

.lr.ph95:                                         ; preds = %.lr.ph95.preheader, %.lr.ph95
  %indvars.iv128 = phi i64 [ 0, %.lr.ph95.preheader ], [ %indvars.iv.next129, %.lr.ph95 ]
  %.07993 = phi i32 [ 0, %.lr.ph95.preheader ], [ %46, %.lr.ph95 ]
  %35 = load ptr, ptr %0, align 8, !tbaa !5
  %36 = getelementptr inbounds i8, ptr %35, i64 8
  %37 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %36, i64 noundef %indvars.iv128) #10
  %38 = getelementptr inbounds i8, ptr %37, i64 72
  %39 = load ptr, ptr %38, align 8, !tbaa !26
  %40 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv128) #10
  %41 = load i32, ptr %40, align 4, !tbaa !22
  %42 = sext i32 %41 to i64
  %43 = getelementptr inbounds i32, ptr %39, i64 %42
  %44 = load i32, ptr %43, align 4, !tbaa !22
  %45 = add i32 %.07993, -1
  %46 = add i32 %45, %44
  %indvars.iv.next129 = add nuw nsw i64 %indvars.iv128, 1
  %exitcond132.not = icmp eq i64 %indvars.iv.next129, %wide.trip.count131
  br i1 %exitcond132.not, label %._crit_edge96, label %.lr.ph95, !llvm.loop !32

47:                                               ; preds = %._crit_edge96
  %48 = getelementptr inbounds %struct.TDelta, ptr %33, i64 %28
  br label %49

49:                                               ; preds = %49, %47
  %50 = phi ptr [ %33, %47 ], [ %51, %49 ]
  call void @_ZN6TDeltaC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %50)
  %51 = getelementptr inbounds i8, ptr %50, i64 24
  %52 = icmp eq ptr %51, %48
  br i1 %52, label %.loopexit, label %49

.loopexit:                                        ; preds = %49, %._crit_edge96
  %53 = load ptr, ptr %0, align 8, !tbaa !5
  %54 = getelementptr inbounds i8, ptr %53, i64 32
  %55 = load double, ptr %54, align 8, !tbaa !33
  %56 = insertelement <2 x double> <double 0.000000e+00, double poison>, double %55, i64 1
  br i1 %11, label %.lr.ph108.preheader, label %._crit_edge109

.lr.ph108.preheader:                              ; preds = %.loopexit
  %wide.trip.count145 = zext nneg i32 %10 to i64
  br label %.lr.ph108

._crit_edge109:                                   ; preds = %._crit_edge101, %.loopexit
  %.1.lcssa = phi i32 [ 0, %.loopexit ], [ %.2.lcssa, %._crit_edge101 ]
  %57 = phi <2 x double> [ %56, %.loopexit ], [ %102, %._crit_edge101 ]
  %58 = sext i32 %.1.lcssa to i64
  %59 = getelementptr inbounds %struct.TDelta, ptr %33, i64 %58
  call void @_ZSt4sortIP6TDeltaEvT_S2_(ptr noundef nonnull %33, ptr noundef nonnull %59)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #10
  store double -1.000000e+100, ptr %6, align 8, !tbaa !34
  %60 = extractelement <2 x double> %57, i64 1
  %61 = call double @llvm.fabs.f64(double %60)
  %62 = fcmp ogt double %61, 1.000000e-08
  br i1 %62, label %127, label %132

.lr.ph108:                                        ; preds = %.lr.ph108.preheader, %._crit_edge101
  %indvars.iv142 = phi i64 [ 0, %.lr.ph108.preheader ], [ %indvars.iv.next143, %._crit_edge101 ]
  %.1106 = phi i32 [ 0, %.lr.ph108.preheader ], [ %.2.lcssa, %._crit_edge101 ]
  %63 = phi <2 x double> [ %56, %.lr.ph108.preheader ], [ %102, %._crit_edge101 ]
  %64 = load ptr, ptr %0, align 8, !tbaa !5
  %65 = getelementptr inbounds i8, ptr %64, i64 8
  %66 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %65, i64 noundef %indvars.iv142) #10
  %67 = getelementptr inbounds i8, ptr %66, i64 40
  %68 = load ptr, ptr %67, align 8, !tbaa !35
  %69 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv142) #10
  %70 = load i32, ptr %69, align 4, !tbaa !22
  %71 = sext i32 %70 to i64
  %72 = getelementptr inbounds ptr, ptr %68, i64 %71
  %73 = load ptr, ptr %72, align 8, !tbaa !36
  %74 = load ptr, ptr %0, align 8, !tbaa !5
  %75 = getelementptr inbounds i8, ptr %74, i64 8
  %76 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %75, i64 noundef %indvars.iv142) #10
  %77 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv142) #10
  %78 = load ptr, ptr %0, align 8, !tbaa !5
  %79 = getelementptr inbounds i8, ptr %78, i64 8
  %80 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %79, i64 noundef %indvars.iv142) #10
  %81 = getelementptr inbounds i8, ptr %80, i64 64
  %82 = load ptr, ptr %81, align 8, !tbaa !37
  %83 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv142) #10
  %84 = load i32, ptr %83, align 4, !tbaa !22
  %85 = sext i32 %84 to i64
  %86 = getelementptr inbounds ptr, ptr %82, i64 %85
  %87 = load ptr, ptr %86, align 8, !tbaa !36
  %88 = load ptr, ptr %0, align 8, !tbaa !5
  %89 = getelementptr inbounds i8, ptr %88, i64 8
  %90 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %89, i64 noundef %indvars.iv142) #10
  %91 = getelementptr inbounds i8, ptr %90, i64 72
  %92 = load ptr, ptr %91, align 8, !tbaa !26
  %93 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %indvars.iv142) #10
  %94 = load i32, ptr %93, align 4, !tbaa !22
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds i32, ptr %92, i64 %95
  %97 = load i32, ptr %96, align 4, !tbaa !22
  %98 = load i32, ptr %87, align 8, !tbaa !38
  %99 = sext i32 %98 to i64
  %100 = getelementptr inbounds %struct.TCandidate, ptr %73, i64 %99, i32 2
  %101 = load <2 x double>, ptr %100, align 8, !tbaa !34
  %102 = fadd <2 x double> %63, %101
  %103 = icmp sgt i32 %97, 1
  br i1 %103, label %.lr.ph100.preheader, label %._crit_edge101

.lr.ph100.preheader:                              ; preds = %.lr.ph108
  %104 = sext i32 %.1106 to i64
  %wide.trip.count140 = zext nneg i32 %97 to i64
  br label %.lr.ph100

._crit_edge101.loopexit:                          ; preds = %.lr.ph100
  %105 = trunc nsw i64 %indvars.iv.next136 to i32
  br label %._crit_edge101

._crit_edge101:                                   ; preds = %._crit_edge101.loopexit, %.lr.ph108
  %.2.lcssa = phi i32 [ %.1106, %.lr.ph108 ], [ %105, %._crit_edge101.loopexit ]
  %indvars.iv.next143 = add nuw nsw i64 %indvars.iv142, 1
  %exitcond146.not = icmp eq i64 %indvars.iv.next143, %wide.trip.count145
  br i1 %exitcond146.not, label %._crit_edge109, label %.lr.ph108, !llvm.loop !40

.lr.ph100:                                        ; preds = %.lr.ph100.preheader, %.lr.ph100
  %indvars.iv135 = phi i64 [ %104, %.lr.ph100.preheader ], [ %indvars.iv.next136, %.lr.ph100 ]
  %indvars.iv133 = phi i64 [ 1, %.lr.ph100.preheader ], [ %indvars.iv.next134, %.lr.ph100 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #10
  %106 = getelementptr inbounds %"struct.std::pair", ptr %87, i64 %indvars.iv133
  %107 = getelementptr inbounds i8, ptr %106, i64 8
  %108 = load double, ptr %107, align 8, !tbaa !41
  %109 = load i32, ptr %106, align 8, !tbaa !38
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds %struct.TCandidate, ptr %73, i64 %110
  %112 = getelementptr inbounds i8, ptr %111, i64 16
  %113 = load double, ptr %112, align 8, !tbaa !42
  %114 = getelementptr i8, ptr %106, i64 -16
  %115 = load i32, ptr %114, align 8, !tbaa !38
  %116 = sext i32 %115 to i64
  %117 = getelementptr inbounds %struct.TCandidate, ptr %73, i64 %116
  %118 = getelementptr inbounds i8, ptr %117, i64 16
  %119 = load double, ptr %118, align 8, !tbaa !42
  %120 = fsub double %113, %119
  %121 = getelementptr inbounds i8, ptr %111, i64 24
  %122 = load double, ptr %121, align 8, !tbaa !44
  %123 = getelementptr inbounds i8, ptr %117, i64 24
  %124 = load double, ptr %123, align 8, !tbaa !44
  %125 = fsub double %122, %124
  call void @_ZN6TDeltaC2Eddd(ptr noundef nonnull align 8 dereferenceable(24) %5, double noundef %108, double noundef %120, double noundef %125)
  %indvars.iv.next136 = add nsw i64 %indvars.iv135, 1
  %126 = getelementptr inbounds %struct.TDelta, ptr %33, i64 %indvars.iv135
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %126, ptr noundef nonnull align 8 dereferenceable(24) %5, i64 24, i1 false), !tbaa.struct !45
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #10
  %indvars.iv.next134 = add nuw nsw i64 %indvars.iv133, 1
  %exitcond141.not = icmp eq i64 %indvars.iv.next134, %wide.trip.count140
  br i1 %exitcond141.not, label %._crit_edge101.loopexit, label %.lr.ph100, !llvm.loop !46

127:                                              ; preds = %._crit_edge109
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #10
  %128 = extractelement <2 x double> %57, i64 0
  %129 = fdiv double %128, %60
  store double %129, ptr %7, align 8, !tbaa !34
  %130 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7)
  %131 = load double, ptr %130, align 8, !tbaa !34
  store double %131, ptr %6, align 8, !tbaa !34
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #10
  br label %132

132:                                              ; preds = %127, %._crit_edge109
  %133 = icmp sgt i32 %.1.lcssa, 0
  br i1 %133, label %.lr.ph117.preheader, label %._crit_edge118

.lr.ph117.preheader:                              ; preds = %132
  %wide.trip.count150 = zext nneg i32 %.1.lcssa to i64
  br label %.lr.ph117

.lr.ph117:                                        ; preds = %.lr.ph117.preheader, %146
  %indvars.iv147 = phi i64 [ 0, %.lr.ph117.preheader ], [ %indvars.iv.next148, %146 ]
  %134 = phi <2 x double> [ %57, %.lr.ph117.preheader ], [ %137, %146 ]
  %135 = getelementptr inbounds %struct.TDelta, ptr %33, i64 %indvars.iv147, i32 1
  %136 = load <2 x double>, ptr %135, align 8, !tbaa !34
  %137 = fadd <2 x double> %134, %136
  %138 = extractelement <2 x double> %137, i64 1
  %139 = call double @llvm.fabs.f64(double %138)
  %140 = fcmp ogt double %139, 1.000000e-08
  br i1 %140, label %141, label %146

141:                                              ; preds = %.lr.ph117
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #10
  %142 = extractelement <2 x double> %137, i64 0
  %143 = fdiv double %142, %138
  store double %143, ptr %8, align 8, !tbaa !34
  %144 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %8)
  %145 = load double, ptr %144, align 8, !tbaa !34
  store double %145, ptr %6, align 8, !tbaa !34
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #10
  br label %146

146:                                              ; preds = %.lr.ph117, %141
  %indvars.iv.next148 = add nuw nsw i64 %indvars.iv147, 1
  %exitcond151.not = icmp eq i64 %indvars.iv.next148, %wide.trip.count150
  br i1 %exitcond151.not, label %._crit_edge118, label %.lr.ph117, !llvm.loop !47

._crit_edge118:                                   ; preds = %146, %132
  call void @_ZdlPvm(ptr noundef nonnull %33, i64 noundef 24) #12
  %147 = load double, ptr %6, align 8, !tbaa !34
  %148 = getelementptr inbounds i8, ptr %0, i64 32
  store double %147, ptr %148, align 8, !tbaa !48
  %149 = getelementptr inbounds i8, ptr %0, i64 8
  %150 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIiSaIiEEaSERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %149, ptr noundef nonnull align 8 dereferenceable(24) %1)
  %151 = load double, ptr %148, align 8, !tbaa !48
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #10
  ret double %151
}

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #3 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #3 align 2

declare void @_ZN5TNest23GeneratePiecewiseLinearEi(ptr noundef nonnull align 8 dereferenceable(84), i32 noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #5

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) local_unnamed_addr #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6TDeltaC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6TDeltaC2Eddd(ptr noundef nonnull align 8 dereferenceable(24), double noundef, double noundef, double noundef) unnamed_addr #3 align 2

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #7

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4sortIP6TDeltaEvT_S2_(ptr noundef, ptr noundef) local_unnamed_addr #8

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZSt3maxIdERKT_S2_S2_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) local_unnamed_addr #9

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

attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { inlinehint 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 #3 = { 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 #4 = { "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 #5 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { nobuiltin allocsize(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 #7 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #8 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #9 = { nobuiltin 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 #10 = { nounwind }
attributes #11 = { builtin allocsize(0) }
attributes #12 = { builtin 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 0}
!6 = !{!"_ZTS17NestedLogitSolver", !7, i64 0, !10, i64 8, !14, i64 32}
!7 = !{!"any pointer", !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", !7, i64 0, !7, i64 8, !7, i64 16}
!14 = !{!"double", !8, i64 0}
!15 = !{!16, !17, i64 0}
!16 = !{!"_ZTS16NestedLogitModel", !17, i64 0, !18, i64 8, !14, i64 32}
!17 = !{!"int", !8, i64 0}
!18 = !{!"_ZTSSt6vectorI5TNestSaIS0_EE", !19, i64 0}
!19 = !{!"_ZTSSt12_Vector_baseI5TNestSaIS0_EE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseI5TNestSaIS0_EE12_Vector_implE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseI5TNestSaIS0_EE17_Vector_impl_dataE", !7, i64 0, !7, i64 8, !7, i64 16}
!22 = !{!17, !17, i64 0}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}
!25 = distinct !{!25, !24}
!26 = !{!27, !7, i64 72}
!27 = !{!"_ZTS5TNest", !17, i64 0, !14, i64 8, !28, i64 16, !7, i64 40, !7, i64 48, !17, i64 56, !7, i64 64, !7, i64 72, !17, i64 80}
!28 = !{!"_ZTSSt6vectorI8TProductSaIS0_EE", !29, i64 0}
!29 = !{!"_ZTSSt12_Vector_baseI8TProductSaIS0_EE", !30, i64 0}
!30 = !{!"_ZTSNSt12_Vector_baseI8TProductSaIS0_EE12_Vector_implE", !31, i64 0}
!31 = !{!"_ZTSNSt12_Vector_baseI8TProductSaIS0_EE17_Vector_impl_dataE", !7, i64 0, !7, i64 8, !7, i64 16}
!32 = distinct !{!32, !24}
!33 = !{!16, !14, i64 32}
!34 = !{!14, !14, i64 0}
!35 = !{!27, !7, i64 40}
!36 = !{!7, !7, i64 0}
!37 = !{!27, !7, i64 64}
!38 = !{!39, !17, i64 0}
!39 = !{!"_ZTSSt4pairIidE", !17, i64 0, !14, i64 8}
!40 = distinct !{!40, !24}
!41 = !{!39, !14, i64 8}
!42 = !{!43, !14, i64 16}
!43 = !{!"_ZTS10TCandidate", !14, i64 0, !14, i64 8, !14, i64 16, !14, i64 24}
!44 = !{!43, !14, i64 24}
!45 = !{i64 0, i64 8, !34, i64 8, i64 8, !34, i64 16, i64 8, !34}
!46 = distinct !{!46, !24}
!47 = distinct !{!47, !24}
!48 = !{!6, !14, i64 32}


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