; LLVM IR from ERGO-Code/HiGHS :: src/ipm/ipx (model)

; 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::_Expr.17" = type { %"struct.std::__detail::_UnClos" }
%"struct.std::__detail::_UnClos" = type { %"class.std::__detail::_UnBase" }
%"class.std::__detail::_UnBase" = type { ptr }
%"class.ipx::Model" = type { i8, i32, i32, i32, i32, %"class.ipx::SparseMatrix", %"class.ipx::SparseMatrix", %"class.std::valarray", %"class.std::valarray", %"class.std::valarray", %"class.std::valarray", double, double, i32, i32, i32, i32, i32, %"class.std::vector", %"class.std::vector.8", double, double, double, %"class.std::valarray", %"class.std::valarray", %"class.std::valarray", %"class.std::valarray", %"class.ipx::SparseMatrix", %"class.std::vector", %"class.std::valarray", %"class.std::valarray" }
%"class.std::vector.8" = type { %"struct.std::_Vector_base.9" }
%"struct.std::_Vector_base.9" = type { %"struct.std::_Vector_base<char, std::allocator<char>>::_Vector_impl" }
%"struct.std::_Vector_base<char, std::allocator<char>>::_Vector_impl" = type { %"struct.std::_Vector_base<char, std::allocator<char>>::_Vector_impl_data" }
%"struct.std::_Vector_base<char, std::allocator<char>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.ipx::SparseMatrix" = type { i32, %"class.std::vector", %"class.std::vector", %"class.std::vector.3", %"class.std::vector", %"class.std::vector.3" }
%"class.std::vector.3" = type { %"struct.std::_Vector_base.4" }
%"struct.std::_Vector_base.4" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::valarray" = type { i64, ptr }

@.str.18 = external hidden unnamed_addr constant [70 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [14 x i8], align 1
@__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_ = external hidden unnamed_addr constant [138 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [59 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [14 x i8], align 1

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK3ipx5Model4rowsEv(ptr noundef nonnull align 8 dereferenceable(704)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK3ipx5Model4colsEv(ptr noundef nonnull align 8 dereferenceable(704)) #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef, i32 noundef, ptr noundef) #4

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_(ptr noundef nonnull align 8 dereferenceable(704) %0, ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull align 8 dereferenceable(16) %2, ptr noundef nonnull align 8 dereferenceable(16) %3, ptr noundef nonnull align 8 dereferenceable(16) %4, ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef nonnull align 8 dereferenceable(16) %6, ptr noundef nonnull align 8 dereferenceable(16) %7) #5 align 2 {
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca %"class.std::_Expr.17", align 8
  %20 = alloca i32, align 4
  %21 = alloca i64, align 8
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i64, align 8
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  store ptr %0, ptr %9, align 8, !tbaa !5
  store ptr %1, ptr %10, align 8, !tbaa !5
  store ptr %2, ptr %11, align 8, !tbaa !5
  store ptr %3, ptr %12, align 8, !tbaa !5
  store ptr %4, ptr %13, align 8, !tbaa !5
  store ptr %5, ptr %14, align 8, !tbaa !5
  store ptr %6, ptr %15, align 8, !tbaa !5
  store ptr %7, ptr %16, align 8, !tbaa !5
  %27 = load ptr, ptr %9, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #6
  %28 = call noundef i32 @_ZNK3ipx5Model4rowsEv(ptr noundef nonnull align 8 dereferenceable(704) %27)
  store i32 %28, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #6
  %29 = call noundef i32 @_ZNK3ipx5Model4colsEv(ptr noundef nonnull align 8 dereferenceable(704) %27)
  store i32 %29, ptr %18, align 4, !tbaa !9
  %30 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 0
  %31 = load i8, ptr %30, align 8, !tbaa !11, !range !30, !noundef !31
  %32 = trunc i8 %31 to i1
  br i1 %32, label %33, label %215

33:                                               ; preds = %8
  %34 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 15
  %35 = load i32, ptr %34, align 8, !tbaa !32
  %36 = load i32, ptr %17, align 4, !tbaa !9
  %37 = icmp eq i32 %35, %36
  br i1 %37, label %38, label %39

38:                                               ; preds = %33
  br label %41

39:                                               ; preds = %33
  call void @__assert_fail(ptr noundef @.str.55, ptr noundef @.str.18, i32 noundef 1085, ptr noundef @__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_) #7
  unreachable

40:                                               ; No predecessors!
  br label %41

41:                                               ; preds = %40, %38
  %42 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 13
  %43 = load i32, ptr %42, align 8, !tbaa !33
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 18
  %46 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %45) #6
  %47 = add i64 %44, %46
  %48 = load i32, ptr %18, align 4, !tbaa !9
  %49 = sext i32 %48 to i64
  %50 = icmp eq i64 %47, %49
  br i1 %50, label %51, label %52

51:                                               ; preds = %41
  br label %54

52:                                               ; preds = %41
  call void @__assert_fail(ptr noundef @.str.56, ptr noundef @.str.18, i32 noundef 1086, ptr noundef @__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_) #7
  unreachable

53:                                               ; No predecessors!
  br label %54

54:                                               ; preds = %53, %51
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #6
  %55 = load ptr, ptr %10, align 8, !tbaa !5
  %56 = call ptr @_ZNKSt8valarrayIdEngEv(ptr noundef nonnull align 8 dereferenceable(16) %55)
  %57 = getelementptr inbounds %"class.std::_Expr.17", ptr %19, i32 0, i32 0
  %58 = getelementptr inbounds %"struct.std::__detail::_UnClos", ptr %57, i32 0, i32 0
  %59 = getelementptr inbounds %"class.std::__detail::_UnBase", ptr %58, i32 0, i32 0
  store ptr %56, ptr %59, align 8
  %60 = load ptr, ptr %15, align 8, !tbaa !5
  %61 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt8valarrayIdEaSINSt8__detail7_UnClosISt8__negateSt9_ValArraydEEEERS0_RKSt5_ExprIT_dE(ptr noundef nonnull align 8 dereferenceable(16) %60, ptr noundef nonnull align 8 dereferenceable(8) %19)
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #6
  store i32 0, ptr %20, align 4, !tbaa !9
  br label %62

62:                                               ; preds = %79, %54
  %63 = load i32, ptr %20, align 4, !tbaa !9
  %64 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 13
  %65 = load i32, ptr %64, align 8, !tbaa !33
  %66 = icmp slt i32 %63, %65
  br i1 %66, label %68, label %67

67:                                               ; preds = %62
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #6
  br label %82

68:                                               ; preds = %62
  %69 = load ptr, ptr %11, align 8, !tbaa !5
  %70 = load i32, ptr %20, align 4, !tbaa !9
  %71 = sext i32 %70 to i64
  %72 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %69, i64 noundef %71) #6
  %73 = load double, ptr %72, align 8, !tbaa !34
  %74 = fneg double %73
  %75 = load ptr, ptr %16, align 8, !tbaa !5
  %76 = load i32, ptr %20, align 4, !tbaa !9
  %77 = sext i32 %76 to i64
  %78 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %75, i64 noundef %77) #6
  store double %74, ptr %78, align 8, !tbaa !34
  br label %79

79:                                               ; preds = %68
  %80 = load i32, ptr %20, align 4, !tbaa !9
  %81 = add nsw i32 %80, 1
  store i32 %81, ptr %20, align 4, !tbaa !9
  br label %62, !llvm.loop !35

82:                                               ; preds = %67
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #6
  store i64 0, ptr %21, align 8, !tbaa !37
  br label %83

83:                                               ; preds = %114, %82
  %84 = load i64, ptr %21, align 8, !tbaa !37
  %85 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 18
  %86 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %85) #6
  %87 = icmp ult i64 %84, %86
  br i1 %87, label %89, label %88

88:                                               ; preds = %83
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #6
  br label %117

89:                                               ; preds = %83
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #6
  %90 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 18
  %91 = load i64, ptr %21, align 8, !tbaa !37
  %92 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %90, i64 noundef %91) #6
  %93 = load i32, ptr %92, align 4, !tbaa !9
  store i32 %93, ptr %22, align 4, !tbaa !9
  %94 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 13
  %95 = load i32, ptr %94, align 8, !tbaa !33
  %96 = sext i32 %95 to i64
  %97 = load i64, ptr %21, align 8, !tbaa !37
  %98 = add i64 %96, %97
  %99 = trunc i64 %98 to i32
  %100 = call noundef double @_ZNK3ipx5Model1cEi(ptr noundef nonnull align 8 dereferenceable(704) %27, i32 noundef %99)
  %101 = load ptr, ptr %15, align 8, !tbaa !5
  %102 = load i32, ptr %22, align 4, !tbaa !9
  %103 = sext i32 %102 to i64
  %104 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %101, i64 noundef %103) #6
  %105 = load double, ptr %104, align 8, !tbaa !34
  %106 = fadd double %100, %105
  %107 = load ptr, ptr %16, align 8, !tbaa !5
  %108 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 13
  %109 = load i32, ptr %108, align 8, !tbaa !33
  %110 = sext i32 %109 to i64
  %111 = load i64, ptr %21, align 8, !tbaa !37
  %112 = add i64 %110, %111
  %113 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %107, i64 noundef %112) #6
  store double %106, ptr %113, align 8, !tbaa !34
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #6
  br label %114

114:                                              ; preds = %89
  %115 = load i64, ptr %21, align 8, !tbaa !37
  %116 = add i64 %115, 1
  store i64 %116, ptr %21, align 8, !tbaa !37
  br label %83, !llvm.loop !38

117:                                              ; preds = %88
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #6
  store i32 0, ptr %23, align 4, !tbaa !9
  br label %118

118:                                              ; preds = %140, %117
  %119 = load i32, ptr %23, align 4, !tbaa !9
  %120 = load i32, ptr %17, align 4, !tbaa !9
  %121 = icmp slt i32 %119, %120
  br i1 %121, label %123, label %122

122:                                              ; preds = %118
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #6
  br label %143

123:                                              ; preds = %118
  %124 = load i32, ptr %18, align 4, !tbaa !9
  %125 = load i32, ptr %23, align 4, !tbaa !9
  %126 = add nsw i32 %124, %125
  %127 = call noundef double @_ZNK3ipx5Model1cEi(ptr noundef nonnull align 8 dereferenceable(704) %27, i32 noundef %126)
  %128 = load ptr, ptr %15, align 8, !tbaa !5
  %129 = load i32, ptr %23, align 4, !tbaa !9
  %130 = sext i32 %129 to i64
  %131 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %128, i64 noundef %130) #6
  %132 = load double, ptr %131, align 8, !tbaa !34
  %133 = fsub double %127, %132
  %134 = load ptr, ptr %16, align 8, !tbaa !5
  %135 = load i32, ptr %18, align 4, !tbaa !9
  %136 = load i32, ptr %23, align 4, !tbaa !9
  %137 = add nsw i32 %135, %136
  %138 = sext i32 %137 to i64
  %139 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %134, i64 noundef %138) #6
  store double %133, ptr %139, align 8, !tbaa !34
  br label %140

140:                                              ; preds = %123
  %141 = load i32, ptr %23, align 4, !tbaa !9
  %142 = add nsw i32 %141, 1
  store i32 %142, ptr %23, align 4, !tbaa !9
  br label %118, !llvm.loop !39

143:                                              ; preds = %122
  %144 = load ptr, ptr %12, align 8, !tbaa !5
  %145 = call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %144) #6
  %146 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 13
  %147 = load i32, ptr %146, align 8, !tbaa !33
  %148 = load ptr, ptr %14, align 8, !tbaa !5
  %149 = call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %148) #6
  %150 = call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %145, i32 noundef %147, ptr noundef %149)
  %151 = load ptr, ptr %13, align 8, !tbaa !5
  %152 = call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %151) #6
  %153 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 15
  %154 = load i32, ptr %153, align 8, !tbaa !32
  %155 = load ptr, ptr %14, align 8, !tbaa !5
  %156 = call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %155) #6
  %157 = load i32, ptr %18, align 4, !tbaa !9
  %158 = sext i32 %157 to i64
  %159 = getelementptr inbounds double, ptr %156, i64 %158
  %160 = call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %152, i32 noundef %154, ptr noundef %159)
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #6
  store i64 0, ptr %24, align 8, !tbaa !37
  br label %161

161:                                              ; preds = %211, %143
  %162 = load i64, ptr %24, align 8, !tbaa !37
  %163 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 18
  %164 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %163) #6
  %165 = icmp ult i64 %162, %164
  br i1 %165, label %167, label %166

166:                                              ; preds = %161
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #6
  br label %214

167:                                              ; preds = %161
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #6
  %168 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 18
  %169 = load i64, ptr %24, align 8, !tbaa !37
  %170 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %168, i64 noundef %169) #6
  %171 = load i32, ptr %170, align 4, !tbaa !9
  store i32 %171, ptr %25, align 4, !tbaa !9
  %172 = load ptr, ptr %14, align 8, !tbaa !5
  %173 = load i32, ptr %18, align 4, !tbaa !9
  %174 = load i32, ptr %25, align 4, !tbaa !9
  %175 = add nsw i32 %173, %174
  %176 = sext i32 %175 to i64
  %177 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %172, i64 noundef %176) #6
  %178 = load double, ptr %177, align 8, !tbaa !34
  %179 = fcmp olt double %178, 0.000000e+00
  br i1 %179, label %180, label %202

180:                                              ; preds = %167
  %181 = load ptr, ptr %14, align 8, !tbaa !5
  %182 = load i32, ptr %18, align 4, !tbaa !9
  %183 = load i32, ptr %25, align 4, !tbaa !9
  %184 = add nsw i32 %182, %183
  %185 = sext i32 %184 to i64
  %186 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %181, i64 noundef %185) #6
  %187 = load double, ptr %186, align 8, !tbaa !34
  %188 = fneg double %187
  %189 = load ptr, ptr %14, align 8, !tbaa !5
  %190 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 13
  %191 = load i32, ptr %190, align 8, !tbaa !33
  %192 = sext i32 %191 to i64
  %193 = load i64, ptr %24, align 8, !tbaa !37
  %194 = add i64 %192, %193
  %195 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %189, i64 noundef %194) #6
  store double %188, ptr %195, align 8, !tbaa !34
  %196 = load ptr, ptr %14, align 8, !tbaa !5
  %197 = load i32, ptr %18, align 4, !tbaa !9
  %198 = load i32, ptr %25, align 4, !tbaa !9
  %199 = add nsw i32 %197, %198
  %200 = sext i32 %199 to i64
  %201 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %196, i64 noundef %200) #6
  store double 0.000000e+00, ptr %201, align 8, !tbaa !34
  br label %210

202:                                              ; preds = %167
  %203 = load ptr, ptr %14, align 8, !tbaa !5
  %204 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 13
  %205 = load i32, ptr %204, align 8, !tbaa !33
  %206 = sext i32 %205 to i64
  %207 = load i64, ptr %24, align 8, !tbaa !37
  %208 = add i64 %206, %207
  %209 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %203, i64 noundef %208) #6
  store double 0.000000e+00, ptr %209, align 8, !tbaa !34
  br label %210

210:                                              ; preds = %202, %180
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #6
  br label %211

211:                                              ; preds = %210
  %212 = load i64, ptr %24, align 8, !tbaa !37
  %213 = add i64 %212, 1
  store i64 %213, ptr %24, align 8, !tbaa !37
  br label %161, !llvm.loop !40

214:                                              ; preds = %166
  br label %285

215:                                              ; preds = %8
  %216 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 13
  %217 = load i32, ptr %216, align 8, !tbaa !33
  %218 = load i32, ptr %17, align 4, !tbaa !9
  %219 = icmp eq i32 %217, %218
  br i1 %219, label %220, label %221

220:                                              ; preds = %215
  br label %223

221:                                              ; preds = %215
  call void @__assert_fail(ptr noundef @.str.57, ptr noundef @.str.18, i32 noundef 1114, ptr noundef @__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_) #7
  unreachable

222:                                              ; No predecessors!
  br label %223

223:                                              ; preds = %222, %220
  %224 = getelementptr inbounds %"class.ipx::Model", ptr %27, i32 0, i32 15
  %225 = load i32, ptr %224, align 8, !tbaa !32
  %226 = load i32, ptr %18, align 4, !tbaa !9
  %227 = icmp eq i32 %225, %226
  br i1 %227, label %228, label %229

228:                                              ; preds = %223
  br label %231

229:                                              ; preds = %223
  call void @__assert_fail(ptr noundef @.str.58, ptr noundef @.str.18, i32 noundef 1115, ptr noundef @__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_) #7
  unreachable

230:                                              ; No predecessors!
  br label %231

231:                                              ; preds = %230, %228
  %232 = load ptr, ptr %10, align 8, !tbaa !5
  %233 = call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %232) #6
  %234 = load i32, ptr %18, align 4, !tbaa !9
  %235 = load ptr, ptr %14, align 8, !tbaa !5
  %236 = call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %235) #6
  %237 = call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %233, i32 noundef %234, ptr noundef %236)
  %238 = load ptr, ptr %11, align 8, !tbaa !5
  %239 = call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %238) #6
  %240 = load i32, ptr %17, align 4, !tbaa !9
  %241 = load ptr, ptr %14, align 8, !tbaa !5
  %242 = call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %241) #6
  %243 = load i32, ptr %18, align 4, !tbaa !9
  %244 = sext i32 %243 to i64
  %245 = getelementptr inbounds double, ptr %242, i64 %244
  %246 = call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %239, i32 noundef %240, ptr noundef %245)
  %247 = load ptr, ptr %12, align 8, !tbaa !5
  %248 = call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %247) #6
  %249 = load i32, ptr %17, align 4, !tbaa !9
  %250 = load ptr, ptr %15, align 8, !tbaa !5
  %251 = call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %250) #6
  %252 = call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %248, i32 noundef %249, ptr noundef %251)
  %253 = load ptr, ptr %13, align 8, !tbaa !5
  %254 = call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %253) #6
  %255 = load i32, ptr %18, align 4, !tbaa !9
  %256 = load ptr, ptr %16, align 8, !tbaa !5
  %257 = call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %256) #6
  %258 = call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %254, i32 noundef %255, ptr noundef %257)
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #6
  store i32 0, ptr %26, align 4, !tbaa !9
  br label %259

259:                                              ; preds = %281, %231
  %260 = load i32, ptr %26, align 4, !tbaa !9
  %261 = load i32, ptr %17, align 4, !tbaa !9
  %262 = icmp slt i32 %260, %261
  br i1 %262, label %264, label %263

263:                                              ; preds = %259
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #6
  br label %284

264:                                              ; preds = %259
  %265 = load i32, ptr %18, align 4, !tbaa !9
  %266 = load i32, ptr %26, align 4, !tbaa !9
  %267 = add nsw i32 %265, %266
  %268 = call noundef double @_ZNK3ipx5Model1cEi(ptr noundef nonnull align 8 dereferenceable(704) %27, i32 noundef %267)
  %269 = load ptr, ptr %15, align 8, !tbaa !5
  %270 = load i32, ptr %26, align 4, !tbaa !9
  %271 = sext i32 %270 to i64
  %272 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %269, i64 noundef %271) #6
  %273 = load double, ptr %272, align 8, !tbaa !34
  %274 = fsub double %268, %273
  %275 = load ptr, ptr %16, align 8, !tbaa !5
  %276 = load i32, ptr %18, align 4, !tbaa !9
  %277 = load i32, ptr %26, align 4, !tbaa !9
  %278 = add nsw i32 %276, %277
  %279 = sext i32 %278 to i64
  %280 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %275, i64 noundef %279) #6
  store double %274, ptr %280, align 8, !tbaa !34
  br label %281

281:                                              ; preds = %264
  %282 = load i32, ptr %26, align 4, !tbaa !9
  %283 = add nsw i32 %282, 1
  store i32 %283, ptr %26, align 4, !tbaa !9
  br label %259, !llvm.loop !41

284:                                              ; preds = %263
  br label %285

285:                                              ; preds = %284, %214
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #6
  ret void
}

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local ptr @_ZNKSt8valarrayIdEngEv(ptr noundef nonnull align 8 dereferenceable(16)) #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_ZNK3ipx5Model1cEi(ptr noundef nonnull align 8 dereferenceable(704), i32 noundef) #3 align 2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #5 = { 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 #6 = { nounwind }
attributes #7 = { noreturn 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, !13, i64 0}
!12 = !{!"_ZTSN3ipx5ModelE", !13, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !14, i64 24, !14, i64 152, !23, i64 280, !23, i64 296, !23, i64 312, !23, i64 328, !25, i64 344, !25, i64 352, !10, i64 360, !10, i64 364, !10, i64 368, !10, i64 372, !10, i64 376, !15, i64 384, !26, i64 408, !25, i64 432, !25, i64 440, !25, i64 448, !23, i64 456, !23, i64 472, !23, i64 488, !23, i64 504, !14, i64 520, !15, i64 648, !23, i64 672, !23, i64 688}
!13 = !{!"bool", !7, i64 0}
!14 = !{!"_ZTSN3ipx12SparseMatrixE", !10, i64 0, !15, i64 8, !15, i64 32, !19, i64 56, !15, i64 80, !19, i64 104}
!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 = !{!"_ZTSSt6vectorIdSaIdEE", !20, i64 0}
!20 = !{!"_ZTSSt12_Vector_baseIdSaIdEE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE12_Vector_implE", !22, i64 0}
!22 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!23 = !{!"_ZTSSt8valarrayIdE", !24, i64 0, !6, i64 8}
!24 = !{!"long", !7, i64 0}
!25 = !{!"double", !7, i64 0}
!26 = !{!"_ZTSSt6vectorIcSaIcEE", !27, i64 0}
!27 = !{!"_ZTSSt12_Vector_baseIcSaIcEE", !28, i64 0}
!28 = !{!"_ZTSNSt12_Vector_baseIcSaIcEE12_Vector_implE", !29, i64 0}
!29 = !{!"_ZTSNSt12_Vector_baseIcSaIcEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!30 = !{i8 0, i8 2}
!31 = !{}
!32 = !{!12, !10, i64 368}
!33 = !{!12, !10, i64 360}
!34 = !{!25, !25, i64 0}
!35 = distinct !{!35, !36}
!36 = !{!"llvm.loop.mustprogress"}
!37 = !{!24, !24, i64 0}
!38 = distinct !{!38, !36}
!39 = distinct !{!39, !36}
!40 = distinct !{!40, !36}
!41 = distinct !{!41, !36}


; 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::_Expr.17" = type { %"struct.std::__detail::_UnClos" }
%"struct.std::__detail::_UnClos" = type { %"class.std::__detail::_UnBase" }
%"class.std::__detail::_UnBase" = type { ptr }

@.str.18 = external hidden unnamed_addr constant [70 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [14 x i8], align 1
@__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_ = external hidden unnamed_addr constant [138 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [59 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [14 x i8], align 1

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK3ipx5Model4rowsEv(ptr noundef nonnull align 8 dereferenceable(704)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK3ipx5Model4colsEv(ptr noundef nonnull align 8 dereferenceable(704)) local_unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_(ptr noundef nonnull align 8 dereferenceable(704) %0, ptr noundef nonnull align 8 dereferenceable(16) %1, ptr noundef nonnull align 8 dereferenceable(16) %2, ptr noundef nonnull align 8 dereferenceable(16) %3, ptr noundef nonnull align 8 dereferenceable(16) %4, ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef nonnull align 8 dereferenceable(16) %6, ptr noundef nonnull align 8 dereferenceable(16) %7) local_unnamed_addr #5 align 2 {
  %9 = alloca %"class.std::_Expr.17", align 8
  %10 = tail call noundef i32 @_ZNK3ipx5Model4rowsEv(ptr noundef nonnull align 8 dereferenceable(704) %0)
  %11 = tail call noundef i32 @_ZNK3ipx5Model4colsEv(ptr noundef nonnull align 8 dereferenceable(704) %0)
  %12 = load i8, ptr %0, align 8, !tbaa !5, !range !28, !noundef !29
  %13 = trunc nuw i8 %12 to i1
  br i1 %13, label %14, label %101

14:                                               ; preds = %8
  %15 = getelementptr inbounds i8, ptr %0, i64 368
  %16 = load i32, ptr %15, align 8, !tbaa !30
  %17 = icmp eq i32 %16, %10
  br i1 %17, label %19, label %18

18:                                               ; preds = %14
  tail call void @__assert_fail(ptr noundef nonnull @.str.55, ptr noundef nonnull @.str.18, i32 noundef 1085, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_) #6
  unreachable

19:                                               ; preds = %14
  %20 = getelementptr inbounds i8, ptr %0, i64 360
  %21 = load i32, ptr %20, align 8, !tbaa !31
  %22 = sext i32 %21 to i64
  %23 = getelementptr inbounds i8, ptr %0, i64 384
  %24 = tail call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #7
  %25 = add i64 %24, %22
  %26 = sext i32 %11 to i64
  %27 = icmp eq i64 %25, %26
  br i1 %27, label %29, label %28

28:                                               ; preds = %19
  tail call void @__assert_fail(ptr noundef nonnull @.str.56, ptr noundef nonnull @.str.18, i32 noundef 1086, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_) #6
  unreachable

29:                                               ; preds = %19
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #7
  %30 = tail call ptr @_ZNKSt8valarrayIdEngEv(ptr noundef nonnull align 8 dereferenceable(16) %1)
  store ptr %30, ptr %9, align 8
  %31 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt8valarrayIdEaSINSt8__detail7_UnClosISt8__negateSt9_ValArraydEEEERS0_RKSt5_ExprIT_dE(ptr noundef nonnull align 8 dereferenceable(16) %6, ptr noundef nonnull align 8 dereferenceable(8) %9)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #7
  %32 = load i32, ptr %20, align 8, !tbaa !31
  %33 = icmp sgt i32 %32, 0
  br i1 %33, label %.lr.ph85, label %.preheader81

.preheader81:                                     ; preds = %.lr.ph85, %29
  %34 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #7
  %.not = icmp eq i64 %34, 0
  br i1 %.not, label %.preheader, label %.lr.ph87

.lr.ph85:                                         ; preds = %29, %.lr.ph85
  %indvars.iv96 = phi i64 [ %indvars.iv.next97, %.lr.ph85 ], [ 0, %29 ]
  %35 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %2, i64 noundef %indvars.iv96) #7
  %36 = load double, ptr %35, align 8, !tbaa !32
  %37 = fneg double %36
  %38 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %7, i64 noundef %indvars.iv96) #7
  store double %37, ptr %38, align 8, !tbaa !32
  %indvars.iv.next97 = add nuw nsw i64 %indvars.iv96, 1
  %39 = load i32, ptr %20, align 8, !tbaa !31
  %40 = sext i32 %39 to i64
  %41 = icmp slt i64 %indvars.iv.next97, %40
  br i1 %41, label %.lr.ph85, label %.preheader81, !llvm.loop !33

.preheader:                                       ; preds = %.lr.ph87, %.preheader81
  %42 = icmp sgt i32 %10, 0
  br i1 %42, label %.lr.ph89.preheader, label %._crit_edge

.lr.ph89.preheader:                               ; preds = %.preheader
  %wide.trip.count102 = zext nneg i32 %10 to i64
  br label %.lr.ph89

.lr.ph87:                                         ; preds = %.preheader81, %.lr.ph87
  %.07786 = phi i64 [ %57, %.lr.ph87 ], [ 0, %.preheader81 ]
  %43 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %.07786) #7
  %44 = load i32, ptr %43, align 4, !tbaa !35
  %45 = load i32, ptr %20, align 8, !tbaa !31
  %46 = trunc i64 %.07786 to i32
  %47 = add i32 %45, %46
  %48 = call noundef double @_ZNK3ipx5Model1cEi(ptr noundef nonnull align 8 dereferenceable(704) %0, i32 noundef %47)
  %49 = sext i32 %44 to i64
  %50 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %6, i64 noundef %49) #7
  %51 = load double, ptr %50, align 8, !tbaa !32
  %52 = fadd double %48, %51
  %53 = load i32, ptr %20, align 8, !tbaa !31
  %54 = sext i32 %53 to i64
  %55 = add i64 %.07786, %54
  %56 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %7, i64 noundef %55) #7
  store double %52, ptr %56, align 8, !tbaa !32
  %57 = add nuw i64 %.07786, 1
  %58 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #7
  %59 = icmp ult i64 %57, %58
  br i1 %59, label %.lr.ph87, label %.preheader, !llvm.loop !36

._crit_edge:                                      ; preds = %.lr.ph89, %.preheader
  %60 = call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %3) #7
  %61 = load i32, ptr %20, align 8, !tbaa !31
  %62 = call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %5) #7
  %63 = call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %60, i32 noundef %61, ptr noundef %62)
  %64 = call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %4) #7
  %65 = load i32, ptr %15, align 8, !tbaa !30
  %66 = call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %5) #7
  %67 = getelementptr inbounds double, ptr %66, i64 %26
  %68 = call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %64, i32 noundef %65, ptr noundef %67)
  %69 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #7
  %.not93 = icmp eq i64 %69, 0
  br i1 %.not93, label %.loopexit, label %.lr.ph92

.lr.ph89:                                         ; preds = %.lr.ph89.preheader, %.lr.ph89
  %indvars.iv99 = phi i64 [ 0, %.lr.ph89.preheader ], [ %indvars.iv.next100, %.lr.ph89 ]
  %70 = add nsw i64 %indvars.iv99, %26
  %71 = trunc nsw i64 %70 to i32
  %72 = call noundef double @_ZNK3ipx5Model1cEi(ptr noundef nonnull align 8 dereferenceable(704) %0, i32 noundef %71)
  %73 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %6, i64 noundef %indvars.iv99) #7
  %74 = load double, ptr %73, align 8, !tbaa !32
  %75 = fsub double %72, %74
  %76 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %7, i64 noundef %70) #7
  store double %75, ptr %76, align 8, !tbaa !32
  %indvars.iv.next100 = add nuw nsw i64 %indvars.iv99, 1
  %exitcond103.not = icmp eq i64 %indvars.iv.next100, %wide.trip.count102
  br i1 %exitcond103.not, label %._crit_edge, label %.lr.ph89, !llvm.loop !37

.lr.ph92:                                         ; preds = %._crit_edge, %96
  %.07590 = phi i64 [ %98, %96 ], [ 0, %._crit_edge ]
  %77 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %.07590) #7
  %78 = load i32, ptr %77, align 4, !tbaa !35
  %79 = add nsw i32 %78, %11
  %80 = sext i32 %79 to i64
  %81 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %5, i64 noundef %80) #7
  %82 = load double, ptr %81, align 8, !tbaa !32
  %83 = fcmp olt double %82, 0.000000e+00
  br i1 %83, label %84, label %92

84:                                               ; preds = %.lr.ph92
  %85 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %5, i64 noundef %80) #7
  %86 = load double, ptr %85, align 8, !tbaa !32
  %87 = fneg double %86
  %88 = load i32, ptr %20, align 8, !tbaa !31
  %89 = sext i32 %88 to i64
  %90 = add i64 %.07590, %89
  %91 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %5, i64 noundef %90) #7
  store double %87, ptr %91, align 8, !tbaa !32
  br label %96

92:                                               ; preds = %.lr.ph92
  %93 = load i32, ptr %20, align 8, !tbaa !31
  %94 = sext i32 %93 to i64
  %95 = add i64 %.07590, %94
  br label %96

96:                                               ; preds = %92, %84
  %.sink105 = phi i64 [ %95, %92 ], [ %80, %84 ]
  %97 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %5, i64 noundef %.sink105) #7
  store double 0.000000e+00, ptr %97, align 8, !tbaa !32
  %98 = add nuw i64 %.07590, 1
  %99 = call noundef i64 @_ZNKSt6vectorIiSaIiEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #7
  %100 = icmp ult i64 %98, %99
  br i1 %100, label %.lr.ph92, label %.loopexit, !llvm.loop !38

101:                                              ; preds = %8
  %102 = getelementptr inbounds i8, ptr %0, i64 360
  %103 = load i32, ptr %102, align 8, !tbaa !31
  %104 = icmp eq i32 %103, %10
  br i1 %104, label %106, label %105

105:                                              ; preds = %101
  tail call void @__assert_fail(ptr noundef nonnull @.str.57, ptr noundef nonnull @.str.18, i32 noundef 1114, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_) #6
  unreachable

106:                                              ; preds = %101
  %107 = getelementptr inbounds i8, ptr %0, i64 368
  %108 = load i32, ptr %107, align 8, !tbaa !30
  %109 = icmp eq i32 %108, %11
  br i1 %109, label %111, label %110

110:                                              ; preds = %106
  tail call void @__assert_fail(ptr noundef nonnull @.str.58, ptr noundef nonnull @.str.18, i32 noundef 1115, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK3ipx5Model20DualizeBasicSolutionERKSt8valarrayIdES4_S4_S4_RS2_S5_S5_) #6
  unreachable

111:                                              ; preds = %106
  %112 = tail call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %1) #7
  %113 = tail call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %5) #7
  %114 = tail call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %112, i32 noundef %11, ptr noundef %113)
  %115 = tail call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %2) #7
  %116 = tail call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %5) #7
  %117 = sext i32 %11 to i64
  %118 = getelementptr inbounds double, ptr %116, i64 %117
  %119 = tail call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %115, i32 noundef %10, ptr noundef %118)
  %120 = tail call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %3) #7
  %121 = tail call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %6) #7
  %122 = tail call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %120, i32 noundef %10, ptr noundef %121)
  %123 = tail call noundef ptr @_ZSt5beginIdEPKT_RKSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %4) #7
  %124 = tail call noundef ptr @_ZSt5beginIdEPT_RSt8valarrayIS0_E(ptr noundef nonnull align 8 dereferenceable(16) %7) #7
  %125 = tail call noundef ptr @_ZSt6copy_nIPKdiPdET1_T_T0_S3_(ptr noundef %123, i32 noundef %11, ptr noundef %124)
  %126 = icmp sgt i32 %10, 0
  br i1 %126, label %.lr.ph.preheader, label %.loopexit

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

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %127 = add nsw i64 %indvars.iv, %117
  %128 = trunc nsw i64 %127 to i32
  %129 = tail call noundef double @_ZNK3ipx5Model1cEi(ptr noundef nonnull align 8 dereferenceable(704) %0, i32 noundef %128)
  %130 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %6, i64 noundef %indvars.iv) #7
  %131 = load double, ptr %130, align 8, !tbaa !32
  %132 = fsub double %129, %131
  %133 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8valarrayIdEixEm(ptr noundef nonnull align 8 dereferenceable(16) %7, i64 noundef %127) #7
  store double %132, ptr %133, align 8, !tbaa !32
  %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 %.loopexit, label %.lr.ph, !llvm.loop !39

.loopexit:                                        ; preds = %.lr.ph, %96, %111, %._crit_edge
  ret void
}

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local ptr @_ZNKSt8valarrayIdEngEv(ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #4 align 2

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

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

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

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 0}
!6 = !{!"_ZTSN3ipx5ModelE", !7, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !11, i64 24, !11, i64 152, !21, i64 280, !21, i64 296, !21, i64 312, !21, i64 328, !23, i64 344, !23, i64 352, !10, i64 360, !10, i64 364, !10, i64 368, !10, i64 372, !10, i64 376, !12, i64 384, !24, i64 408, !23, i64 432, !23, i64 440, !23, i64 448, !21, i64 456, !21, i64 472, !21, i64 488, !21, i64 504, !11, i64 520, !12, i64 648, !21, i64 672, !21, i64 688}
!7 = !{!"bool", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"_ZTSN3ipx12SparseMatrixE", !10, i64 0, !12, i64 8, !12, i64 32, !17, i64 56, !12, i64 80, !17, i64 104}
!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", !16, i64 0, !16, i64 8, !16, i64 16}
!16 = !{!"any pointer", !8, i64 0}
!17 = !{!"_ZTSSt6vectorIdSaIdEE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseIdSaIdEE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE17_Vector_impl_dataE", !16, i64 0, !16, i64 8, !16, i64 16}
!21 = !{!"_ZTSSt8valarrayIdE", !22, i64 0, !16, i64 8}
!22 = !{!"long", !8, i64 0}
!23 = !{!"double", !8, i64 0}
!24 = !{!"_ZTSSt6vectorIcSaIcEE", !25, i64 0}
!25 = !{!"_ZTSSt12_Vector_baseIcSaIcEE", !26, i64 0}
!26 = !{!"_ZTSNSt12_Vector_baseIcSaIcEE12_Vector_implE", !27, i64 0}
!27 = !{!"_ZTSNSt12_Vector_baseIcSaIcEE17_Vector_impl_dataE", !16, i64 0, !16, i64 8, !16, i64 16}
!28 = !{i8 0, i8 2}
!29 = !{}
!30 = !{!6, !10, i64 368}
!31 = !{!6, !10, i64 360}
!32 = !{!23, !23, i64 0}
!33 = distinct !{!33, !34}
!34 = !{!"llvm.loop.mustprogress"}
!35 = !{!10, !10, i64 0}
!36 = distinct !{!36, !34}
!37 = distinct !{!37, !34}
!38 = distinct !{!38, !34}
!39 = distinct !{!39, !34}


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