; LLVM IR from sourceryinstitute/MORFEUS-Source :: src/FV/src/mesh_optimize/OptMS (SMuntangle)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.__SMlocal_mesh = type { i32, i32, i32, [3 x double], [3 x double], [3 x double], ptr, ptr, ptr, i32, double, ptr, double, i32, i32, i32, ptr, ptr, ptr }
%struct.__SMlp = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }

@.str.1 = external hidden unnamed_addr constant [110 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [16 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 @SMerror(i32 noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, i32 noundef, ptr noundef) #1

; Function Attrs: nounwind uwtable
define dso_local i32 @SMuntangle_mesh(ptr noundef %0, ptr noundef %1) #2 {
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca ptr, align 8
  %20 = alloca double, align 8
  %21 = alloca ptr, align 8
  %22 = alloca i32, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #3
  %23 = load ptr, ptr %4, align 8, !tbaa !5
  %24 = getelementptr inbounds %struct.__SMlocal_mesh, ptr %23, i32 0, i32 2
  %25 = load i32, ptr %24, align 8, !tbaa !9
  store i32 %25, ptr %9, align 4, !tbaa !13
  %26 = load ptr, ptr %4, align 8, !tbaa !5
  %27 = getelementptr inbounds %struct.__SMlocal_mesh, ptr %26, i32 0, i32 0
  %28 = load i32, ptr %27, align 8, !tbaa !14
  store i32 %28, ptr %10, align 4, !tbaa !13
  %29 = load i32, ptr %9, align 4, !tbaa !13
  %30 = load i32, ptr %10, align 4, !tbaa !13
  %31 = sub nsw i32 %29, %30
  store i32 %31, ptr %11, align 4, !tbaa !13
  %32 = load ptr, ptr %5, align 8, !tbaa !5
  store i32 0, ptr %32, align 4, !tbaa !13
  %33 = load ptr, ptr %4, align 8, !tbaa !5
  %34 = call i32 @SMinitLP(ptr noundef %33)
  store i32 %34, ptr %6, align 4, !tbaa !13
  %35 = load i32, ptr %6, align 4, !tbaa !13
  %36 = icmp ne i32 %35, 0
  br i1 %36, label %37, label %40

37:                                               ; preds = %2
  %38 = load i32, ptr %6, align 4, !tbaa !13
  %39 = call i32 @SMerror(i32 noundef 191, ptr noundef @.str.4, ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef %38, i32 noundef 0, ptr noundef null)
  store i32 %39, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %282

40:                                               ; preds = %2
  %41 = load ptr, ptr %4, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.__SMlocal_mesh, ptr %41, i32 0, i32 18
  %43 = load ptr, ptr %42, align 8, !tbaa !15
  store ptr %43, ptr %21, align 8, !tbaa !5
  %44 = load ptr, ptr %21, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.__SMlp, ptr %44, i32 0, i32 0
  %46 = load ptr, ptr %45, align 8, !tbaa !16
  store ptr %46, ptr %14, align 8, !tbaa !5
  %47 = load ptr, ptr %21, align 8, !tbaa !5
  %48 = getelementptr inbounds %struct.__SMlp, ptr %47, i32 0, i32 1
  %49 = load ptr, ptr %48, align 8, !tbaa !18
  store ptr %49, ptr %15, align 8, !tbaa !5
  %50 = load ptr, ptr %21, align 8, !tbaa !5
  %51 = getelementptr inbounds %struct.__SMlp, ptr %50, i32 0, i32 2
  %52 = load ptr, ptr %51, align 8, !tbaa !19
  store ptr %52, ptr %16, align 8, !tbaa !5
  %53 = load ptr, ptr %21, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.__SMlp, ptr %53, i32 0, i32 3
  %55 = load ptr, ptr %54, align 8, !tbaa !20
  store ptr %55, ptr %19, align 8, !tbaa !5
  %56 = load ptr, ptr %21, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct.__SMlp, ptr %56, i32 0, i32 8
  %58 = load ptr, ptr %57, align 8, !tbaa !21
  store ptr %58, ptr %18, align 8, !tbaa !5
  %59 = load ptr, ptr %21, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.__SMlp, ptr %59, i32 0, i32 9
  %61 = load ptr, ptr %60, align 8, !tbaa !22
  store ptr %61, ptr %17, align 8, !tbaa !5
  %62 = load ptr, ptr %4, align 8, !tbaa !5
  %63 = load i32, ptr %9, align 4, !tbaa !13
  %64 = load ptr, ptr %14, align 8, !tbaa !5
  %65 = load ptr, ptr %18, align 8, !tbaa !5
  %66 = call i32 @SMcomputeConstraintMatrix(ptr noundef %62, i32 noundef %63, ptr noundef %64, ptr noundef %65)
  %67 = load ptr, ptr %14, align 8, !tbaa !5
  %68 = load i32, ptr %9, align 4, !tbaa !13
  %69 = load i32, ptr %10, align 4, !tbaa !13
  %70 = load ptr, ptr %15, align 8, !tbaa !5
  %71 = call i32 @SMtransposeMatrix2(ptr noundef %67, i32 noundef %68, i32 noundef %69, ptr noundef %70)
  store i32 %71, ptr %6, align 4, !tbaa !13
  %72 = load i32, ptr %6, align 4, !tbaa !13
  %73 = icmp ne i32 %72, 0
  br i1 %73, label %74, label %77

74:                                               ; preds = %40
  %75 = load i32, ptr %6, align 4, !tbaa !13
  %76 = call i32 @SMerror(i32 noundef 205, ptr noundef @.str.4, ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef %75, i32 noundef 0, ptr noundef null)
  store i32 %76, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %282

77:                                               ; preds = %40
  %78 = load i32, ptr %10, align 4, !tbaa !13
  %79 = load i32, ptr %9, align 4, !tbaa !13
  %80 = load ptr, ptr %15, align 8, !tbaa !5
  %81 = load ptr, ptr %18, align 8, !tbaa !5
  %82 = load ptr, ptr %5, align 8, !tbaa !5
  %83 = call i32 @SMdegenerate(i32 noundef %78, i32 noundef %79, ptr noundef %80, ptr noundef %81, ptr noundef %82)
  store i32 %83, ptr %6, align 4, !tbaa !13
  %84 = load i32, ptr %6, align 4, !tbaa !13
  %85 = icmp ne i32 %84, 0
  br i1 %85, label %86, label %89

86:                                               ; preds = %77
  %87 = load i32, ptr %6, align 4, !tbaa !13
  %88 = call i32 @SMerror(i32 noundef 207, ptr noundef @.str.4, ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef %87, i32 noundef 0, ptr noundef null)
  store i32 %88, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %282

89:                                               ; preds = %77
  %90 = load ptr, ptr %5, align 8, !tbaa !5
  %91 = load i32, ptr %90, align 4, !tbaa !13
  %92 = icmp ne i32 %91, 0
  br i1 %92, label %281, label %93

93:                                               ; preds = %89
  %94 = load i32, ptr %9, align 4, !tbaa !13
  %95 = load i32, ptr %10, align 4, !tbaa !13
  %96 = load ptr, ptr %15, align 8, !tbaa !5
  %97 = load ptr, ptr %19, align 8, !tbaa !5
  %98 = load ptr, ptr %21, align 8, !tbaa !5
  %99 = call i32 @SMphaseOneLP(i32 noundef %94, i32 noundef %95, ptr noundef %96, ptr noundef %97, ptr noundef %98, ptr noundef %12)
  store i32 %99, ptr %6, align 4, !tbaa !13
  %100 = load i32, ptr %6, align 4, !tbaa !13
  %101 = icmp ne i32 %100, 0
  br i1 %101, label %102, label %105

102:                                              ; preds = %93
  %103 = load i32, ptr %6, align 4, !tbaa !13
  %104 = call i32 @SMerror(i32 noundef 214, ptr noundef @.str.4, ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef %103, i32 noundef 0, ptr noundef null)
  store i32 %104, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %282

105:                                              ; preds = %93
  %106 = load i32, ptr %12, align 4, !tbaa !13
  %107 = icmp ne i32 %106, 0
  br i1 %107, label %108, label %279

108:                                              ; preds = %105
  %109 = load ptr, ptr %19, align 8, !tbaa !5
  %110 = load i32, ptr %9, align 4, !tbaa !13
  %111 = sub nsw i32 %110, 1
  %112 = sext i32 %111 to i64
  %113 = getelementptr inbounds double, ptr %109, i64 %112
  store double 1.000000e+00, ptr %113, align 8, !tbaa !23
  store double 0.000000e+00, ptr %20, align 8, !tbaa !23
  store i32 0, ptr %7, align 4, !tbaa !13
  br label %114

114:                                              ; preds = %126, %108
  %115 = load i32, ptr %7, align 4, !tbaa !13
  %116 = load i32, ptr %9, align 4, !tbaa !13
  %117 = icmp slt i32 %115, %116
  br i1 %117, label %118, label %129

118:                                              ; preds = %114
  %119 = load ptr, ptr %19, align 8, !tbaa !5
  %120 = load i32, ptr %7, align 4, !tbaa !13
  %121 = sext i32 %120 to i64
  %122 = getelementptr inbounds double, ptr %119, i64 %121
  %123 = load double, ptr %122, align 8, !tbaa !23
  %124 = load double, ptr %20, align 8, !tbaa !23
  %125 = fadd double %124, %123
  store double %125, ptr %20, align 8, !tbaa !23
  br label %126

126:                                              ; preds = %118
  %127 = load i32, ptr %7, align 4, !tbaa !13
  %128 = add nsw i32 %127, 1
  store i32 %128, ptr %7, align 4, !tbaa !13
  br label %114, !llvm.loop !24

129:                                              ; preds = %114
  store i32 0, ptr %7, align 4, !tbaa !13
  br label %130

130:                                              ; preds = %156, %129
  %131 = load i32, ptr %7, align 4, !tbaa !13
  %132 = load i32, ptr %9, align 4, !tbaa !13
  %133 = icmp slt i32 %131, %132
  br i1 %133, label %134, label %159

134:                                              ; preds = %130
  %135 = load ptr, ptr %19, align 8, !tbaa !5
  %136 = load i32, ptr %7, align 4, !tbaa !13
  %137 = sext i32 %136 to i64
  %138 = getelementptr inbounds double, ptr %135, i64 %137
  %139 = load double, ptr %138, align 8, !tbaa !23
  %140 = load double, ptr %20, align 8, !tbaa !23
  %141 = fdiv double %139, %140
  %142 = load ptr, ptr %19, align 8, !tbaa !5
  %143 = load i32, ptr %7, align 4, !tbaa !13
  %144 = sext i32 %143 to i64
  %145 = getelementptr inbounds double, ptr %142, i64 %144
  store double %141, ptr %145, align 8, !tbaa !23
  %146 = load ptr, ptr %18, align 8, !tbaa !5
  %147 = load i32, ptr %7, align 4, !tbaa !13
  %148 = sext i32 %147 to i64
  %149 = getelementptr inbounds double, ptr %146, i64 %148
  %150 = load double, ptr %149, align 8, !tbaa !23
  %151 = fneg double %150
  %152 = load ptr, ptr %18, align 8, !tbaa !5
  %153 = load i32, ptr %7, align 4, !tbaa !13
  %154 = sext i32 %153 to i64
  %155 = getelementptr inbounds double, ptr %152, i64 %154
  store double %151, ptr %155, align 8, !tbaa !23
  br label %156

156:                                              ; preds = %134
  %157 = load i32, ptr %7, align 4, !tbaa !13
  %158 = add nsw i32 %157, 1
  store i32 %158, ptr %7, align 4, !tbaa !13
  br label %130, !llvm.loop !26

159:                                              ; preds = %130
  store i32 0, ptr %7, align 4, !tbaa !13
  br label %160

160:                                              ; preds = %220, %159
  %161 = load i32, ptr %7, align 4, !tbaa !13
  %162 = load i32, ptr %10, align 4, !tbaa !13
  %163 = add nsw i32 %162, 1
  %164 = icmp slt i32 %161, %163
  br i1 %164, label %165, label %223

165:                                              ; preds = %160
  %166 = load i32, ptr %7, align 4, !tbaa !13
  %167 = load i32, ptr %10, align 4, !tbaa !13
  %168 = icmp slt i32 %166, %167
  br i1 %168, label %169, label %197

169:                                              ; preds = %165
  store i32 0, ptr %8, align 4, !tbaa !13
  br label %170

170:                                              ; preds = %193, %169
  %171 = load i32, ptr %8, align 4, !tbaa !13
  %172 = load i32, ptr %9, align 4, !tbaa !13
  %173 = icmp slt i32 %171, %172
  br i1 %173, label %174, label %196

174:                                              ; preds = %170
  %175 = load ptr, ptr %15, align 8, !tbaa !5
  %176 = load i32, ptr %7, align 4, !tbaa !13
  %177 = sext i32 %176 to i64
  %178 = getelementptr inbounds ptr, ptr %175, i64 %177
  %179 = load ptr, ptr %178, align 8, !tbaa !5
  %180 = load i32, ptr %8, align 4, !tbaa !13
  %181 = sext i32 %180 to i64
  %182 = getelementptr inbounds double, ptr %179, i64 %181
  %183 = load double, ptr %182, align 8, !tbaa !23
  %184 = fneg double %183
  %185 = load ptr, ptr %16, align 8, !tbaa !5
  %186 = load i32, ptr %7, align 4, !tbaa !13
  %187 = sext i32 %186 to i64
  %188 = getelementptr inbounds ptr, ptr %185, i64 %187
  %189 = load ptr, ptr %188, align 8, !tbaa !5
  %190 = load i32, ptr %8, align 4, !tbaa !13
  %191 = sext i32 %190 to i64
  %192 = getelementptr inbounds double, ptr %189, i64 %191
  store double %184, ptr %192, align 8, !tbaa !23
  br label %193

193:                                              ; preds = %174
  %194 = load i32, ptr %8, align 4, !tbaa !13
  %195 = add nsw i32 %194, 1
  store i32 %195, ptr %8, align 4, !tbaa !13
  br label %170, !llvm.loop !27

196:                                              ; preds = %170
  br label %197

197:                                              ; preds = %196, %165
  %198 = load i32, ptr %7, align 4, !tbaa !13
  %199 = load i32, ptr %10, align 4, !tbaa !13
  %200 = icmp eq i32 %198, %199
  br i1 %200, label %201, label %219

201:                                              ; preds = %197
  store i32 0, ptr %8, align 4, !tbaa !13
  br label %202

202:                                              ; preds = %215, %201
  %203 = load i32, ptr %8, align 4, !tbaa !13
  %204 = load i32, ptr %9, align 4, !tbaa !13
  %205 = icmp slt i32 %203, %204
  br i1 %205, label %206, label %218

206:                                              ; preds = %202
  %207 = load ptr, ptr %16, align 8, !tbaa !5
  %208 = load i32, ptr %7, align 4, !tbaa !13
  %209 = sext i32 %208 to i64
  %210 = getelementptr inbounds ptr, ptr %207, i64 %209
  %211 = load ptr, ptr %210, align 8, !tbaa !5
  %212 = load i32, ptr %8, align 4, !tbaa !13
  %213 = sext i32 %212 to i64
  %214 = getelementptr inbounds double, ptr %211, i64 %213
  store double 1.000000e+00, ptr %214, align 8, !tbaa !23
  br label %215

215:                                              ; preds = %206
  %216 = load i32, ptr %8, align 4, !tbaa !13
  %217 = add nsw i32 %216, 1
  store i32 %217, ptr %8, align 4, !tbaa !13
  br label %202, !llvm.loop !28

218:                                              ; preds = %202
  br label %219

219:                                              ; preds = %218, %197
  br label %220

220:                                              ; preds = %219
  %221 = load i32, ptr %7, align 4, !tbaa !13
  %222 = add nsw i32 %221, 1
  store i32 %222, ptr %7, align 4, !tbaa !13
  br label %160, !llvm.loop !29

223:                                              ; preds = %160
  %224 = load i32, ptr %10, align 4, !tbaa !13
  %225 = add nsw i32 %224, 1
  store i32 %225, ptr %10, align 4, !tbaa !13
  %226 = load i32, ptr %9, align 4, !tbaa !13
  %227 = load i32, ptr %10, align 4, !tbaa !13
  %228 = load ptr, ptr %16, align 8, !tbaa !5
  %229 = load ptr, ptr %19, align 8, !tbaa !5
  %230 = load ptr, ptr %18, align 8, !tbaa !5
  %231 = load ptr, ptr %17, align 8, !tbaa !5
  %232 = load ptr, ptr %21, align 8, !tbaa !5
  %233 = call i32 @SMsolveLP(i32 noundef %226, i32 noundef %227, ptr noundef %228, ptr noundef %229, ptr noundef %230, ptr noundef %231, ptr noundef %232, ptr noundef %13)
  store i32 %233, ptr %6, align 4, !tbaa !13
  %234 = load i32, ptr %6, align 4, !tbaa !13
  %235 = icmp ne i32 %234, 0
  br i1 %235, label %236, label %239

236:                                              ; preds = %223
  %237 = load i32, ptr %6, align 4, !tbaa !13
  %238 = call i32 @SMerror(i32 noundef 242, ptr noundef @.str.4, ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef %237, i32 noundef 0, ptr noundef null)
  store i32 %238, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %282

239:                                              ; preds = %223
  %240 = load i32, ptr %13, align 4, !tbaa !13
  %241 = icmp ne i32 %240, 0
  br i1 %241, label %242, label %277

242:                                              ; preds = %239
  %243 = load ptr, ptr %17, align 8, !tbaa !5
  %244 = load ptr, ptr %4, align 8, !tbaa !5
  %245 = getelementptr inbounds %struct.__SMlocal_mesh, ptr %244, i32 0, i32 0
  %246 = load i32, ptr %245, align 8, !tbaa !14
  %247 = sext i32 %246 to i64
  %248 = getelementptr inbounds double, ptr %243, i64 %247
  %249 = load double, ptr %248, align 8, !tbaa !23
  %250 = fcmp oge double %249, 0.000000e+00
  br i1 %250, label %251, label %254

251:                                              ; preds = %242
  %252 = load ptr, ptr %4, align 8, !tbaa !5
  %253 = getelementptr inbounds %struct.__SMlocal_mesh, ptr %252, i32 0, i32 15
  store i32 1, ptr %253, align 8, !tbaa !30
  br label %255

254:                                              ; preds = %242
  br label %255

255:                                              ; preds = %254, %251
  store i32 0, ptr %7, align 4, !tbaa !13
  br label %256

256:                                              ; preds = %273, %255
  %257 = load i32, ptr %7, align 4, !tbaa !13
  %258 = load ptr, ptr %4, align 8, !tbaa !5
  %259 = getelementptr inbounds %struct.__SMlocal_mesh, ptr %258, i32 0, i32 0
  %260 = load i32, ptr %259, align 8, !tbaa !14
  %261 = icmp slt i32 %257, %260
  br i1 %261, label %262, label %276

262:                                              ; preds = %256
  %263 = load ptr, ptr %17, align 8, !tbaa !5
  %264 = load i32, ptr %7, align 4, !tbaa !13
  %265 = sext i32 %264 to i64
  %266 = getelementptr inbounds double, ptr %263, i64 %265
  %267 = load double, ptr %266, align 8, !tbaa !23
  %268 = load ptr, ptr %4, align 8, !tbaa !5
  %269 = getelementptr inbounds %struct.__SMlocal_mesh, ptr %268, i32 0, i32 5
  %270 = load i32, ptr %7, align 4, !tbaa !13
  %271 = sext i32 %270 to i64
  %272 = getelementptr inbounds [3 x double], ptr %269, i64 0, i64 %271
  store double %267, ptr %272, align 8, !tbaa !23
  br label %273

273:                                              ; preds = %262
  %274 = load i32, ptr %7, align 4, !tbaa !13
  %275 = add nsw i32 %274, 1
  store i32 %275, ptr %7, align 4, !tbaa !13
  br label %256, !llvm.loop !31

276:                                              ; preds = %256
  br label %278

277:                                              ; preds = %239
  br label %278

278:                                              ; preds = %277, %276
  br label %280

279:                                              ; preds = %105
  br label %280

280:                                              ; preds = %279, %278
  store i32 0, ptr %6, align 4, !tbaa !13
  store i32 0, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %282

281:                                              ; preds = %89
  store i32 0, ptr %6, align 4, !tbaa !13
  store i32 0, ptr %3, align 4
  store i32 1, ptr %22, align 4
  br label %282

282:                                              ; preds = %281, %280, %236, %102, %86, %74, %37
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #3
  %283 = load i32, ptr %3, align 4
  ret i32 %283
}

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

declare i32 @SMinitLP(ptr noundef) #1

; Function Attrs: nounwind uwtable
declare dso_local i32 @SMcomputeConstraintMatrix(ptr noundef, i32 noundef, ptr noundef, ptr noundef) #2

declare i32 @SMtransposeMatrix2(ptr noundef, i32 noundef, i32 noundef, ptr noundef) #1

; Function Attrs: nounwind uwtable
declare dso_local i32 @SMdegenerate(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: nounwind uwtable
declare dso_local i32 @SMphaseOneLP(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: nounwind uwtable
declare dso_local i32 @SMsolveLP(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 = { 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 = { 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/C++ TBAA"}
!9 = !{!10, !11, i64 8}
!10 = !{!"__SMlocal_mesh", !11, i64 0, !11, i64 4, !11, i64 8, !7, i64 16, !7, i64 40, !7, i64 64, !6, i64 88, !6, i64 96, !6, i64 104, !11, i64 112, !12, i64 120, !6, i64 128, !12, i64 136, !11, i64 144, !11, i64 148, !11, i64 152, !6, i64 160, !6, i64 168, !6, i64 176}
!11 = !{!"int", !7, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!11, !11, i64 0}
!14 = !{!10, !11, i64 0}
!15 = !{!10, !6, i64 176}
!16 = !{!17, !6, i64 0}
!17 = !{!"__SMlp", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120}
!18 = !{!17, !6, i64 8}
!19 = !{!17, !6, i64 16}
!20 = !{!17, !6, i64 24}
!21 = !{!17, !6, i64 64}
!22 = !{!17, !6, i64 72}
!23 = !{!12, !12, i64 0}
!24 = distinct !{!24, !25}
!25 = !{!"llvm.loop.mustprogress"}
!26 = distinct !{!26, !25}
!27 = distinct !{!27, !25}
!28 = distinct !{!28, !25}
!29 = distinct !{!29, !25}
!30 = !{!10, !11, i64 152}
!31 = distinct !{!31, !25}


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

@.str.1 = external hidden unnamed_addr constant [110 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [16 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 @SMerror(i32 noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local i32 @SMuntangle_mesh(ptr noundef %0, ptr noundef %1) local_unnamed_addr #2 {
  %3 = ptrtoint ptr %0 to i64
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #3
  %6 = getelementptr inbounds i8, ptr %0, i64 8
  %7 = load i32, ptr %6, align 8, !tbaa !5
  %.fr153 = freeze i32 %7
  %8 = load i32, ptr %0, align 8, !tbaa !12
  store i32 0, ptr %1, align 4, !tbaa !13
  %9 = tail call i32 @SMinitLP(ptr noundef nonnull %0) #3
  %.not = icmp eq i32 %9, 0
  br i1 %.not, label %12, label %10

10:                                               ; preds = %2
  %11 = tail call i32 @SMerror(i32 noundef 191, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef %9, i32 noundef 0, ptr noundef null) #3
  br label %.loopexit

12:                                               ; preds = %2
  %13 = getelementptr inbounds i8, ptr %0, i64 176
  %14 = load ptr, ptr %13, align 8, !tbaa !14
  %15 = load ptr, ptr %14, align 8, !tbaa !15
  %16 = getelementptr inbounds i8, ptr %14, i64 8
  %17 = load ptr, ptr %16, align 8, !tbaa !17
  %18 = getelementptr inbounds i8, ptr %14, i64 16
  %19 = load ptr, ptr %18, align 8, !tbaa !18
  %20 = getelementptr inbounds i8, ptr %14, i64 24
  %21 = load ptr, ptr %20, align 8, !tbaa !19
  %22 = getelementptr inbounds i8, ptr %14, i64 64
  %23 = load ptr, ptr %22, align 8, !tbaa !20
  %24 = getelementptr inbounds i8, ptr %14, i64 72
  %25 = load ptr, ptr %24, align 8, !tbaa !21
  %26 = ptrtoint ptr %25 to i64
  %27 = tail call i32 @SMcomputeConstraintMatrix(ptr noundef nonnull %0, i32 noundef %.fr153, ptr noundef %15, ptr noundef %23)
  %28 = tail call i32 @SMtransposeMatrix2(ptr noundef %15, i32 noundef %.fr153, i32 noundef %8, ptr noundef %17) #3
  %.not113 = icmp eq i32 %28, 0
  br i1 %.not113, label %31, label %29

29:                                               ; preds = %12
  %30 = tail call i32 @SMerror(i32 noundef 205, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef %28, i32 noundef 0, ptr noundef null) #3
  br label %.loopexit

31:                                               ; preds = %12
  %32 = tail call i32 @SMdegenerate(i32 noundef %8, i32 noundef %.fr153, ptr noundef %17, ptr noundef %23, ptr noundef nonnull %1)
  %.not114 = icmp eq i32 %32, 0
  br i1 %.not114, label %35, label %33

33:                                               ; preds = %31
  %34 = tail call i32 @SMerror(i32 noundef 207, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef %32, i32 noundef 0, ptr noundef null) #3
  br label %.loopexit

35:                                               ; preds = %31
  %36 = load i32, ptr %1, align 4, !tbaa !13
  %.not115 = icmp eq i32 %36, 0
  br i1 %.not115, label %37, label %.loopexit

37:                                               ; preds = %35
  %38 = call i32 @SMphaseOneLP(i32 noundef %.fr153, i32 noundef %8, ptr noundef %17, ptr noundef %21, ptr noundef nonnull %14, ptr noundef nonnull %4)
  %.not116 = icmp eq i32 %38, 0
  br i1 %.not116, label %41, label %39

39:                                               ; preds = %37
  %40 = call i32 @SMerror(i32 noundef 214, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef %38, i32 noundef 0, ptr noundef null) #3
  br label %.loopexit

41:                                               ; preds = %37
  %42 = load i32, ptr %4, align 4, !tbaa !13
  %.not117 = icmp eq i32 %42, 0
  br i1 %.not117, label %.loopexit, label %43

43:                                               ; preds = %41
  %44 = sext i32 %.fr153 to i64
  %45 = getelementptr double, ptr %21, i64 %44
  %46 = getelementptr i8, ptr %45, i64 -8
  store double 1.000000e+00, ptr %46, align 8, !tbaa !22
  %47 = icmp sgt i32 %.fr153, 0
  br i1 %47, label %.lr.ph.preheader, label %.preheader124

.lr.ph.preheader:                                 ; preds = %43
  %wide.trip.count = zext nneg i32 %.fr153 to i64
  %xtraiter = and i64 %wide.trip.count, 7
  %48 = icmp ult i32 %.fr153, 8
  br i1 %48, label %.preheader125.unr-lcssa, label %.lr.ph.preheader.new

.lr.ph.preheader.new:                             ; preds = %.lr.ph.preheader
  %unroll_iter = and i64 %wide.trip.count, 2147483640
  br label %.lr.ph

.preheader125.unr-lcssa:                          ; preds = %.lr.ph, %.lr.ph.preheader
  %.lcssa.ph = phi double [ poison, %.lr.ph.preheader ], [ %89, %.lr.ph ]
  %indvars.iv.unr = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next.7, %.lr.ph ]
  %.0102127.unr = phi double [ 0.000000e+00, %.lr.ph.preheader ], [ %89, %.lr.ph ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.preheader125, label %.lr.ph.epil

.lr.ph.epil:                                      ; preds = %.preheader125.unr-lcssa, %.lr.ph.epil
  %indvars.iv.epil = phi i64 [ %indvars.iv.next.epil, %.lr.ph.epil ], [ %indvars.iv.unr, %.preheader125.unr-lcssa ]
  %.0102127.epil = phi double [ %51, %.lr.ph.epil ], [ %.0102127.unr, %.preheader125.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.lr.ph.epil ], [ 0, %.preheader125.unr-lcssa ]
  %49 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.epil
  %50 = load double, ptr %49, align 8, !tbaa !22
  %51 = fadd double %.0102127.epil, %50
  %indvars.iv.next.epil = add nuw nsw i64 %indvars.iv.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 %.preheader125, label %.lr.ph.epil, !llvm.loop !23

.preheader125:                                    ; preds = %.lr.ph.epil, %.preheader125.unr-lcssa
  %.lcssa = phi double [ %.lcssa.ph, %.preheader125.unr-lcssa ], [ %51, %.lr.ph.epil ]
  br i1 %47, label %.lr.ph129.preheader, label %.preheader124

.lr.ph129.preheader:                              ; preds = %.preheader125
  %wide.trip.count160 = zext nneg i32 %.fr153 to i64
  %min.iters.check = icmp eq i32 %.fr153, 1
  br i1 %min.iters.check, label %.lr.ph129.preheader237, label %vector.memcheck

.lr.ph129.preheader237:                           ; preds = %middle.block, %vector.memcheck, %.lr.ph129.preheader
  %indvars.iv157.ph = phi i64 [ 0, %vector.memcheck ], [ 0, %.lr.ph129.preheader ], [ %n.vec, %middle.block ]
  %xtraiter239 = and i64 %wide.trip.count, 1
  %lcmp.mod240.not = icmp eq i64 %xtraiter239, 0
  br i1 %lcmp.mod240.not, label %.lr.ph129.prol.loopexit, label %.lr.ph129.prol

.lr.ph129.prol:                                   ; preds = %.lr.ph129.preheader237
  %52 = getelementptr inbounds double, ptr %21, i64 %indvars.iv157.ph
  %53 = load double, ptr %52, align 8, !tbaa !22
  %54 = fdiv double %53, %.lcssa
  store double %54, ptr %52, align 8, !tbaa !22
  %55 = getelementptr inbounds double, ptr %23, i64 %indvars.iv157.ph
  %56 = load double, ptr %55, align 8, !tbaa !22
  %57 = fneg double %56
  store double %57, ptr %55, align 8, !tbaa !22
  %indvars.iv.next158.prol = or disjoint i64 %indvars.iv157.ph, 1
  br label %.lr.ph129.prol.loopexit

.lr.ph129.prol.loopexit:                          ; preds = %.lr.ph129.prol, %.lr.ph129.preheader237
  %indvars.iv157.unr = phi i64 [ %indvars.iv157.ph, %.lr.ph129.preheader237 ], [ %indvars.iv.next158.prol, %.lr.ph129.prol ]
  %58 = add nsw i64 %wide.trip.count, -1
  %59 = icmp eq i64 %indvars.iv157.ph, %58
  br i1 %59, label %.preheader124, label %.lr.ph129

vector.memcheck:                                  ; preds = %.lr.ph129.preheader
  %60 = shl nuw nsw i64 %wide.trip.count, 3
  %scevgep = getelementptr i8, ptr %21, i64 %60
  %scevgep193 = getelementptr i8, ptr %23, i64 %60
  %bound0 = icmp ult ptr %21, %scevgep193
  %bound1 = icmp ult ptr %23, %scevgep
  %found.conflict = and i1 %bound0, %bound1
  br i1 %found.conflict, label %.lr.ph129.preheader237, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %n.vec = and i64 %wide.trip.count, 2147483646
  %broadcast.splatinsert = insertelement <2 x double> poison, double %.lcssa, i64 0
  %broadcast.splat = shufflevector <2 x double> %broadcast.splatinsert, <2 x double> poison, <2 x i32> zeroinitializer
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %61 = getelementptr inbounds double, ptr %21, i64 %index
  %wide.load = load <2 x double>, ptr %61, align 8, !tbaa !22, !alias.scope !25, !noalias !28
  %62 = fdiv <2 x double> %wide.load, %broadcast.splat
  store <2 x double> %62, ptr %61, align 8, !tbaa !22, !alias.scope !25, !noalias !28
  %63 = getelementptr inbounds double, ptr %23, i64 %index
  %wide.load194 = load <2 x double>, ptr %63, align 8, !tbaa !22, !alias.scope !28
  %64 = fneg <2 x double> %wide.load194
  store <2 x double> %64, ptr %63, align 8, !tbaa !22, !alias.scope !28
  %index.next = add nuw i64 %index, 2
  %65 = icmp eq i64 %index.next, %n.vec
  br i1 %65, label %middle.block, label %vector.body, !llvm.loop !30

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br i1 %cmp.n, label %.preheader124, label %.lr.ph129.preheader237

.lr.ph:                                           ; preds = %.lr.ph, %.lr.ph.preheader.new
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader.new ], [ %indvars.iv.next.7, %.lr.ph ]
  %.0102127 = phi double [ 0.000000e+00, %.lr.ph.preheader.new ], [ %89, %.lr.ph ]
  %niter = phi i64 [ 0, %.lr.ph.preheader.new ], [ %niter.next.7, %.lr.ph ]
  %66 = getelementptr inbounds double, ptr %21, i64 %indvars.iv
  %67 = load double, ptr %66, align 8, !tbaa !22
  %68 = fadd double %.0102127, %67
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %69 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.next
  %70 = load double, ptr %69, align 8, !tbaa !22
  %71 = fadd double %68, %70
  %indvars.iv.next.1 = or disjoint i64 %indvars.iv, 2
  %72 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.next.1
  %73 = load double, ptr %72, align 8, !tbaa !22
  %74 = fadd double %71, %73
  %indvars.iv.next.2 = or disjoint i64 %indvars.iv, 3
  %75 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.next.2
  %76 = load double, ptr %75, align 8, !tbaa !22
  %77 = fadd double %74, %76
  %indvars.iv.next.3 = or disjoint i64 %indvars.iv, 4
  %78 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.next.3
  %79 = load double, ptr %78, align 8, !tbaa !22
  %80 = fadd double %77, %79
  %indvars.iv.next.4 = or disjoint i64 %indvars.iv, 5
  %81 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.next.4
  %82 = load double, ptr %81, align 8, !tbaa !22
  %83 = fadd double %80, %82
  %indvars.iv.next.5 = or disjoint i64 %indvars.iv, 6
  %84 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.next.5
  %85 = load double, ptr %84, align 8, !tbaa !22
  %86 = fadd double %83, %85
  %indvars.iv.next.6 = or disjoint i64 %indvars.iv, 7
  %87 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.next.6
  %88 = load double, ptr %87, align 8, !tbaa !22
  %89 = fadd double %86, %88
  %indvars.iv.next.7 = add nuw nsw i64 %indvars.iv, 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 %.preheader125.unr-lcssa, label %.lr.ph, !llvm.loop !34

.preheader124:                                    ; preds = %.lr.ph129.prol.loopexit, %.lr.ph129, %middle.block, %43, %.preheader125
  %.not118134 = icmp slt i32 %8, 0
  br i1 %.not118134, label %._crit_edge, label %.lr.ph138

.lr.ph138:                                        ; preds = %.preheader124
  %90 = icmp slt i32 %.fr153, 1
  br i1 %47, label %.lr.ph138.split.us.preheader, label %._crit_edge

.lr.ph138.split.us.preheader:                     ; preds = %.lr.ph138
  %91 = zext nneg i32 %8 to i64
  %92 = zext nneg i32 %8 to i64
  %93 = add nuw i32 %8, 1
  %wide.trip.count185 = zext i32 %93 to i64
  %wide.trip.count175 = zext nneg i32 %.fr153 to i64
  %94 = getelementptr inbounds ptr, ptr %19, i64 %92
  %wide.trip.count180 = zext nneg i32 %.fr153 to i64
  %min.iters.check209 = icmp ult i32 %.fr153, 4
  %n.vec212 = and i64 %wide.trip.count175, 2147483644
  %cmp.n219 = icmp eq i64 %n.vec212, %wide.trip.count175
  %xtraiter241 = and i64 %wide.trip.count175, 3
  %lcmp.mod242.not = icmp eq i64 %xtraiter241, 0
  %min.iters.check197 = icmp ult i32 %.fr153, 4
  %n.vec200 = and i64 %wide.trip.count175, 2147483644
  %cmp.n205 = icmp eq i64 %n.vec200, %wide.trip.count175
  br label %.lr.ph138.split.us

.lr.ph138.split.us:                               ; preds = %.lr.ph138.split.us.preheader, %.loopexit121.us
  %indvars.iv182 = phi i64 [ 0, %.lr.ph138.split.us.preheader ], [ %indvars.iv.next183, %.loopexit121.us ]
  %95 = icmp ult i64 %indvars.iv182, %91
  br i1 %95, label %.preheader122.us, label %..loopexit123_crit_edge.us

..loopexit123_crit_edge.us:                       ; preds = %scalar.ph208.prol.loopexit, %scalar.ph208, %middle.block207, %.lr.ph138.split.us
  %96 = icmp ne i64 %indvars.iv182, %92
  %brmerge = or i1 %96, %90
  br i1 %brmerge, label %.loopexit121.us, label %.lr.ph133.us

.loopexit121.us:                                  ; preds = %scalar.ph196, %middle.block195, %..loopexit123_crit_edge.us
  %indvars.iv.next183 = add nuw nsw i64 %indvars.iv182, 1
  %exitcond186.not = icmp eq i64 %indvars.iv.next183, %wide.trip.count185
  br i1 %exitcond186.not, label %._crit_edge, label %.lr.ph138.split.us, !llvm.loop !35

scalar.ph196:                                     ; preds = %scalar.ph196.preheader, %scalar.ph196
  %indvars.iv177 = phi i64 [ %indvars.iv.next178, %scalar.ph196 ], [ %indvars.iv177.ph, %scalar.ph196.preheader ]
  %97 = getelementptr inbounds double, ptr %134, i64 %indvars.iv177
  store double 1.000000e+00, ptr %97, align 8, !tbaa !22
  %indvars.iv.next178 = add nuw nsw i64 %indvars.iv177, 1
  %exitcond181.not = icmp eq i64 %indvars.iv.next178, %wide.trip.count180
  br i1 %exitcond181.not, label %.loopexit121.us, label %scalar.ph196, !llvm.loop !36

scalar.ph208:                                     ; preds = %scalar.ph208.prol.loopexit, %scalar.ph208
  %indvars.iv172 = phi i64 [ %indvars.iv.next173.3, %scalar.ph208 ], [ %indvars.iv172.unr, %scalar.ph208.prol.loopexit ]
  %98 = getelementptr inbounds double, ptr %115, i64 %indvars.iv172
  %99 = load double, ptr %98, align 8, !tbaa !22
  %100 = fneg double %99
  %101 = getelementptr inbounds double, ptr %117, i64 %indvars.iv172
  store double %100, ptr %101, align 8, !tbaa !22
  %indvars.iv.next173 = add nuw nsw i64 %indvars.iv172, 1
  %102 = getelementptr inbounds double, ptr %115, i64 %indvars.iv.next173
  %103 = load double, ptr %102, align 8, !tbaa !22
  %104 = fneg double %103
  %105 = getelementptr inbounds double, ptr %117, i64 %indvars.iv.next173
  store double %104, ptr %105, align 8, !tbaa !22
  %indvars.iv.next173.1 = add nuw nsw i64 %indvars.iv172, 2
  %106 = getelementptr inbounds double, ptr %115, i64 %indvars.iv.next173.1
  %107 = load double, ptr %106, align 8, !tbaa !22
  %108 = fneg double %107
  %109 = getelementptr inbounds double, ptr %117, i64 %indvars.iv.next173.1
  store double %108, ptr %109, align 8, !tbaa !22
  %indvars.iv.next173.2 = add nuw nsw i64 %indvars.iv172, 3
  %110 = getelementptr inbounds double, ptr %115, i64 %indvars.iv.next173.2
  %111 = load double, ptr %110, align 8, !tbaa !22
  %112 = fneg double %111
  %113 = getelementptr inbounds double, ptr %117, i64 %indvars.iv.next173.2
  store double %112, ptr %113, align 8, !tbaa !22
  %indvars.iv.next173.3 = add nuw nsw i64 %indvars.iv172, 4
  %exitcond176.not.3 = icmp eq i64 %indvars.iv.next173.3, %wide.trip.count175
  br i1 %exitcond176.not.3, label %..loopexit123_crit_edge.us, label %scalar.ph208, !llvm.loop !37

.preheader122.us:                                 ; preds = %.lr.ph138.split.us
  %114 = getelementptr inbounds ptr, ptr %17, i64 %indvars.iv182
  %115 = load ptr, ptr %114, align 8, !tbaa !38
  %116 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv182
  %117 = load ptr, ptr %116, align 8, !tbaa !38
  %118 = ptrtoint ptr %117 to i64
  %119 = ptrtoint ptr %115 to i64
  %120 = sub i64 %118, %119
  %diff.check = icmp ult i64 %120, 32
  %or.cond = select i1 %min.iters.check209, i1 true, i1 %diff.check
  br i1 %or.cond, label %scalar.ph208.preheader, label %vector.body214

scalar.ph208.preheader:                           ; preds = %middle.block207, %.preheader122.us
  %indvars.iv172.ph = phi i64 [ 0, %.preheader122.us ], [ %n.vec212, %middle.block207 ]
  br i1 %lcmp.mod242.not, label %scalar.ph208.prol.loopexit, label %scalar.ph208.prol

scalar.ph208.prol:                                ; preds = %scalar.ph208.preheader, %scalar.ph208.prol
  %indvars.iv172.prol = phi i64 [ %indvars.iv.next173.prol, %scalar.ph208.prol ], [ %indvars.iv172.ph, %scalar.ph208.preheader ]
  %prol.iter = phi i64 [ %prol.iter.next, %scalar.ph208.prol ], [ 0, %scalar.ph208.preheader ]
  %121 = getelementptr inbounds double, ptr %115, i64 %indvars.iv172.prol
  %122 = load double, ptr %121, align 8, !tbaa !22
  %123 = fneg double %122
  %124 = getelementptr inbounds double, ptr %117, i64 %indvars.iv172.prol
  store double %123, ptr %124, align 8, !tbaa !22
  %indvars.iv.next173.prol = add nuw nsw i64 %indvars.iv172.prol, 1
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter241
  br i1 %prol.iter.cmp.not, label %scalar.ph208.prol.loopexit, label %scalar.ph208.prol, !llvm.loop !39

scalar.ph208.prol.loopexit:                       ; preds = %scalar.ph208.prol, %scalar.ph208.preheader
  %indvars.iv172.unr = phi i64 [ %indvars.iv172.ph, %scalar.ph208.preheader ], [ %indvars.iv.next173.prol, %scalar.ph208.prol ]
  %125 = sub nsw i64 %indvars.iv172.ph, %wide.trip.count175
  %126 = icmp ugt i64 %125, -4
  br i1 %126, label %..loopexit123_crit_edge.us, label %scalar.ph208

vector.body214:                                   ; preds = %.preheader122.us, %vector.body214
  %index215 = phi i64 [ %index.next218, %vector.body214 ], [ 0, %.preheader122.us ]
  %127 = getelementptr inbounds double, ptr %115, i64 %index215
  %128 = getelementptr inbounds i8, ptr %127, i64 16
  %wide.load216 = load <2 x double>, ptr %127, align 8, !tbaa !22
  %wide.load217 = load <2 x double>, ptr %128, align 8, !tbaa !22
  %129 = fneg <2 x double> %wide.load216
  %130 = fneg <2 x double> %wide.load217
  %131 = getelementptr inbounds double, ptr %117, i64 %index215
  %132 = getelementptr inbounds i8, ptr %131, i64 16
  store <2 x double> %129, ptr %131, align 8, !tbaa !22
  store <2 x double> %130, ptr %132, align 8, !tbaa !22
  %index.next218 = add nuw i64 %index215, 4
  %133 = icmp eq i64 %index.next218, %n.vec212
  br i1 %133, label %middle.block207, label %vector.body214, !llvm.loop !40

middle.block207:                                  ; preds = %vector.body214
  br i1 %cmp.n219, label %..loopexit123_crit_edge.us, label %scalar.ph208.preheader

.lr.ph133.us:                                     ; preds = %..loopexit123_crit_edge.us
  %134 = load ptr, ptr %94, align 8, !tbaa !38
  br i1 %min.iters.check197, label %scalar.ph196.preheader, label %vector.body202

scalar.ph196.preheader:                           ; preds = %middle.block195, %.lr.ph133.us
  %indvars.iv177.ph = phi i64 [ 0, %.lr.ph133.us ], [ %n.vec200, %middle.block195 ]
  br label %scalar.ph196

vector.body202:                                   ; preds = %.lr.ph133.us, %vector.body202
  %index203 = phi i64 [ %index.next204, %vector.body202 ], [ 0, %.lr.ph133.us ]
  %135 = getelementptr inbounds double, ptr %134, i64 %index203
  %136 = getelementptr inbounds i8, ptr %135, i64 16
  store <2 x double> <double 1.000000e+00, double 1.000000e+00>, ptr %135, align 8, !tbaa !22
  store <2 x double> <double 1.000000e+00, double 1.000000e+00>, ptr %136, align 8, !tbaa !22
  %index.next204 = add nuw i64 %index203, 4
  %137 = icmp eq i64 %index.next204, %n.vec200
  br i1 %137, label %middle.block195, label %vector.body202, !llvm.loop !41

middle.block195:                                  ; preds = %vector.body202
  br i1 %cmp.n205, label %.loopexit121.us, label %scalar.ph196.preheader

.lr.ph129:                                        ; preds = %.lr.ph129.prol.loopexit, %.lr.ph129
  %indvars.iv157 = phi i64 [ %indvars.iv.next158.1, %.lr.ph129 ], [ %indvars.iv157.unr, %.lr.ph129.prol.loopexit ]
  %138 = getelementptr inbounds double, ptr %21, i64 %indvars.iv157
  %139 = load double, ptr %138, align 8, !tbaa !22
  %140 = fdiv double %139, %.lcssa
  store double %140, ptr %138, align 8, !tbaa !22
  %141 = getelementptr inbounds double, ptr %23, i64 %indvars.iv157
  %142 = load double, ptr %141, align 8, !tbaa !22
  %143 = fneg double %142
  store double %143, ptr %141, align 8, !tbaa !22
  %indvars.iv.next158 = add nuw nsw i64 %indvars.iv157, 1
  %144 = getelementptr inbounds double, ptr %21, i64 %indvars.iv.next158
  %145 = load double, ptr %144, align 8, !tbaa !22
  %146 = fdiv double %145, %.lcssa
  store double %146, ptr %144, align 8, !tbaa !22
  %147 = getelementptr inbounds double, ptr %23, i64 %indvars.iv.next158
  %148 = load double, ptr %147, align 8, !tbaa !22
  %149 = fneg double %148
  store double %149, ptr %147, align 8, !tbaa !22
  %indvars.iv.next158.1 = add nuw nsw i64 %indvars.iv157, 2
  %exitcond161.not.1 = icmp eq i64 %indvars.iv.next158.1, %wide.trip.count160
  br i1 %exitcond161.not.1, label %.preheader124, label %.lr.ph129, !llvm.loop !42

._crit_edge:                                      ; preds = %.loopexit121.us, %.lr.ph138, %.preheader124
  %150 = add nsw i32 %8, 1
  %151 = call i32 @SMsolveLP(i32 noundef %.fr153, i32 noundef %150, ptr noundef %19, ptr noundef %21, ptr noundef %23, ptr noundef %25, ptr noundef nonnull %14, ptr noundef nonnull %5)
  %.not119 = icmp eq i32 %151, 0
  br i1 %.not119, label %154, label %152

152:                                              ; preds = %._crit_edge
  %153 = call i32 @SMerror(i32 noundef 242, ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef %151, i32 noundef 0, ptr noundef null) #3
  br label %.loopexit

154:                                              ; preds = %._crit_edge
  %155 = load i32, ptr %5, align 4, !tbaa !13
  %.not120 = icmp eq i32 %155, 0
  br i1 %.not120, label %.loopexit, label %156

156:                                              ; preds = %154
  %157 = load i32, ptr %0, align 8, !tbaa !12
  %158 = sext i32 %157 to i64
  %159 = getelementptr inbounds double, ptr %25, i64 %158
  %160 = load double, ptr %159, align 8, !tbaa !22
  %161 = fcmp ult double %160, 0.000000e+00
  br i1 %161, label %164, label %162

162:                                              ; preds = %156
  %163 = getelementptr inbounds i8, ptr %0, i64 152
  store i32 1, ptr %163, align 8, !tbaa !43
  br label %164

164:                                              ; preds = %156, %162
  %165 = icmp sgt i32 %157, 0
  br i1 %165, label %.lr.ph150, label %.loopexit

.lr.ph150:                                        ; preds = %164
  %166 = getelementptr inbounds i8, ptr %0, i64 64
  %wide.trip.count190 = zext nneg i32 %157 to i64
  %min.iters.check224 = icmp ult i32 %157, 8
  br i1 %min.iters.check224, label %scalar.ph223.preheader, label %vector.memcheck220

vector.memcheck220:                               ; preds = %.lr.ph150
  %167 = add i64 %3, 64
  %168 = sub i64 %167, %26
  %diff.check221 = icmp ult i64 %168, 32
  br i1 %diff.check221, label %scalar.ph223.preheader, label %vector.ph225

vector.ph225:                                     ; preds = %vector.memcheck220
  %n.vec227 = and i64 %wide.trip.count190, 2147483644
  br label %vector.body229

vector.body229:                                   ; preds = %vector.body229, %vector.ph225
  %index230 = phi i64 [ 0, %vector.ph225 ], [ %index.next233, %vector.body229 ]
  %169 = getelementptr inbounds double, ptr %25, i64 %index230
  %170 = getelementptr inbounds i8, ptr %169, i64 16
  %wide.load231 = load <2 x double>, ptr %169, align 8, !tbaa !22
  %wide.load232 = load <2 x double>, ptr %170, align 8, !tbaa !22
  %171 = getelementptr inbounds [3 x double], ptr %166, i64 0, i64 %index230
  %172 = getelementptr inbounds i8, ptr %171, i64 16
  store <2 x double> %wide.load231, ptr %171, align 8, !tbaa !22
  store <2 x double> %wide.load232, ptr %172, align 8, !tbaa !22
  %index.next233 = add nuw i64 %index230, 4
  %173 = icmp eq i64 %index.next233, %n.vec227
  br i1 %173, label %middle.block222, label %vector.body229, !llvm.loop !44

middle.block222:                                  ; preds = %vector.body229
  %cmp.n234 = icmp eq i64 %n.vec227, %wide.trip.count190
  br i1 %cmp.n234, label %.loopexit, label %scalar.ph223.preheader

scalar.ph223.preheader:                           ; preds = %middle.block222, %vector.memcheck220, %.lr.ph150
  %indvars.iv187.ph = phi i64 [ 0, %vector.memcheck220 ], [ 0, %.lr.ph150 ], [ %n.vec227, %middle.block222 ]
  %xtraiter243 = and i64 %wide.trip.count190, 3
  %lcmp.mod244.not = icmp eq i64 %xtraiter243, 0
  br i1 %lcmp.mod244.not, label %scalar.ph223.prol.loopexit, label %scalar.ph223.prol

scalar.ph223.prol:                                ; preds = %scalar.ph223.preheader, %scalar.ph223.prol
  %indvars.iv187.prol = phi i64 [ %indvars.iv.next188.prol, %scalar.ph223.prol ], [ %indvars.iv187.ph, %scalar.ph223.preheader ]
  %prol.iter245 = phi i64 [ %prol.iter245.next, %scalar.ph223.prol ], [ 0, %scalar.ph223.preheader ]
  %174 = getelementptr inbounds double, ptr %25, i64 %indvars.iv187.prol
  %175 = load double, ptr %174, align 8, !tbaa !22
  %176 = getelementptr inbounds [3 x double], ptr %166, i64 0, i64 %indvars.iv187.prol
  store double %175, ptr %176, align 8, !tbaa !22
  %indvars.iv.next188.prol = add nuw nsw i64 %indvars.iv187.prol, 1
  %prol.iter245.next = add i64 %prol.iter245, 1
  %prol.iter245.cmp.not = icmp eq i64 %prol.iter245.next, %xtraiter243
  br i1 %prol.iter245.cmp.not, label %scalar.ph223.prol.loopexit, label %scalar.ph223.prol, !llvm.loop !45

scalar.ph223.prol.loopexit:                       ; preds = %scalar.ph223.prol, %scalar.ph223.preheader
  %indvars.iv187.unr = phi i64 [ %indvars.iv187.ph, %scalar.ph223.preheader ], [ %indvars.iv.next188.prol, %scalar.ph223.prol ]
  %177 = sub nsw i64 %indvars.iv187.ph, %wide.trip.count190
  %178 = icmp ugt i64 %177, -4
  br i1 %178, label %.loopexit, label %scalar.ph223

scalar.ph223:                                     ; preds = %scalar.ph223.prol.loopexit, %scalar.ph223
  %indvars.iv187 = phi i64 [ %indvars.iv.next188.3, %scalar.ph223 ], [ %indvars.iv187.unr, %scalar.ph223.prol.loopexit ]
  %179 = getelementptr inbounds double, ptr %25, i64 %indvars.iv187
  %180 = load double, ptr %179, align 8, !tbaa !22
  %181 = getelementptr inbounds [3 x double], ptr %166, i64 0, i64 %indvars.iv187
  store double %180, ptr %181, align 8, !tbaa !22
  %indvars.iv.next188 = add nuw nsw i64 %indvars.iv187, 1
  %182 = getelementptr inbounds double, ptr %25, i64 %indvars.iv.next188
  %183 = load double, ptr %182, align 8, !tbaa !22
  %184 = getelementptr inbounds [3 x double], ptr %166, i64 0, i64 %indvars.iv.next188
  store double %183, ptr %184, align 8, !tbaa !22
  %indvars.iv.next188.1 = add nuw nsw i64 %indvars.iv187, 2
  %185 = getelementptr inbounds double, ptr %25, i64 %indvars.iv.next188.1
  %186 = load double, ptr %185, align 8, !tbaa !22
  %187 = getelementptr inbounds [3 x double], ptr %166, i64 0, i64 %indvars.iv.next188.1
  store double %186, ptr %187, align 8, !tbaa !22
  %indvars.iv.next188.2 = add nuw nsw i64 %indvars.iv187, 3
  %188 = getelementptr inbounds double, ptr %25, i64 %indvars.iv.next188.2
  %189 = load double, ptr %188, align 8, !tbaa !22
  %190 = getelementptr inbounds [3 x double], ptr %166, i64 0, i64 %indvars.iv.next188.2
  store double %189, ptr %190, align 8, !tbaa !22
  %indvars.iv.next188.3 = add nuw nsw i64 %indvars.iv187, 4
  %exitcond191.not.3 = icmp eq i64 %indvars.iv.next188.3, %wide.trip.count190
  br i1 %exitcond191.not.3, label %.loopexit, label %scalar.ph223, !llvm.loop !46

.loopexit:                                        ; preds = %scalar.ph223.prol.loopexit, %scalar.ph223, %middle.block222, %164, %35, %154, %41, %152, %39, %33, %29, %10
  %.0 = phi i32 [ %11, %10 ], [ %30, %29 ], [ %34, %33 ], [ %40, %39 ], [ %153, %152 ], [ 0, %41 ], [ 0, %154 ], [ 0, %35 ], [ 0, %164 ], [ 0, %middle.block222 ], [ 0, %scalar.ph223 ], [ 0, %scalar.ph223.prol.loopexit ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #3
  ret i32 %.0
}

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

declare i32 @SMinitLP(ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local i32 @SMcomputeConstraintMatrix(ptr noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @SMtransposeMatrix2(ptr noundef, i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local i32 @SMdegenerate(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: nounwind uwtable
declare dso_local i32 @SMphaseOneLP(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: nounwind uwtable
declare dso_local i32 @SMsolveLP(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #2

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 8}
!6 = !{!"__SMlocal_mesh", !7, i64 0, !7, i64 4, !7, i64 8, !8, i64 16, !8, i64 40, !8, i64 64, !10, i64 88, !10, i64 96, !10, i64 104, !7, i64 112, !11, i64 120, !10, i64 128, !11, i64 136, !7, i64 144, !7, i64 148, !7, i64 152, !10, i64 160, !10, i64 168, !10, i64 176}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"double", !8, i64 0}
!12 = !{!6, !7, i64 0}
!13 = !{!7, !7, i64 0}
!14 = !{!6, !10, i64 176}
!15 = !{!16, !10, i64 0}
!16 = !{!"__SMlp", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !10, i64 96, !10, i64 104, !10, i64 112, !10, i64 120}
!17 = !{!16, !10, i64 8}
!18 = !{!16, !10, i64 16}
!19 = !{!16, !10, i64 24}
!20 = !{!16, !10, i64 64}
!21 = !{!16, !10, i64 72}
!22 = !{!11, !11, i64 0}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.unroll.disable"}
!25 = !{!26}
!26 = distinct !{!26, !27}
!27 = distinct !{!27, !"LVerDomain"}
!28 = !{!29}
!29 = distinct !{!29, !27}
!30 = distinct !{!30, !31, !32, !33}
!31 = !{!"llvm.loop.mustprogress"}
!32 = !{!"llvm.loop.isvectorized", i32 1}
!33 = !{!"llvm.loop.unroll.runtime.disable"}
!34 = distinct !{!34, !31}
!35 = distinct !{!35, !31}
!36 = distinct !{!36, !31, !33, !32}
!37 = distinct !{!37, !31, !32}
!38 = !{!10, !10, i64 0}
!39 = distinct !{!39, !24}
!40 = distinct !{!40, !31, !32, !33}
!41 = distinct !{!41, !31, !32, !33}
!42 = distinct !{!42, !31, !32}
!43 = !{!6, !7, i64 152}
!44 = distinct !{!44, !31, !32, !33}
!45 = distinct !{!45, !24}
!46 = distinct !{!46, !31, !32}


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