; LLVM IR from Tian-Xie/NLS :: NestedLogitSolverJoint.ll (ZN17NestedLogitSolver10SolveJointEib)

; 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.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.NestedLogitSolver = type { ptr, %"class.std::vector", double }
%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 }

@.str = external hidden unnamed_addr constant [10 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [73 x i8], align 1
@__PRETTY_FUNCTION__._ZN17NestedLogitSolver10SolveJointEib = external hidden unnamed_addr constant [48 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [62 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_ZN17NestedLogitSolver13JointDPOracleEdiPd(ptr noundef nonnull align 8 dereferenceable(40), double noundef, i32 noundef, ptr noundef) #0 align 2

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

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

; 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) #0 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef double @_ZN17NestedLogitSolver10SolveJointEib(ptr noundef nonnull align 8 dereferenceable(40) %0, i32 noundef %1, i1 noundef zeroext %2) #3 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca i8, align 1
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %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 i32, align 4
  %26 = alloca i32, align 4
  %27 = alloca i32, align 4
  %28 = alloca ptr, align 8
  %29 = alloca i32, align 4
  %30 = alloca double, align 8
  %31 = alloca double, align 8
  %32 = alloca ptr, align 8
  %33 = alloca ptr, align 8
  %34 = alloca i32, align 4
  %35 = alloca ptr, align 8
  %36 = alloca i32, align 4
  %37 = alloca ptr, align 8
  %38 = alloca double, align 8
  %39 = alloca i32, align 4
  %40 = alloca i32, align 4
  %41 = alloca double, align 8
  %42 = alloca ptr, align 8
  %43 = alloca i32, align 4
  %44 = alloca %"class.std::vector", align 8
  %45 = alloca ptr, align 8
  %46 = alloca i32, align 4
  %47 = alloca i32, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store i32 %1, ptr %5, align 4, !tbaa !9
  %48 = zext i1 %2 to i8
  store i8 %48, ptr %6, align 1, !tbaa !11
  %49 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #10
  %50 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 0
  %51 = load ptr, ptr %50, align 8, !tbaa !13
  %52 = getelementptr inbounds %struct.NestedLogitModel, ptr %51, i32 0, i32 0
  %53 = load i32, ptr %52, align 8, !tbaa !20
  store i32 %53, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #10
  store i32 0, ptr %8, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #10
  store i32 0, ptr %9, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #10
  %54 = load i32, ptr %7, align 4, !tbaa !9
  %55 = sext i32 %54 to i64
  %56 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %55, i64 4)
  %57 = extractvalue { i64, i1 } %56, 1
  %58 = extractvalue { i64, i1 } %56, 0
  %59 = select i1 %57, i64 -1, i64 %58
  %60 = call noalias noundef nonnull ptr @_Znam(i64 noundef %59) #11
  store ptr %60, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #10
  store i32 0, ptr %11, align 4, !tbaa !9
  br label %61

61:                                               ; preds = %92, %3
  %62 = load i32, ptr %11, align 4, !tbaa !9
  %63 = load i32, ptr %7, align 4, !tbaa !9
  %64 = icmp slt i32 %62, %63
  br i1 %64, label %66, label %65

65:                                               ; preds = %61
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #10
  br label %95

66:                                               ; preds = %61
  %67 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 0
  %68 = load ptr, ptr %67, align 8, !tbaa !13
  %69 = getelementptr inbounds %struct.NestedLogitModel, ptr %68, i32 0, i32 1
  %70 = load i32, ptr %11, align 4, !tbaa !9
  %71 = sext i32 %70 to i64
  %72 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %69, i64 noundef %71) #10
  %73 = getelementptr inbounds %struct.TNest, ptr %72, i32 0, i32 0
  %74 = load i32, ptr %73, align 8, !tbaa !26
  %75 = load ptr, ptr %10, align 8, !tbaa !5
  %76 = load i32, ptr %11, align 4, !tbaa !9
  %77 = sext i32 %76 to i64
  %78 = getelementptr inbounds i32, ptr %75, i64 %77
  store i32 %74, ptr %78, align 4, !tbaa !9
  %79 = load ptr, ptr %10, align 8, !tbaa !5
  %80 = load i32, ptr %11, align 4, !tbaa !9
  %81 = sext i32 %80 to i64
  %82 = getelementptr inbounds i32, ptr %79, i64 %81
  %83 = load i32, ptr %82, align 4, !tbaa !9
  %84 = load i32, ptr %8, align 4, !tbaa !9
  %85 = add nsw i32 %84, %83
  store i32 %85, ptr %8, align 4, !tbaa !9
  %86 = load ptr, ptr %10, align 8, !tbaa !5
  %87 = load i32, ptr %11, align 4, !tbaa !9
  %88 = sext i32 %87 to i64
  %89 = getelementptr inbounds i32, ptr %86, i64 %88
  %90 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %9, ptr noundef nonnull align 4 dereferenceable(4) %89)
  %91 = load i32, ptr %90, align 4, !tbaa !9
  store i32 %91, ptr %9, align 4, !tbaa !9
  br label %92

92:                                               ; preds = %66
  %93 = load i32, ptr %11, align 4, !tbaa !9
  %94 = add nsw i32 %93, 1
  store i32 %94, ptr %11, align 4, !tbaa !9
  br label %61, !llvm.loop !32

95:                                               ; preds = %65
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #10
  store i32 0, ptr %12, align 4, !tbaa !9
  %96 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %12)
  %97 = load i32, ptr %96, align 4, !tbaa !9
  store i32 %97, ptr %5, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #10
  %98 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %5, ptr noundef nonnull align 4 dereferenceable(4) %8)
  %99 = load i32, ptr %98, align 4, !tbaa !9
  store i32 %99, ptr %5, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #10
  store i32 0, ptr %13, align 4, !tbaa !9
  br label %100

100:                                              ; preds = %116, %95
  %101 = load i32, ptr %13, align 4, !tbaa !9
  %102 = load i32, ptr %7, align 4, !tbaa !9
  %103 = icmp slt i32 %101, %102
  br i1 %103, label %105, label %104

104:                                              ; preds = %100
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #10
  br label %119

105:                                              ; preds = %100
  %106 = load ptr, ptr %10, align 8, !tbaa !5
  %107 = load i32, ptr %13, align 4, !tbaa !9
  %108 = sext i32 %107 to i64
  %109 = getelementptr inbounds i32, ptr %106, i64 %108
  %110 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %109, ptr noundef nonnull align 4 dereferenceable(4) %5)
  %111 = load i32, ptr %110, align 4, !tbaa !9
  %112 = load ptr, ptr %10, align 8, !tbaa !5
  %113 = load i32, ptr %13, align 4, !tbaa !9
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds i32, ptr %112, i64 %114
  store i32 %111, ptr %115, align 4, !tbaa !9
  br label %116

116:                                              ; preds = %105
  %117 = load i32, ptr %13, align 4, !tbaa !9
  %118 = add nsw i32 %117, 1
  store i32 %118, ptr %13, align 4, !tbaa !9
  br label %100, !llvm.loop !34

119:                                              ; preds = %104
  %120 = load i8, ptr %6, align 1, !tbaa !11, !range !35, !noundef !36
  %121 = trunc i8 %120 to i1
  br i1 %121, label %122, label %154

122:                                              ; preds = %119
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #10
  store i32 0, ptr %14, align 4, !tbaa !9
  br label %123

123:                                              ; preds = %150, %122
  %124 = load i32, ptr %14, align 4, !tbaa !9
  %125 = load i32, ptr %7, align 4, !tbaa !9
  %126 = icmp slt i32 %124, %125
  br i1 %126, label %128, label %127

127:                                              ; preds = %123
  store i32 8, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #10
  br label %153

128:                                              ; preds = %123
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #10
  store i32 0, ptr %16, align 4, !tbaa !9
  br label %129

129:                                              ; preds = %146, %128
  %130 = load i32, ptr %16, align 4, !tbaa !9
  %131 = load ptr, ptr %10, align 8, !tbaa !5
  %132 = load i32, ptr %14, align 4, !tbaa !9
  %133 = sext i32 %132 to i64
  %134 = getelementptr inbounds i32, ptr %131, i64 %133
  %135 = load i32, ptr %134, align 4, !tbaa !9
  %136 = icmp sle i32 %130, %135
  br i1 %136, label %138, label %137

137:                                              ; preds = %129
  store i32 11, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #10
  br label %149

138:                                              ; preds = %129
  %139 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 0
  %140 = load ptr, ptr %139, align 8, !tbaa !13
  %141 = getelementptr inbounds %struct.NestedLogitModel, ptr %140, i32 0, i32 1
  %142 = load i32, ptr %14, align 4, !tbaa !9
  %143 = sext i32 %142 to i64
  %144 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %141, i64 noundef %143) #10
  %145 = load i32, ptr %16, align 4, !tbaa !9
  call void @_ZN5TNest23GeneratePiecewiseLinearEi(ptr noundef nonnull align 8 dereferenceable(84) %144, i32 noundef %145)
  br label %146

146:                                              ; preds = %138
  %147 = load i32, ptr %16, align 4, !tbaa !9
  %148 = add nsw i32 %147, 1
  store i32 %148, ptr %16, align 4, !tbaa !9
  br label %129, !llvm.loop !37

149:                                              ; preds = %137
  br label %150

150:                                              ; preds = %149
  %151 = load i32, ptr %14, align 4, !tbaa !9
  %152 = add nsw i32 %151, 1
  store i32 %152, ptr %14, align 4, !tbaa !9
  br label %123, !llvm.loop !38

153:                                              ; preds = %127
  br label %154

154:                                              ; preds = %153, %119
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #10
  store i32 0, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #10
  store i32 0, ptr %18, align 4, !tbaa !9
  br label %155

155:                                              ; preds = %189, %154
  %156 = load i32, ptr %18, align 4, !tbaa !9
  %157 = load i32, ptr %7, align 4, !tbaa !9
  %158 = icmp slt i32 %156, %157
  br i1 %158, label %160, label %159

159:                                              ; preds = %155
  store i32 14, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #10
  br label %192

160:                                              ; preds = %155
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #10
  store i32 0, ptr %19, align 4, !tbaa !9
  br label %161

161:                                              ; preds = %185, %160
  %162 = load i32, ptr %19, align 4, !tbaa !9
  %163 = load ptr, ptr %10, align 8, !tbaa !5
  %164 = load i32, ptr %18, align 4, !tbaa !9
  %165 = sext i32 %164 to i64
  %166 = getelementptr inbounds i32, ptr %163, i64 %165
  %167 = load i32, ptr %166, align 4, !tbaa !9
  %168 = icmp sle i32 %162, %167
  br i1 %168, label %170, label %169

169:                                              ; preds = %161
  store i32 17, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #10
  br label %188

170:                                              ; preds = %161
  %171 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 0
  %172 = load ptr, ptr %171, align 8, !tbaa !13
  %173 = getelementptr inbounds %struct.NestedLogitModel, ptr %172, i32 0, i32 1
  %174 = load i32, ptr %18, align 4, !tbaa !9
  %175 = sext i32 %174 to i64
  %176 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %173, i64 noundef %175) #10
  %177 = getelementptr inbounds %struct.TNest, ptr %176, i32 0, i32 9
  %178 = load ptr, ptr %177, align 8, !tbaa !39
  %179 = load i32, ptr %19, align 4, !tbaa !9
  %180 = sext i32 %179 to i64
  %181 = getelementptr inbounds i32, ptr %178, i64 %180
  %182 = load i32, ptr %181, align 4, !tbaa !9
  %183 = load i32, ptr %17, align 4, !tbaa !9
  %184 = add nsw i32 %183, %182
  store i32 %184, ptr %17, align 4, !tbaa !9
  br label %185

185:                                              ; preds = %170
  %186 = load i32, ptr %19, align 4, !tbaa !9
  %187 = add nsw i32 %186, 1
  store i32 %187, ptr %19, align 4, !tbaa !9
  br label %161, !llvm.loop !40

188:                                              ; preds = %169
  br label %189

189:                                              ; preds = %188
  %190 = load i32, ptr %18, align 4, !tbaa !9
  %191 = add nsw i32 %190, 1
  store i32 %191, ptr %18, align 4, !tbaa !9
  br label %155, !llvm.loop !41

192:                                              ; preds = %159
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #10
  %193 = load i32, ptr %17, align 4, !tbaa !9
  %194 = add nsw i32 %193, 1
  %195 = sext i32 %194 to i64
  %196 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %195, i64 8)
  %197 = extractvalue { i64, i1 } %196, 1
  %198 = extractvalue { i64, i1 } %196, 0
  %199 = select i1 %197, i64 -1, i64 %198
  %200 = call noalias noundef nonnull ptr @_Znam(i64 noundef %199) #11
  store ptr %200, ptr %20, align 8, !tbaa !5
  store i32 0, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #10
  store i32 0, ptr %21, align 4, !tbaa !9
  br label %201

201:                                              ; preds = %260, %192
  %202 = load i32, ptr %21, align 4, !tbaa !9
  %203 = load i32, ptr %7, align 4, !tbaa !9
  %204 = icmp slt i32 %202, %203
  br i1 %204, label %206, label %205

205:                                              ; preds = %201
  store i32 20, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #10
  br label %263

206:                                              ; preds = %201
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #10
  %207 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 0
  %208 = load ptr, ptr %207, align 8, !tbaa !13
  %209 = getelementptr inbounds %struct.NestedLogitModel, ptr %208, i32 0, i32 1
  %210 = load i32, ptr %21, align 4, !tbaa !9
  %211 = sext i32 %210 to i64
  %212 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %209, i64 noundef %211) #10
  store ptr %212, ptr %22, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #10
  store i32 0, ptr %23, align 4, !tbaa !9
  br label %213

213:                                              ; preds = %256, %206
  %214 = load i32, ptr %23, align 4, !tbaa !9
  %215 = load ptr, ptr %10, align 8, !tbaa !5
  %216 = load i32, ptr %21, align 4, !tbaa !9
  %217 = sext i32 %216 to i64
  %218 = getelementptr inbounds i32, ptr %215, i64 %217
  %219 = load i32, ptr %218, align 4, !tbaa !9
  %220 = icmp sle i32 %214, %219
  br i1 %220, label %222, label %221

221:                                              ; preds = %213
  store i32 23, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #10
  br label %259

222:                                              ; preds = %213
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #10
  store i32 0, ptr %24, align 4, !tbaa !9
  br label %223

223:                                              ; preds = %252, %222
  %224 = load i32, ptr %24, align 4, !tbaa !9
  %225 = load ptr, ptr %22, align 8, !tbaa !5
  %226 = getelementptr inbounds %struct.TNest, ptr %225, i32 0, i32 9
  %227 = load ptr, ptr %226, align 8, !tbaa !39
  %228 = load i32, ptr %23, align 4, !tbaa !9
  %229 = sext i32 %228 to i64
  %230 = getelementptr inbounds i32, ptr %227, i64 %229
  %231 = load i32, ptr %230, align 4, !tbaa !9
  %232 = icmp slt i32 %224, %231
  br i1 %232, label %234, label %233

233:                                              ; preds = %223
  store i32 26, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #10
  br label %255

234:                                              ; preds = %223
  %235 = load ptr, ptr %22, align 8, !tbaa !5
  %236 = getelementptr inbounds %struct.TNest, ptr %235, i32 0, i32 8
  %237 = load ptr, ptr %236, align 8, !tbaa !42
  %238 = load i32, ptr %23, align 4, !tbaa !9
  %239 = sext i32 %238 to i64
  %240 = getelementptr inbounds ptr, ptr %237, i64 %239
  %241 = load ptr, ptr %240, align 8, !tbaa !5
  %242 = load i32, ptr %24, align 4, !tbaa !9
  %243 = sext i32 %242 to i64
  %244 = getelementptr inbounds %"struct.std::pair", ptr %241, i64 %243
  %245 = getelementptr inbounds %"struct.std::pair", ptr %244, i32 0, i32 1
  %246 = load double, ptr %245, align 8, !tbaa !43
  %247 = load ptr, ptr %20, align 8, !tbaa !5
  %248 = load i32, ptr %17, align 4, !tbaa !9
  %249 = add nsw i32 %248, 1
  store i32 %249, ptr %17, align 4, !tbaa !9
  %250 = sext i32 %248 to i64
  %251 = getelementptr inbounds double, ptr %247, i64 %250
  store double %246, ptr %251, align 8, !tbaa !45
  br label %252

252:                                              ; preds = %234
  %253 = load i32, ptr %24, align 4, !tbaa !9
  %254 = add nsw i32 %253, 1
  store i32 %254, ptr %24, align 4, !tbaa !9
  br label %223, !llvm.loop !46

255:                                              ; preds = %233
  br label %256

256:                                              ; preds = %255
  %257 = load i32, ptr %23, align 4, !tbaa !9
  %258 = add nsw i32 %257, 1
  store i32 %258, ptr %23, align 4, !tbaa !9
  br label %213, !llvm.loop !47

259:                                              ; preds = %221
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #10
  br label %260

260:                                              ; preds = %259
  %261 = load i32, ptr %21, align 4, !tbaa !9
  %262 = add nsw i32 %261, 1
  store i32 %262, ptr %21, align 4, !tbaa !9
  br label %201, !llvm.loop !48

263:                                              ; preds = %205
  %264 = load ptr, ptr %20, align 8, !tbaa !5
  %265 = load i32, ptr %17, align 4, !tbaa !9
  %266 = add nsw i32 %265, 1
  store i32 %266, ptr %17, align 4, !tbaa !9
  %267 = sext i32 %265 to i64
  %268 = getelementptr inbounds double, ptr %264, i64 %267
  store double 1.000000e+100, ptr %268, align 8, !tbaa !45
  %269 = load ptr, ptr %20, align 8, !tbaa !5
  %270 = load ptr, ptr %20, align 8, !tbaa !5
  %271 = load i32, ptr %17, align 4, !tbaa !9
  %272 = sext i32 %271 to i64
  %273 = getelementptr inbounds double, ptr %270, i64 %272
  call void @_ZSt4sortIPdEvT_S1_(ptr noundef %269, ptr noundef %273)
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #10
  store i32 0, ptr %25, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #10
  %274 = load i32, ptr %17, align 4, !tbaa !9
  %275 = sub nsw i32 %274, 2
  store i32 %275, ptr %26, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #10
  store i32 -1, ptr %27, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #10
  %276 = load i32, ptr %5, align 4, !tbaa !9
  %277 = add nsw i32 %276, 1
  %278 = mul nsw i32 2, %277
  %279 = load i32, ptr %9, align 4, !tbaa !9
  %280 = add nsw i32 %278, %279
  %281 = add nsw i32 %280, 1
  %282 = sext i32 %281 to i64
  %283 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %282, i64 8)
  %284 = extractvalue { i64, i1 } %283, 1
  %285 = extractvalue { i64, i1 } %283, 0
  %286 = select i1 %284, i64 -1, i64 %285
  %287 = call noalias noundef nonnull ptr @_Znam(i64 noundef %286) #11
  store ptr %287, ptr %28, align 8, !tbaa !5
  br label %288

288:                                              ; preds = %314, %263
  %289 = load i32, ptr %25, align 4, !tbaa !9
  %290 = load i32, ptr %26, align 4, !tbaa !9
  %291 = icmp sle i32 %289, %290
  br i1 %291, label %292, label %315

292:                                              ; preds = %288
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #10
  %293 = load i32, ptr %25, align 4, !tbaa !9
  %294 = load i32, ptr %26, align 4, !tbaa !9
  %295 = add nsw i32 %293, %294
  %296 = sdiv i32 %295, 2
  store i32 %296, ptr %29, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #10
  %297 = load ptr, ptr %20, align 8, !tbaa !5
  %298 = load i32, ptr %29, align 4, !tbaa !9
  %299 = sext i32 %298 to i64
  %300 = getelementptr inbounds double, ptr %297, i64 %299
  %301 = load double, ptr %300, align 8, !tbaa !45
  %302 = load i32, ptr %5, align 4, !tbaa !9
  %303 = load ptr, ptr %28, align 8, !tbaa !5
  %304 = call noundef double @_ZN17NestedLogitSolver13JointDPOracleEdiPd(ptr noundef nonnull align 8 dereferenceable(40) %49, double noundef %301, i32 noundef %302, ptr noundef %303)
  store double %304, ptr %30, align 8, !tbaa !45
  %305 = load double, ptr %30, align 8, !tbaa !45
  %306 = fcmp oge double %305, 0.000000e+00
  br i1 %306, label %307, label %311

307:                                              ; preds = %292
  %308 = load i32, ptr %29, align 4, !tbaa !9
  store i32 %308, ptr %27, align 4, !tbaa !9
  %309 = load i32, ptr %29, align 4, !tbaa !9
  %310 = add nsw i32 %309, 1
  store i32 %310, ptr %25, align 4, !tbaa !9
  br label %314

311:                                              ; preds = %292
  %312 = load i32, ptr %29, align 4, !tbaa !9
  %313 = sub nsw i32 %312, 1
  store i32 %313, ptr %26, align 4, !tbaa !9
  br label %314

314:                                              ; preds = %311, %307
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #10
  br label %288, !llvm.loop !49

315:                                              ; preds = %288
  %316 = load i32, ptr %27, align 4, !tbaa !9
  %317 = icmp ne i32 %316, -1
  br i1 %317, label %318, label %319

318:                                              ; preds = %315
  br label %321

319:                                              ; preds = %315
  call void @__assert_fail(ptr noundef @.str, ptr noundef @.str.1, i32 noundef 112, ptr noundef @__PRETTY_FUNCTION__._ZN17NestedLogitSolver10SolveJointEib) #12
  unreachable

320:                                              ; No predecessors!
  br label %321

321:                                              ; preds = %320, %318
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #10
  %322 = load ptr, ptr %20, align 8, !tbaa !5
  %323 = load i32, ptr %27, align 4, !tbaa !9
  %324 = sext i32 %323 to i64
  %325 = getelementptr inbounds double, ptr %322, i64 %324
  %326 = load double, ptr %325, align 8, !tbaa !45
  %327 = load ptr, ptr %20, align 8, !tbaa !5
  %328 = load i32, ptr %27, align 4, !tbaa !9
  %329 = add nsw i32 %328, 1
  %330 = sext i32 %329 to i64
  %331 = getelementptr inbounds double, ptr %327, i64 %330
  %332 = load double, ptr %331, align 8, !tbaa !45
  %333 = fadd double %326, %332
  %334 = fmul double %333, 5.000000e-01
  store double %334, ptr %31, align 8, !tbaa !45
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #10
  %335 = load i32, ptr %7, align 4, !tbaa !9
  %336 = sext i32 %335 to i64
  %337 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %336, i64 8)
  %338 = extractvalue { i64, i1 } %337, 1
  %339 = extractvalue { i64, i1 } %337, 0
  %340 = select i1 %338, i64 -1, i64 %339
  %341 = call noalias noundef nonnull ptr @_Znam(i64 noundef %340) #11
  store ptr %341, ptr %32, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #10
  %342 = load i32, ptr %7, align 4, !tbaa !9
  %343 = sext i32 %342 to i64
  %344 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %343, i64 8)
  %345 = extractvalue { i64, i1 } %344, 1
  %346 = extractvalue { i64, i1 } %344, 0
  %347 = select i1 %345, i64 -1, i64 %346
  %348 = call noalias noundef nonnull ptr @_Znam(i64 noundef %347) #11
  store ptr %348, ptr %33, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %34) #10
  store i32 0, ptr %34, align 4, !tbaa !9
  br label %349

349:                                              ; preds = %493, %321
  %350 = load i32, ptr %34, align 4, !tbaa !9
  %351 = load i32, ptr %7, align 4, !tbaa !9
  %352 = icmp slt i32 %350, %351
  br i1 %352, label %354, label %353

353:                                              ; preds = %349
  store i32 31, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #10
  br label %496

354:                                              ; preds = %349
  %355 = load ptr, ptr %10, align 8, !tbaa !5
  %356 = load i32, ptr %34, align 4, !tbaa !9
  %357 = sext i32 %356 to i64
  %358 = getelementptr inbounds i32, ptr %355, i64 %357
  %359 = load i32, ptr %358, align 4, !tbaa !9
  %360 = add nsw i32 %359, 1
  %361 = sext i32 %360 to i64
  %362 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %361, i64 8)
  %363 = extractvalue { i64, i1 } %362, 1
  %364 = extractvalue { i64, i1 } %362, 0
  %365 = select i1 %363, i64 -1, i64 %364
  %366 = call noalias noundef nonnull ptr @_Znam(i64 noundef %365) #11
  %367 = load ptr, ptr %32, align 8, !tbaa !5
  %368 = load i32, ptr %34, align 4, !tbaa !9
  %369 = sext i32 %368 to i64
  %370 = getelementptr inbounds ptr, ptr %367, i64 %369
  store ptr %366, ptr %370, align 8, !tbaa !5
  %371 = load ptr, ptr %10, align 8, !tbaa !5
  %372 = load i32, ptr %34, align 4, !tbaa !9
  %373 = sext i32 %372 to i64
  %374 = getelementptr inbounds i32, ptr %371, i64 %373
  %375 = load i32, ptr %374, align 4, !tbaa !9
  %376 = add nsw i32 %375, 1
  %377 = sext i32 %376 to i64
  %378 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %377, i64 8)
  %379 = extractvalue { i64, i1 } %378, 1
  %380 = extractvalue { i64, i1 } %378, 0
  %381 = select i1 %379, i64 -1, i64 %380
  %382 = call noalias noundef nonnull ptr @_Znam(i64 noundef %381) #11
  %383 = load ptr, ptr %33, align 8, !tbaa !5
  %384 = load i32, ptr %34, align 4, !tbaa !9
  %385 = sext i32 %384 to i64
  %386 = getelementptr inbounds ptr, ptr %383, i64 %385
  store ptr %382, ptr %386, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #10
  %387 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 0
  %388 = load ptr, ptr %387, align 8, !tbaa !13
  %389 = getelementptr inbounds %struct.NestedLogitModel, ptr %388, i32 0, i32 1
  %390 = load i32, ptr %34, align 4, !tbaa !9
  %391 = sext i32 %390 to i64
  %392 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %389, i64 noundef %391) #10
  store ptr %392, ptr %35, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %36) #10
  store i32 0, ptr %36, align 4, !tbaa !9
  br label %393

393:                                              ; preds = %489, %354
  %394 = load i32, ptr %36, align 4, !tbaa !9
  %395 = load ptr, ptr %10, align 8, !tbaa !5
  %396 = load i32, ptr %34, align 4, !tbaa !9
  %397 = sext i32 %396 to i64
  %398 = getelementptr inbounds i32, ptr %395, i64 %397
  %399 = load i32, ptr %398, align 4, !tbaa !9
  %400 = icmp sle i32 %394, %399
  br i1 %400, label %402, label %401

401:                                              ; preds = %393
  store i32 34, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %36) #10
  br label %492

402:                                              ; preds = %393
  call void @llvm.lifetime.start.p0(i64 8, ptr %37) #10
  %403 = load ptr, ptr %35, align 8, !tbaa !5
  %404 = getelementptr inbounds %struct.TNest, ptr %403, i32 0, i32 4
  %405 = load ptr, ptr %404, align 8, !tbaa !50
  %406 = load i32, ptr %36, align 4, !tbaa !9
  %407 = sext i32 %406 to i64
  %408 = getelementptr inbounds ptr, ptr %405, i64 %407
  %409 = load ptr, ptr %408, align 8, !tbaa !5
  store ptr %409, ptr %37, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %38) #10
  store double -1.000000e+100, ptr %38, align 8, !tbaa !45
  call void @llvm.lifetime.start.p0(i64 4, ptr %39) #10
  store i32 -1, ptr %39, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %40) #10
  store i32 0, ptr %40, align 4, !tbaa !9
  br label %410

410:                                              ; preds = %457, %402
  %411 = load i32, ptr %40, align 4, !tbaa !9
  %412 = load ptr, ptr %35, align 8, !tbaa !5
  %413 = getelementptr inbounds %struct.TNest, ptr %412, i32 0, i32 5
  %414 = load ptr, ptr %413, align 8, !tbaa !51
  %415 = load i32, ptr %36, align 4, !tbaa !9
  %416 = sext i32 %415 to i64
  %417 = getelementptr inbounds i32, ptr %414, i64 %416
  %418 = load i32, ptr %417, align 4, !tbaa !9
  %419 = icmp slt i32 %411, %418
  br i1 %419, label %421, label %420

420:                                              ; preds = %410
  store i32 37, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %40) #10
  br label %460

421:                                              ; preds = %410
  %422 = load ptr, ptr %37, align 8, !tbaa !5
  %423 = load i32, ptr %40, align 4, !tbaa !9
  %424 = sext i32 %423 to i64
  %425 = getelementptr inbounds %struct.TCandidate, ptr %422, i64 %424
  %426 = getelementptr inbounds %struct.TCandidate, ptr %425, i32 0, i32 2
  %427 = load double, ptr %426, align 8, !tbaa !52
  %428 = load ptr, ptr %37, align 8, !tbaa !5
  %429 = load i32, ptr %40, align 4, !tbaa !9
  %430 = sext i32 %429 to i64
  %431 = getelementptr inbounds %struct.TCandidate, ptr %428, i64 %430
  %432 = getelementptr inbounds %struct.TCandidate, ptr %431, i32 0, i32 3
  %433 = load double, ptr %432, align 8, !tbaa !54
  %434 = load double, ptr %31, align 8, !tbaa !45
  %435 = fneg double %433
  %436 = call double @llvm.fmuladd.f64(double %435, double %434, double %427)
  %437 = load double, ptr %38, align 8, !tbaa !45
  %438 = fcmp ogt double %436, %437
  br i1 %438, label %439, label %456

439:                                              ; preds = %421
  %440 = load ptr, ptr %37, align 8, !tbaa !5
  %441 = load i32, ptr %40, align 4, !tbaa !9
  %442 = sext i32 %441 to i64
  %443 = getelementptr inbounds %struct.TCandidate, ptr %440, i64 %442
  %444 = getelementptr inbounds %struct.TCandidate, ptr %443, i32 0, i32 2
  %445 = load double, ptr %444, align 8, !tbaa !52
  %446 = load ptr, ptr %37, align 8, !tbaa !5
  %447 = load i32, ptr %40, align 4, !tbaa !9
  %448 = sext i32 %447 to i64
  %449 = getelementptr inbounds %struct.TCandidate, ptr %446, i64 %448
  %450 = getelementptr inbounds %struct.TCandidate, ptr %449, i32 0, i32 3
  %451 = load double, ptr %450, align 8, !tbaa !54
  %452 = load double, ptr %31, align 8, !tbaa !45
  %453 = fneg double %451
  %454 = call double @llvm.fmuladd.f64(double %453, double %452, double %445)
  store double %454, ptr %38, align 8, !tbaa !45
  %455 = load i32, ptr %40, align 4, !tbaa !9
  store i32 %455, ptr %39, align 4, !tbaa !9
  br label %456

456:                                              ; preds = %439, %421
  br label %457

457:                                              ; preds = %456
  %458 = load i32, ptr %40, align 4, !tbaa !9
  %459 = add nsw i32 %458, 1
  store i32 %459, ptr %40, align 4, !tbaa !9
  br label %410, !llvm.loop !55

460:                                              ; preds = %420
  %461 = load ptr, ptr %37, align 8, !tbaa !5
  %462 = load i32, ptr %39, align 4, !tbaa !9
  %463 = sext i32 %462 to i64
  %464 = getelementptr inbounds %struct.TCandidate, ptr %461, i64 %463
  %465 = getelementptr inbounds %struct.TCandidate, ptr %464, i32 0, i32 2
  %466 = load double, ptr %465, align 8, !tbaa !52
  %467 = load ptr, ptr %32, align 8, !tbaa !5
  %468 = load i32, ptr %34, align 4, !tbaa !9
  %469 = sext i32 %468 to i64
  %470 = getelementptr inbounds ptr, ptr %467, i64 %469
  %471 = load ptr, ptr %470, align 8, !tbaa !5
  %472 = load i32, ptr %36, align 4, !tbaa !9
  %473 = sext i32 %472 to i64
  %474 = getelementptr inbounds double, ptr %471, i64 %473
  store double %466, ptr %474, align 8, !tbaa !45
  %475 = load ptr, ptr %37, align 8, !tbaa !5
  %476 = load i32, ptr %39, align 4, !tbaa !9
  %477 = sext i32 %476 to i64
  %478 = getelementptr inbounds %struct.TCandidate, ptr %475, i64 %477
  %479 = getelementptr inbounds %struct.TCandidate, ptr %478, i32 0, i32 3
  %480 = load double, ptr %479, align 8, !tbaa !54
  %481 = load ptr, ptr %33, align 8, !tbaa !5
  %482 = load i32, ptr %34, align 4, !tbaa !9
  %483 = sext i32 %482 to i64
  %484 = getelementptr inbounds ptr, ptr %481, i64 %483
  %485 = load ptr, ptr %484, align 8, !tbaa !5
  %486 = load i32, ptr %36, align 4, !tbaa !9
  %487 = sext i32 %486 to i64
  %488 = getelementptr inbounds double, ptr %485, i64 %487
  store double %480, ptr %488, align 8, !tbaa !45
  call void @llvm.lifetime.end.p0(i64 4, ptr %39) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #10
  br label %489

489:                                              ; preds = %460
  %490 = load i32, ptr %36, align 4, !tbaa !9
  %491 = add nsw i32 %490, 1
  store i32 %491, ptr %36, align 4, !tbaa !9
  br label %393, !llvm.loop !56

492:                                              ; preds = %401
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #10
  br label %493

493:                                              ; preds = %492
  %494 = load i32, ptr %34, align 4, !tbaa !9
  %495 = add nsw i32 %494, 1
  store i32 %495, ptr %34, align 4, !tbaa !9
  br label %349, !llvm.loop !57

496:                                              ; preds = %353
  call void @llvm.lifetime.start.p0(i64 8, ptr %41) #10
  store double -1.000000e+00, ptr %41, align 8, !tbaa !45
  call void @llvm.lifetime.start.p0(i64 8, ptr %42) #10
  %497 = load i32, ptr %7, align 4, !tbaa !9
  %498 = sext i32 %497 to i64
  %499 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %498, i64 4)
  %500 = extractvalue { i64, i1 } %499, 1
  %501 = extractvalue { i64, i1 } %499, 0
  %502 = select i1 %500, i64 -1, i64 %501
  %503 = call noalias noundef nonnull ptr @_Znam(i64 noundef %502) #11
  store ptr %503, ptr %42, align 8, !tbaa !5
  %504 = load i32, ptr %7, align 4, !tbaa !9
  %505 = load ptr, ptr %10, align 8, !tbaa !5
  %506 = load i32, ptr %5, align 4, !tbaa !9
  %507 = load ptr, ptr %32, align 8, !tbaa !5
  %508 = load ptr, ptr %33, align 8, !tbaa !5
  %509 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 0
  %510 = load ptr, ptr %509, align 8, !tbaa !13
  %511 = getelementptr inbounds %struct.NestedLogitModel, ptr %510, i32 0, i32 2
  %512 = load double, ptr %511, align 8, !tbaa !58
  %513 = load ptr, ptr %42, align 8, !tbaa !5
  call void @_Z16MaximizeFractioniPiiPPdS1_ddRdS_(i32 noundef %504, ptr noundef %505, i32 noundef %506, ptr noundef %507, ptr noundef %508, double noundef 0.000000e+00, double noundef %512, ptr noundef nonnull align 8 dereferenceable(8) %41, ptr noundef %513)
  %514 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 1
  call void @_ZNSt6vectorIiSaIiEE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %514) #10
  %515 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 1
  %516 = load i32, ptr %7, align 4, !tbaa !9
  %517 = sext i32 %516 to i64
  call void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %515, i64 noundef %517)
  call void @llvm.lifetime.start.p0(i64 4, ptr %43) #10
  store i32 0, ptr %43, align 4, !tbaa !9
  br label %518

518:                                              ; preds = %533, %496
  %519 = load i32, ptr %43, align 4, !tbaa !9
  %520 = load i32, ptr %7, align 4, !tbaa !9
  %521 = icmp slt i32 %519, %520
  br i1 %521, label %523, label %522

522:                                              ; preds = %518
  store i32 40, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %43) #10
  br label %536

523:                                              ; preds = %518
  %524 = load ptr, ptr %42, align 8, !tbaa !5
  %525 = load i32, ptr %43, align 4, !tbaa !9
  %526 = sext i32 %525 to i64
  %527 = getelementptr inbounds i32, ptr %524, i64 %526
  %528 = load i32, ptr %527, align 4, !tbaa !9
  %529 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 1
  %530 = load i32, ptr %43, align 4, !tbaa !9
  %531 = sext i32 %530 to i64
  %532 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %529, i64 noundef %531) #10
  store i32 %528, ptr %532, align 4, !tbaa !9
  br label %533

533:                                              ; preds = %523
  %534 = load i32, ptr %43, align 4, !tbaa !9
  %535 = add nsw i32 %534, 1
  store i32 %535, ptr %43, align 4, !tbaa !9
  br label %518, !llvm.loop !59

536:                                              ; preds = %522
  %537 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 2
  store double -1.000000e+00, ptr %537, align 8, !tbaa !60
  %538 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 1
  call void @_ZNSt6vectorIiSaIiEEC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %44, ptr noundef nonnull align 8 dereferenceable(24) %538)
  %539 = invoke noundef double @_ZN17NestedLogitSolver13SolveDisjointESt6vectorIiSaIiEEb(ptr noundef nonnull align 8 dereferenceable(40) %49, ptr noundef %44, i1 noundef zeroext false)
          to label %540 unwind label %549

540:                                              ; preds = %536
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %44) #10
  %541 = load double, ptr %41, align 8, !tbaa !45
  %542 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 2
  %543 = load double, ptr %542, align 8, !tbaa !60
  %544 = fsub double %541, %543
  %545 = call double @llvm.fabs.f64(double %544)
  %546 = fcmp olt double %545, 1.000000e-08
  br i1 %546, label %547, label %548

547:                                              ; preds = %540
  br label %554

548:                                              ; preds = %540
  call void @__assert_fail(ptr noundef @.str.2, ptr noundef @.str.1, i32 noundef 150, ptr noundef @__PRETTY_FUNCTION__._ZN17NestedLogitSolver10SolveJointEib) #12
  unreachable

549:                                              ; preds = %536
  %550 = landingpad { ptr, i32 }
          cleanup
  %551 = extractvalue { ptr, i32 } %550, 0
  store ptr %551, ptr %45, align 8
  %552 = extractvalue { ptr, i32 } %550, 1
  store i32 %552, ptr %46, align 4
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %44) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #10
  br label %607

553:                                              ; No predecessors!
  br label %554

554:                                              ; preds = %553, %547
  %555 = load ptr, ptr %28, align 8, !tbaa !5
  %556 = icmp eq ptr %555, null
  br i1 %556, label %558, label %557

557:                                              ; preds = %554
  call void @_ZdlPvm(ptr noundef %555, i64 noundef 8) #13
  br label %558

558:                                              ; preds = %557, %554
  %559 = load ptr, ptr %20, align 8, !tbaa !5
  %560 = icmp eq ptr %559, null
  br i1 %560, label %562, label %561

561:                                              ; preds = %558
  call void @_ZdlPvm(ptr noundef %559, i64 noundef 8) #13
  br label %562

562:                                              ; preds = %561, %558
  call void @llvm.lifetime.start.p0(i64 4, ptr %47) #10
  store i32 0, ptr %47, align 4, !tbaa !9
  br label %563

563:                                              ; preds = %585, %562
  %564 = load i32, ptr %47, align 4, !tbaa !9
  %565 = load i32, ptr %7, align 4, !tbaa !9
  %566 = icmp slt i32 %564, %565
  br i1 %566, label %568, label %567

567:                                              ; preds = %563
  store i32 43, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %47) #10
  br label %588

568:                                              ; preds = %563
  %569 = load ptr, ptr %32, align 8, !tbaa !5
  %570 = load i32, ptr %47, align 4, !tbaa !9
  %571 = sext i32 %570 to i64
  %572 = getelementptr inbounds ptr, ptr %569, i64 %571
  %573 = load ptr, ptr %572, align 8, !tbaa !5
  %574 = icmp eq ptr %573, null
  br i1 %574, label %576, label %575

575:                                              ; preds = %568
  call void @_ZdlPvm(ptr noundef %573, i64 noundef 8) #13
  br label %576

576:                                              ; preds = %575, %568
  %577 = load ptr, ptr %33, align 8, !tbaa !5
  %578 = load i32, ptr %47, align 4, !tbaa !9
  %579 = sext i32 %578 to i64
  %580 = getelementptr inbounds ptr, ptr %577, i64 %579
  %581 = load ptr, ptr %580, align 8, !tbaa !5
  %582 = icmp eq ptr %581, null
  br i1 %582, label %584, label %583

583:                                              ; preds = %576
  call void @_ZdlPvm(ptr noundef %581, i64 noundef 8) #13
  br label %584

584:                                              ; preds = %583, %576
  br label %585

585:                                              ; preds = %584
  %586 = load i32, ptr %47, align 4, !tbaa !9
  %587 = add nsw i32 %586, 1
  store i32 %587, ptr %47, align 4, !tbaa !9
  br label %563, !llvm.loop !61

588:                                              ; preds = %567
  %589 = load ptr, ptr %32, align 8, !tbaa !5
  %590 = icmp eq ptr %589, null
  br i1 %590, label %592, label %591

591:                                              ; preds = %588
  call void @_ZdlPvm(ptr noundef %589, i64 noundef 8) #13
  br label %592

592:                                              ; preds = %591, %588
  %593 = load ptr, ptr %33, align 8, !tbaa !5
  %594 = icmp eq ptr %593, null
  br i1 %594, label %596, label %595

595:                                              ; preds = %592
  call void @_ZdlPvm(ptr noundef %593, i64 noundef 8) #13
  br label %596

596:                                              ; preds = %595, %592
  %597 = load ptr, ptr %42, align 8, !tbaa !5
  %598 = icmp eq ptr %597, null
  br i1 %598, label %600, label %599

599:                                              ; preds = %596
  call void @_ZdlPvm(ptr noundef %597, i64 noundef 4) #13
  br label %600

600:                                              ; preds = %599, %596
  %601 = load ptr, ptr %10, align 8, !tbaa !5
  %602 = icmp eq ptr %601, null
  br i1 %602, label %604, label %603

603:                                              ; preds = %600
  call void @_ZdlPvm(ptr noundef %601, i64 noundef 4) #13
  br label %604

604:                                              ; preds = %603, %600
  %605 = getelementptr inbounds %struct.NestedLogitSolver, ptr %49, i32 0, i32 2
  %606 = load double, ptr %605, align 8, !tbaa !60
  store i32 1, ptr %15, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #10
  ret double %606

607:                                              ; preds = %549
  %608 = load ptr, ptr %45, align 8
  %609 = load i32, ptr %46, align 4
  %610 = insertvalue { ptr, i32 } poison, ptr %608, 0
  %611 = insertvalue { ptr, i32 } %610, i32 %609, 1
  resume { ptr, i32 } %611
}

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

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

; 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)) #5

; 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)) #5

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

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

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

declare void @_Z16MaximizeFractioniPiiPPdS1_ddRdS_(i32 noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef, double noundef, double noundef, ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #6

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #3 align 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) #0 align 2

declare noundef double @_ZN17NestedLogitSolver13SolveDisjointESt6vectorIiSaIiEEb(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef, i1 noundef zeroext) #6

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEEC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(24), 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 @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

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

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

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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { 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 #4 = { 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 #5 = { 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 #6 = { "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 = { 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 #8 = { 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 #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 = { noreturn nounwind }
attributes #13 = { 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 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"bool", !7, i64 0}
!13 = !{!14, !6, i64 0}
!14 = !{!"_ZTS17NestedLogitSolver", !6, i64 0, !15, i64 8, !19, i64 32}
!15 = !{!"_ZTSSt6vectorIiSaIiEE", !16, i64 0}
!16 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !17, i64 0}
!17 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !18, i64 0}
!18 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!19 = !{!"double", !7, i64 0}
!20 = !{!21, !10, i64 0}
!21 = !{!"_ZTS16NestedLogitModel", !10, i64 0, !22, i64 8, !19, i64 32}
!22 = !{!"_ZTSSt6vectorI5TNestSaIS0_EE", !23, i64 0}
!23 = !{!"_ZTSSt12_Vector_baseI5TNestSaIS0_EE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseI5TNestSaIS0_EE12_Vector_implE", !25, i64 0}
!25 = !{!"_ZTSNSt12_Vector_baseI5TNestSaIS0_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!26 = !{!27, !10, i64 0}
!27 = !{!"_ZTS5TNest", !10, i64 0, !19, i64 8, !28, i64 16, !6, i64 40, !6, i64 48, !10, i64 56, !6, i64 64, !6, i64 72, !10, 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", !6, i64 0, !6, i64 8, !6, i64 16}
!32 = distinct !{!32, !33}
!33 = !{!"llvm.loop.mustprogress"}
!34 = distinct !{!34, !33}
!35 = !{i8 0, i8 2}
!36 = !{}
!37 = distinct !{!37, !33}
!38 = distinct !{!38, !33}
!39 = !{!27, !6, i64 72}
!40 = distinct !{!40, !33}
!41 = distinct !{!41, !33}
!42 = !{!27, !6, i64 64}
!43 = !{!44, !19, i64 8}
!44 = !{!"_ZTSSt4pairIidE", !10, i64 0, !19, i64 8}
!45 = !{!19, !19, i64 0}
!46 = distinct !{!46, !33}
!47 = distinct !{!47, !33}
!48 = distinct !{!48, !33}
!49 = distinct !{!49, !33}
!50 = !{!27, !6, i64 40}
!51 = !{!27, !6, i64 48}
!52 = !{!53, !19, i64 16}
!53 = !{!"_ZTS10TCandidate", !19, i64 0, !19, i64 8, !19, i64 16, !19, i64 24}
!54 = !{!53, !19, i64 24}
!55 = distinct !{!55, !33}
!56 = distinct !{!56, !33}
!57 = distinct !{!57, !33}
!58 = !{!21, !19, i64 32}
!59 = distinct !{!59, !33}
!60 = !{!14, !19, i64 32}
!61 = distinct !{!61, !33}


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

%"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.std::pair" = type { i32, double }
%struct.TCandidate = type { double, double, double, double }

@.str = external hidden unnamed_addr constant [10 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [73 x i8], align 1
@__PRETTY_FUNCTION__._ZN17NestedLogitSolver10SolveJointEib = external hidden unnamed_addr constant [48 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [62 x i8], align 1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_ZN17NestedLogitSolver13JointDPOracleEdiPd(ptr noundef nonnull align 8 dereferenceable(40), double noundef, i32 noundef, ptr noundef) local_unnamed_addr #0 align 2

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

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

; 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 #0 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef double @_ZN17NestedLogitSolver10SolveJointEib(ptr noundef nonnull align 8 dereferenceable(40) %0, i32 noundef %1, i1 noundef zeroext %2) local_unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca double, align 8
  %9 = alloca %"class.std::vector", align 8
  store i32 %1, ptr %4, align 4, !tbaa !5
  %10 = load ptr, ptr %0, align 8, !tbaa !9
  %11 = load i32, ptr %10, align 8, !tbaa !17
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #10
  store i32 0, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #10
  store i32 0, ptr %6, align 4, !tbaa !5
  %12 = sext i32 %11 to i64
  %13 = icmp slt i32 %11, 0
  %14 = shl nsw i64 %12, 2
  %15 = select i1 %13, i64 -1, i64 %14
  %16 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %15) #11
  %17 = icmp sgt i32 %11, 0
  br i1 %17, label %.lr.ph.preheader, label %.thread.critedge

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

._crit_edge:                                      ; preds = %.lr.ph
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #10
  store i32 0, ptr %7, align 4, !tbaa !5
  %18 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %7)
  %19 = load i32, ptr %18, align 4, !tbaa !5
  store i32 %19, ptr %4, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #10
  %20 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5)
  %21 = load i32, ptr %20, align 4, !tbaa !5
  store i32 %21, ptr %4, align 4, !tbaa !5
  br i1 %17, label %.lr.ph191.preheader, label %.thread

.lr.ph191.preheader:                              ; preds = %._crit_edge
  %wide.trip.count260 = zext nneg i32 %11 to i64
  br label %.lr.ph191

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %22 = load ptr, ptr %0, align 8, !tbaa !9
  %23 = getelementptr inbounds i8, ptr %22, i64 8
  %24 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %indvars.iv) #10
  %25 = load i32, ptr %24, align 8, !tbaa !23
  %26 = getelementptr inbounds i32, ptr %16, i64 %indvars.iv
  store i32 %25, ptr %26, align 4, !tbaa !5
  %27 = load i32, ptr %5, align 4, !tbaa !5
  %28 = add nsw i32 %27, %25
  store i32 %28, ptr %5, align 4, !tbaa !5
  %29 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %6, ptr noundef nonnull align 4 dereferenceable(4) %26)
  %30 = load i32, ptr %29, align 4, !tbaa !5
  store i32 %30, ptr %6, align 4, !tbaa !5
  %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 !29

._crit_edge192:                                   ; preds = %.lr.ph191
  %or.cond = and i1 %17, %2
  br i1 %or.cond, label %.preheader186.preheader, label %.loopexit

.preheader186.preheader:                          ; preds = %._crit_edge192
  %wide.trip.count265 = zext nneg i32 %11 to i64
  br label %.preheader186

.lr.ph191:                                        ; preds = %.lr.ph191.preheader, %.lr.ph191
  %indvars.iv257 = phi i64 [ 0, %.lr.ph191.preheader ], [ %indvars.iv.next258, %.lr.ph191 ]
  %31 = getelementptr inbounds i32, ptr %16, i64 %indvars.iv257
  %32 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %31, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %33 = load i32, ptr %32, align 4, !tbaa !5
  store i32 %33, ptr %31, align 4, !tbaa !5
  %indvars.iv.next258 = add nuw nsw i64 %indvars.iv257, 1
  %exitcond261.not = icmp eq i64 %indvars.iv.next258, %wide.trip.count260
  br i1 %exitcond261.not, label %._crit_edge192, label %.lr.ph191, !llvm.loop !31

.preheader186:                                    ; preds = %.preheader186.preheader, %._crit_edge196
  %indvars.iv262 = phi i64 [ 0, %.preheader186.preheader ], [ %indvars.iv.next263, %._crit_edge196 ]
  %34 = getelementptr inbounds i32, ptr %16, i64 %indvars.iv262
  %35 = load i32, ptr %34, align 4, !tbaa !5
  %.not184193 = icmp slt i32 %35, 0
  br i1 %.not184193, label %._crit_edge196, label %.lr.ph195

._crit_edge196:                                   ; preds = %.lr.ph195, %.preheader186
  %indvars.iv.next263 = add nuw nsw i64 %indvars.iv262, 1
  %exitcond266.not = icmp eq i64 %indvars.iv.next263, %wide.trip.count265
  br i1 %exitcond266.not, label %.loopexit, label %.preheader186, !llvm.loop !32

.lr.ph195:                                        ; preds = %.preheader186, %.lr.ph195
  %.0161194 = phi i32 [ %39, %.lr.ph195 ], [ 0, %.preheader186 ]
  %36 = load ptr, ptr %0, align 8, !tbaa !9
  %37 = getelementptr inbounds i8, ptr %36, i64 8
  %38 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %37, i64 noundef %indvars.iv262) #10
  call void @_ZN5TNest23GeneratePiecewiseLinearEi(ptr noundef nonnull align 8 dereferenceable(84) %38, i32 noundef %.0161194)
  %39 = add nuw nsw i32 %.0161194, 1
  %40 = load i32, ptr %34, align 4, !tbaa !5
  %.not184.not = icmp slt i32 %.0161194, %40
  br i1 %.not184.not, label %.lr.ph195, label %._crit_edge196, !llvm.loop !33

.loopexit:                                        ; preds = %._crit_edge196, %._crit_edge192
  br i1 %17, label %.preheader185.preheader, label %.thread

.preheader185.preheader:                          ; preds = %.loopexit
  %wide.trip.count273 = zext nneg i32 %11 to i64
  br label %.preheader185

.preheader185:                                    ; preds = %.preheader185.preheader, %._crit_edge202
  %indvars.iv270 = phi i64 [ 0, %.preheader185.preheader ], [ %indvars.iv.next271, %._crit_edge202 ]
  %.0163204 = phi i32 [ 0, %.preheader185.preheader ], [ %.1164.lcssa.fr, %._crit_edge202 ]
  %41 = getelementptr inbounds i32, ptr %16, i64 %indvars.iv270
  %42 = load i32, ptr %41, align 4, !tbaa !5
  %.not183198 = icmp slt i32 %42, 0
  br i1 %.not183198, label %._crit_edge202, label %.lr.ph201

.thread.critedge:                                 ; preds = %3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #10
  store i32 0, ptr %7, align 4, !tbaa !5
  %43 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3maxIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %7)
  %44 = load i32, ptr %43, align 4, !tbaa !5
  store i32 %44, ptr %4, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #10
  %45 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZSt3minIiERKT_S2_S2_(ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5)
  %46 = load i32, ptr %45, align 4, !tbaa !5
  store i32 %46, ptr %4, align 4, !tbaa !5
  br label %.thread

.thread:                                          ; preds = %.thread.critedge, %._crit_edge, %.loopexit
  %47 = call noalias noundef nonnull dereferenceable(8) ptr @_Znam(i64 noundef 8) #11
  br label %._crit_edge221

._crit_edge205:                                   ; preds = %._crit_edge202
  %48 = add nsw i32 %.1164.lcssa.fr, 1
  %49 = sext i32 %48 to i64
  %50 = icmp slt i32 %.1164.lcssa.fr, -1
  %51 = shl nsw i64 %49, 3
  %spec.select = select i1 %50, i64 -1, i64 %51
  %52 = call noalias noundef nonnull ptr @_Znam(i64 noundef %spec.select) #11
  br i1 %17, label %.lr.ph220.preheader, label %._crit_edge221

.lr.ph220.preheader:                              ; preds = %._crit_edge205
  %wide.trip.count292 = zext nneg i32 %11 to i64
  %invariant.gep331 = getelementptr i8, ptr %52, i64 8
  %invariant.gep333 = getelementptr i8, ptr %52, i64 16
  %invariant.gep335 = getelementptr i8, ptr %52, i64 24
  br label %.lr.ph220

._crit_edge202:                                   ; preds = %.lr.ph201, %.preheader185
  %.1164.lcssa = phi i32 [ %.0163204, %.preheader185 ], [ %60, %.lr.ph201 ]
  %.1164.lcssa.fr = freeze i32 %.1164.lcssa
  %indvars.iv.next271 = add nuw nsw i64 %indvars.iv270, 1
  %exitcond274.not = icmp eq i64 %indvars.iv.next271, %wide.trip.count273
  br i1 %exitcond274.not, label %._crit_edge205, label %.preheader185, !llvm.loop !34

.lr.ph201:                                        ; preds = %.preheader185, %.lr.ph201
  %indvars.iv267 = phi i64 [ %indvars.iv.next268, %.lr.ph201 ], [ 0, %.preheader185 ]
  %.1164200 = phi i32 [ %60, %.lr.ph201 ], [ %.0163204, %.preheader185 ]
  %53 = load ptr, ptr %0, align 8, !tbaa !9
  %54 = getelementptr inbounds i8, ptr %53, i64 8
  %55 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %54, i64 noundef %indvars.iv270) #10
  %56 = getelementptr inbounds i8, ptr %55, i64 72
  %57 = load ptr, ptr %56, align 8, !tbaa !35
  %58 = getelementptr inbounds i32, ptr %57, i64 %indvars.iv267
  %59 = load i32, ptr %58, align 4, !tbaa !5
  %60 = add nsw i32 %59, %.1164200
  %indvars.iv.next268 = add nuw nsw i64 %indvars.iv267, 1
  %61 = load i32, ptr %41, align 4, !tbaa !5
  %62 = sext i32 %61 to i64
  %.not183.not = icmp slt i64 %indvars.iv267, %62
  br i1 %.not183.not, label %.lr.ph201, label %._crit_edge202, !llvm.loop !36

._crit_edge221:                                   ; preds = %._crit_edge215, %.thread, %._crit_edge205
  %63 = phi ptr [ %52, %._crit_edge205 ], [ %47, %.thread ], [ %52, %._crit_edge215 ]
  %.2.lcssa = phi i32 [ 0, %._crit_edge205 ], [ 0, %.thread ], [ %.3.lcssa, %._crit_edge215 ]
  %64 = sext i32 %.2.lcssa to i64
  %65 = getelementptr double, ptr %63, i64 %64
  store double 1.000000e+100, ptr %65, align 8, !tbaa !37
  %66 = getelementptr i8, ptr %65, i64 8
  call void @_ZSt4sortIPdEvT_S1_(ptr noundef nonnull %63, ptr noundef nonnull %66)
  %67 = load i32, ptr %4, align 4, !tbaa !5
  %68 = shl i32 %67, 1
  %69 = add i32 %68, 2
  %70 = load i32, ptr %6, align 4, !tbaa !5
  %71 = add nsw i32 %69, %70
  %72 = add nsw i32 %71, 1
  %73 = sext i32 %72 to i64
  %74 = icmp slt i32 %71, -1
  %75 = shl nsw i64 %73, 3
  %76 = select i1 %74, i64 -1, i64 %75
  %77 = call noalias noundef nonnull ptr @_Znam(i64 noundef %76) #11
  %.not223 = icmp slt i32 %.2.lcssa, 1
  br i1 %.not223, label %._crit_edge229.thread, label %.lr.ph228.preheader

.lr.ph228.preheader:                              ; preds = %._crit_edge221
  %78 = add nsw i32 %.2.lcssa, -1
  br label %.lr.ph228

.lr.ph220:                                        ; preds = %.lr.ph220.preheader, %._crit_edge215
  %indvars.iv289 = phi i64 [ 0, %.lr.ph220.preheader ], [ %indvars.iv.next290, %._crit_edge215 ]
  %.2218 = phi i32 [ 0, %.lr.ph220.preheader ], [ %.3.lcssa, %._crit_edge215 ]
  %79 = load ptr, ptr %0, align 8, !tbaa !9
  %80 = getelementptr inbounds i8, ptr %79, i64 8
  %81 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %80, i64 noundef %indvars.iv289) #10
  %82 = getelementptr inbounds i32, ptr %16, i64 %indvars.iv289
  %83 = load i32, ptr %82, align 4, !tbaa !5
  %.not182212 = icmp slt i32 %83, 0
  br i1 %.not182212, label %._crit_edge215, label %.preheader.lr.ph

.preheader.lr.ph:                                 ; preds = %.lr.ph220
  %84 = getelementptr inbounds i8, ptr %81, i64 72
  %85 = load ptr, ptr %84, align 8, !tbaa !35
  %86 = getelementptr inbounds i8, ptr %81, i64 64
  %87 = load ptr, ptr %86, align 8
  %88 = add nuw i32 %83, 1
  %wide.trip.count287 = zext i32 %88 to i64
  br label %.preheader

.preheader:                                       ; preds = %.preheader.lr.ph, %._crit_edge210
  %indvars.iv284 = phi i64 [ 0, %.preheader.lr.ph ], [ %indvars.iv.next285, %._crit_edge210 ]
  %.3214 = phi i32 [ %.2218, %.preheader.lr.ph ], [ %.4.lcssa, %._crit_edge210 ]
  %89 = getelementptr inbounds i32, ptr %85, i64 %indvars.iv284
  %90 = load i32, ptr %89, align 4, !tbaa !5
  %91 = icmp sgt i32 %90, 0
  br i1 %91, label %.lr.ph209, label %._crit_edge210

.lr.ph209:                                        ; preds = %.preheader
  %92 = getelementptr inbounds ptr, ptr %87, i64 %indvars.iv284
  %93 = load ptr, ptr %92, align 8, !tbaa !38
  %94 = sext i32 %.3214 to i64
  %wide.trip.count282 = zext nneg i32 %90 to i64
  %min.iters.check = icmp ult i32 %90, 7
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.memcheck

scalar.ph.preheader:                              ; preds = %vector.body, %vector.memcheck, %.lr.ph209
  %indvars.iv277.ph = phi i64 [ 0, %vector.memcheck ], [ 0, %.lr.ph209 ], [ %n.vec, %vector.body ]
  %indvars.iv275.ph = phi i64 [ %94, %vector.memcheck ], [ %94, %.lr.ph209 ], [ %ind.end, %vector.body ]
  %95 = sub nsw i64 %wide.trip.count282, %indvars.iv277.ph
  %xtraiter = and i64 %95, 3
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol

scalar.ph.prol:                                   ; preds = %scalar.ph.preheader, %scalar.ph.prol
  %indvars.iv277.prol = phi i64 [ %indvars.iv.next278.prol, %scalar.ph.prol ], [ %indvars.iv277.ph, %scalar.ph.preheader ]
  %indvars.iv275.prol = phi i64 [ %indvars.iv.next276.prol, %scalar.ph.prol ], [ %indvars.iv275.ph, %scalar.ph.preheader ]
  %prol.iter = phi i64 [ %prol.iter.next, %scalar.ph.prol ], [ 0, %scalar.ph.preheader ]
  %96 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %indvars.iv277.prol, i32 1
  %97 = load double, ptr %96, align 8, !tbaa !39
  %indvars.iv.next276.prol = add nsw i64 %indvars.iv275.prol, 1
  %98 = getelementptr inbounds double, ptr %52, i64 %indvars.iv275.prol
  store double %97, ptr %98, align 8, !tbaa !37
  %indvars.iv.next278.prol = add nuw nsw i64 %indvars.iv277.prol, 1
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter
  br i1 %prol.iter.cmp.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol, !llvm.loop !41

scalar.ph.prol.loopexit:                          ; preds = %scalar.ph.prol, %scalar.ph.preheader
  %indvars.iv.next276.lcssa.unr = phi i64 [ poison, %scalar.ph.preheader ], [ %indvars.iv.next276.prol, %scalar.ph.prol ]
  %indvars.iv277.unr = phi i64 [ %indvars.iv277.ph, %scalar.ph.preheader ], [ %indvars.iv.next278.prol, %scalar.ph.prol ]
  %indvars.iv275.unr = phi i64 [ %indvars.iv275.ph, %scalar.ph.preheader ], [ %indvars.iv.next276.prol, %scalar.ph.prol ]
  %99 = sub nsw i64 %indvars.iv277.ph, %wide.trip.count282
  %100 = icmp ugt i64 %99, -4
  br i1 %100, label %._crit_edge210.loopexit, label %scalar.ph

vector.memcheck:                                  ; preds = %.lr.ph209
  %101 = shl nsw i64 %94, 3
  %scevgep = getelementptr i8, ptr %52, i64 %101
  %102 = add nsw i64 %94, %wide.trip.count282
  %103 = shl nsw i64 %102, 3
  %scevgep324 = getelementptr i8, ptr %52, i64 %103
  %scevgep325 = getelementptr i8, ptr %93, i64 8
  %104 = shl nuw nsw i64 %wide.trip.count282, 4
  %scevgep326 = getelementptr i8, ptr %93, i64 %104
  %bound0 = icmp ult ptr %scevgep, %scevgep326
  %bound1 = icmp ult ptr %scevgep325, %scevgep324
  %found.conflict = and i1 %bound0, %bound1
  br i1 %found.conflict, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %n.mod.vf = and i64 %wide.trip.count282, 3
  %105 = icmp eq i64 %n.mod.vf, 0
  %106 = select i1 %105, i64 4, i64 %n.mod.vf
  %n.vec = sub nsw i64 %wide.trip.count282, %106
  %ind.end = add nsw i64 %n.vec, %94
  %invariant.gep = getelementptr double, ptr %52, i64 %94
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %107 = or disjoint i64 %index, 1
  %108 = or disjoint i64 %index, 2
  %109 = or disjoint i64 %index, 3
  %110 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %index, i32 1
  %111 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %107, i32 1
  %112 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %108, i32 1
  %113 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %109, i32 1
  %114 = load double, ptr %110, align 8, !tbaa !39, !alias.scope !43
  %115 = load double, ptr %111, align 8, !tbaa !39, !alias.scope !43
  %116 = insertelement <2 x double> poison, double %114, i64 0
  %117 = insertelement <2 x double> %116, double %115, i64 1
  %118 = load double, ptr %112, align 8, !tbaa !39, !alias.scope !43
  %119 = load double, ptr %113, align 8, !tbaa !39, !alias.scope !43
  %120 = insertelement <2 x double> poison, double %118, i64 0
  %121 = insertelement <2 x double> %120, double %119, i64 1
  %gep = getelementptr double, ptr %invariant.gep, i64 %index
  %122 = getelementptr inbounds i8, ptr %gep, i64 16
  store <2 x double> %117, ptr %gep, align 8, !tbaa !37, !alias.scope !46, !noalias !43
  store <2 x double> %121, ptr %122, align 8, !tbaa !37, !alias.scope !46, !noalias !43
  %index.next = add nuw i64 %index, 4
  %123 = icmp eq i64 %index.next, %n.vec
  br i1 %123, label %scalar.ph.preheader, label %vector.body, !llvm.loop !48

._crit_edge215:                                   ; preds = %._crit_edge210, %.lr.ph220
  %.3.lcssa = phi i32 [ %.2218, %.lr.ph220 ], [ %.4.lcssa, %._crit_edge210 ]
  %indvars.iv.next290 = add nuw nsw i64 %indvars.iv289, 1
  %exitcond293.not = icmp eq i64 %indvars.iv.next290, %wide.trip.count292
  br i1 %exitcond293.not, label %._crit_edge221, label %.lr.ph220, !llvm.loop !51

._crit_edge210.loopexit:                          ; preds = %scalar.ph, %scalar.ph.prol.loopexit
  %indvars.iv.next276.lcssa = phi i64 [ %indvars.iv.next276.lcssa.unr, %scalar.ph.prol.loopexit ], [ %indvars.iv.next276.3, %scalar.ph ]
  %124 = trunc nsw i64 %indvars.iv.next276.lcssa to i32
  br label %._crit_edge210

._crit_edge210:                                   ; preds = %._crit_edge210.loopexit, %.preheader
  %.4.lcssa = phi i32 [ %.3214, %.preheader ], [ %124, %._crit_edge210.loopexit ]
  %indvars.iv.next285 = add nuw nsw i64 %indvars.iv284, 1
  %exitcond288.not = icmp eq i64 %indvars.iv.next285, %wide.trip.count287
  br i1 %exitcond288.not, label %._crit_edge215, label %.preheader, !llvm.loop !52

scalar.ph:                                        ; preds = %scalar.ph.prol.loopexit, %scalar.ph
  %indvars.iv277 = phi i64 [ %indvars.iv.next278.3, %scalar.ph ], [ %indvars.iv277.unr, %scalar.ph.prol.loopexit ]
  %indvars.iv275 = phi i64 [ %indvars.iv.next276.3, %scalar.ph ], [ %indvars.iv275.unr, %scalar.ph.prol.loopexit ]
  %125 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %indvars.iv277, i32 1
  %126 = load double, ptr %125, align 8, !tbaa !39
  %127 = getelementptr inbounds double, ptr %52, i64 %indvars.iv275
  store double %126, ptr %127, align 8, !tbaa !37
  %indvars.iv.next278 = add nuw nsw i64 %indvars.iv277, 1
  %128 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %indvars.iv.next278, i32 1
  %129 = load double, ptr %128, align 8, !tbaa !39
  %gep332 = getelementptr double, ptr %invariant.gep331, i64 %indvars.iv275
  store double %129, ptr %gep332, align 8, !tbaa !37
  %indvars.iv.next278.1 = add nuw nsw i64 %indvars.iv277, 2
  %130 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %indvars.iv.next278.1, i32 1
  %131 = load double, ptr %130, align 8, !tbaa !39
  %gep334 = getelementptr double, ptr %invariant.gep333, i64 %indvars.iv275
  store double %131, ptr %gep334, align 8, !tbaa !37
  %indvars.iv.next278.2 = add nuw nsw i64 %indvars.iv277, 3
  %132 = getelementptr inbounds %"struct.std::pair", ptr %93, i64 %indvars.iv.next278.2, i32 1
  %133 = load double, ptr %132, align 8, !tbaa !39
  %indvars.iv.next276.3 = add nsw i64 %indvars.iv275, 4
  %gep336 = getelementptr double, ptr %invariant.gep335, i64 %indvars.iv275
  store double %133, ptr %gep336, align 8, !tbaa !37
  %indvars.iv.next278.3 = add nuw nsw i64 %indvars.iv277, 4
  %exitcond283.not.3 = icmp eq i64 %indvars.iv.next278.3, %wide.trip.count282
  br i1 %exitcond283.not.3, label %._crit_edge210.loopexit, label %scalar.ph, !llvm.loop !53

.lr.ph228:                                        ; preds = %.lr.ph228.preheader, %.lr.ph228
  %.0170226 = phi i32 [ %.1171, %.lr.ph228 ], [ -1, %.lr.ph228.preheader ]
  %.0172225 = phi i32 [ %.1173, %.lr.ph228 ], [ %78, %.lr.ph228.preheader ]
  %.0174224 = phi i32 [ %.1175, %.lr.ph228 ], [ 0, %.lr.ph228.preheader ]
  %134 = add nsw i32 %.0172225, %.0174224
  %135 = sdiv i32 %134, 2
  %136 = sext i32 %135 to i64
  %137 = getelementptr inbounds double, ptr %63, i64 %136
  %138 = load double, ptr %137, align 8, !tbaa !37
  %139 = load i32, ptr %4, align 4, !tbaa !5
  %140 = call noundef double @_ZN17NestedLogitSolver13JointDPOracleEdiPd(ptr noundef nonnull align 8 dereferenceable(40) %0, double noundef %138, i32 noundef %139, ptr noundef nonnull %77)
  %141 = fcmp ult double %140, 0.000000e+00
  %142 = add nsw i32 %135, 1
  %143 = add nsw i32 %135, -1
  %.1175 = select i1 %141, i32 %.0174224, i32 %142
  %.1173 = select i1 %141, i32 %143, i32 %.0172225
  %.1171 = select i1 %141, i32 %.0170226, i32 %135
  %.not = icmp sgt i32 %.1175, %.1173
  br i1 %.not, label %._crit_edge229, label %.lr.ph228, !llvm.loop !54

._crit_edge229:                                   ; preds = %.lr.ph228
  %.not180 = icmp eq i32 %.1171, -1
  br i1 %.not180, label %._crit_edge229.thread, label %144

._crit_edge229.thread:                            ; preds = %._crit_edge221, %._crit_edge229
  call void @__assert_fail(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, i32 noundef 112, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17NestedLogitSolver10SolveJointEib) #12
  unreachable

144:                                              ; preds = %._crit_edge229
  %145 = sext i32 %.1171 to i64
  %146 = getelementptr inbounds double, ptr %63, i64 %145
  %147 = load double, ptr %146, align 8, !tbaa !37
  %148 = getelementptr i8, ptr %146, i64 8
  %149 = load double, ptr %148, align 8, !tbaa !37
  %150 = fadd double %147, %149
  %151 = fmul double %150, 5.000000e-01
  %152 = shl nsw i64 %12, 3
  %153 = select i1 %13, i64 -1, i64 %152
  %154 = call noalias noundef nonnull ptr @_Znam(i64 noundef %153) #11
  %155 = call noalias noundef nonnull ptr @_Znam(i64 noundef %153) #11
  br i1 %17, label %.lr.ph245.preheader, label %._crit_edge246

.lr.ph245.preheader:                              ; preds = %144
  %wide.trip.count307 = zext nneg i32 %11 to i64
  br label %.lr.ph245

._crit_edge246:                                   ; preds = %._crit_edge242, %144
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #10
  store double -1.000000e+00, ptr %8, align 8, !tbaa !37
  %156 = call noalias noundef nonnull ptr @_Znam(i64 noundef %15) #11
  %157 = load i32, ptr %4, align 4, !tbaa !5
  %158 = load ptr, ptr %0, align 8, !tbaa !9
  %159 = getelementptr inbounds i8, ptr %158, i64 32
  %160 = load double, ptr %159, align 8, !tbaa !55
  call void @_Z16MaximizeFractioniPiiPPdS1_ddRdS_(i32 noundef %11, ptr noundef nonnull %16, i32 noundef %157, ptr noundef nonnull %154, ptr noundef nonnull %155, double noundef 0.000000e+00, double noundef %160, ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull %156)
  %161 = getelementptr inbounds i8, ptr %0, i64 8
  call void @_ZNSt6vectorIiSaIiEE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %161) #10
  call void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %161, i64 noundef %12)
  br i1 %17, label %.lr.ph249.preheader, label %._crit_edge250

.lr.ph249.preheader:                              ; preds = %._crit_edge246
  %wide.trip.count312 = zext nneg i32 %11 to i64
  br label %.lr.ph249

.lr.ph245:                                        ; preds = %.lr.ph245.preheader, %._crit_edge242
  %indvars.iv304 = phi i64 [ 0, %.lr.ph245.preheader ], [ %indvars.iv.next305, %._crit_edge242 ]
  %162 = getelementptr inbounds i32, ptr %16, i64 %indvars.iv304
  %163 = load i32, ptr %162, align 4, !tbaa !5
  %164 = add nsw i32 %163, 1
  %165 = sext i32 %164 to i64
  %166 = icmp slt i32 %163, -1
  %167 = shl nsw i64 %165, 3
  %168 = select i1 %166, i64 -1, i64 %167
  %169 = call noalias noundef nonnull ptr @_Znam(i64 noundef %168) #11
  %170 = getelementptr inbounds ptr, ptr %154, i64 %indvars.iv304
  store ptr %169, ptr %170, align 8, !tbaa !38
  %171 = call noalias noundef nonnull ptr @_Znam(i64 noundef %168) #11
  %172 = getelementptr inbounds ptr, ptr %155, i64 %indvars.iv304
  store ptr %171, ptr %172, align 8, !tbaa !38
  %173 = load ptr, ptr %0, align 8, !tbaa !9
  %174 = getelementptr inbounds i8, ptr %173, i64 8
  %175 = call noundef nonnull align 8 dereferenceable(84) ptr @_ZNSt6vectorI5TNestSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %174, i64 noundef %indvars.iv304) #10
  %176 = load i32, ptr %162, align 4, !tbaa !5
  %.not181238 = icmp slt i32 %176, 0
  br i1 %.not181238, label %._crit_edge242, label %.lr.ph241

.lr.ph241:                                        ; preds = %.lr.ph245
  %177 = getelementptr inbounds i8, ptr %175, i64 40
  %178 = load ptr, ptr %177, align 8, !tbaa !56
  %179 = getelementptr inbounds i8, ptr %175, i64 48
  %180 = load ptr, ptr %179, align 8, !tbaa !57
  %181 = add nuw i32 %176, 1
  %wide.trip.count302 = zext i32 %181 to i64
  br label %182

._crit_edge242:                                   ; preds = %._crit_edge236, %.lr.ph245
  %indvars.iv.next305 = add nuw nsw i64 %indvars.iv304, 1
  %exitcond308.not = icmp eq i64 %indvars.iv.next305, %wide.trip.count307
  br i1 %exitcond308.not, label %._crit_edge246, label %.lr.ph245, !llvm.loop !58

182:                                              ; preds = %.lr.ph241, %._crit_edge236
  %indvars.iv299 = phi i64 [ 0, %.lr.ph241 ], [ %indvars.iv.next300, %._crit_edge236 ]
  %183 = getelementptr inbounds ptr, ptr %178, i64 %indvars.iv299
  %184 = load ptr, ptr %183, align 8, !tbaa !38
  %185 = getelementptr inbounds i32, ptr %180, i64 %indvars.iv299
  %186 = load i32, ptr %185, align 4, !tbaa !5
  %187 = icmp sgt i32 %186, 0
  br i1 %187, label %.lr.ph235.preheader, label %._crit_edge236

.lr.ph235.preheader:                              ; preds = %182
  %wide.trip.count297 = zext nneg i32 %186 to i64
  %xtraiter328 = and i64 %wide.trip.count297, 1
  %188 = icmp eq i32 %186, 1
  br i1 %188, label %._crit_edge236.loopexit.unr-lcssa, label %.lr.ph235.preheader.new

.lr.ph235.preheader.new:                          ; preds = %.lr.ph235.preheader
  %unroll_iter = and i64 %wide.trip.count297, 2147483646
  br label %.lr.ph235

._crit_edge236.loopexit.unr-lcssa:                ; preds = %.lr.ph235, %.lr.ph235.preheader
  %.1.lcssa.ph = phi i32 [ poison, %.lr.ph235.preheader ], [ %.1.1, %.lr.ph235 ]
  %indvars.iv294.unr = phi i64 [ 0, %.lr.ph235.preheader ], [ %indvars.iv.next295.1, %.lr.ph235 ]
  %.0157232.unr = phi i32 [ -1, %.lr.ph235.preheader ], [ %.1.1, %.lr.ph235 ]
  %.0158231.unr = phi double [ -1.000000e+100, %.lr.ph235.preheader ], [ %.1159.1, %.lr.ph235 ]
  %lcmp.mod329.not = icmp eq i64 %xtraiter328, 0
  br i1 %lcmp.mod329.not, label %._crit_edge236, label %.lr.ph235.epil

.lr.ph235.epil:                                   ; preds = %._crit_edge236.loopexit.unr-lcssa
  %189 = getelementptr inbounds %struct.TCandidate, ptr %184, i64 %indvars.iv294.unr
  %190 = getelementptr inbounds i8, ptr %189, i64 16
  %191 = load double, ptr %190, align 8, !tbaa !59
  %192 = getelementptr inbounds i8, ptr %189, i64 24
  %193 = load double, ptr %192, align 8, !tbaa !61
  %194 = fneg double %193
  %195 = call double @llvm.fmuladd.f64(double %194, double %151, double %191)
  %196 = fcmp ogt double %195, %.0158231.unr
  %197 = trunc nuw nsw i64 %indvars.iv294.unr to i32
  %.1.epil = select i1 %196, i32 %197, i32 %.0157232.unr
  br label %._crit_edge236

._crit_edge236:                                   ; preds = %.lr.ph235.epil, %._crit_edge236.loopexit.unr-lcssa, %182
  %.0157.lcssa = phi i32 [ -1, %182 ], [ %.1.lcssa.ph, %._crit_edge236.loopexit.unr-lcssa ], [ %.1.epil, %.lr.ph235.epil ]
  %198 = sext i32 %.0157.lcssa to i64
  %199 = getelementptr inbounds %struct.TCandidate, ptr %184, i64 %198
  %200 = getelementptr inbounds i8, ptr %199, i64 16
  %201 = load double, ptr %200, align 8, !tbaa !59
  %202 = getelementptr inbounds double, ptr %169, i64 %indvars.iv299
  store double %201, ptr %202, align 8, !tbaa !37
  %203 = getelementptr inbounds i8, ptr %199, i64 24
  %204 = load double, ptr %203, align 8, !tbaa !61
  %205 = getelementptr inbounds double, ptr %171, i64 %indvars.iv299
  store double %204, ptr %205, align 8, !tbaa !37
  %indvars.iv.next300 = add nuw nsw i64 %indvars.iv299, 1
  %exitcond303.not = icmp eq i64 %indvars.iv.next300, %wide.trip.count302
  br i1 %exitcond303.not, label %._crit_edge242, label %182, !llvm.loop !62

.lr.ph235:                                        ; preds = %.lr.ph235, %.lr.ph235.preheader.new
  %indvars.iv294 = phi i64 [ 0, %.lr.ph235.preheader.new ], [ %indvars.iv.next295.1, %.lr.ph235 ]
  %.0157232 = phi i32 [ -1, %.lr.ph235.preheader.new ], [ %.1.1, %.lr.ph235 ]
  %.0158231 = phi double [ -1.000000e+100, %.lr.ph235.preheader.new ], [ %.1159.1, %.lr.ph235 ]
  %niter = phi i64 [ 0, %.lr.ph235.preheader.new ], [ %niter.next.1, %.lr.ph235 ]
  %206 = getelementptr inbounds %struct.TCandidate, ptr %184, i64 %indvars.iv294
  %207 = getelementptr inbounds i8, ptr %206, i64 16
  %208 = load double, ptr %207, align 8, !tbaa !59
  %209 = getelementptr inbounds i8, ptr %206, i64 24
  %210 = load double, ptr %209, align 8, !tbaa !61
  %211 = fneg double %210
  %212 = call double @llvm.fmuladd.f64(double %211, double %151, double %208)
  %213 = fcmp ogt double %212, %.0158231
  %.1159 = select i1 %213, double %212, double %.0158231
  %214 = trunc nuw nsw i64 %indvars.iv294 to i32
  %.1 = select i1 %213, i32 %214, i32 %.0157232
  %indvars.iv.next295 = or disjoint i64 %indvars.iv294, 1
  %215 = getelementptr inbounds %struct.TCandidate, ptr %184, i64 %indvars.iv.next295
  %216 = getelementptr inbounds i8, ptr %215, i64 16
  %217 = load double, ptr %216, align 8, !tbaa !59
  %218 = getelementptr inbounds i8, ptr %215, i64 24
  %219 = load double, ptr %218, align 8, !tbaa !61
  %220 = fneg double %219
  %221 = call double @llvm.fmuladd.f64(double %220, double %151, double %217)
  %222 = fcmp ogt double %221, %.1159
  %.1159.1 = select i1 %222, double %221, double %.1159
  %223 = trunc nuw nsw i64 %indvars.iv.next295 to i32
  %.1.1 = select i1 %222, i32 %223, i32 %.1
  %indvars.iv.next295.1 = add nuw nsw i64 %indvars.iv294, 2
  %niter.next.1 = add i64 %niter, 2
  %niter.ncmp.1 = icmp eq i64 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %._crit_edge236.loopexit.unr-lcssa, label %.lr.ph235, !llvm.loop !63

._crit_edge250:                                   ; preds = %.lr.ph249, %._crit_edge246
  %224 = getelementptr inbounds i8, ptr %0, i64 32
  store double -1.000000e+00, ptr %224, align 8, !tbaa !64
  call void @_ZNSt6vectorIiSaIiEEC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(24) %161)
  %225 = invoke noundef double @_ZN17NestedLogitSolver13SolveDisjointESt6vectorIiSaIiEEb(ptr noundef nonnull align 8 dereferenceable(40) %0, ptr noundef nonnull %9, i1 noundef zeroext false)
          to label %229 unwind label %236

.lr.ph249:                                        ; preds = %.lr.ph249.preheader, %.lr.ph249
  %indvars.iv309 = phi i64 [ 0, %.lr.ph249.preheader ], [ %indvars.iv.next310, %.lr.ph249 ]
  %226 = getelementptr inbounds i32, ptr %156, i64 %indvars.iv309
  %227 = load i32, ptr %226, align 4, !tbaa !5
  %228 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %161, i64 noundef %indvars.iv309) #10
  store i32 %227, ptr %228, align 4, !tbaa !5
  %indvars.iv.next310 = add nuw nsw i64 %indvars.iv309, 1
  %exitcond313.not = icmp eq i64 %indvars.iv.next310, %wide.trip.count312
  br i1 %exitcond313.not, label %._crit_edge250, label %.lr.ph249, !llvm.loop !65

229:                                              ; preds = %._crit_edge250
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #10
  %230 = load double, ptr %8, align 8, !tbaa !37
  %231 = load double, ptr %224, align 8, !tbaa !64
  %232 = fsub double %230, %231
  %233 = call double @llvm.fabs.f64(double %232)
  %234 = fcmp olt double %233, 1.000000e-08
  br i1 %234, label %238, label %235

235:                                              ; preds = %229
  call void @__assert_fail(ptr noundef nonnull @.str.2, ptr noundef nonnull @.str.1, i32 noundef 150, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17NestedLogitSolver10SolveJointEib) #12
  unreachable

236:                                              ; preds = %._crit_edge250
  %237 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #10
  resume { ptr, i32 } %237

238:                                              ; preds = %229
  call void @_ZdlPvm(ptr noundef nonnull %77, i64 noundef 8) #13
  call void @_ZdlPvm(ptr noundef nonnull %63, i64 noundef 8) #13
  br i1 %17, label %.lr.ph253.preheader, label %._crit_edge254

.lr.ph253.preheader:                              ; preds = %238
  %wide.trip.count317 = zext nneg i32 %11 to i64
  br label %.lr.ph253

.lr.ph253:                                        ; preds = %.lr.ph253.preheader, %248
  %indvars.iv314 = phi i64 [ 0, %.lr.ph253.preheader ], [ %indvars.iv.next315, %248 ]
  %239 = getelementptr inbounds ptr, ptr %154, i64 %indvars.iv314
  %240 = load ptr, ptr %239, align 8, !tbaa !38
  %241 = icmp eq ptr %240, null
  br i1 %241, label %243, label %242

242:                                              ; preds = %.lr.ph253
  call void @_ZdlPvm(ptr noundef nonnull %240, i64 noundef 8) #13
  br label %243

243:                                              ; preds = %242, %.lr.ph253
  %244 = getelementptr inbounds ptr, ptr %155, i64 %indvars.iv314
  %245 = load ptr, ptr %244, align 8, !tbaa !38
  %246 = icmp eq ptr %245, null
  br i1 %246, label %248, label %247

247:                                              ; preds = %243
  call void @_ZdlPvm(ptr noundef nonnull %245, i64 noundef 8) #13
  br label %248

248:                                              ; preds = %243, %247
  %indvars.iv.next315 = add nuw nsw i64 %indvars.iv314, 1
  %exitcond318.not = icmp eq i64 %indvars.iv.next315, %wide.trip.count317
  br i1 %exitcond318.not, label %._crit_edge254, label %.lr.ph253, !llvm.loop !66

._crit_edge254:                                   ; preds = %248, %238
  call void @_ZdlPvm(ptr noundef nonnull %154, i64 noundef 8) #13
  call void @_ZdlPvm(ptr noundef nonnull %155, i64 noundef 8) #13
  call void @_ZdlPvm(ptr noundef nonnull %156, i64 noundef 4) #13
  call void @_ZdlPvm(ptr noundef nonnull %16, i64 noundef 4) #13
  %249 = load double, ptr %224, align 8, !tbaa !64
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #10
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #10
  ret double %249
}

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

; 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 #5

; 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 #5

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

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

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

declare void @_Z16MaximizeFractioniPiiPPdS1_ddRdS_(i32 noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef, double noundef, double noundef, ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #6

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #3 align 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 #0 align 2

declare noundef double @_ZN17NestedLogitSolver13SolveDisjointESt6vectorIiSaIiEEb(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef, i1 noundef zeroext) local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEEC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(24), 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 @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

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

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

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 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { 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 #4 = { 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 #5 = { 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 #6 = { "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 = { 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 #8 = { 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 #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 = { noreturn nounwind }
attributes #13 = { 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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !11, i64 0}
!10 = !{!"_ZTS17NestedLogitSolver", !11, i64 0, !12, i64 8, !16, i64 32}
!11 = !{!"any pointer", !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", !11, i64 0, !11, i64 8, !11, i64 16}
!16 = !{!"double", !7, i64 0}
!17 = !{!18, !6, i64 0}
!18 = !{!"_ZTS16NestedLogitModel", !6, i64 0, !19, i64 8, !16, i64 32}
!19 = !{!"_ZTSSt6vectorI5TNestSaIS0_EE", !20, i64 0}
!20 = !{!"_ZTSSt12_Vector_baseI5TNestSaIS0_EE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseI5TNestSaIS0_EE12_Vector_implE", !22, i64 0}
!22 = !{!"_ZTSNSt12_Vector_baseI5TNestSaIS0_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!23 = !{!24, !6, i64 0}
!24 = !{!"_ZTS5TNest", !6, i64 0, !16, i64 8, !25, i64 16, !11, i64 40, !11, i64 48, !6, i64 56, !11, i64 64, !11, i64 72, !6, i64 80}
!25 = !{!"_ZTSSt6vectorI8TProductSaIS0_EE", !26, i64 0}
!26 = !{!"_ZTSSt12_Vector_baseI8TProductSaIS0_EE", !27, i64 0}
!27 = !{!"_ZTSNSt12_Vector_baseI8TProductSaIS0_EE12_Vector_implE", !28, i64 0}
!28 = !{!"_ZTSNSt12_Vector_baseI8TProductSaIS0_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!29 = distinct !{!29, !30}
!30 = !{!"llvm.loop.mustprogress"}
!31 = distinct !{!31, !30}
!32 = distinct !{!32, !30}
!33 = distinct !{!33, !30}
!34 = distinct !{!34, !30}
!35 = !{!24, !11, i64 72}
!36 = distinct !{!36, !30}
!37 = !{!16, !16, i64 0}
!38 = !{!11, !11, i64 0}
!39 = !{!40, !16, i64 8}
!40 = !{!"_ZTSSt4pairIidE", !6, i64 0, !16, i64 8}
!41 = distinct !{!41, !42}
!42 = !{!"llvm.loop.unroll.disable"}
!43 = !{!44}
!44 = distinct !{!44, !45}
!45 = distinct !{!45, !"LVerDomain"}
!46 = !{!47}
!47 = distinct !{!47, !45}
!48 = distinct !{!48, !30, !49, !50}
!49 = !{!"llvm.loop.isvectorized", i32 1}
!50 = !{!"llvm.loop.unroll.runtime.disable"}
!51 = distinct !{!51, !30}
!52 = distinct !{!52, !30}
!53 = distinct !{!53, !30, !49}
!54 = distinct !{!54, !30}
!55 = !{!18, !16, i64 32}
!56 = !{!24, !11, i64 40}
!57 = !{!24, !11, i64 48}
!58 = distinct !{!58, !30}
!59 = !{!60, !16, i64 16}
!60 = !{!"_ZTS10TCandidate", !16, i64 0, !16, i64 8, !16, i64 16, !16, i64 24}
!61 = !{!60, !16, i64 24}
!62 = distinct !{!62, !30}
!63 = distinct !{!63, !30}
!64 = !{!10, !16, i64 32}
!65 = distinct !{!65, !30}
!66 = distinct !{!66, !30}


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