; LLVM IR from Tencent-RoboticsX/jbdl :: src/jbdl/experimental/qpoases/src (Matrices)

; 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.qpOASES::Indexlist" = type <{ ptr, ptr, i32, i32, i32, i32, i32, [4 x i8] }>
%"class.qpOASES::SparseMatrix" = type { ptr, i32, i32, ptr, ptr, ptr, ptr, %"class.qpOASES::Matrix.base" }
%"class.qpOASES::Matrix.base" = type <{ ptr, i32 }>

; 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: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) #1

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN7qpOASES7isEqualEddd(double noundef, double noundef, double noundef) #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN7qpOASES6isZeroEdd(double noundef, double noundef) #4

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZNK7qpOASES12SparseMatrix10transTimesEPKNS_9IndexlistES3_idPKdidPdi(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef %1, ptr noundef %2, i32 noundef %3, double noundef %4, ptr noundef %5, i32 noundef %6, double noundef %7, ptr noundef %8, i32 noundef %9) unnamed_addr #5 align 2 {
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca double, align 8
  %17 = alloca ptr, align 8
  %18 = alloca i32, align 4
  %19 = alloca double, align 8
  %20 = alloca ptr, align 8
  %21 = alloca i32, align 4
  %22 = alloca i64, align 8
  %23 = alloca i64, align 8
  %24 = alloca i64, align 8
  %25 = alloca i64, align 8
  %26 = alloca i64, align 8
  %27 = alloca double, align 8
  %28 = alloca i32, align 4
  %29 = alloca i32, align 4
  %30 = alloca ptr, align 8
  store ptr %0, ptr %12, align 8, !tbaa !5
  store ptr %1, ptr %13, align 8, !tbaa !5
  store ptr %2, ptr %14, align 8, !tbaa !5
  store i32 %3, ptr %15, align 4, !tbaa !9
  store double %4, ptr %16, align 8, !tbaa !11
  store ptr %5, ptr %17, align 8, !tbaa !5
  store i32 %6, ptr %18, align 4, !tbaa !9
  store double %7, ptr %19, align 8, !tbaa !11
  store ptr %8, ptr %20, align 8, !tbaa !5
  store i32 %9, ptr %21, align 4, !tbaa !9
  %31 = load ptr, ptr %12, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #6
  %32 = load double, ptr %19, align 8, !tbaa !11
  %33 = call noundef i32 @_ZN7qpOASES6isZeroEdd(double noundef %32, double noundef 1.000000e-25)
  %34 = icmp eq i32 %33, 1
  br i1 %34, label %35, label %66

35:                                               ; preds = %10
  store i64 0, ptr %24, align 8, !tbaa !13
  br label %36

36:                                               ; preds = %62, %35
  %37 = load i64, ptr %24, align 8, !tbaa !13
  %38 = load i32, ptr %15, align 4, !tbaa !9
  %39 = sext i32 %38 to i64
  %40 = icmp slt i64 %37, %39
  br i1 %40, label %41, label %65

41:                                               ; preds = %36
  store i64 0, ptr %23, align 8, !tbaa !13
  br label %42

42:                                               ; preds = %58, %41
  %43 = load i64, ptr %23, align 8, !tbaa !13
  %44 = load ptr, ptr %14, align 8, !tbaa !5
  %45 = getelementptr inbounds %"class.qpOASES::Indexlist", ptr %44, i32 0, i32 2
  %46 = load i32, ptr %45, align 8, !tbaa !15
  %47 = sext i32 %46 to i64
  %48 = icmp slt i64 %43, %47
  br i1 %48, label %49, label %61

49:                                               ; preds = %42
  %50 = load ptr, ptr %20, align 8, !tbaa !5
  %51 = load i64, ptr %23, align 8, !tbaa !13
  %52 = load i64, ptr %24, align 8, !tbaa !13
  %53 = load i32, ptr %21, align 4, !tbaa !9
  %54 = sext i32 %53 to i64
  %55 = mul nsw i64 %52, %54
  %56 = add nsw i64 %51, %55
  %57 = getelementptr inbounds double, ptr %50, i64 %56
  store double 0.000000e+00, ptr %57, align 8, !tbaa !11
  br label %58

58:                                               ; preds = %49
  %59 = load i64, ptr %23, align 8, !tbaa !13
  %60 = add nsw i64 %59, 1
  store i64 %60, ptr %23, align 8, !tbaa !13
  br label %42, !llvm.loop !17

61:                                               ; preds = %42
  br label %62

62:                                               ; preds = %61
  %63 = load i64, ptr %24, align 8, !tbaa !13
  %64 = add nsw i64 %63, 1
  store i64 %64, ptr %24, align 8, !tbaa !13
  br label %36, !llvm.loop !19

65:                                               ; preds = %36
  br label %151

66:                                               ; preds = %10
  %67 = load double, ptr %19, align 8, !tbaa !11
  %68 = call noundef i32 @_ZN7qpOASES7isEqualEddd(double noundef %67, double noundef -1.000000e+00, double noundef 1.000000e-25)
  %69 = icmp eq i32 %68, 1
  br i1 %69, label %70, label %111

70:                                               ; preds = %66
  store i64 0, ptr %24, align 8, !tbaa !13
  br label %71

71:                                               ; preds = %107, %70
  %72 = load i64, ptr %24, align 8, !tbaa !13
  %73 = load i32, ptr %15, align 4, !tbaa !9
  %74 = sext i32 %73 to i64
  %75 = icmp slt i64 %72, %74
  br i1 %75, label %76, label %110

76:                                               ; preds = %71
  store i64 0, ptr %23, align 8, !tbaa !13
  br label %77

77:                                               ; preds = %103, %76
  %78 = load i64, ptr %23, align 8, !tbaa !13
  %79 = load ptr, ptr %14, align 8, !tbaa !5
  %80 = getelementptr inbounds %"class.qpOASES::Indexlist", ptr %79, i32 0, i32 2
  %81 = load i32, ptr %80, align 8, !tbaa !15
  %82 = sext i32 %81 to i64
  %83 = icmp slt i64 %78, %82
  br i1 %83, label %84, label %106

84:                                               ; preds = %77
  %85 = load ptr, ptr %20, align 8, !tbaa !5
  %86 = load i64, ptr %23, align 8, !tbaa !13
  %87 = load i64, ptr %24, align 8, !tbaa !13
  %88 = load i32, ptr %21, align 4, !tbaa !9
  %89 = sext i32 %88 to i64
  %90 = mul nsw i64 %87, %89
  %91 = add nsw i64 %86, %90
  %92 = getelementptr inbounds double, ptr %85, i64 %91
  %93 = load double, ptr %92, align 8, !tbaa !11
  %94 = fneg double %93
  %95 = load ptr, ptr %20, align 8, !tbaa !5
  %96 = load i64, ptr %23, align 8, !tbaa !13
  %97 = load i64, ptr %24, align 8, !tbaa !13
  %98 = load i32, ptr %21, align 4, !tbaa !9
  %99 = sext i32 %98 to i64
  %100 = mul nsw i64 %97, %99
  %101 = add nsw i64 %96, %100
  %102 = getelementptr inbounds double, ptr %95, i64 %101
  store double %94, ptr %102, align 8, !tbaa !11
  br label %103

103:                                              ; preds = %84
  %104 = load i64, ptr %23, align 8, !tbaa !13
  %105 = add nsw i64 %104, 1
  store i64 %105, ptr %23, align 8, !tbaa !13
  br label %77, !llvm.loop !20

106:                                              ; preds = %77
  br label %107

107:                                              ; preds = %106
  %108 = load i64, ptr %24, align 8, !tbaa !13
  %109 = add nsw i64 %108, 1
  store i64 %109, ptr %24, align 8, !tbaa !13
  br label %71, !llvm.loop !21

110:                                              ; preds = %71
  br label %150

111:                                              ; preds = %66
  %112 = load double, ptr %19, align 8, !tbaa !11
  %113 = call noundef i32 @_ZN7qpOASES7isEqualEddd(double noundef %112, double noundef 1.000000e+00, double noundef 1.000000e-25)
  %114 = icmp eq i32 %113, 0
  br i1 %114, label %115, label %149

115:                                              ; preds = %111
  store i64 0, ptr %24, align 8, !tbaa !13
  br label %116

116:                                              ; preds = %145, %115
  %117 = load i64, ptr %24, align 8, !tbaa !13
  %118 = load i32, ptr %15, align 4, !tbaa !9
  %119 = sext i32 %118 to i64
  %120 = icmp slt i64 %117, %119
  br i1 %120, label %121, label %148

121:                                              ; preds = %116
  store i64 0, ptr %23, align 8, !tbaa !13
  br label %122

122:                                              ; preds = %141, %121
  %123 = load i64, ptr %23, align 8, !tbaa !13
  %124 = load ptr, ptr %14, align 8, !tbaa !5
  %125 = getelementptr inbounds %"class.qpOASES::Indexlist", ptr %124, i32 0, i32 2
  %126 = load i32, ptr %125, align 8, !tbaa !15
  %127 = sext i32 %126 to i64
  %128 = icmp slt i64 %123, %127
  br i1 %128, label %129, label %144

129:                                              ; preds = %122
  %130 = load double, ptr %19, align 8, !tbaa !11
  %131 = load ptr, ptr %20, align 8, !tbaa !5
  %132 = load i64, ptr %23, align 8, !tbaa !13
  %133 = load i64, ptr %24, align 8, !tbaa !13
  %134 = load i32, ptr %21, align 4, !tbaa !9
  %135 = sext i32 %134 to i64
  %136 = mul nsw i64 %133, %135
  %137 = add nsw i64 %132, %136
  %138 = getelementptr inbounds double, ptr %131, i64 %137
  %139 = load double, ptr %138, align 8, !tbaa !11
  %140 = fmul double %139, %130
  store double %140, ptr %138, align 8, !tbaa !11
  br label %141

141:                                              ; preds = %129
  %142 = load i64, ptr %23, align 8, !tbaa !13
  %143 = add nsw i64 %142, 1
  store i64 %143, ptr %23, align 8, !tbaa !13
  br label %122, !llvm.loop !22

144:                                              ; preds = %122
  br label %145

145:                                              ; preds = %144
  %146 = load i64, ptr %24, align 8, !tbaa !13
  %147 = add nsw i64 %146, 1
  store i64 %147, ptr %24, align 8, !tbaa !13
  br label %116, !llvm.loop !23

148:                                              ; preds = %116
  br label %149

149:                                              ; preds = %148, %111
  br label %150

150:                                              ; preds = %149, %110
  br label %151

151:                                              ; preds = %150, %65
  %152 = load double, ptr %16, align 8, !tbaa !11
  %153 = call noundef i32 @_ZN7qpOASES7isEqualEddd(double noundef %152, double noundef 0.000000e+00, double noundef 1.000000e-25)
  %154 = icmp eq i32 %153, 1
  br i1 %154, label %155, label %156

155:                                              ; preds = %151
  store i32 0, ptr %11, align 4
  store i32 1, ptr %28, align 4
  br label %297

156:                                              ; preds = %151
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #6
  %157 = getelementptr inbounds %"class.qpOASES::SparseMatrix", ptr %31, i32 0, i32 1
  %158 = load i32, ptr %157, align 8, !tbaa !24
  store i32 %158, ptr %29, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #6
  %159 = load i32, ptr %29, align 4, !tbaa !9
  %160 = sext i32 %159 to i64
  %161 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %160, i64 8)
  %162 = extractvalue { i64, i1 } %161, 1
  %163 = extractvalue { i64, i1 } %161, 0
  %164 = select i1 %162, i64 -1, i64 %163
  %165 = call noalias noundef nonnull ptr @_Znam(i64 noundef %164) #7
  store ptr %165, ptr %30, align 8, !tbaa !5
  store i64 0, ptr %24, align 8, !tbaa !13
  br label %166

166:                                              ; preds = %289, %156
  %167 = load i64, ptr %24, align 8, !tbaa !13
  %168 = load i32, ptr %15, align 4, !tbaa !9
  %169 = sext i32 %168 to i64
  %170 = icmp slt i64 %167, %169
  br i1 %170, label %171, label %292

171:                                              ; preds = %166
  store i64 0, ptr %22, align 8, !tbaa !13
  br label %172

172:                                              ; preds = %181, %171
  %173 = load i64, ptr %22, align 8, !tbaa !13
  %174 = load i32, ptr %29, align 4, !tbaa !9
  %175 = sext i32 %174 to i64
  %176 = icmp slt i64 %173, %175
  br i1 %176, label %177, label %184

177:                                              ; preds = %172
  %178 = load ptr, ptr %30, align 8, !tbaa !5
  %179 = load i64, ptr %22, align 8, !tbaa !13
  %180 = getelementptr inbounds double, ptr %178, i64 %179
  store double 0.000000e+00, ptr %180, align 8, !tbaa !11
  br label %181

181:                                              ; preds = %177
  %182 = load i64, ptr %22, align 8, !tbaa !13
  %183 = add nsw i64 %182, 1
  store i64 %183, ptr %22, align 8, !tbaa !13
  br label %172, !llvm.loop !26

184:                                              ; preds = %172
  store i64 0, ptr %22, align 8, !tbaa !13
  br label %185

185:                                              ; preds = %211, %184
  %186 = load i64, ptr %22, align 8, !tbaa !13
  %187 = load ptr, ptr %13, align 8, !tbaa !5
  %188 = getelementptr inbounds %"class.qpOASES::Indexlist", ptr %187, i32 0, i32 2
  %189 = load i32, ptr %188, align 8, !tbaa !15
  %190 = sext i32 %189 to i64
  %191 = icmp slt i64 %186, %190
  br i1 %191, label %192, label %214

192:                                              ; preds = %185
  %193 = load ptr, ptr %17, align 8, !tbaa !5
  %194 = load i64, ptr %24, align 8, !tbaa !13
  %195 = load i32, ptr %18, align 4, !tbaa !9
  %196 = sext i32 %195 to i64
  %197 = mul nsw i64 %194, %196
  %198 = load i64, ptr %22, align 8, !tbaa !13
  %199 = add nsw i64 %197, %198
  %200 = getelementptr inbounds double, ptr %193, i64 %199
  %201 = load double, ptr %200, align 8, !tbaa !11
  %202 = load ptr, ptr %30, align 8, !tbaa !5
  %203 = load ptr, ptr %13, align 8, !tbaa !5
  %204 = getelementptr inbounds %"class.qpOASES::Indexlist", ptr %203, i32 0, i32 0
  %205 = load ptr, ptr %204, align 8, !tbaa !27
  %206 = load i64, ptr %22, align 8, !tbaa !13
  %207 = getelementptr inbounds i32, ptr %205, i64 %206
  %208 = load i32, ptr %207, align 4, !tbaa !9
  %209 = sext i32 %208 to i64
  %210 = getelementptr inbounds double, ptr %202, i64 %209
  store double %201, ptr %210, align 8, !tbaa !11
  br label %211

211:                                              ; preds = %192
  %212 = load i64, ptr %22, align 8, !tbaa !13
  %213 = add nsw i64 %212, 1
  store i64 %213, ptr %22, align 8, !tbaa !13
  br label %185, !llvm.loop !28

214:                                              ; preds = %185
  store i64 0, ptr %25, align 8, !tbaa !13
  br label %215

215:                                              ; preds = %281, %214
  %216 = load i64, ptr %25, align 8, !tbaa !13
  %217 = load ptr, ptr %14, align 8, !tbaa !5
  %218 = getelementptr inbounds %"class.qpOASES::Indexlist", ptr %217, i32 0, i32 2
  %219 = load i32, ptr %218, align 8, !tbaa !15
  %220 = sext i32 %219 to i64
  %221 = icmp slt i64 %216, %220
  br i1 %221, label %222, label %284

222:                                              ; preds = %215
  %223 = load ptr, ptr %14, align 8, !tbaa !5
  %224 = getelementptr inbounds %"class.qpOASES::Indexlist", ptr %223, i32 0, i32 1
  %225 = load ptr, ptr %224, align 8, !tbaa !29
  %226 = load i64, ptr %25, align 8, !tbaa !13
  %227 = getelementptr inbounds i32, ptr %225, i64 %226
  %228 = load i32, ptr %227, align 4, !tbaa !9
  %229 = sext i32 %228 to i64
  store i64 %229, ptr %26, align 8, !tbaa !13
  store double 0.000000e+00, ptr %27, align 8, !tbaa !11
  %230 = load ptr, ptr %14, align 8, !tbaa !5
  %231 = getelementptr inbounds %"class.qpOASES::Indexlist", ptr %230, i32 0, i32 0
  %232 = load ptr, ptr %231, align 8, !tbaa !27
  %233 = load i64, ptr %26, align 8, !tbaa !13
  %234 = getelementptr inbounds i32, ptr %232, i64 %233
  %235 = load i32, ptr %234, align 4, !tbaa !9
  %236 = sext i32 %235 to i64
  store i64 %236, ptr %23, align 8, !tbaa !13
  %237 = getelementptr inbounds %"class.qpOASES::SparseMatrix", ptr %31, i32 0, i32 4
  %238 = load ptr, ptr %237, align 8, !tbaa !30
  %239 = load i64, ptr %23, align 8, !tbaa !13
  %240 = getelementptr inbounds i32, ptr %238, i64 %239
  %241 = load i32, ptr %240, align 4, !tbaa !9
  %242 = sext i32 %241 to i64
  store i64 %242, ptr %22, align 8, !tbaa !13
  br label %243

243:                                              ; preds = %270, %222
  %244 = load i64, ptr %22, align 8, !tbaa !13
  %245 = getelementptr inbounds %"class.qpOASES::SparseMatrix", ptr %31, i32 0, i32 4
  %246 = load ptr, ptr %245, align 8, !tbaa !30
  %247 = load i64, ptr %23, align 8, !tbaa !13
  %248 = add nsw i64 %247, 1
  %249 = getelementptr inbounds i32, ptr %246, i64 %248
  %250 = load i32, ptr %249, align 4, !tbaa !9
  %251 = sext i32 %250 to i64
  %252 = icmp slt i64 %244, %251
  br i1 %252, label %253, label %273

253:                                              ; preds = %243
  %254 = getelementptr inbounds %"class.qpOASES::SparseMatrix", ptr %31, i32 0, i32 6
  %255 = load ptr, ptr %254, align 8, !tbaa !31
  %256 = load i64, ptr %22, align 8, !tbaa !13
  %257 = getelementptr inbounds double, ptr %255, i64 %256
  %258 = load double, ptr %257, align 8, !tbaa !11
  %259 = load ptr, ptr %30, align 8, !tbaa !5
  %260 = getelementptr inbounds %"class.qpOASES::SparseMatrix", ptr %31, i32 0, i32 3
  %261 = load ptr, ptr %260, align 8, !tbaa !32
  %262 = load i64, ptr %22, align 8, !tbaa !13
  %263 = getelementptr inbounds i32, ptr %261, i64 %262
  %264 = load i32, ptr %263, align 4, !tbaa !9
  %265 = sext i32 %264 to i64
  %266 = getelementptr inbounds double, ptr %259, i64 %265
  %267 = load double, ptr %266, align 8, !tbaa !11
  %268 = load double, ptr %27, align 8, !tbaa !11
  %269 = call double @llvm.fmuladd.f64(double %258, double %267, double %268)
  store double %269, ptr %27, align 8, !tbaa !11
  br label %270

270:                                              ; preds = %253
  %271 = load i64, ptr %22, align 8, !tbaa !13
  %272 = add nsw i64 %271, 1
  store i64 %272, ptr %22, align 8, !tbaa !13
  br label %243, !llvm.loop !33

273:                                              ; preds = %243
  %274 = load double, ptr %16, align 8, !tbaa !11
  %275 = load double, ptr %27, align 8, !tbaa !11
  %276 = load ptr, ptr %20, align 8, !tbaa !5
  %277 = load i64, ptr %26, align 8, !tbaa !13
  %278 = getelementptr inbounds double, ptr %276, i64 %277
  %279 = load double, ptr %278, align 8, !tbaa !11
  %280 = call double @llvm.fmuladd.f64(double %274, double %275, double %279)
  store double %280, ptr %278, align 8, !tbaa !11
  br label %281

281:                                              ; preds = %273
  %282 = load i64, ptr %25, align 8, !tbaa !13
  %283 = add nsw i64 %282, 1
  store i64 %283, ptr %25, align 8, !tbaa !13
  br label %215, !llvm.loop !34

284:                                              ; preds = %215
  %285 = load i32, ptr %21, align 4, !tbaa !9
  %286 = load ptr, ptr %20, align 8, !tbaa !5
  %287 = sext i32 %285 to i64
  %288 = getelementptr inbounds double, ptr %286, i64 %287
  store ptr %288, ptr %20, align 8, !tbaa !5
  br label %289

289:                                              ; preds = %284
  %290 = load i64, ptr %24, align 8, !tbaa !13
  %291 = add nsw i64 %290, 1
  store i64 %291, ptr %24, align 8, !tbaa !13
  br label %166, !llvm.loop !35

292:                                              ; preds = %166
  %293 = load ptr, ptr %30, align 8, !tbaa !5
  %294 = icmp eq ptr %293, null
  br i1 %294, label %296, label %295

295:                                              ; preds = %292
  call void @_ZdaPv(ptr noundef %293) #8
  br label %296

296:                                              ; preds = %295, %292
  store i32 0, ptr %11, align 4
  store i32 1, ptr %28, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #6
  br label %297

297:                                              ; preds = %296, %155
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #6
  %298 = load i32, ptr %11, align 4
  ret i32 %298
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #3 = { nobuiltin allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #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 = { builtin allocsize(0) }
attributes #8 = { builtin nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!16, !10, i64 16}
!16 = !{!"_ZTSN7qpOASES9IndexlistE", !6, i64 0, !6, i64 8, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28, !10, i64 32}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = distinct !{!19, !18}
!20 = distinct !{!20, !18}
!21 = distinct !{!21, !18}
!22 = distinct !{!22, !18}
!23 = distinct !{!23, !18}
!24 = !{!25, !10, i64 8}
!25 = !{!"_ZTSN7qpOASES12SparseMatrixE", !10, i64 8, !10, i64 12, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40}
!26 = distinct !{!26, !18}
!27 = !{!16, !6, i64 0}
!28 = distinct !{!28, !18}
!29 = !{!16, !6, i64 8}
!30 = !{!25, !6, i64 24}
!31 = !{!25, !6, i64 40}
!32 = !{!25, !6, i64 16}
!33 = distinct !{!33, !18}
!34 = distinct !{!34, !18}
!35 = distinct !{!35, !18}


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

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) local_unnamed_addr #0

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN7qpOASES7isEqualEddd(double noundef, double noundef, double noundef) local_unnamed_addr #2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN7qpOASES6isZeroEdd(double noundef, double noundef) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZNK7qpOASES12SparseMatrix10transTimesEPKNS_9IndexlistES3_idPKdidPdi(ptr nocapture noundef nonnull readonly align 8 dereferenceable(48) %0, ptr nocapture noundef readonly %1, ptr nocapture noundef readonly %2, i32 noundef %3, double noundef %4, ptr nocapture noundef readonly %5, i32 noundef %6, double noundef %7, ptr nocapture noundef %8, i32 noundef %9) unnamed_addr #4 align 2 {
  %11 = tail call noundef i32 @_ZN7qpOASES6isZeroEdd(double noundef %7, double noundef 1.000000e-25)
  %12 = icmp eq i32 %11, 1
  br i1 %12, label %.preheader94, label %39

.preheader94:                                     ; preds = %10
  %13 = sext i32 %3 to i64
  %14 = icmp sgt i32 %3, 0
  br i1 %14, label %.preheader93.lr.ph, label %.loopexit

.preheader93.lr.ph:                               ; preds = %.preheader94
  %15 = getelementptr inbounds i8, ptr %2, i64 16
  %16 = load i32, ptr %15, align 8, !tbaa !5
  %17 = icmp sgt i32 %16, 0
  br i1 %17, label %.preheader93.us.preheader, label %.loopexit

.preheader93.us.preheader:                        ; preds = %.preheader93.lr.ph
  %18 = sext i32 %9 to i64
  %19 = zext nneg i32 %16 to i64
  %20 = shl nsw i64 %18, 3
  %21 = shl nuw nsw i64 %19, 3
  %xtraiter = and i64 %13, 7
  %22 = icmp ult i32 %3, 8
  br i1 %22, label %.loopexit.loopexit.unr-lcssa, label %.preheader93.us.preheader.new

.preheader93.us.preheader.new:                    ; preds = %.preheader93.us.preheader
  %unroll_iter = and i64 %13, 2147483640
  br label %.preheader93.us

.preheader93.us:                                  ; preds = %.preheader93.us, %.preheader93.us.preheader.new
  %.085109.us = phi i64 [ 0, %.preheader93.us.preheader.new ], [ %38, %.preheader93.us ]
  %niter = phi i64 [ 0, %.preheader93.us.preheader.new ], [ %niter.next.7, %.preheader93.us ]
  %23 = mul i64 %20, %.085109.us
  %scevgep = getelementptr i8, ptr %8, i64 %23
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep, i8 0, i64 %21, i1 false), !tbaa !11
  %24 = or disjoint i64 %.085109.us, 1
  %25 = mul i64 %20, %24
  %scevgep.1 = getelementptr i8, ptr %8, i64 %25
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep.1, i8 0, i64 %21, i1 false), !tbaa !11
  %26 = or disjoint i64 %.085109.us, 2
  %27 = mul i64 %20, %26
  %scevgep.2 = getelementptr i8, ptr %8, i64 %27
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep.2, i8 0, i64 %21, i1 false), !tbaa !11
  %28 = or disjoint i64 %.085109.us, 3
  %29 = mul i64 %20, %28
  %scevgep.3 = getelementptr i8, ptr %8, i64 %29
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep.3, i8 0, i64 %21, i1 false), !tbaa !11
  %30 = or disjoint i64 %.085109.us, 4
  %31 = mul i64 %20, %30
  %scevgep.4 = getelementptr i8, ptr %8, i64 %31
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep.4, i8 0, i64 %21, i1 false), !tbaa !11
  %32 = or disjoint i64 %.085109.us, 5
  %33 = mul i64 %20, %32
  %scevgep.5 = getelementptr i8, ptr %8, i64 %33
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep.5, i8 0, i64 %21, i1 false), !tbaa !11
  %34 = or disjoint i64 %.085109.us, 6
  %35 = mul i64 %20, %34
  %scevgep.6 = getelementptr i8, ptr %8, i64 %35
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep.6, i8 0, i64 %21, i1 false), !tbaa !11
  %36 = or disjoint i64 %.085109.us, 7
  %37 = mul i64 %20, %36
  %scevgep.7 = getelementptr i8, ptr %8, i64 %37
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep.7, i8 0, i64 %21, i1 false), !tbaa !11
  %38 = add nuw nsw i64 %.085109.us, 8
  %niter.next.7 = add i64 %niter, 8
  %niter.ncmp.7 = icmp eq i64 %niter.next.7, %unroll_iter
  br i1 %niter.ncmp.7, label %.loopexit.loopexit.unr-lcssa, label %.preheader93.us, !llvm.loop !13

39:                                               ; preds = %10
  %40 = tail call noundef i32 @_ZN7qpOASES7isEqualEddd(double noundef %7, double noundef -1.000000e+00, double noundef 1.000000e-25)
  %41 = icmp eq i32 %40, 1
  br i1 %41, label %.preheader96, label %59

.preheader96:                                     ; preds = %39
  %42 = sext i32 %3 to i64
  %43 = icmp sgt i32 %3, 0
  br i1 %43, label %.preheader95.lr.ph, label %.loopexit

.preheader95.lr.ph:                               ; preds = %.preheader96
  %44 = getelementptr inbounds i8, ptr %2, i64 16
  %45 = load i32, ptr %44, align 8, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = icmp sgt i32 %45, 0
  %48 = sext i32 %9 to i64
  br i1 %47, label %.preheader95.us.preheader, label %.loopexit

.preheader95.us.preheader:                        ; preds = %.preheader95.lr.ph
  %min.iters.check145 = icmp ult i32 %45, 4
  %n.vec148 = and i64 %46, 2147483644
  %cmp.n155 = icmp eq i64 %n.vec148, %46
  br label %.preheader95.us

.preheader95.us:                                  ; preds = %.preheader95.us.preheader, %._crit_edge.us107
  %.186104.us = phi i64 [ %58, %._crit_edge.us107 ], [ 0, %.preheader95.us.preheader ]
  %49 = mul nsw i64 %.186104.us, %48
  %invariant.gep.us106 = getelementptr double, ptr %8, i64 %49
  br i1 %min.iters.check145, label %scalar.ph144.preheader, label %vector.body150

vector.body150:                                   ; preds = %.preheader95.us, %vector.body150
  %index151 = phi i64 [ %index.next154, %vector.body150 ], [ 0, %.preheader95.us ]
  %50 = getelementptr double, ptr %invariant.gep.us106, i64 %index151
  %51 = getelementptr i8, ptr %50, i64 16
  %wide.load152 = load <2 x double>, ptr %50, align 8, !tbaa !11
  %wide.load153 = load <2 x double>, ptr %51, align 8, !tbaa !11
  %52 = fneg <2 x double> %wide.load152
  %53 = fneg <2 x double> %wide.load153
  store <2 x double> %52, ptr %50, align 8, !tbaa !11
  store <2 x double> %53, ptr %51, align 8, !tbaa !11
  %index.next154 = add nuw i64 %index151, 4
  %54 = icmp eq i64 %index.next154, %n.vec148
  br i1 %54, label %middle.block143, label %vector.body150, !llvm.loop !15

middle.block143:                                  ; preds = %vector.body150
  br i1 %cmp.n155, label %._crit_edge.us107, label %scalar.ph144.preheader

scalar.ph144.preheader:                           ; preds = %middle.block143, %.preheader95.us
  %.189103.us.ph = phi i64 [ 0, %.preheader95.us ], [ %n.vec148, %middle.block143 ]
  br label %scalar.ph144

scalar.ph144:                                     ; preds = %scalar.ph144.preheader, %scalar.ph144
  %.189103.us = phi i64 [ %57, %scalar.ph144 ], [ %.189103.us.ph, %scalar.ph144.preheader ]
  %gep.us105 = getelementptr double, ptr %invariant.gep.us106, i64 %.189103.us
  %55 = load double, ptr %gep.us105, align 8, !tbaa !11
  %56 = fneg double %55
  store double %56, ptr %gep.us105, align 8, !tbaa !11
  %57 = add nuw nsw i64 %.189103.us, 1
  %exitcond131.not = icmp eq i64 %57, %46
  br i1 %exitcond131.not, label %._crit_edge.us107, label %scalar.ph144, !llvm.loop !18

._crit_edge.us107:                                ; preds = %scalar.ph144, %middle.block143
  %58 = add nuw nsw i64 %.186104.us, 1
  %exitcond132.not = icmp eq i64 %58, %42
  br i1 %exitcond132.not, label %.loopexit, label %.preheader95.us, !llvm.loop !19

59:                                               ; preds = %39
  %60 = tail call noundef i32 @_ZN7qpOASES7isEqualEddd(double noundef %7, double noundef 1.000000e+00, double noundef 1.000000e-25)
  %61 = icmp eq i32 %60, 0
  br i1 %61, label %.preheader99, label %.loopexit

.preheader99:                                     ; preds = %59
  %62 = sext i32 %3 to i64
  %63 = icmp sgt i32 %3, 0
  br i1 %63, label %.preheader98.lr.ph, label %.loopexit

.preheader98.lr.ph:                               ; preds = %.preheader99
  %64 = getelementptr inbounds i8, ptr %2, i64 16
  %65 = load i32, ptr %64, align 8, !tbaa !5
  %66 = sext i32 %65 to i64
  %67 = icmp sgt i32 %65, 0
  %68 = sext i32 %9 to i64
  br i1 %67, label %.preheader98.us.preheader, label %.loopexit

.preheader98.us.preheader:                        ; preds = %.preheader98.lr.ph
  %min.iters.check = icmp ult i32 %65, 4
  %n.vec = and i64 %66, 2147483644
  %broadcast.splatinsert = insertelement <2 x double> poison, double %7, i64 0
  %broadcast.splat = shufflevector <2 x double> %broadcast.splatinsert, <2 x double> poison, <2 x i32> zeroinitializer
  %cmp.n = icmp eq i64 %n.vec, %66
  br label %.preheader98.us

.preheader98.us:                                  ; preds = %.preheader98.us.preheader, %._crit_edge.us
  %.287102.us = phi i64 [ %78, %._crit_edge.us ], [ 0, %.preheader98.us.preheader ]
  %69 = mul nsw i64 %.287102.us, %68
  %invariant.gep.us = getelementptr double, ptr %8, i64 %69
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.body

vector.body:                                      ; preds = %.preheader98.us, %vector.body
  %index = phi i64 [ %index.next, %vector.body ], [ 0, %.preheader98.us ]
  %70 = getelementptr double, ptr %invariant.gep.us, i64 %index
  %71 = getelementptr i8, ptr %70, i64 16
  %wide.load = load <2 x double>, ptr %70, align 8, !tbaa !11
  %wide.load142 = load <2 x double>, ptr %71, align 8, !tbaa !11
  %72 = fmul <2 x double> %wide.load, %broadcast.splat
  %73 = fmul <2 x double> %wide.load142, %broadcast.splat
  store <2 x double> %72, ptr %70, align 8, !tbaa !11
  store <2 x double> %73, ptr %71, align 8, !tbaa !11
  %index.next = add nuw i64 %index, 4
  %74 = icmp eq i64 %index.next, %n.vec
  br i1 %74, label %middle.block, label %vector.body, !llvm.loop !20

middle.block:                                     ; preds = %vector.body
  br i1 %cmp.n, label %._crit_edge.us, label %scalar.ph.preheader

scalar.ph.preheader:                              ; preds = %middle.block, %.preheader98.us
  %.290101.us.ph = phi i64 [ 0, %.preheader98.us ], [ %n.vec, %middle.block ]
  br label %scalar.ph

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %.290101.us = phi i64 [ %77, %scalar.ph ], [ %.290101.us.ph, %scalar.ph.preheader ]
  %gep.us = getelementptr double, ptr %invariant.gep.us, i64 %.290101.us
  %75 = load double, ptr %gep.us, align 8, !tbaa !11
  %76 = fmul double %75, %7
  store double %76, ptr %gep.us, align 8, !tbaa !11
  %77 = add nuw nsw i64 %.290101.us, 1
  %exitcond.not = icmp eq i64 %77, %66
  br i1 %exitcond.not, label %._crit_edge.us, label %scalar.ph, !llvm.loop !21

._crit_edge.us:                                   ; preds = %scalar.ph, %middle.block
  %78 = add nuw nsw i64 %.287102.us, 1
  %exitcond130.not = icmp eq i64 %78, %62
  br i1 %exitcond130.not, label %.loopexit, label %.preheader98.us, !llvm.loop !22

.loopexit.loopexit.unr-lcssa:                     ; preds = %.preheader93.us, %.preheader93.us.preheader
  %.085109.us.unr = phi i64 [ 0, %.preheader93.us.preheader ], [ %38, %.preheader93.us ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.loopexit, label %.preheader93.us.epil

.preheader93.us.epil:                             ; preds = %.loopexit.loopexit.unr-lcssa, %.preheader93.us.epil
  %.085109.us.epil = phi i64 [ %80, %.preheader93.us.epil ], [ %.085109.us.unr, %.loopexit.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.preheader93.us.epil ], [ 0, %.loopexit.loopexit.unr-lcssa ]
  %79 = mul i64 %20, %.085109.us.epil
  %scevgep.epil = getelementptr i8, ptr %8, i64 %79
  tail call void @llvm.memset.p0.i64(ptr align 8 %scevgep.epil, i8 0, i64 %21, i1 false), !tbaa !11
  %80 = add nuw nsw i64 %.085109.us.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %.loopexit, label %.preheader93.us.epil, !llvm.loop !23

.loopexit:                                        ; preds = %._crit_edge.us, %._crit_edge.us107, %.loopexit.loopexit.unr-lcssa, %.preheader93.us.epil, %.preheader98.lr.ph, %.preheader95.lr.ph, %.preheader93.lr.ph, %.preheader99, %.preheader96, %.preheader94, %59
  %81 = tail call noundef i32 @_ZN7qpOASES7isEqualEddd(double noundef %4, double noundef 0.000000e+00, double noundef 1.000000e-25)
  %82 = icmp eq i32 %81, 1
  br i1 %82, label %220, label %83

83:                                               ; preds = %.loopexit
  %84 = getelementptr inbounds i8, ptr %0, i64 8
  %85 = load i32, ptr %84, align 8, !tbaa !25
  %86 = sext i32 %85 to i64
  %87 = icmp slt i32 %85, 0
  %88 = shl nsw i64 %86, 3
  %89 = select i1 %87, i64 -1, i64 %88
  %90 = tail call noalias noundef nonnull ptr @_Znam(i64 noundef %89) #6
  %91 = sext i32 %3 to i64
  %92 = icmp sgt i32 %3, 0
  br i1 %92, label %.preheader92.lr.ph, label %._crit_edge124

.preheader92.lr.ph:                               ; preds = %83
  %93 = icmp sgt i32 %85, 0
  %94 = getelementptr inbounds i8, ptr %1, i64 16
  %95 = load i32, ptr %94, align 8, !tbaa !5
  %96 = sext i32 %95 to i64
  %97 = icmp sgt i32 %95, 0
  %98 = sext i32 %6 to i64
  %99 = getelementptr inbounds i8, ptr %2, i64 16
  %100 = load i32, ptr %99, align 8, !tbaa !5
  %101 = sext i32 %100 to i64
  %102 = icmp sgt i32 %100, 0
  %103 = getelementptr inbounds i8, ptr %2, i64 8
  %104 = getelementptr inbounds i8, ptr %0, i64 24
  %105 = load ptr, ptr %104, align 8
  %106 = getelementptr inbounds i8, ptr %0, i64 40
  %107 = getelementptr inbounds i8, ptr %0, i64 16
  %108 = sext i32 %9 to i64
  %xtraiter158 = and i64 %96, 3
  %109 = icmp ult i32 %95, 4
  %unroll_iter161 = and i64 %96, 2147483644
  %lcmp.mod160.not = icmp eq i64 %xtraiter158, 0
  br label %.preheader92

.preheader92:                                     ; preds = %.preheader92.lr.ph, %._crit_edge121
  %.081123 = phi ptr [ %8, %.preheader92.lr.ph ], [ %218, %._crit_edge121 ]
  %.3122 = phi i64 [ 0, %.preheader92.lr.ph ], [ %219, %._crit_edge121 ]
  br i1 %93, label %.lr.ph.preheader, label %.preheader91

.lr.ph.preheader:                                 ; preds = %.preheader92
  tail call void @llvm.memset.p0.i64(ptr nonnull align 8 %90, i8 0, i64 %88, i1 false), !tbaa !11
  br label %.preheader91

.preheader91:                                     ; preds = %.lr.ph.preheader, %.preheader92
  br i1 %97, label %.lr.ph115, label %.preheader

.lr.ph115:                                        ; preds = %.preheader91
  %110 = mul nsw i64 %.3122, %98
  %111 = getelementptr double, ptr %5, i64 %110
  %112 = load ptr, ptr %1, align 8, !tbaa !27
  br i1 %109, label %.preheader.loopexit.unr-lcssa, label %.lr.ph115.new

.preheader.loopexit.unr-lcssa:                    ; preds = %.lr.ph115.new, %.lr.ph115
  %.1114.unr = phi i64 [ 0, %.lr.ph115 ], [ %151, %.lr.ph115.new ]
  br i1 %lcmp.mod160.not, label %.preheader, label %.epil.preheader

.epil.preheader:                                  ; preds = %.preheader.loopexit.unr-lcssa, %.epil.preheader
  %.1114.epil = phi i64 [ %119, %.epil.preheader ], [ %.1114.unr, %.preheader.loopexit.unr-lcssa ]
  %epil.iter159 = phi i64 [ %epil.iter159.next, %.epil.preheader ], [ 0, %.preheader.loopexit.unr-lcssa ]
  %113 = getelementptr double, ptr %111, i64 %.1114.epil
  %114 = load double, ptr %113, align 8, !tbaa !11
  %115 = getelementptr inbounds i32, ptr %112, i64 %.1114.epil
  %116 = load i32, ptr %115, align 4, !tbaa !28
  %117 = sext i32 %116 to i64
  %118 = getelementptr inbounds double, ptr %90, i64 %117
  store double %114, ptr %118, align 8, !tbaa !11
  %119 = add nuw nsw i64 %.1114.epil, 1
  %epil.iter159.next = add i64 %epil.iter159, 1
  %epil.iter159.cmp.not = icmp eq i64 %epil.iter159.next, %xtraiter158
  br i1 %epil.iter159.cmp.not, label %.preheader, label %.epil.preheader, !llvm.loop !29

.preheader:                                       ; preds = %.preheader.loopexit.unr-lcssa, %.epil.preheader, %.preheader91
  br i1 %102, label %.lr.ph120, label %._crit_edge121

.lr.ph120:                                        ; preds = %.preheader
  %120 = load ptr, ptr %103, align 8, !tbaa !30
  %121 = load ptr, ptr %2, align 8, !tbaa !27
  %122 = load ptr, ptr %106, align 8
  %123 = load ptr, ptr %107, align 8
  br label %152

.lr.ph115.new:                                    ; preds = %.lr.ph115, %.lr.ph115.new
  %.1114 = phi i64 [ %151, %.lr.ph115.new ], [ 0, %.lr.ph115 ]
  %niter162 = phi i64 [ %niter162.next.3, %.lr.ph115.new ], [ 0, %.lr.ph115 ]
  %124 = getelementptr double, ptr %111, i64 %.1114
  %125 = load double, ptr %124, align 8, !tbaa !11
  %126 = getelementptr inbounds i32, ptr %112, i64 %.1114
  %127 = load i32, ptr %126, align 4, !tbaa !28
  %128 = sext i32 %127 to i64
  %129 = getelementptr inbounds double, ptr %90, i64 %128
  store double %125, ptr %129, align 8, !tbaa !11
  %130 = or disjoint i64 %.1114, 1
  %131 = getelementptr double, ptr %111, i64 %130
  %132 = load double, ptr %131, align 8, !tbaa !11
  %133 = getelementptr inbounds i32, ptr %112, i64 %130
  %134 = load i32, ptr %133, align 4, !tbaa !28
  %135 = sext i32 %134 to i64
  %136 = getelementptr inbounds double, ptr %90, i64 %135
  store double %132, ptr %136, align 8, !tbaa !11
  %137 = or disjoint i64 %.1114, 2
  %138 = getelementptr double, ptr %111, i64 %137
  %139 = load double, ptr %138, align 8, !tbaa !11
  %140 = getelementptr inbounds i32, ptr %112, i64 %137
  %141 = load i32, ptr %140, align 4, !tbaa !28
  %142 = sext i32 %141 to i64
  %143 = getelementptr inbounds double, ptr %90, i64 %142
  store double %139, ptr %143, align 8, !tbaa !11
  %144 = or disjoint i64 %.1114, 3
  %145 = getelementptr double, ptr %111, i64 %144
  %146 = load double, ptr %145, align 8, !tbaa !11
  %147 = getelementptr inbounds i32, ptr %112, i64 %144
  %148 = load i32, ptr %147, align 4, !tbaa !28
  %149 = sext i32 %148 to i64
  %150 = getelementptr inbounds double, ptr %90, i64 %149
  store double %146, ptr %150, align 8, !tbaa !11
  %151 = add nuw nsw i64 %.1114, 4
  %niter162.next.3 = add i64 %niter162, 4
  %niter162.ncmp.3 = icmp eq i64 %niter162.next.3, %unroll_iter161
  br i1 %niter162.ncmp.3, label %.preheader.loopexit.unr-lcssa, label %.lr.ph115.new, !llvm.loop !31

152:                                              ; preds = %.lr.ph120, %._crit_edge
  %.084119 = phi i64 [ 0, %.lr.ph120 ], [ %217, %._crit_edge ]
  %153 = getelementptr inbounds i32, ptr %120, i64 %.084119
  %154 = load i32, ptr %153, align 4, !tbaa !28
  %155 = sext i32 %154 to i64
  %156 = getelementptr inbounds i32, ptr %121, i64 %155
  %157 = load i32, ptr %156, align 4, !tbaa !28
  %158 = sext i32 %157 to i64
  %159 = getelementptr inbounds i32, ptr %105, i64 %158
  %160 = load i32, ptr %159, align 4, !tbaa !28
  %161 = getelementptr i8, ptr %159, i64 4
  %162 = load i32, ptr %161, align 4, !tbaa !28
  %163 = sext i32 %162 to i64
  %164 = icmp slt i32 %160, %162
  br i1 %164, label %.lr.ph118.preheader, label %._crit_edge

.lr.ph118.preheader:                              ; preds = %152
  %165 = sext i32 %160 to i64
  %166 = sub nsw i64 %163, %165
  %xtraiter163 = and i64 %166, 3
  %lcmp.mod164.not = icmp eq i64 %xtraiter163, 0
  br i1 %lcmp.mod164.not, label %.lr.ph118.prol.loopexit, label %.lr.ph118.prol

.lr.ph118.prol:                                   ; preds = %.lr.ph118.preheader, %.lr.ph118.prol
  %.082117.prol = phi double [ %174, %.lr.ph118.prol ], [ 0.000000e+00, %.lr.ph118.preheader ]
  %.2116.prol = phi i64 [ %175, %.lr.ph118.prol ], [ %165, %.lr.ph118.preheader ]
  %prol.iter = phi i64 [ %prol.iter.next, %.lr.ph118.prol ], [ 0, %.lr.ph118.preheader ]
  %167 = getelementptr inbounds double, ptr %122, i64 %.2116.prol
  %168 = load double, ptr %167, align 8, !tbaa !11
  %169 = getelementptr inbounds i32, ptr %123, i64 %.2116.prol
  %170 = load i32, ptr %169, align 4, !tbaa !28
  %171 = sext i32 %170 to i64
  %172 = getelementptr inbounds double, ptr %90, i64 %171
  %173 = load double, ptr %172, align 8, !tbaa !11
  %174 = tail call double @llvm.fmuladd.f64(double %168, double %173, double %.082117.prol)
  %175 = add nsw i64 %.2116.prol, 1
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter163
  br i1 %prol.iter.cmp.not, label %.lr.ph118.prol.loopexit, label %.lr.ph118.prol, !llvm.loop !32

.lr.ph118.prol.loopexit:                          ; preds = %.lr.ph118.prol, %.lr.ph118.preheader
  %.lcssa.unr = phi double [ poison, %.lr.ph118.preheader ], [ %174, %.lr.ph118.prol ]
  %.082117.unr = phi double [ 0.000000e+00, %.lr.ph118.preheader ], [ %174, %.lr.ph118.prol ]
  %.2116.unr = phi i64 [ %165, %.lr.ph118.preheader ], [ %175, %.lr.ph118.prol ]
  %176 = sub nsw i64 %165, %163
  %177 = icmp ugt i64 %176, -4
  br i1 %177, label %._crit_edge, label %.lr.ph118

.lr.ph118:                                        ; preds = %.lr.ph118.prol.loopexit, %.lr.ph118
  %.082117 = phi double [ %212, %.lr.ph118 ], [ %.082117.unr, %.lr.ph118.prol.loopexit ]
  %.2116 = phi i64 [ %213, %.lr.ph118 ], [ %.2116.unr, %.lr.ph118.prol.loopexit ]
  %178 = getelementptr inbounds double, ptr %122, i64 %.2116
  %179 = load double, ptr %178, align 8, !tbaa !11
  %180 = getelementptr inbounds i32, ptr %123, i64 %.2116
  %181 = load i32, ptr %180, align 4, !tbaa !28
  %182 = sext i32 %181 to i64
  %183 = getelementptr inbounds double, ptr %90, i64 %182
  %184 = load double, ptr %183, align 8, !tbaa !11
  %185 = tail call double @llvm.fmuladd.f64(double %179, double %184, double %.082117)
  %186 = add nsw i64 %.2116, 1
  %187 = getelementptr inbounds double, ptr %122, i64 %186
  %188 = load double, ptr %187, align 8, !tbaa !11
  %189 = getelementptr inbounds i32, ptr %123, i64 %186
  %190 = load i32, ptr %189, align 4, !tbaa !28
  %191 = sext i32 %190 to i64
  %192 = getelementptr inbounds double, ptr %90, i64 %191
  %193 = load double, ptr %192, align 8, !tbaa !11
  %194 = tail call double @llvm.fmuladd.f64(double %188, double %193, double %185)
  %195 = add nsw i64 %.2116, 2
  %196 = getelementptr inbounds double, ptr %122, i64 %195
  %197 = load double, ptr %196, align 8, !tbaa !11
  %198 = getelementptr inbounds i32, ptr %123, i64 %195
  %199 = load i32, ptr %198, align 4, !tbaa !28
  %200 = sext i32 %199 to i64
  %201 = getelementptr inbounds double, ptr %90, i64 %200
  %202 = load double, ptr %201, align 8, !tbaa !11
  %203 = tail call double @llvm.fmuladd.f64(double %197, double %202, double %194)
  %204 = add nsw i64 %.2116, 3
  %205 = getelementptr inbounds double, ptr %122, i64 %204
  %206 = load double, ptr %205, align 8, !tbaa !11
  %207 = getelementptr inbounds i32, ptr %123, i64 %204
  %208 = load i32, ptr %207, align 4, !tbaa !28
  %209 = sext i32 %208 to i64
  %210 = getelementptr inbounds double, ptr %90, i64 %209
  %211 = load double, ptr %210, align 8, !tbaa !11
  %212 = tail call double @llvm.fmuladd.f64(double %206, double %211, double %203)
  %213 = add nsw i64 %.2116, 4
  %exitcond135.not.3 = icmp eq i64 %213, %163
  br i1 %exitcond135.not.3, label %._crit_edge, label %.lr.ph118, !llvm.loop !33

._crit_edge:                                      ; preds = %.lr.ph118.prol.loopexit, %.lr.ph118, %152
  %.082.lcssa = phi double [ 0.000000e+00, %152 ], [ %.lcssa.unr, %.lr.ph118.prol.loopexit ], [ %212, %.lr.ph118 ]
  %214 = getelementptr inbounds double, ptr %.081123, i64 %155
  %215 = load double, ptr %214, align 8, !tbaa !11
  %216 = tail call double @llvm.fmuladd.f64(double %4, double %.082.lcssa, double %215)
  store double %216, ptr %214, align 8, !tbaa !11
  %217 = add nuw nsw i64 %.084119, 1
  %exitcond136.not = icmp eq i64 %217, %101
  br i1 %exitcond136.not, label %._crit_edge121, label %152, !llvm.loop !34

._crit_edge121:                                   ; preds = %._crit_edge, %.preheader
  %218 = getelementptr inbounds double, ptr %.081123, i64 %108
  %219 = add nuw nsw i64 %.3122, 1
  %exitcond137.not = icmp eq i64 %219, %91
  br i1 %exitcond137.not, label %._crit_edge124, label %.preheader92, !llvm.loop !35

._crit_edge124:                                   ; preds = %._crit_edge121, %83
  tail call void @_ZdaPv(ptr noundef nonnull %90) #7
  br label %220

220:                                              ; preds = %.loopexit, %._crit_edge124
  ret i32 0
}

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #5

attributes #0 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nobuiltin allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { 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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #6 = { builtin allocsize(0) }
attributes #7 = { builtin nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !10, i64 16}
!6 = !{!"_ZTSN7qpOASES9IndexlistE", !7, i64 0, !7, i64 8, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28, !10, i64 32}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"double", !8, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14, !16, !17}
!16 = !{!"llvm.loop.isvectorized", i32 1}
!17 = !{!"llvm.loop.unroll.runtime.disable"}
!18 = distinct !{!18, !14, !17, !16}
!19 = distinct !{!19, !14}
!20 = distinct !{!20, !14, !16, !17}
!21 = distinct !{!21, !14, !17, !16}
!22 = distinct !{!22, !14}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.unroll.disable"}
!25 = !{!26, !10, i64 8}
!26 = !{!"_ZTSN7qpOASES12SparseMatrixE", !10, i64 8, !10, i64 12, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40}
!27 = !{!6, !7, i64 0}
!28 = !{!10, !10, i64 0}
!29 = distinct !{!29, !24}
!30 = !{!6, !7, i64 8}
!31 = distinct !{!31, !14}
!32 = distinct !{!32, !24}
!33 = distinct !{!33, !14}
!34 = distinct !{!34, !14}
!35 = distinct !{!35, !14}


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