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

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

@.str.1 = external hidden unnamed_addr constant [108 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [21 x i8], align 1

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

; Function Attrs: nounwind
declare double @sqrt(double noundef) #1

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

declare i32 @SMerror(i32 noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, i32 noundef, ptr noundef) #3

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

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

; Function Attrs: nounwind
declare double @pow(double noundef, double noundef) #1

; Function Attrs: nounwind uwtable
define dso_local i32 @vGradSMRSVolumeRatio(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5) #4 {
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca double, align 8
  %16 = alloca double, align 8
  %17 = alloca double, align 8
  %18 = alloca double, align 8
  %19 = alloca double, align 8
  %20 = alloca double, align 8
  %21 = alloca double, align 8
  %22 = alloca double, align 8
  %23 = alloca double, align 8
  %24 = alloca double, align 8
  %25 = alloca double, align 8
  %26 = alloca double, align 8
  %27 = alloca double, align 8
  %28 = alloca double, align 8
  %29 = alloca double, align 8
  %30 = alloca double, align 8
  %31 = alloca double, align 8
  %32 = alloca double, align 8
  %33 = alloca double, align 8
  %34 = alloca double, align 8
  %35 = alloca double, align 8
  %36 = alloca double, align 8
  %37 = alloca double, align 8
  %38 = alloca double, align 8
  %39 = alloca double, align 8
  %40 = alloca i32, align 4
  store ptr %0, ptr %8, align 8, !tbaa !5
  store ptr %1, ptr %9, align 8, !tbaa !5
  store ptr %2, ptr %10, align 8, !tbaa !5
  store ptr %3, ptr %11, align 8, !tbaa !5
  store ptr %4, ptr %12, align 8, !tbaa !5
  store ptr %5, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %36) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %37) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %38) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %39) #5
  %41 = load ptr, ptr %8, align 8, !tbaa !5
  %42 = getelementptr inbounds double, ptr %41, i64 0
  %43 = load double, ptr %42, align 8, !tbaa !9
  store double %43, ptr %18, align 8, !tbaa !9
  %44 = load ptr, ptr %8, align 8, !tbaa !5
  %45 = getelementptr inbounds double, ptr %44, i64 1
  %46 = load double, ptr %45, align 8, !tbaa !9
  store double %46, ptr %22, align 8, !tbaa !9
  %47 = load ptr, ptr %8, align 8, !tbaa !5
  %48 = getelementptr inbounds double, ptr %47, i64 2
  %49 = load double, ptr %48, align 8, !tbaa !9
  store double %49, ptr %26, align 8, !tbaa !9
  %50 = load ptr, ptr %9, align 8, !tbaa !5
  %51 = getelementptr inbounds double, ptr %50, i64 0
  %52 = load double, ptr %51, align 8, !tbaa !9
  store double %52, ptr %19, align 8, !tbaa !9
  %53 = load ptr, ptr %9, align 8, !tbaa !5
  %54 = getelementptr inbounds double, ptr %53, i64 1
  %55 = load double, ptr %54, align 8, !tbaa !9
  store double %55, ptr %23, align 8, !tbaa !9
  %56 = load ptr, ptr %9, align 8, !tbaa !5
  %57 = getelementptr inbounds double, ptr %56, i64 2
  %58 = load double, ptr %57, align 8, !tbaa !9
  store double %58, ptr %27, align 8, !tbaa !9
  %59 = load ptr, ptr %10, align 8, !tbaa !5
  %60 = getelementptr inbounds double, ptr %59, i64 0
  %61 = load double, ptr %60, align 8, !tbaa !9
  store double %61, ptr %20, align 8, !tbaa !9
  %62 = load ptr, ptr %10, align 8, !tbaa !5
  %63 = getelementptr inbounds double, ptr %62, i64 1
  %64 = load double, ptr %63, align 8, !tbaa !9
  store double %64, ptr %24, align 8, !tbaa !9
  %65 = load ptr, ptr %10, align 8, !tbaa !5
  %66 = getelementptr inbounds double, ptr %65, i64 2
  %67 = load double, ptr %66, align 8, !tbaa !9
  store double %67, ptr %28, align 8, !tbaa !9
  %68 = load ptr, ptr %11, align 8, !tbaa !5
  %69 = getelementptr inbounds double, ptr %68, i64 0
  %70 = load double, ptr %69, align 8, !tbaa !9
  store double %70, ptr %21, align 8, !tbaa !9
  %71 = load ptr, ptr %11, align 8, !tbaa !5
  %72 = getelementptr inbounds double, ptr %71, i64 1
  %73 = load double, ptr %72, align 8, !tbaa !9
  store double %73, ptr %25, align 8, !tbaa !9
  %74 = load ptr, ptr %11, align 8, !tbaa !5
  %75 = getelementptr inbounds double, ptr %74, i64 2
  %76 = load double, ptr %75, align 8, !tbaa !9
  store double %76, ptr %29, align 8, !tbaa !9
  %77 = load double, ptr %19, align 8, !tbaa !9
  %78 = load double, ptr %24, align 8, !tbaa !9
  %79 = load double, ptr %29, align 8, !tbaa !9
  %80 = load double, ptr %28, align 8, !tbaa !9
  %81 = load double, ptr %25, align 8, !tbaa !9
  %82 = fmul double %80, %81
  %83 = fneg double %82
  %84 = call double @llvm.fmuladd.f64(double %78, double %79, double %83)
  %85 = load double, ptr %20, align 8, !tbaa !9
  %86 = load double, ptr %23, align 8, !tbaa !9
  %87 = load double, ptr %29, align 8, !tbaa !9
  %88 = load double, ptr %25, align 8, !tbaa !9
  %89 = load double, ptr %27, align 8, !tbaa !9
  %90 = fmul double %88, %89
  %91 = fneg double %90
  %92 = call double @llvm.fmuladd.f64(double %86, double %87, double %91)
  %93 = fmul double %85, %92
  %94 = fneg double %93
  %95 = call double @llvm.fmuladd.f64(double %77, double %84, double %94)
  %96 = load double, ptr %21, align 8, !tbaa !9
  %97 = load double, ptr %23, align 8, !tbaa !9
  %98 = load double, ptr %28, align 8, !tbaa !9
  %99 = load double, ptr %27, align 8, !tbaa !9
  %100 = load double, ptr %24, align 8, !tbaa !9
  %101 = fmul double %99, %100
  %102 = fneg double %101
  %103 = call double @llvm.fmuladd.f64(double %97, double %98, double %102)
  %104 = call double @llvm.fmuladd.f64(double %96, double %103, double %95)
  store double %104, ptr %36, align 8, !tbaa !9
  %105 = load double, ptr %24, align 8, !tbaa !9
  %106 = load double, ptr %29, align 8, !tbaa !9
  %107 = load double, ptr %28, align 8, !tbaa !9
  %108 = load double, ptr %25, align 8, !tbaa !9
  %109 = fmul double %107, %108
  %110 = fneg double %109
  %111 = call double @llvm.fmuladd.f64(double %105, double %106, double %110)
  %112 = load double, ptr %23, align 8, !tbaa !9
  %113 = load double, ptr %29, align 8, !tbaa !9
  %114 = load double, ptr %25, align 8, !tbaa !9
  %115 = load double, ptr %27, align 8, !tbaa !9
  %116 = fmul double %114, %115
  %117 = fneg double %116
  %118 = call double @llvm.fmuladd.f64(double %112, double %113, double %117)
  %119 = fsub double %111, %118
  %120 = load double, ptr %23, align 8, !tbaa !9
  %121 = load double, ptr %28, align 8, !tbaa !9
  %122 = load double, ptr %24, align 8, !tbaa !9
  %123 = load double, ptr %27, align 8, !tbaa !9
  %124 = fmul double %122, %123
  %125 = fneg double %124
  %126 = call double @llvm.fmuladd.f64(double %120, double %121, double %125)
  %127 = fadd double %119, %126
  store double %127, ptr %37, align 8, !tbaa !9
  %128 = load double, ptr %19, align 8, !tbaa !9
  %129 = load double, ptr %29, align 8, !tbaa !9
  %130 = load double, ptr %28, align 8, !tbaa !9
  %131 = fsub double %129, %130
  %132 = load double, ptr %20, align 8, !tbaa !9
  %133 = load double, ptr %29, align 8, !tbaa !9
  %134 = load double, ptr %27, align 8, !tbaa !9
  %135 = fsub double %133, %134
  %136 = fmul double %132, %135
  %137 = fneg double %136
  %138 = call double @llvm.fmuladd.f64(double %128, double %131, double %137)
  %139 = load double, ptr %21, align 8, !tbaa !9
  %140 = load double, ptr %28, align 8, !tbaa !9
  %141 = load double, ptr %27, align 8, !tbaa !9
  %142 = fsub double %140, %141
  %143 = call double @llvm.fmuladd.f64(double %139, double %142, double %138)
  store double %143, ptr %38, align 8, !tbaa !9
  %144 = load double, ptr %19, align 8, !tbaa !9
  %145 = load double, ptr %24, align 8, !tbaa !9
  %146 = load double, ptr %25, align 8, !tbaa !9
  %147 = fsub double %145, %146
  %148 = load double, ptr %20, align 8, !tbaa !9
  %149 = load double, ptr %23, align 8, !tbaa !9
  %150 = load double, ptr %25, align 8, !tbaa !9
  %151 = fsub double %149, %150
  %152 = fmul double %148, %151
  %153 = fneg double %152
  %154 = call double @llvm.fmuladd.f64(double %144, double %147, double %153)
  %155 = load double, ptr %21, align 8, !tbaa !9
  %156 = load double, ptr %23, align 8, !tbaa !9
  %157 = load double, ptr %24, align 8, !tbaa !9
  %158 = fsub double %156, %157
  %159 = call double @llvm.fmuladd.f64(double %155, double %158, double %154)
  store double %159, ptr %39, align 8, !tbaa !9
  %160 = load double, ptr %36, align 8, !tbaa !9
  %161 = load double, ptr %37, align 8, !tbaa !9
  %162 = load double, ptr %18, align 8, !tbaa !9
  %163 = fneg double %161
  %164 = call double @llvm.fmuladd.f64(double %163, double %162, double %160)
  %165 = load double, ptr %38, align 8, !tbaa !9
  %166 = load double, ptr %22, align 8, !tbaa !9
  %167 = fneg double %165
  %168 = call double @llvm.fmuladd.f64(double %167, double %166, double %164)
  %169 = load double, ptr %39, align 8, !tbaa !9
  %170 = load double, ptr %26, align 8, !tbaa !9
  %171 = fneg double %169
  %172 = call double @llvm.fmuladd.f64(double %171, double %170, double %168)
  store double %172, ptr %15, align 8, !tbaa !9
  %173 = load double, ptr %15, align 8, !tbaa !9
  %174 = call double @llvm.fabs.f64(double %173)
  %175 = fcmp olt double %174, 0x3696D601AD376ABA
  br i1 %175, label %176, label %178

176:                                              ; preds = %6
  %177 = call i32 @SMerror(i32 noundef 622, ptr noundef @.str.22, ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 62, i32 noundef 0, ptr noundef @.str.16)
  store i32 %177, ptr %7, align 4
  store i32 1, ptr %40, align 4
  br label %408

178:                                              ; preds = %6
  %179 = load double, ptr %19, align 8, !tbaa !9
  %180 = load double, ptr %18, align 8, !tbaa !9
  %181 = fsub double %179, %180
  %182 = load double, ptr %19, align 8, !tbaa !9
  %183 = load double, ptr %18, align 8, !tbaa !9
  %184 = fsub double %182, %183
  %185 = load double, ptr %23, align 8, !tbaa !9
  %186 = load double, ptr %22, align 8, !tbaa !9
  %187 = fsub double %185, %186
  %188 = load double, ptr %23, align 8, !tbaa !9
  %189 = load double, ptr %22, align 8, !tbaa !9
  %190 = fsub double %188, %189
  %191 = fmul double %187, %190
  %192 = call double @llvm.fmuladd.f64(double %181, double %184, double %191)
  %193 = load double, ptr %27, align 8, !tbaa !9
  %194 = load double, ptr %26, align 8, !tbaa !9
  %195 = fsub double %193, %194
  %196 = load double, ptr %27, align 8, !tbaa !9
  %197 = load double, ptr %26, align 8, !tbaa !9
  %198 = fsub double %196, %197
  %199 = call double @llvm.fmuladd.f64(double %195, double %198, double %192)
  store double %199, ptr %30, align 8, !tbaa !9
  %200 = load double, ptr %20, align 8, !tbaa !9
  %201 = load double, ptr %18, align 8, !tbaa !9
  %202 = fsub double %200, %201
  %203 = load double, ptr %20, align 8, !tbaa !9
  %204 = load double, ptr %18, align 8, !tbaa !9
  %205 = fsub double %203, %204
  %206 = load double, ptr %24, align 8, !tbaa !9
  %207 = load double, ptr %22, align 8, !tbaa !9
  %208 = fsub double %206, %207
  %209 = load double, ptr %24, align 8, !tbaa !9
  %210 = load double, ptr %22, align 8, !tbaa !9
  %211 = fsub double %209, %210
  %212 = fmul double %208, %211
  %213 = call double @llvm.fmuladd.f64(double %202, double %205, double %212)
  %214 = load double, ptr %28, align 8, !tbaa !9
  %215 = load double, ptr %26, align 8, !tbaa !9
  %216 = fsub double %214, %215
  %217 = load double, ptr %28, align 8, !tbaa !9
  %218 = load double, ptr %26, align 8, !tbaa !9
  %219 = fsub double %217, %218
  %220 = call double @llvm.fmuladd.f64(double %216, double %219, double %213)
  store double %220, ptr %31, align 8, !tbaa !9
  %221 = load double, ptr %21, align 8, !tbaa !9
  %222 = load double, ptr %18, align 8, !tbaa !9
  %223 = fsub double %221, %222
  %224 = load double, ptr %21, align 8, !tbaa !9
  %225 = load double, ptr %18, align 8, !tbaa !9
  %226 = fsub double %224, %225
  %227 = load double, ptr %25, align 8, !tbaa !9
  %228 = load double, ptr %22, align 8, !tbaa !9
  %229 = fsub double %227, %228
  %230 = load double, ptr %25, align 8, !tbaa !9
  %231 = load double, ptr %22, align 8, !tbaa !9
  %232 = fsub double %230, %231
  %233 = fmul double %229, %232
  %234 = call double @llvm.fmuladd.f64(double %223, double %226, double %233)
  %235 = load double, ptr %29, align 8, !tbaa !9
  %236 = load double, ptr %26, align 8, !tbaa !9
  %237 = fsub double %235, %236
  %238 = load double, ptr %29, align 8, !tbaa !9
  %239 = load double, ptr %26, align 8, !tbaa !9
  %240 = fsub double %238, %239
  %241 = call double @llvm.fmuladd.f64(double %237, double %240, double %234)
  store double %241, ptr %32, align 8, !tbaa !9
  %242 = load double, ptr %19, align 8, !tbaa !9
  %243 = load double, ptr %20, align 8, !tbaa !9
  %244 = fsub double %242, %243
  %245 = load double, ptr %19, align 8, !tbaa !9
  %246 = load double, ptr %20, align 8, !tbaa !9
  %247 = fsub double %245, %246
  %248 = load double, ptr %23, align 8, !tbaa !9
  %249 = load double, ptr %24, align 8, !tbaa !9
  %250 = fsub double %248, %249
  %251 = load double, ptr %23, align 8, !tbaa !9
  %252 = load double, ptr %24, align 8, !tbaa !9
  %253 = fsub double %251, %252
  %254 = fmul double %250, %253
  %255 = call double @llvm.fmuladd.f64(double %244, double %247, double %254)
  %256 = load double, ptr %27, align 8, !tbaa !9
  %257 = load double, ptr %28, align 8, !tbaa !9
  %258 = fsub double %256, %257
  %259 = load double, ptr %27, align 8, !tbaa !9
  %260 = load double, ptr %28, align 8, !tbaa !9
  %261 = fsub double %259, %260
  %262 = call double @llvm.fmuladd.f64(double %258, double %261, double %255)
  store double %262, ptr %33, align 8, !tbaa !9
  %263 = load double, ptr %21, align 8, !tbaa !9
  %264 = load double, ptr %19, align 8, !tbaa !9
  %265 = fsub double %263, %264
  %266 = load double, ptr %21, align 8, !tbaa !9
  %267 = load double, ptr %19, align 8, !tbaa !9
  %268 = fsub double %266, %267
  %269 = load double, ptr %25, align 8, !tbaa !9
  %270 = load double, ptr %23, align 8, !tbaa !9
  %271 = fsub double %269, %270
  %272 = load double, ptr %25, align 8, !tbaa !9
  %273 = load double, ptr %23, align 8, !tbaa !9
  %274 = fsub double %272, %273
  %275 = fmul double %271, %274
  %276 = call double @llvm.fmuladd.f64(double %265, double %268, double %275)
  %277 = load double, ptr %29, align 8, !tbaa !9
  %278 = load double, ptr %27, align 8, !tbaa !9
  %279 = fsub double %277, %278
  %280 = load double, ptr %29, align 8, !tbaa !9
  %281 = load double, ptr %27, align 8, !tbaa !9
  %282 = fsub double %280, %281
  %283 = call double @llvm.fmuladd.f64(double %279, double %282, double %276)
  store double %283, ptr %34, align 8, !tbaa !9
  %284 = load double, ptr %21, align 8, !tbaa !9
  %285 = load double, ptr %20, align 8, !tbaa !9
  %286 = fsub double %284, %285
  %287 = load double, ptr %21, align 8, !tbaa !9
  %288 = load double, ptr %20, align 8, !tbaa !9
  %289 = fsub double %287, %288
  %290 = load double, ptr %25, align 8, !tbaa !9
  %291 = load double, ptr %24, align 8, !tbaa !9
  %292 = fsub double %290, %291
  %293 = load double, ptr %25, align 8, !tbaa !9
  %294 = load double, ptr %24, align 8, !tbaa !9
  %295 = fsub double %293, %294
  %296 = fmul double %292, %295
  %297 = call double @llvm.fmuladd.f64(double %286, double %289, double %296)
  %298 = load double, ptr %29, align 8, !tbaa !9
  %299 = load double, ptr %28, align 8, !tbaa !9
  %300 = fsub double %298, %299
  %301 = load double, ptr %29, align 8, !tbaa !9
  %302 = load double, ptr %28, align 8, !tbaa !9
  %303 = fsub double %301, %302
  %304 = call double @llvm.fmuladd.f64(double %300, double %303, double %297)
  store double %304, ptr %35, align 8, !tbaa !9
  %305 = load double, ptr %30, align 8, !tbaa !9
  %306 = load double, ptr %31, align 8, !tbaa !9
  %307 = fadd double %305, %306
  %308 = load double, ptr %32, align 8, !tbaa !9
  %309 = fadd double %307, %308
  %310 = load double, ptr %33, align 8, !tbaa !9
  %311 = fadd double %309, %310
  %312 = load double, ptr %34, align 8, !tbaa !9
  %313 = fadd double %311, %312
  %314 = load double, ptr %35, align 8, !tbaa !9
  %315 = fadd double %313, %314
  %316 = fmul double 0x3FC5555555555555, %315
  %317 = call double @sqrt(double noundef %316) #5
  store double %317, ptr %16, align 8, !tbaa !9
  %318 = load double, ptr %16, align 8, !tbaa !9
  %319 = call double @pow(double noundef %318, double noundef 3.000000e+00) #5
  store double %319, ptr %17, align 8, !tbaa !9
  %320 = load double, ptr %16, align 8, !tbaa !9
  %321 = fmul double 1.500000e+00, %320
  %322 = load double, ptr %19, align 8, !tbaa !9
  %323 = load double, ptr %18, align 8, !tbaa !9
  %324 = fmul double 6.000000e+00, %323
  %325 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %322, double %324)
  %326 = load double, ptr %20, align 8, !tbaa !9
  %327 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %326, double %325)
  %328 = load double, ptr %21, align 8, !tbaa !9
  %329 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %328, double %327)
  %330 = fmul double %321, %329
  %331 = load double, ptr %15, align 8, !tbaa !9
  %332 = fmul double 8.479670e+00, %331
  %333 = fdiv double %330, %332
  %334 = load double, ptr %17, align 8, !tbaa !9
  %335 = fmul double 6.000000e+00, %334
  %336 = load double, ptr %37, align 8, !tbaa !9
  %337 = fmul double %335, %336
  %338 = load double, ptr %15, align 8, !tbaa !9
  %339 = fmul double 8.479670e+00, %338
  %340 = load double, ptr %15, align 8, !tbaa !9
  %341 = fmul double %339, %340
  %342 = fdiv double %337, %341
  %343 = fadd double %333, %342
  %344 = fneg double %343
  %345 = load ptr, ptr %12, align 8, !tbaa !5
  %346 = getelementptr inbounds ptr, ptr %345, i64 0
  %347 = load ptr, ptr %346, align 8, !tbaa !5
  %348 = getelementptr inbounds double, ptr %347, i64 0
  store double %344, ptr %348, align 8, !tbaa !9
  %349 = load double, ptr %16, align 8, !tbaa !9
  %350 = fmul double 1.500000e+00, %349
  %351 = load double, ptr %23, align 8, !tbaa !9
  %352 = load double, ptr %22, align 8, !tbaa !9
  %353 = fmul double 6.000000e+00, %352
  %354 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %351, double %353)
  %355 = load double, ptr %24, align 8, !tbaa !9
  %356 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %355, double %354)
  %357 = load double, ptr %25, align 8, !tbaa !9
  %358 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %357, double %356)
  %359 = fmul double %350, %358
  %360 = load double, ptr %15, align 8, !tbaa !9
  %361 = fmul double 8.479670e+00, %360
  %362 = fdiv double %359, %361
  %363 = load double, ptr %17, align 8, !tbaa !9
  %364 = fmul double 6.000000e+00, %363
  %365 = load double, ptr %38, align 8, !tbaa !9
  %366 = fmul double %364, %365
  %367 = load double, ptr %15, align 8, !tbaa !9
  %368 = fmul double 8.479670e+00, %367
  %369 = load double, ptr %15, align 8, !tbaa !9
  %370 = fmul double %368, %369
  %371 = fdiv double %366, %370
  %372 = fadd double %362, %371
  %373 = fneg double %372
  %374 = load ptr, ptr %12, align 8, !tbaa !5
  %375 = getelementptr inbounds ptr, ptr %374, i64 0
  %376 = load ptr, ptr %375, align 8, !tbaa !5
  %377 = getelementptr inbounds double, ptr %376, i64 1
  store double %373, ptr %377, align 8, !tbaa !9
  %378 = load double, ptr %16, align 8, !tbaa !9
  %379 = fmul double 1.500000e+00, %378
  %380 = load double, ptr %27, align 8, !tbaa !9
  %381 = load double, ptr %26, align 8, !tbaa !9
  %382 = fmul double 6.000000e+00, %381
  %383 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %380, double %382)
  %384 = load double, ptr %28, align 8, !tbaa !9
  %385 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %384, double %383)
  %386 = load double, ptr %29, align 8, !tbaa !9
  %387 = call double @llvm.fmuladd.f64(double -2.000000e+00, double %386, double %385)
  %388 = fmul double %379, %387
  %389 = load double, ptr %15, align 8, !tbaa !9
  %390 = fmul double 8.479670e+00, %389
  %391 = fdiv double %388, %390
  %392 = load double, ptr %17, align 8, !tbaa !9
  %393 = fmul double 6.000000e+00, %392
  %394 = load double, ptr %39, align 8, !tbaa !9
  %395 = fmul double %393, %394
  %396 = load double, ptr %15, align 8, !tbaa !9
  %397 = fmul double 8.479670e+00, %396
  %398 = load double, ptr %15, align 8, !tbaa !9
  %399 = fmul double %397, %398
  %400 = fdiv double %395, %399
  %401 = fadd double %391, %400
  %402 = fneg double %401
  %403 = load ptr, ptr %12, align 8, !tbaa !5
  %404 = getelementptr inbounds ptr, ptr %403, i64 0
  %405 = load ptr, ptr %404, align 8, !tbaa !5
  %406 = getelementptr inbounds double, ptr %405, i64 2
  store double %402, ptr %406, align 8, !tbaa !9
  %407 = load ptr, ptr %13, align 8, !tbaa !5
  store i32 1, ptr %407, align 4, !tbaa !11
  store i32 0, ptr %14, align 4, !tbaa !11
  store i32 0, ptr %7, align 4
  store i32 1, ptr %40, align 4
  br label %408

408:                                              ; preds = %178, %176
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  %409 = load i32, ptr %7, align 4
  ret i32 %409
}

attributes #0 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #1 = { 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 willreturn memory(argmem: readwrite) }
attributes #3 = { "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 = { 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 = { 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, !10, i64 0}
!10 = !{!"double", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}


; 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 [108 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [21 x i8], align 1

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @sqrt(double noundef) local_unnamed_addr #1

declare i32 @SMerror(i32 noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #2

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @pow(double noundef, double noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local i32 @vGradSMRSVolumeRatio(ptr nocapture noundef readonly %0, ptr nocapture noundef readonly %1, ptr nocapture noundef readonly %2, ptr nocapture noundef readonly %3, ptr nocapture noundef readonly %4, ptr nocapture noundef writeonly %5) local_unnamed_addr #3 {
  %7 = load double, ptr %0, align 8, !tbaa !5
  %8 = getelementptr inbounds i8, ptr %0, i64 8
  %9 = load double, ptr %8, align 8, !tbaa !5
  %10 = getelementptr inbounds i8, ptr %0, i64 16
  %11 = load double, ptr %10, align 8, !tbaa !5
  %12 = load double, ptr %1, align 8, !tbaa !5
  %13 = getelementptr inbounds i8, ptr %1, i64 8
  %14 = load double, ptr %13, align 8, !tbaa !5
  %15 = getelementptr inbounds i8, ptr %1, i64 16
  %16 = load double, ptr %15, align 8, !tbaa !5
  %17 = load double, ptr %2, align 8, !tbaa !5
  %18 = getelementptr inbounds i8, ptr %2, i64 8
  %19 = load double, ptr %18, align 8, !tbaa !5
  %20 = getelementptr inbounds i8, ptr %2, i64 16
  %21 = load double, ptr %20, align 8, !tbaa !5
  %22 = load double, ptr %3, align 8, !tbaa !5
  %23 = getelementptr inbounds i8, ptr %3, i64 8
  %24 = load double, ptr %23, align 8, !tbaa !5
  %25 = getelementptr inbounds i8, ptr %3, i64 16
  %26 = load double, ptr %25, align 8, !tbaa !5
  %27 = insertelement <2 x double> poison, double %21, i64 0
  %28 = insertelement <2 x double> %27, double %24, i64 1
  %29 = fneg <2 x double> %28
  %30 = insertelement <2 x double> poison, double %24, i64 0
  %31 = insertelement <2 x double> %30, double %16, i64 1
  %32 = fmul <2 x double> %31, %29
  %33 = insertelement <2 x double> poison, double %19, i64 0
  %34 = insertelement <2 x double> %33, double %14, i64 1
  %35 = insertelement <2 x double> poison, double %26, i64 0
  %36 = shufflevector <2 x double> %35, <2 x double> poison, <2 x i32> zeroinitializer
  %37 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %34, <2 x double> %36, <2 x double> %32)
  %38 = fneg double %17
  %39 = extractelement <2 x double> %37, i64 1
  %40 = fmul double %39, %38
  %41 = extractelement <2 x double> %37, i64 0
  %42 = tail call double @llvm.fmuladd.f64(double %12, double %41, double %40)
  %43 = fneg double %16
  %44 = fmul double %19, %43
  %45 = tail call double @llvm.fmuladd.f64(double %14, double %21, double %44)
  %46 = tail call double @llvm.fmuladd.f64(double %22, double %45, double %42)
  %47 = fsub double %41, %39
  %48 = fadd double %45, %47
  %49 = fsub double %26, %21
  %50 = fsub double %26, %16
  %51 = fmul double %50, %38
  %52 = tail call double @llvm.fmuladd.f64(double %12, double %49, double %51)
  %53 = fsub double %21, %16
  %54 = tail call double @llvm.fmuladd.f64(double %22, double %53, double %52)
  %55 = fsub double %19, %24
  %56 = fsub double %14, %24
  %57 = fmul double %56, %38
  %58 = tail call double @llvm.fmuladd.f64(double %12, double %55, double %57)
  %59 = fsub double %14, %19
  %60 = tail call double @llvm.fmuladd.f64(double %22, double %59, double %58)
  %61 = fneg double %48
  %62 = tail call double @llvm.fmuladd.f64(double %61, double %7, double %46)
  %63 = fneg double %54
  %64 = tail call double @llvm.fmuladd.f64(double %63, double %9, double %62)
  %65 = fneg double %60
  %66 = tail call double @llvm.fmuladd.f64(double %65, double %11, double %64)
  %67 = tail call double @llvm.fabs.f64(double %66)
  %68 = fcmp olt double %67, 0x3696D601AD376ABA
  br i1 %68, label %69, label %71

69:                                               ; preds = %6
  %70 = tail call i32 @SMerror(i32 noundef 622, ptr noundef nonnull @.str.22, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef 62, i32 noundef 0, ptr noundef nonnull @.str.16) #5
  br label %161

71:                                               ; preds = %6
  %72 = insertelement <2 x double> poison, double %12, i64 0
  %73 = insertelement <2 x double> %72, double %17, i64 1
  %74 = insertelement <2 x double> poison, double %7, i64 0
  %75 = shufflevector <2 x double> %74, <2 x double> poison, <2 x i32> zeroinitializer
  %76 = fsub <2 x double> %73, %75
  %77 = insertelement <2 x double> poison, double %14, i64 0
  %78 = insertelement <2 x double> %77, double %19, i64 1
  %79 = insertelement <2 x double> poison, double %9, i64 0
  %80 = shufflevector <2 x double> %79, <2 x double> poison, <2 x i32> zeroinitializer
  %81 = fsub <2 x double> %78, %80
  %82 = insertelement <2 x double> poison, double %16, i64 0
  %83 = insertelement <2 x double> %82, double %21, i64 1
  %84 = insertelement <2 x double> poison, double %11, i64 0
  %85 = shufflevector <2 x double> %84, <2 x double> poison, <2 x i32> zeroinitializer
  %86 = fsub <2 x double> %83, %85
  %87 = fmul <2 x double> %81, %81
  %88 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %76, <2 x double> %76, <2 x double> %87)
  %89 = tail call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %86, <2 x double> %86, <2 x double> %88)
  %90 = fsub double %22, %7
  %91 = fsub double %24, %9
  %92 = fmul double %91, %91
  %93 = tail call double @llvm.fmuladd.f64(double %90, double %90, double %92)
  %94 = fsub double %26, %11
  %95 = tail call double @llvm.fmuladd.f64(double %94, double %94, double %93)
  %96 = fsub double %12, %17
  %97 = fmul double %59, %59
  %98 = tail call double @llvm.fmuladd.f64(double %96, double %96, double %97)
  %99 = fsub double %16, %21
  %100 = tail call double @llvm.fmuladd.f64(double %99, double %99, double %98)
  %101 = fsub double %22, %12
  %102 = fsub double %24, %14
  %103 = fmul double %102, %102
  %104 = tail call double @llvm.fmuladd.f64(double %101, double %101, double %103)
  %105 = tail call double @llvm.fmuladd.f64(double %50, double %50, double %104)
  %106 = fsub double %22, %17
  %107 = fsub double %24, %19
  %108 = fmul double %107, %107
  %109 = tail call double @llvm.fmuladd.f64(double %106, double %106, double %108)
  %110 = tail call double @llvm.fmuladd.f64(double %49, double %49, double %109)
  %shift = shufflevector <2 x double> %89, <2 x double> poison, <2 x i32> <i32 1, i32 poison>
  %111 = fadd <2 x double> %89, %shift
  %112 = extractelement <2 x double> %111, i64 0
  %113 = fadd double %112, %95
  %114 = fadd double %100, %113
  %115 = fadd double %105, %114
  %116 = fadd double %110, %115
  %117 = fmul double %116, 0x3FC5555555555555
  %118 = tail call double @sqrt(double noundef %117) #5
  %119 = tail call double @pow(double noundef %118, double noundef 3.000000e+00) #5
  %120 = fmul double %7, 6.000000e+00
  %121 = tail call double @llvm.fmuladd.f64(double %12, double -2.000000e+00, double %120)
  %122 = tail call double @llvm.fmuladd.f64(double %17, double -2.000000e+00, double %121)
  %123 = tail call double @llvm.fmuladd.f64(double %22, double -2.000000e+00, double %122)
  %124 = load ptr, ptr %4, align 8, !tbaa !9
  %125 = fmul double %9, 6.000000e+00
  %126 = tail call double @llvm.fmuladd.f64(double %14, double -2.000000e+00, double %125)
  %127 = tail call double @llvm.fmuladd.f64(double %19, double -2.000000e+00, double %126)
  %128 = tail call double @llvm.fmuladd.f64(double %24, double -2.000000e+00, double %127)
  %129 = fmul double %66, 8.479670e+00
  %130 = insertelement <2 x double> poison, double %118, i64 0
  %131 = insertelement <2 x double> %130, double %119, i64 1
  %132 = fmul <2 x double> %131, <double 1.500000e+00, double 6.000000e+00>
  %133 = fmul double %66, %129
  %134 = insertelement <2 x double> poison, double %128, i64 0
  %135 = insertelement <2 x double> %134, double %48, i64 1
  %136 = fmul <2 x double> %135, %132
  %137 = insertelement <2 x double> poison, double %129, i64 0
  %138 = insertelement <2 x double> %137, double %133, i64 1
  %139 = fdiv <2 x double> %136, %138
  %140 = insertelement <2 x double> poison, double %123, i64 0
  %141 = insertelement <2 x double> %140, double %54, i64 1
  %142 = fmul <2 x double> %141, %132
  %143 = fdiv <2 x double> %142, %138
  %144 = shufflevector <2 x double> %143, <2 x double> poison, <2 x i32> <i32 1, i32 0>
  %145 = fadd <2 x double> %139, %144
  %146 = shufflevector <2 x double> %145, <2 x double> poison, <2 x i32> <i32 1, i32 0>
  %147 = fneg <2 x double> %146
  store <2 x double> %147, ptr %124, align 8, !tbaa !5
  %148 = fmul double %11, 6.000000e+00
  %149 = tail call double @llvm.fmuladd.f64(double %16, double -2.000000e+00, double %148)
  %150 = tail call double @llvm.fmuladd.f64(double %21, double -2.000000e+00, double %149)
  %151 = tail call double @llvm.fmuladd.f64(double %26, double -2.000000e+00, double %150)
  %152 = extractelement <2 x double> %132, i64 0
  %153 = fmul double %151, %152
  %154 = fdiv double %153, %129
  %155 = extractelement <2 x double> %132, i64 1
  %156 = fmul double %60, %155
  %157 = fdiv double %156, %133
  %158 = fadd double %154, %157
  %159 = fneg double %158
  %160 = getelementptr inbounds i8, ptr %124, i64 16
  store double %159, ptr %160, align 8, !tbaa !5
  store i32 1, ptr %5, align 4, !tbaa !11
  br label %161

161:                                              ; preds = %71, %69
  %.0 = phi i32 [ %70, %69 ], [ 0, %71 ]
  ret i32 %.0
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare <2 x double> @llvm.fmuladd.v2f64(<2 x double>, <2 x double>, <2 x double>) #4

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,ReassociatePass,SLPVectorizerPass,SROAPass,TailCallElimPass,VectorCombinePass