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

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

@.str.52 = external hidden unnamed_addr constant [80 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.71 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.72 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.73 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.74 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.75 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.77 = external hidden unnamed_addr constant [21 x i8], align 1
@__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa = external hidden unnamed_addr constant [73 x i8], align 1
@.str.78 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.79 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.80 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.81 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.82 = external hidden unnamed_addr constant [13 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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIiSaIiEE6assignEmRKi(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef, ptr noundef nonnull align 4 dereferenceable(4)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK17HighsSparseMatrix9isColwiseEv(ptr noundef nonnull align 8 dereferenceable(112)) #2 align 2

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK17HighsSparseMatrix9isRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZNK17HighsSparseMatrix5numNzEv(ptr noundef nonnull align 8 dereferenceable(112)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK17HighsSparseMatrix8formatOkEv(ptr noundef nonnull align 8 dereferenceable(112)) #2 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) #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN17HighsSparseMatrix13ensureRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112)) #1 align 2

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN17HighsSparseMatrix7addRowsES_PKa(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef %1, ptr noundef %2) #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca i8, align 1
  %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 i32, align 4
  %21 = alloca %"class.std::vector", align 8
  %22 = alloca i32, align 4
  %23 = alloca %"class.std::vector", align 8
  %24 = alloca i32, align 4
  %25 = alloca ptr, align 8
  %26 = alloca i32, align 4
  %27 = alloca i32, align 4
  %28 = alloca i32, align 4
  %29 = alloca i32, align 4
  %30 = alloca i32, align 4
  %31 = alloca i32, align 4
  %32 = alloca i32, align 4
  %33 = alloca i32, align 4
  %34 = alloca i32, align 4
  %35 = alloca i32, align 4
  %36 = alloca i32, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  %37 = load ptr, ptr %4, align 8
  %38 = call noundef zeroext i1 @_ZNK17HighsSparseMatrix9isRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %1)
  br i1 %38, label %39, label %40

39:                                               ; preds = %3
  br label %42

40:                                               ; preds = %3
  call void @__assert_fail(ptr noundef @.str.77, ptr noundef @.str.52, i32 noundef 365, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

41:                                               ; No predecessors!
  br label %42

42:                                               ; preds = %41, %39
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  %43 = getelementptr inbounds %class.HighsSparseMatrix, ptr %1, i32 0, i32 2
  %44 = load i32, ptr %43, align 8, !tbaa !9
  store i32 %44, ptr %7, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  %45 = call noundef i32 @_ZNK17HighsSparseMatrix5numNzEv(ptr noundef nonnull align 8 dereferenceable(112) %1)
  store i32 %45, ptr %8, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %46 = getelementptr inbounds %class.HighsSparseMatrix, ptr %1, i32 0, i32 3
  store ptr %46, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %47 = getelementptr inbounds %class.HighsSparseMatrix, ptr %1, i32 0, i32 5
  store ptr %47, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  %48 = getelementptr inbounds %class.HighsSparseMatrix, ptr %1, i32 0, i32 6
  store ptr %48, ptr %11, align 8, !tbaa !5
  %49 = call noundef zeroext i1 @_ZNK17HighsSparseMatrix8formatOkEv(ptr noundef nonnull align 8 dereferenceable(112) %37)
  br i1 %49, label %50, label %51

50:                                               ; preds = %42
  br label %53

51:                                               ; preds = %42
  call void @__assert_fail(ptr noundef @.str.53, ptr noundef @.str.52, i32 noundef 372, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

52:                                               ; No predecessors!
  br label %53

53:                                               ; preds = %52, %50
  call void @llvm.lifetime.start.p0(i64 1, ptr %12) #5
  %54 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 0
  %55 = load i32, ptr %54, align 8, !tbaa !22
  %56 = icmp eq i32 %55, 3
  %57 = zext i1 %56 to i8
  store i8 %57, ptr %12, align 1, !tbaa !23
  %58 = load i8, ptr %12, align 1, !tbaa !23, !range !25, !noundef !26
  %59 = trunc i8 %58 to i1
  br i1 %59, label %60, label %61

60:                                               ; preds = %53
  call void @__assert_fail(ptr noundef @.str.78, ptr noundef @.str.52, i32 noundef 377, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

61:                                               ; preds = %53
  %62 = load i32, ptr %7, align 4, !tbaa !21
  %63 = icmp sge i32 %62, 0
  br i1 %63, label %64, label %65

64:                                               ; preds = %61
  br label %67

65:                                               ; preds = %61
  call void @__assert_fail(ptr noundef @.str.79, ptr noundef @.str.52, i32 noundef 380, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

66:                                               ; No predecessors!
  br label %67

67:                                               ; preds = %66, %64
  %68 = load i32, ptr %8, align 4, !tbaa !21
  %69 = icmp sge i32 %68, 0
  br i1 %69, label %70, label %71

70:                                               ; preds = %67
  br label %73

71:                                               ; preds = %67
  call void @__assert_fail(ptr noundef @.str.71, ptr noundef @.str.52, i32 noundef 381, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

72:                                               ; No predecessors!
  br label %73

73:                                               ; preds = %72, %70
  %74 = load i32, ptr %7, align 4, !tbaa !21
  %75 = icmp eq i32 %74, 0
  br i1 %75, label %76, label %83

76:                                               ; preds = %73
  %77 = load i32, ptr %8, align 4, !tbaa !21
  %78 = icmp eq i32 %77, 0
  br i1 %78, label %79, label %80

79:                                               ; preds = %76
  br label %82

80:                                               ; preds = %76
  call void @__assert_fail(ptr noundef @.str.72, ptr noundef @.str.52, i32 noundef 385, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

81:                                               ; No predecessors!
  br label %82

82:                                               ; preds = %81, %79
  store i32 1, ptr %13, align 4
  br label %446

83:                                               ; preds = %73
  %84 = load i32, ptr %8, align 4, !tbaa !21
  %85 = icmp ne i32 %84, 0
  br i1 %85, label %86, label %108

86:                                               ; preds = %83
  %87 = load ptr, ptr %9, align 8, !tbaa !5
  %88 = call noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %87) #5
  %89 = xor i1 %88, true
  br i1 %89, label %90, label %91

90:                                               ; preds = %86
  br label %93

91:                                               ; preds = %86
  call void @__assert_fail(ptr noundef @.str.73, ptr noundef @.str.52, i32 noundef 392, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

92:                                               ; No predecessors!
  br label %93

93:                                               ; preds = %92, %90
  %94 = load ptr, ptr %10, align 8, !tbaa !5
  %95 = call noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %94) #5
  %96 = xor i1 %95, true
  br i1 %96, label %97, label %98

97:                                               ; preds = %93
  br label %100

98:                                               ; preds = %93
  call void @__assert_fail(ptr noundef @.str.74, ptr noundef @.str.52, i32 noundef 393, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

99:                                               ; No predecessors!
  br label %100

100:                                              ; preds = %99, %97
  %101 = load ptr, ptr %11, align 8, !tbaa !5
  %102 = call noundef zeroext i1 @_ZNKSt6vectorIdSaIdEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %101) #5
  %103 = xor i1 %102, true
  br i1 %103, label %104, label %105

104:                                              ; preds = %100
  br label %107

105:                                              ; preds = %100
  call void @__assert_fail(ptr noundef @.str.75, ptr noundef @.str.52, i32 noundef 394, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

106:                                              ; No predecessors!
  br label %107

107:                                              ; preds = %106, %104
  br label %108

108:                                              ; preds = %107, %83
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  %109 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 1
  %110 = load i32, ptr %109, align 4, !tbaa !27
  store i32 %110, ptr %14, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %111 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 2
  %112 = load i32, ptr %111, align 8, !tbaa !9
  store i32 %112, ptr %15, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  %113 = call noundef i32 @_ZNK17HighsSparseMatrix5numNzEv(ptr noundef nonnull align 8 dereferenceable(112) %37)
  store i32 %113, ptr %16, align 4, !tbaa !21
  %114 = load i32, ptr %8, align 4, !tbaa !21
  %115 = icmp sle i32 %114, 0
  br i1 %115, label %119, label %116

116:                                              ; preds = %108
  %117 = load i32, ptr %14, align 4, !tbaa !21
  %118 = icmp sgt i32 %117, 0
  br label %119

119:                                              ; preds = %116, %108
  %120 = phi i1 [ true, %108 ], [ %118, %116 ]
  br i1 %120, label %121, label %122

121:                                              ; preds = %119
  br label %124

122:                                              ; preds = %119
  call void @__assert_fail(ptr noundef @.str.80, ptr noundef @.str.52, i32 noundef 400, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

123:                                              ; No predecessors!
  br label %124

124:                                              ; preds = %123, %121
  %125 = call noundef zeroext i1 @_ZNK17HighsSparseMatrix9isColwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %37)
  br i1 %125, label %126, label %132

126:                                              ; preds = %124
  %127 = load i32, ptr %8, align 4, !tbaa !21
  %128 = load i32, ptr %16, align 4, !tbaa !21
  %129 = icmp sgt i32 %127, %128
  br i1 %129, label %130, label %131

130:                                              ; preds = %126
  call void @_ZN17HighsSparseMatrix13ensureRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %37)
  br label %131

131:                                              ; preds = %130, %126
  br label %132

132:                                              ; preds = %131, %124
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #5
  %133 = load i32, ptr %16, align 4, !tbaa !21
  %134 = load i32, ptr %8, align 4, !tbaa !21
  %135 = add nsw i32 %133, %134
  store i32 %135, ptr %17, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  %136 = load i32, ptr %15, align 4, !tbaa !21
  %137 = load i32, ptr %7, align 4, !tbaa !21
  %138 = add nsw i32 %136, %137
  store i32 %138, ptr %18, align 4, !tbaa !21
  %139 = call noundef zeroext i1 @_ZNK17HighsSparseMatrix9isRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %37)
  br i1 %139, label %140, label %242

140:                                              ; preds = %132
  %141 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 3
  %142 = load i32, ptr %18, align 4, !tbaa !21
  %143 = add nsw i32 %142, 1
  %144 = sext i32 %143 to i64
  call void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %141, i64 noundef %144)
  %145 = load i32, ptr %8, align 4, !tbaa !21
  %146 = icmp ne i32 %145, 0
  br i1 %146, label %147, label %171

147:                                              ; preds = %140
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #5
  store i32 0, ptr %19, align 4, !tbaa !21
  br label %148

148:                                              ; preds = %167, %147
  %149 = load i32, ptr %19, align 4, !tbaa !21
  %150 = load i32, ptr %7, align 4, !tbaa !21
  %151 = icmp slt i32 %149, %150
  br i1 %151, label %153, label %152

152:                                              ; preds = %148
  store i32 2, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #5
  br label %170

153:                                              ; preds = %148
  %154 = load i32, ptr %16, align 4, !tbaa !21
  %155 = load ptr, ptr %9, align 8, !tbaa !5
  %156 = load i32, ptr %19, align 4, !tbaa !21
  %157 = sext i32 %156 to i64
  %158 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %155, i64 noundef %157) #5
  %159 = load i32, ptr %158, align 4, !tbaa !21
  %160 = add nsw i32 %154, %159
  %161 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 3
  %162 = load i32, ptr %15, align 4, !tbaa !21
  %163 = load i32, ptr %19, align 4, !tbaa !21
  %164 = add nsw i32 %162, %163
  %165 = sext i32 %164 to i64
  %166 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %161, i64 noundef %165) #5
  store i32 %160, ptr %166, align 4, !tbaa !21
  br label %167

167:                                              ; preds = %153
  %168 = load i32, ptr %19, align 4, !tbaa !21
  %169 = add nsw i32 %168, 1
  store i32 %169, ptr %19, align 4, !tbaa !21
  br label %148, !llvm.loop !28

170:                                              ; preds = %152
  br label %189

171:                                              ; preds = %140
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #5
  store i32 0, ptr %20, align 4, !tbaa !21
  br label %172

172:                                              ; preds = %185, %171
  %173 = load i32, ptr %20, align 4, !tbaa !21
  %174 = load i32, ptr %7, align 4, !tbaa !21
  %175 = icmp slt i32 %173, %174
  br i1 %175, label %177, label %176

176:                                              ; preds = %172
  store i32 5, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #5
  br label %188

177:                                              ; preds = %172
  %178 = load i32, ptr %16, align 4, !tbaa !21
  %179 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 3
  %180 = load i32, ptr %15, align 4, !tbaa !21
  %181 = load i32, ptr %20, align 4, !tbaa !21
  %182 = add nsw i32 %180, %181
  %183 = sext i32 %182 to i64
  %184 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %179, i64 noundef %183) #5
  store i32 %178, ptr %184, align 4, !tbaa !21
  br label %185

185:                                              ; preds = %177
  %186 = load i32, ptr %20, align 4, !tbaa !21
  %187 = add nsw i32 %186, 1
  store i32 %187, ptr %20, align 4, !tbaa !21
  br label %172, !llvm.loop !30

188:                                              ; preds = %176
  br label %189

189:                                              ; preds = %188, %170
  %190 = load i32, ptr %17, align 4, !tbaa !21
  %191 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 3
  %192 = load i32, ptr %18, align 4, !tbaa !21
  %193 = sext i32 %192 to i64
  %194 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %191, i64 noundef %193) #5
  store i32 %190, ptr %194, align 4, !tbaa !21
  %195 = load i32, ptr %8, align 4, !tbaa !21
  %196 = icmp sgt i32 %195, 0
  br i1 %196, label %197, label %241

197:                                              ; preds = %189
  %198 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 5
  %199 = load i32, ptr %17, align 4, !tbaa !21
  %200 = sext i32 %199 to i64
  call void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %198, i64 noundef %200)
  %201 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 6
  %202 = load i32, ptr %17, align 4, !tbaa !21
  %203 = sext i32 %202 to i64
  call void @_ZNSt6vectorIdSaIdEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %201, i64 noundef %203)
  %204 = load i8, ptr %12, align 1, !tbaa !23, !range !25, !noundef !26
  %205 = trunc i8 %204 to i1
  br i1 %205, label %206, label %207

206:                                              ; preds = %197
  call void @__assert_fail(ptr noundef @.str.78, ptr noundef @.str.52, i32 noundef 433, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

207:                                              ; preds = %197
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #5
  store i32 0, ptr %22, align 4, !tbaa !21
  br label %208

208:                                              ; preds = %236, %207
  %209 = load i32, ptr %22, align 4, !tbaa !21
  %210 = load i32, ptr %8, align 4, !tbaa !21
  %211 = icmp slt i32 %209, %210
  br i1 %211, label %213, label %212

212:                                              ; preds = %208
  store i32 8, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #5
  br label %239

213:                                              ; preds = %208
  %214 = load ptr, ptr %10, align 8, !tbaa !5
  %215 = load i32, ptr %22, align 4, !tbaa !21
  %216 = sext i32 %215 to i64
  %217 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %214, i64 noundef %216) #5
  %218 = load i32, ptr %217, align 4, !tbaa !21
  %219 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 5
  %220 = load i32, ptr %16, align 4, !tbaa !21
  %221 = load i32, ptr %22, align 4, !tbaa !21
  %222 = add nsw i32 %220, %221
  %223 = sext i32 %222 to i64
  %224 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %219, i64 noundef %223) #5
  store i32 %218, ptr %224, align 4, !tbaa !21
  %225 = load ptr, ptr %11, align 8, !tbaa !5
  %226 = load i32, ptr %22, align 4, !tbaa !21
  %227 = sext i32 %226 to i64
  %228 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %225, i64 noundef %227) #5
  %229 = load double, ptr %228, align 8, !tbaa !31
  %230 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 6
  %231 = load i32, ptr %16, align 4, !tbaa !21
  %232 = load i32, ptr %22, align 4, !tbaa !21
  %233 = add nsw i32 %231, %232
  %234 = sext i32 %233 to i64
  %235 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %230, i64 noundef %234) #5
  store double %229, ptr %235, align 8, !tbaa !31
  br label %236

236:                                              ; preds = %213
  %237 = load i32, ptr %22, align 4, !tbaa !21
  %238 = add nsw i32 %237, 1
  store i32 %238, ptr %22, align 4, !tbaa !21
  br label %208, !llvm.loop !33

239:                                              ; preds = %212
  br label %240

240:                                              ; preds = %239
  br label %241

241:                                              ; preds = %240, %189
  br label %441

242:                                              ; preds = %132
  %243 = call noundef zeroext i1 @_ZNK17HighsSparseMatrix9isColwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %37)
  br i1 %243, label %244, label %245

244:                                              ; preds = %242
  br label %247

245:                                              ; preds = %242
  call void @__assert_fail(ptr noundef @.str.81, ptr noundef @.str.52, i32 noundef 483, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

246:                                              ; No predecessors!
  br label %247

247:                                              ; preds = %246, %244
  %248 = load i32, ptr %8, align 4, !tbaa !21
  %249 = icmp ne i32 %248, 0
  br i1 %249, label %250, label %440

250:                                              ; preds = %247
  call void @llvm.lifetime.start.p0(i64 24, ptr %23) #5
  call void @_ZNSt6vectorIiSaIiEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #5
  %251 = load i32, ptr %14, align 4, !tbaa !21
  %252 = sext i32 %251 to i64
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #5
  store i32 0, ptr %24, align 4, !tbaa !21
  invoke void @_ZNSt6vectorIiSaIiEE6assignEmRKi(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %252, ptr noundef nonnull align 4 dereferenceable(4) %24)
          to label %253 unwind label %259

253:                                              ; preds = %250
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #5
  store i32 0, ptr %27, align 4, !tbaa !21
  br label %254

254:                                              ; preds = %273, %253
  %255 = load i32, ptr %27, align 4, !tbaa !21
  %256 = load i32, ptr %8, align 4, !tbaa !21
  %257 = icmp slt i32 %255, %256
  br i1 %257, label %263, label %258

258:                                              ; preds = %254
  store i32 11, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #5
  br label %276

259:                                              ; preds = %250
  %260 = landingpad { ptr, i32 }
          cleanup
  %261 = extractvalue { ptr, i32 } %260, 0
  store ptr %261, ptr %25, align 8
  %262 = extractvalue { ptr, i32 } %260, 1
  store i32 %262, ptr %26, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #5
  br label %439

263:                                              ; preds = %254
  %264 = load ptr, ptr %10, align 8, !tbaa !5
  %265 = load i32, ptr %27, align 4, !tbaa !21
  %266 = sext i32 %265 to i64
  %267 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %264, i64 noundef %266) #5
  %268 = load i32, ptr %267, align 4, !tbaa !21
  %269 = sext i32 %268 to i64
  %270 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %269) #5
  %271 = load i32, ptr %270, align 4, !tbaa !21
  %272 = add nsw i32 %271, 1
  store i32 %272, ptr %270, align 4, !tbaa !21
  br label %273

273:                                              ; preds = %263
  %274 = load i32, ptr %27, align 4, !tbaa !21
  %275 = add nsw i32 %274, 1
  store i32 %275, ptr %27, align 4, !tbaa !21
  br label %254, !llvm.loop !34

276:                                              ; preds = %258
  %277 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 5
  %278 = load i32, ptr %17, align 4, !tbaa !21
  %279 = sext i32 %278 to i64
  invoke void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %277, i64 noundef %279)
          to label %280 unwind label %292

280:                                              ; preds = %276
  %281 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 6
  %282 = load i32, ptr %17, align 4, !tbaa !21
  %283 = sext i32 %282 to i64
  invoke void @_ZNSt6vectorIdSaIdEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %281, i64 noundef %283)
          to label %284 unwind label %292

284:                                              ; preds = %280
  call void @llvm.lifetime.start.p0(i64 4, ptr %28) #5
  %285 = load i32, ptr %17, align 4, !tbaa !21
  store i32 %285, ptr %28, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #5
  %286 = load i32, ptr %14, align 4, !tbaa !21
  %287 = sub nsw i32 %286, 1
  store i32 %287, ptr %29, align 4, !tbaa !21
  br label %288

288:                                              ; preds = %351, %284
  %289 = load i32, ptr %29, align 4, !tbaa !21
  %290 = icmp sge i32 %289, 0
  br i1 %290, label %296, label %291

291:                                              ; preds = %288
  store i32 14, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #5
  br label %354

292:                                              ; preds = %280, %276
  %293 = landingpad { ptr, i32 }
          cleanup
  %294 = extractvalue { ptr, i32 } %293, 0
  store ptr %294, ptr %25, align 8
  %295 = extractvalue { ptr, i32 } %293, 1
  store i32 %295, ptr %26, align 4
  br label %439

296:                                              ; preds = %288
  call void @llvm.lifetime.start.p0(i64 4, ptr %30) #5
  %297 = load i32, ptr %28, align 4, !tbaa !21
  store i32 %297, ptr %30, align 4, !tbaa !21
  %298 = load i32, ptr %29, align 4, !tbaa !21
  %299 = sext i32 %298 to i64
  %300 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %299) #5
  %301 = load i32, ptr %300, align 4, !tbaa !21
  %302 = load i32, ptr %28, align 4, !tbaa !21
  %303 = sub nsw i32 %302, %301
  store i32 %303, ptr %28, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %31) #5
  %304 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 3
  %305 = load i32, ptr %29, align 4, !tbaa !21
  %306 = add nsw i32 %305, 1
  %307 = sext i32 %306 to i64
  %308 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %304, i64 noundef %307) #5
  %309 = load i32, ptr %308, align 4, !tbaa !21
  %310 = sub nsw i32 %309, 1
  store i32 %310, ptr %31, align 4, !tbaa !21
  br label %311

311:                                              ; preds = %341, %296
  %312 = load i32, ptr %31, align 4, !tbaa !21
  %313 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 3
  %314 = load i32, ptr %29, align 4, !tbaa !21
  %315 = sext i32 %314 to i64
  %316 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %313, i64 noundef %315) #5
  %317 = load i32, ptr %316, align 4, !tbaa !21
  %318 = icmp sge i32 %312, %317
  br i1 %318, label %320, label %319

319:                                              ; preds = %311
  store i32 17, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #5
  br label %344

320:                                              ; preds = %311
  %321 = load i32, ptr %28, align 4, !tbaa !21
  %322 = add nsw i32 %321, -1
  store i32 %322, ptr %28, align 4, !tbaa !21
  %323 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 5
  %324 = load i32, ptr %31, align 4, !tbaa !21
  %325 = sext i32 %324 to i64
  %326 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %323, i64 noundef %325) #5
  %327 = load i32, ptr %326, align 4, !tbaa !21
  %328 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 5
  %329 = load i32, ptr %28, align 4, !tbaa !21
  %330 = sext i32 %329 to i64
  %331 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %328, i64 noundef %330) #5
  store i32 %327, ptr %331, align 4, !tbaa !21
  %332 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 6
  %333 = load i32, ptr %31, align 4, !tbaa !21
  %334 = sext i32 %333 to i64
  %335 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %332, i64 noundef %334) #5
  %336 = load double, ptr %335, align 8, !tbaa !31
  %337 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 6
  %338 = load i32, ptr %28, align 4, !tbaa !21
  %339 = sext i32 %338 to i64
  %340 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %337, i64 noundef %339) #5
  store double %336, ptr %340, align 8, !tbaa !31
  br label %341

341:                                              ; preds = %320
  %342 = load i32, ptr %31, align 4, !tbaa !21
  %343 = add nsw i32 %342, -1
  store i32 %343, ptr %31, align 4, !tbaa !21
  br label %311, !llvm.loop !35

344:                                              ; preds = %319
  %345 = load i32, ptr %30, align 4, !tbaa !21
  %346 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 3
  %347 = load i32, ptr %29, align 4, !tbaa !21
  %348 = add nsw i32 %347, 1
  %349 = sext i32 %348 to i64
  %350 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %346, i64 noundef %349) #5
  store i32 %345, ptr %350, align 4, !tbaa !21
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #5
  br label %351

351:                                              ; preds = %344
  %352 = load i32, ptr %29, align 4, !tbaa !21
  %353 = add nsw i32 %352, -1
  store i32 %353, ptr %29, align 4, !tbaa !21
  br label %288, !llvm.loop !36

354:                                              ; preds = %291
  %355 = load i32, ptr %28, align 4, !tbaa !21
  %356 = icmp eq i32 %355, 0
  br i1 %356, label %357, label %358

357:                                              ; preds = %354
  br label %360

358:                                              ; preds = %354
  call void @__assert_fail(ptr noundef @.str.82, ptr noundef @.str.52, i32 noundef 507, ptr noundef @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #4
  unreachable

359:                                              ; No predecessors!
  br label %360

360:                                              ; preds = %359, %357
  call void @llvm.lifetime.start.p0(i64 4, ptr %32) #5
  store i32 0, ptr %32, align 4, !tbaa !21
  br label %361

361:                                              ; preds = %435, %360
  %362 = load i32, ptr %32, align 4, !tbaa !21
  %363 = load i32, ptr %7, align 4, !tbaa !21
  %364 = icmp slt i32 %362, %363
  br i1 %364, label %366, label %365

365:                                              ; preds = %361
  store i32 20, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %32) #5
  br label %438

366:                                              ; preds = %361
  call void @llvm.lifetime.start.p0(i64 4, ptr %33) #5
  %367 = load ptr, ptr %9, align 8, !tbaa !5
  %368 = load i32, ptr %32, align 4, !tbaa !21
  %369 = sext i32 %368 to i64
  %370 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %367, i64 noundef %369) #5
  %371 = load i32, ptr %370, align 4, !tbaa !21
  store i32 %371, ptr %33, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %34) #5
  %372 = load i32, ptr %32, align 4, !tbaa !21
  %373 = load i32, ptr %7, align 4, !tbaa !21
  %374 = sub nsw i32 %373, 1
  %375 = icmp slt i32 %372, %374
  br i1 %375, label %376, label %383

376:                                              ; preds = %366
  %377 = load ptr, ptr %9, align 8, !tbaa !5
  %378 = load i32, ptr %32, align 4, !tbaa !21
  %379 = add nsw i32 %378, 1
  %380 = sext i32 %379 to i64
  %381 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %377, i64 noundef %380) #5
  %382 = load i32, ptr %381, align 4, !tbaa !21
  br label %385

383:                                              ; preds = %366
  %384 = load i32, ptr %8, align 4, !tbaa !21
  br label %385

385:                                              ; preds = %383, %376
  %386 = phi i32 [ %382, %376 ], [ %384, %383 ]
  store i32 %386, ptr %34, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %35) #5
  %387 = load i32, ptr %33, align 4, !tbaa !21
  store i32 %387, ptr %35, align 4, !tbaa !21
  br label %388

388:                                              ; preds = %431, %385
  %389 = load i32, ptr %35, align 4, !tbaa !21
  %390 = load i32, ptr %34, align 4, !tbaa !21
  %391 = icmp slt i32 %389, %390
  br i1 %391, label %393, label %392

392:                                              ; preds = %388
  store i32 23, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %35) #5
  br label %434

393:                                              ; preds = %388
  call void @llvm.lifetime.start.p0(i64 4, ptr %36) #5
  %394 = load ptr, ptr %10, align 8, !tbaa !5
  %395 = load i32, ptr %35, align 4, !tbaa !21
  %396 = sext i32 %395 to i64
  %397 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %394, i64 noundef %396) #5
  %398 = load i32, ptr %397, align 4, !tbaa !21
  store i32 %398, ptr %36, align 4, !tbaa !21
  %399 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 3
  %400 = load i32, ptr %36, align 4, !tbaa !21
  %401 = add nsw i32 %400, 1
  %402 = sext i32 %401 to i64
  %403 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %399, i64 noundef %402) #5
  %404 = load i32, ptr %403, align 4, !tbaa !21
  %405 = load i32, ptr %36, align 4, !tbaa !21
  %406 = sext i32 %405 to i64
  %407 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %406) #5
  %408 = load i32, ptr %407, align 4, !tbaa !21
  %409 = sub nsw i32 %404, %408
  store i32 %409, ptr %28, align 4, !tbaa !21
  %410 = load i32, ptr %36, align 4, !tbaa !21
  %411 = sext i32 %410 to i64
  %412 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %23, i64 noundef %411) #5
  %413 = load i32, ptr %412, align 4, !tbaa !21
  %414 = add nsw i32 %413, -1
  store i32 %414, ptr %412, align 4, !tbaa !21
  %415 = load i32, ptr %15, align 4, !tbaa !21
  %416 = load i32, ptr %32, align 4, !tbaa !21
  %417 = add nsw i32 %415, %416
  %418 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 5
  %419 = load i32, ptr %28, align 4, !tbaa !21
  %420 = sext i32 %419 to i64
  %421 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %418, i64 noundef %420) #5
  store i32 %417, ptr %421, align 4, !tbaa !21
  %422 = load ptr, ptr %11, align 8, !tbaa !5
  %423 = load i32, ptr %35, align 4, !tbaa !21
  %424 = sext i32 %423 to i64
  %425 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %422, i64 noundef %424) #5
  %426 = load double, ptr %425, align 8, !tbaa !31
  %427 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 6
  %428 = load i32, ptr %28, align 4, !tbaa !21
  %429 = sext i32 %428 to i64
  %430 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %427, i64 noundef %429) #5
  store double %426, ptr %430, align 8, !tbaa !31
  call void @llvm.lifetime.end.p0(i64 4, ptr %36) #5
  br label %431

431:                                              ; preds = %393
  %432 = load i32, ptr %35, align 4, !tbaa !21
  %433 = add nsw i32 %432, 1
  store i32 %433, ptr %35, align 4, !tbaa !21
  br label %388, !llvm.loop !37

434:                                              ; preds = %392
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %33) #5
  br label %435

435:                                              ; preds = %434
  %436 = load i32, ptr %32, align 4, !tbaa !21
  %437 = add nsw i32 %436, 1
  store i32 %437, ptr %32, align 4, !tbaa !21
  br label %361, !llvm.loop !38

438:                                              ; preds = %365
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #5
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #5
  br label %440

439:                                              ; preds = %292, %259
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  br label %449

440:                                              ; preds = %438, %247
  br label %441

441:                                              ; preds = %440, %241
  %442 = load i32, ptr %7, align 4, !tbaa !21
  %443 = getelementptr inbounds %class.HighsSparseMatrix, ptr %37, i32 0, i32 2
  %444 = load i32, ptr %443, align 8, !tbaa !9
  %445 = add nsw i32 %444, %442
  store i32 %445, ptr %443, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  store i32 0, ptr %13, align 4
  br label %446

446:                                              ; preds = %441, %82
  call void @llvm.lifetime.end.p0(i64 1, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  %447 = load i32, ptr %13, align 4
  switch i32 %447, label %454 [
    i32 0, label %448
    i32 1, label %448
  ]

448:                                              ; preds = %446, %446
  ret void

449:                                              ; preds = %439
  %450 = load ptr, ptr %25, align 8
  %451 = load i32, ptr %26, align 4
  %452 = insertvalue { ptr, i32 } poison, ptr %450, 0
  %453 = insertvalue { ptr, i32 } %452, i32 %451, 1
  resume { ptr, i32 } %453

454:                                              ; preds = %446
  unreachable
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 = { 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 #4 = { noreturn nounwind }
attributes #5 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !12, i64 8}
!10 = !{!"_ZTS17HighsSparseMatrix", !11, i64 0, !12, i64 4, !12, i64 8, !13, i64 16, !13, i64 40, !13, i64 64, !17, i64 88}
!11 = !{!"_ZTS12MatrixFormat", !7, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!"_ZTSSt6vectorIiSaIiEE", !14, i64 0}
!14 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !15, i64 0}
!15 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !16, i64 0}
!16 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!17 = !{!"_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", !6, i64 0, !6, i64 8, !6, i64 16}
!21 = !{!12, !12, i64 0}
!22 = !{!10, !11, i64 0}
!23 = !{!24, !24, i64 0}
!24 = !{!"bool", !7, i64 0}
!25 = !{i8 0, i8 2}
!26 = !{}
!27 = !{!10, !12, i64 4}
!28 = distinct !{!28, !29}
!29 = !{!"llvm.loop.mustprogress"}
!30 = distinct !{!30, !29}
!31 = !{!32, !32, i64 0}
!32 = !{!"double", !7, i64 0}
!33 = distinct !{!33, !29}
!34 = distinct !{!34, !29}
!35 = distinct !{!35, !29}
!36 = distinct !{!36, !29}
!37 = distinct !{!37, !29}
!38 = distinct !{!38, !29}


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

@.str.52 = external hidden unnamed_addr constant [80 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.71 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.72 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.73 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.74 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.75 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.77 = external hidden unnamed_addr constant [21 x i8], align 1
@__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa = external hidden unnamed_addr constant [73 x i8], align 1
@.str.78 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.79 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.80 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.81 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.82 = external hidden unnamed_addr constant [13 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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK17HighsSparseMatrix9isColwiseEv(ptr noundef nonnull align 8 dereferenceable(112)) local_unnamed_addr #2 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIdSaIdEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK17HighsSparseMatrix9isRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZNK17HighsSparseMatrix5numNzEv(ptr noundef nonnull align 8 dereferenceable(112)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK17HighsSparseMatrix8formatOkEv(ptr noundef nonnull align 8 dereferenceable(112)) local_unnamed_addr #2 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 #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN17HighsSparseMatrix13ensureRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112)) local_unnamed_addr #1 align 2

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN17HighsSparseMatrix7addRowsES_PKa(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull %1, ptr nocapture noundef readnone %2) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.std::vector", align 8
  %5 = alloca i32, align 4
  %6 = tail call noundef zeroext i1 @_ZNK17HighsSparseMatrix9isRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %1)
  br i1 %6, label %8, label %7

7:                                                ; preds = %3
  tail call void @__assert_fail(ptr noundef nonnull @.str.77, ptr noundef nonnull @.str.52, i32 noundef 365, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

8:                                                ; preds = %3
  %9 = getelementptr inbounds i8, ptr %1, i64 8
  %10 = load i32, ptr %9, align 8, !tbaa !5
  %11 = tail call noundef i32 @_ZNK17HighsSparseMatrix5numNzEv(ptr noundef nonnull align 8 dereferenceable(112) %1)
  %12 = getelementptr inbounds i8, ptr %1, i64 16
  %13 = getelementptr inbounds i8, ptr %1, i64 64
  %14 = getelementptr inbounds i8, ptr %1, i64 88
  %15 = tail call noundef zeroext i1 @_ZNK17HighsSparseMatrix8formatOkEv(ptr noundef nonnull align 8 dereferenceable(112) %0)
  br i1 %15, label %17, label %16

16:                                               ; preds = %8
  tail call void @__assert_fail(ptr noundef nonnull @.str.53, ptr noundef nonnull @.str.52, i32 noundef 372, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

17:                                               ; preds = %8
  %18 = load i32, ptr %0, align 8, !tbaa !20
  %19 = icmp eq i32 %18, 3
  br i1 %19, label %20, label %21

20:                                               ; preds = %17
  tail call void @__assert_fail(ptr noundef nonnull @.str.78, ptr noundef nonnull @.str.52, i32 noundef 377, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

21:                                               ; preds = %17
  %22 = icmp sgt i32 %10, -1
  br i1 %22, label %24, label %23

23:                                               ; preds = %21
  tail call void @__assert_fail(ptr noundef nonnull @.str.79, ptr noundef nonnull @.str.52, i32 noundef 380, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

24:                                               ; preds = %21
  %25 = icmp sgt i32 %11, -1
  br i1 %25, label %27, label %26

26:                                               ; preds = %24
  tail call void @__assert_fail(ptr noundef nonnull @.str.71, ptr noundef nonnull @.str.52, i32 noundef 381, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

27:                                               ; preds = %24
  %28 = icmp eq i32 %10, 0
  %29 = icmp eq i32 %11, 0
  br i1 %28, label %30, label %32

30:                                               ; preds = %27
  br i1 %29, label %169, label %31

31:                                               ; preds = %30
  tail call void @__assert_fail(ptr noundef nonnull @.str.72, ptr noundef nonnull @.str.52, i32 noundef 385, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

32:                                               ; preds = %27
  br i1 %29, label %42, label %33

33:                                               ; preds = %32
  %34 = tail call noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #6
  br i1 %34, label %35, label %36

35:                                               ; preds = %33
  tail call void @__assert_fail(ptr noundef nonnull @.str.73, ptr noundef nonnull @.str.52, i32 noundef 392, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

36:                                               ; preds = %33
  %37 = tail call noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #6
  br i1 %37, label %38, label %39

38:                                               ; preds = %36
  tail call void @__assert_fail(ptr noundef nonnull @.str.74, ptr noundef nonnull @.str.52, i32 noundef 393, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

39:                                               ; preds = %36
  %40 = tail call noundef zeroext i1 @_ZNKSt6vectorIdSaIdEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %14) #6
  br i1 %40, label %41, label %42

41:                                               ; preds = %39
  tail call void @__assert_fail(ptr noundef nonnull @.str.75, ptr noundef nonnull @.str.52, i32 noundef 394, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

42:                                               ; preds = %39, %32
  %43 = getelementptr inbounds i8, ptr %0, i64 4
  %44 = load i32, ptr %43, align 4, !tbaa !21
  %45 = getelementptr inbounds i8, ptr %0, i64 8
  %46 = load i32, ptr %45, align 8, !tbaa !5
  %47 = tail call noundef i32 @_ZNK17HighsSparseMatrix5numNzEv(ptr noundef nonnull align 8 dereferenceable(112) %0)
  %48 = icmp sgt i32 %44, 0
  %49 = select i1 %29, i1 true, i1 %48
  br i1 %49, label %51, label %50

50:                                               ; preds = %42
  tail call void @__assert_fail(ptr noundef nonnull @.str.80, ptr noundef nonnull @.str.52, i32 noundef 400, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

51:                                               ; preds = %42
  %52 = tail call noundef zeroext i1 @_ZNK17HighsSparseMatrix9isColwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %0)
  %53 = icmp sgt i32 %11, %47
  %or.cond = and i1 %53, %52
  br i1 %or.cond, label %54, label %55

54:                                               ; preds = %51
  tail call void @_ZN17HighsSparseMatrix13ensureRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %0)
  br label %55

55:                                               ; preds = %54, %51
  %56 = add nsw i32 %47, %11
  %57 = add nsw i32 %46, %10
  %58 = tail call noundef zeroext i1 @_ZNK17HighsSparseMatrix9isRowwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %0)
  br i1 %58, label %59, label %84

59:                                               ; preds = %55
  %60 = getelementptr inbounds i8, ptr %0, i64 16
  %61 = add nsw i32 %57, 1
  %62 = sext i32 %61 to i64
  tail call void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %60, i64 noundef %62)
  %63 = sext i32 %46 to i64
  %wide.trip.count187 = zext nneg i32 %10 to i64
  br i1 %29, label %.lr.ph151, label %.lr.ph149

.lr.ph149:                                        ; preds = %59, %.lr.ph149
  %indvars.iv177 = phi i64 [ %indvars.iv.next178, %.lr.ph149 ], [ 0, %59 ]
  %64 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %indvars.iv177) #6
  %65 = load i32, ptr %64, align 4, !tbaa !22
  %66 = add nsw i32 %65, %47
  %67 = add nsw i64 %indvars.iv177, %63
  %68 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %60, i64 noundef %67) #6
  store i32 %66, ptr %68, align 4, !tbaa !22
  %indvars.iv.next178 = add nuw nsw i64 %indvars.iv177, 1
  %exitcond182.not = icmp eq i64 %indvars.iv.next178, %wide.trip.count187
  br i1 %exitcond182.not, label %.loopexit122, label %.lr.ph149, !llvm.loop !23

.lr.ph151:                                        ; preds = %59, %.lr.ph151
  %indvars.iv183 = phi i64 [ %indvars.iv.next184, %.lr.ph151 ], [ 0, %59 ]
  %69 = add nsw i64 %indvars.iv183, %63
  %70 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %60, i64 noundef %69) #6
  store i32 %47, ptr %70, align 4, !tbaa !22
  %indvars.iv.next184 = add nuw nsw i64 %indvars.iv183, 1
  %exitcond188.not = icmp eq i64 %indvars.iv.next184, %wide.trip.count187
  br i1 %exitcond188.not, label %.loopexit122, label %.lr.ph151, !llvm.loop !25

.loopexit122:                                     ; preds = %.lr.ph149, %.lr.ph151
  %71 = sext i32 %57 to i64
  %72 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %60, i64 noundef %71) #6
  store i32 %56, ptr %72, align 4, !tbaa !22
  br i1 %29, label %.loopexit, label %.lr.ph154.preheader

.lr.ph154.preheader:                              ; preds = %.loopexit122
  %73 = getelementptr inbounds i8, ptr %0, i64 64
  %74 = sext i32 %56 to i64
  tail call void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %73, i64 noundef %74)
  %75 = getelementptr inbounds i8, ptr %0, i64 88
  tail call void @_ZNSt6vectorIdSaIdEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %75, i64 noundef %74)
  %76 = sext i32 %47 to i64
  %smax192 = tail call i32 @llvm.smax.i32(i32 %11, i32 1)
  %wide.trip.count193 = zext nneg i32 %smax192 to i64
  br label %.lr.ph154

.lr.ph154:                                        ; preds = %.lr.ph154.preheader, %.lr.ph154
  %indvars.iv189 = phi i64 [ 0, %.lr.ph154.preheader ], [ %indvars.iv.next190, %.lr.ph154 ]
  %77 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef %indvars.iv189) #6
  %78 = load i32, ptr %77, align 4, !tbaa !22
  %79 = add nsw i64 %indvars.iv189, %76
  %80 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %73, i64 noundef %79) #6
  store i32 %78, ptr %80, align 4, !tbaa !22
  %81 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %14, i64 noundef %indvars.iv189) #6
  %82 = load double, ptr %81, align 8, !tbaa !26
  %83 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %75, i64 noundef %79) #6
  store double %82, ptr %83, align 8, !tbaa !26
  %indvars.iv.next190 = add nuw nsw i64 %indvars.iv189, 1
  %exitcond194.not = icmp eq i64 %indvars.iv.next190, %wide.trip.count193
  br i1 %exitcond194.not, label %.loopexit, label %.lr.ph154, !llvm.loop !28

84:                                               ; preds = %55
  %85 = tail call noundef zeroext i1 @_ZNK17HighsSparseMatrix9isColwiseEv(ptr noundef nonnull align 8 dereferenceable(112) %0)
  br i1 %85, label %87, label %86

86:                                               ; preds = %84
  tail call void @__assert_fail(ptr noundef nonnull @.str.81, ptr noundef nonnull @.str.52, i32 noundef 483, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

87:                                               ; preds = %84
  br i1 %29, label %.loopexit, label %88

88:                                               ; preds = %87
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #6
  call void @_ZNSt6vectorIiSaIiEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  %89 = sext i32 %44 to i64
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #6
  store i32 0, ptr %5, align 4, !tbaa !22
  invoke void @_ZNSt6vectorIiSaIiEE6assignEmRKi(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %89, ptr noundef nonnull align 4 dereferenceable(4) %5)
          to label %.lr.ph.preheader unwind label %92

.lr.ph.preheader:                                 ; preds = %88
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #6
  %wide.trip.count = zext nneg i32 %11 to i64
  br label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph
  %90 = getelementptr inbounds i8, ptr %0, i64 64
  %91 = sext i32 %56 to i64
  invoke void @_ZNSt6vectorIiSaIiEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %90, i64 noundef %91)
          to label %100 unwind label %108

92:                                               ; preds = %88
  %93 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #6
  br label %166

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %94 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef %indvars.iv) #6
  %95 = load i32, ptr %94, align 4, !tbaa !22
  %96 = sext i32 %95 to i64
  %97 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %96) #6
  %98 = load i32, ptr %97, align 4, !tbaa !22
  %99 = add nsw i32 %98, 1
  store i32 %99, ptr %97, align 4, !tbaa !22
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !29

100:                                              ; preds = %._crit_edge
  %101 = getelementptr inbounds i8, ptr %0, i64 88
  invoke void @_ZNSt6vectorIdSaIdEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %101, i64 noundef %91)
          to label %.preheader126 unwind label %108

.preheader126:                                    ; preds = %100
  br i1 %48, label %.lr.ph138, label %._crit_edge139

.lr.ph138:                                        ; preds = %.preheader126
  %102 = getelementptr inbounds i8, ptr %0, i64 16
  %103 = zext nneg i32 %44 to i64
  br label %110

._crit_edge139:                                   ; preds = %._crit_edge133, %.preheader126
  %.0112.lcssa = phi i32 [ %56, %.preheader126 ], [ %.1.lcssa, %._crit_edge133 ]
  %104 = icmp eq i32 %.0112.lcssa, 0
  br i1 %104, label %.lr.ph146, label %132

.lr.ph146:                                        ; preds = %._crit_edge139
  %105 = add nsw i32 %10, -1
  %106 = getelementptr inbounds i8, ptr %0, i64 16
  %107 = sext i32 %105 to i64
  %smax174 = call i32 @llvm.smax.i32(i32 %10, i32 1)
  %wide.trip.count175 = zext nneg i32 %smax174 to i64
  br label %133

108:                                              ; preds = %100, %._crit_edge
  %109 = landingpad { ptr, i32 }
          cleanup
  br label %166

110:                                              ; preds = %.lr.ph138, %._crit_edge133
  %indvars.iv164 = phi i64 [ %103, %.lr.ph138 ], [ %indvars.iv.next165, %._crit_edge133 ]
  %.0112135 = phi i32 [ %56, %.lr.ph138 ], [ %.1.lcssa, %._crit_edge133 ]
  %indvars.iv.next165 = add nsw i64 %indvars.iv164, -1
  %111 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %indvars.iv.next165) #6
  %112 = load i32, ptr %111, align 4, !tbaa !22
  %113 = sub i32 %.0112135, %112
  %114 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %102, i64 noundef %indvars.iv164) #6
  %115 = load i32, ptr %114, align 4, !tbaa !22
  %116 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %102, i64 noundef %indvars.iv.next165) #6
  %117 = load i32, ptr %116, align 4, !tbaa !22
  %.not120.not128 = icmp sgt i32 %115, %117
  br i1 %.not120.not128, label %.lr.ph132.preheader, label %._crit_edge133

.lr.ph132.preheader:                              ; preds = %110
  %118 = sext i32 %115 to i64
  %119 = sext i32 %113 to i64
  br label %.lr.ph132

._crit_edge133.loopexit:                          ; preds = %.lr.ph132
  %120 = trunc nsw i64 %indvars.iv.next160 to i32
  br label %._crit_edge133

._crit_edge133:                                   ; preds = %._crit_edge133.loopexit, %110
  %.1.lcssa = phi i32 [ %113, %110 ], [ %120, %._crit_edge133.loopexit ]
  %121 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %102, i64 noundef %indvars.iv164) #6
  store i32 %.0112135, ptr %121, align 4, !tbaa !22
  %122 = icmp sgt i64 %indvars.iv164, 1
  br i1 %122, label %110, label %._crit_edge139, !llvm.loop !30

.lr.ph132:                                        ; preds = %.lr.ph132.preheader, %.lr.ph132
  %indvars.iv159 = phi i64 [ %119, %.lr.ph132.preheader ], [ %indvars.iv.next160, %.lr.ph132 ]
  %indvars.iv157 = phi i64 [ %118, %.lr.ph132.preheader ], [ %indvars.iv.next158, %.lr.ph132 ]
  %indvars.iv.next158 = add nsw i64 %indvars.iv157, -1
  %indvars.iv.next160 = add nsw i64 %indvars.iv159, -1
  %123 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %90, i64 noundef %indvars.iv.next158) #6
  %124 = load i32, ptr %123, align 4, !tbaa !22
  %125 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %90, i64 noundef %indvars.iv.next160) #6
  store i32 %124, ptr %125, align 4, !tbaa !22
  %126 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %101, i64 noundef %indvars.iv.next158) #6
  %127 = load double, ptr %126, align 8, !tbaa !26
  %128 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %101, i64 noundef %indvars.iv.next160) #6
  store double %127, ptr %128, align 8, !tbaa !26
  %129 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %102, i64 noundef %indvars.iv.next165) #6
  %130 = load i32, ptr %129, align 4, !tbaa !22
  %131 = sext i32 %130 to i64
  %.not120.not = icmp sgt i64 %indvars.iv.next158, %131
  br i1 %.not120.not, label %.lr.ph132, label %._crit_edge133.loopexit, !llvm.loop !31

132:                                              ; preds = %._crit_edge139
  call void @__assert_fail(ptr noundef nonnull @.str.82, ptr noundef nonnull @.str.52, i32 noundef 507, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN17HighsSparseMatrix7addRowsES_PKa) #5
  unreachable

._crit_edge147:                                   ; preds = %._crit_edge144
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #6
  br label %.loopexit

133:                                              ; preds = %.lr.ph146, %._crit_edge144
  %indvars.iv171 = phi i64 [ 0, %.lr.ph146 ], [ %indvars.iv.next172, %._crit_edge144 ]
  %134 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %indvars.iv171) #6
  %135 = load i32, ptr %134, align 4, !tbaa !22
  %136 = icmp slt i64 %indvars.iv171, %107
  br i1 %136, label %137, label %141

137:                                              ; preds = %133
  %138 = add nuw nsw i64 %indvars.iv171, 1
  %139 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %12, i64 noundef %138) #6
  %140 = load i32, ptr %139, align 4, !tbaa !22
  br label %141

141:                                              ; preds = %133, %137
  %142 = phi i32 [ %140, %137 ], [ %11, %133 ]
  %143 = icmp slt i32 %135, %142
  br i1 %143, label %.lr.ph143, label %._crit_edge144

.lr.ph143:                                        ; preds = %141
  %144 = sext i32 %135 to i64
  %145 = trunc i64 %indvars.iv171 to i32
  %146 = add i32 %46, %145
  br label %147

._crit_edge144:                                   ; preds = %147, %141
  %indvars.iv.next172 = add nuw nsw i64 %indvars.iv171, 1
  %exitcond176.not = icmp eq i64 %indvars.iv.next172, %wide.trip.count175
  br i1 %exitcond176.not, label %._crit_edge147, label %133, !llvm.loop !32

147:                                              ; preds = %.lr.ph143, %147
  %indvars.iv167 = phi i64 [ %144, %.lr.ph143 ], [ %indvars.iv.next168, %147 ]
  %148 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %13, i64 noundef %indvars.iv167) #6
  %149 = load i32, ptr %148, align 4, !tbaa !22
  %150 = add nsw i32 %149, 1
  %151 = sext i32 %150 to i64
  %152 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %106, i64 noundef %151) #6
  %153 = load i32, ptr %152, align 4, !tbaa !22
  %154 = sext i32 %149 to i64
  %155 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %154) #6
  %156 = load i32, ptr %155, align 4, !tbaa !22
  %157 = sub nsw i32 %153, %156
  %158 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %154) #6
  %159 = load i32, ptr %158, align 4, !tbaa !22
  %160 = add nsw i32 %159, -1
  store i32 %160, ptr %158, align 4, !tbaa !22
  %161 = sext i32 %157 to i64
  %162 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %90, i64 noundef %161) #6
  store i32 %146, ptr %162, align 4, !tbaa !22
  %163 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %14, i64 noundef %indvars.iv167) #6
  %164 = load double, ptr %163, align 8, !tbaa !26
  %165 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %101, i64 noundef %161) #6
  store double %164, ptr %165, align 8, !tbaa !26
  %indvars.iv.next168 = add nsw i64 %indvars.iv167, 1
  %lftr.wideiv = trunc i64 %indvars.iv.next168 to i32
  %exitcond170.not = icmp eq i32 %142, %lftr.wideiv
  br i1 %exitcond170.not, label %._crit_edge144, label %147, !llvm.loop !33

166:                                              ; preds = %108, %92
  %.pn = phi { ptr, i32 } [ %109, %108 ], [ %93, %92 ]
  call void @_ZNSt6vectorIiSaIiEED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #6
  resume { ptr, i32 } %.pn

.loopexit:                                        ; preds = %.lr.ph154, %87, %._crit_edge147, %.loopexit122
  %167 = load i32, ptr %45, align 8, !tbaa !5
  %168 = add nsw i32 %167, %10
  store i32 %168, ptr %45, align 8, !tbaa !5
  br label %169

169:                                              ; preds = %30, %.loopexit
  ret void
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.smax.i32(i32, i32) #4

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 = { 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 #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { noreturn nounwind }
attributes #6 = { 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, !10, i64 8}
!6 = !{!"_ZTS17HighsSparseMatrix", !7, i64 0, !10, i64 4, !10, i64 8, !11, i64 16, !11, i64 40, !11, i64 64, !16, i64 88}
!7 = !{!"_ZTS12MatrixFormat", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"_ZTSSt6vectorIiSaIiEE", !12, i64 0}
!12 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !13, i64 0}
!13 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !14, i64 0}
!14 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!15 = !{!"any pointer", !8, i64 0}
!16 = !{!"_ZTSSt6vectorIdSaIdEE", !17, i64 0}
!17 = !{!"_ZTSSt12_Vector_baseIdSaIdEE", !18, i64 0}
!18 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE12_Vector_implE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseIdSaIdEE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!20 = !{!6, !7, i64 0}
!21 = !{!6, !10, i64 4}
!22 = !{!10, !10, i64 0}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}
!25 = distinct !{!25, !24}
!26 = !{!27, !27, i64 0}
!27 = !{!"double", !8, i64 0}
!28 = distinct !{!28, !24}
!29 = distinct !{!29, !24}
!30 = distinct !{!30, !24}
!31 = distinct !{!31, !24}
!32 = distinct !{!32, !24}
!33 = distinct !{!33, !24}


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