; LLVM IR from askforalfred/alfred :: gen/ff_planner (memory)

; 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._NormEffect = type { i32, [15 x i32], [15 x i32], ptr, i32, ptr, i32, ptr, i32, ptr, ptr, ptr, i32, ptr, ptr, ptr, i32, ptr, ptr }
%struct._Fact = type { i32, [5 x i32] }
%struct._Fluent = type { i32, [5 x i32] }

@stdout = external global ptr, align 8
@.str = external hidden unnamed_addr constant [28 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [77 x i8], align 1
@garity = external global [50 x i32], align 16
@gf_arity = external global [50 x i32], align 16

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

; Function Attrs: nounwind allocsize(0,1)
declare noalias ptr @calloc(i64 noundef, i64 noundef) #1

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #2

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) #3

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

; Function Attrs: nounwind uwtable
define dso_local ptr @new_NormEffect2(ptr noundef %0) #4 {
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  store ptr %0, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #6
  %6 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 256) #7
  store ptr %6, ptr %5, align 8, !tbaa !5
  %7 = load ptr, ptr %5, align 8, !tbaa !5
  %8 = icmp eq ptr null, %7
  br i1 %8, label %9, label %12

9:                                                ; preds = %1
  %10 = load ptr, ptr @stdout, align 8, !tbaa !5
  %11 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %10, ptr noundef @.str, ptr noundef @.str.1, i32 noundef 538) #6
  call void @exit(i32 noundef 1) #8
  unreachable

12:                                               ; preds = %1
  %13 = load ptr, ptr %5, align 8, !tbaa !5
  %14 = getelementptr inbounds %struct._NormEffect, ptr %13, i32 0, i32 0
  store i32 0, ptr %14, align 8, !tbaa !9
  %15 = load ptr, ptr %2, align 8, !tbaa !5
  %16 = getelementptr inbounds %struct._NormEffect, ptr %15, i32 0, i32 4
  %17 = load i32, ptr %16, align 8, !tbaa !12
  %18 = sext i32 %17 to i64
  %19 = call noalias ptr @calloc(i64 noundef %18, i64 noundef 24) #7
  %20 = load ptr, ptr %5, align 8, !tbaa !5
  %21 = getelementptr inbounds %struct._NormEffect, ptr %20, i32 0, i32 3
  store ptr %19, ptr %21, align 8, !tbaa !13
  %22 = load ptr, ptr %2, align 8, !tbaa !5
  %23 = getelementptr inbounds %struct._NormEffect, ptr %22, i32 0, i32 4
  %24 = load i32, ptr %23, align 8, !tbaa !12
  %25 = load ptr, ptr %5, align 8, !tbaa !5
  %26 = getelementptr inbounds %struct._NormEffect, ptr %25, i32 0, i32 4
  store i32 %24, ptr %26, align 8, !tbaa !12
  store i32 0, ptr %3, align 4, !tbaa !14
  br label %27

27:                                               ; preds = %89, %12
  %28 = load i32, ptr %3, align 4, !tbaa !14
  %29 = load ptr, ptr %2, align 8, !tbaa !5
  %30 = getelementptr inbounds %struct._NormEffect, ptr %29, i32 0, i32 4
  %31 = load i32, ptr %30, align 8, !tbaa !12
  %32 = icmp slt i32 %28, %31
  br i1 %32, label %33, label %92

33:                                               ; preds = %27
  %34 = load ptr, ptr %2, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct._NormEffect, ptr %34, i32 0, i32 3
  %36 = load ptr, ptr %35, align 8, !tbaa !13
  %37 = load i32, ptr %3, align 4, !tbaa !14
  %38 = sext i32 %37 to i64
  %39 = getelementptr inbounds %struct._Fact, ptr %36, i64 %38
  %40 = getelementptr inbounds %struct._Fact, ptr %39, i32 0, i32 0
  %41 = load i32, ptr %40, align 4, !tbaa !15
  %42 = load ptr, ptr %5, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct._NormEffect, ptr %42, i32 0, i32 3
  %44 = load ptr, ptr %43, align 8, !tbaa !13
  %45 = load i32, ptr %3, align 4, !tbaa !14
  %46 = sext i32 %45 to i64
  %47 = getelementptr inbounds %struct._Fact, ptr %44, i64 %46
  %48 = getelementptr inbounds %struct._Fact, ptr %47, i32 0, i32 0
  store i32 %41, ptr %48, align 4, !tbaa !15
  store i32 0, ptr %4, align 4, !tbaa !14
  br label %49

49:                                               ; preds = %85, %33
  %50 = load i32, ptr %4, align 4, !tbaa !14
  %51 = load ptr, ptr %2, align 8, !tbaa !5
  %52 = getelementptr inbounds %struct._NormEffect, ptr %51, i32 0, i32 3
  %53 = load ptr, ptr %52, align 8, !tbaa !13
  %54 = load i32, ptr %3, align 4, !tbaa !14
  %55 = sext i32 %54 to i64
  %56 = getelementptr inbounds %struct._Fact, ptr %53, i64 %55
  %57 = getelementptr inbounds %struct._Fact, ptr %56, i32 0, i32 0
  %58 = load i32, ptr %57, align 4, !tbaa !15
  %59 = sext i32 %58 to i64
  %60 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %59
  %61 = load i32, ptr %60, align 4, !tbaa !14
  %62 = icmp slt i32 %50, %61
  br i1 %62, label %63, label %88

63:                                               ; preds = %49
  %64 = load ptr, ptr %2, align 8, !tbaa !5
  %65 = getelementptr inbounds %struct._NormEffect, ptr %64, i32 0, i32 3
  %66 = load ptr, ptr %65, align 8, !tbaa !13
  %67 = load i32, ptr %3, align 4, !tbaa !14
  %68 = sext i32 %67 to i64
  %69 = getelementptr inbounds %struct._Fact, ptr %66, i64 %68
  %70 = getelementptr inbounds %struct._Fact, ptr %69, i32 0, i32 1
  %71 = load i32, ptr %4, align 4, !tbaa !14
  %72 = sext i32 %71 to i64
  %73 = getelementptr inbounds [5 x i32], ptr %70, i64 0, i64 %72
  %74 = load i32, ptr %73, align 4, !tbaa !14
  %75 = load ptr, ptr %5, align 8, !tbaa !5
  %76 = getelementptr inbounds %struct._NormEffect, ptr %75, i32 0, i32 3
  %77 = load ptr, ptr %76, align 8, !tbaa !13
  %78 = load i32, ptr %3, align 4, !tbaa !14
  %79 = sext i32 %78 to i64
  %80 = getelementptr inbounds %struct._Fact, ptr %77, i64 %79
  %81 = getelementptr inbounds %struct._Fact, ptr %80, i32 0, i32 1
  %82 = load i32, ptr %4, align 4, !tbaa !14
  %83 = sext i32 %82 to i64
  %84 = getelementptr inbounds [5 x i32], ptr %81, i64 0, i64 %83
  store i32 %74, ptr %84, align 4, !tbaa !14
  br label %85

85:                                               ; preds = %63
  %86 = load i32, ptr %4, align 4, !tbaa !14
  %87 = add nsw i32 %86, 1
  store i32 %87, ptr %4, align 4, !tbaa !14
  br label %49, !llvm.loop !17

88:                                               ; preds = %49
  br label %89

89:                                               ; preds = %88
  %90 = load i32, ptr %3, align 4, !tbaa !14
  %91 = add nsw i32 %90, 1
  store i32 %91, ptr %3, align 4, !tbaa !14
  br label %27, !llvm.loop !19

92:                                               ; preds = %27
  %93 = load ptr, ptr %2, align 8, !tbaa !5
  %94 = getelementptr inbounds %struct._NormEffect, ptr %93, i32 0, i32 6
  %95 = load i32, ptr %94, align 8, !tbaa !20
  %96 = sext i32 %95 to i64
  %97 = call noalias ptr @calloc(i64 noundef %96, i64 noundef 24) #7
  %98 = load ptr, ptr %5, align 8, !tbaa !5
  %99 = getelementptr inbounds %struct._NormEffect, ptr %98, i32 0, i32 5
  store ptr %97, ptr %99, align 8, !tbaa !21
  %100 = load ptr, ptr %2, align 8, !tbaa !5
  %101 = getelementptr inbounds %struct._NormEffect, ptr %100, i32 0, i32 6
  %102 = load i32, ptr %101, align 8, !tbaa !20
  %103 = load ptr, ptr %5, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct._NormEffect, ptr %103, i32 0, i32 6
  store i32 %102, ptr %104, align 8, !tbaa !20
  store i32 0, ptr %3, align 4, !tbaa !14
  br label %105

105:                                              ; preds = %167, %92
  %106 = load i32, ptr %3, align 4, !tbaa !14
  %107 = load ptr, ptr %2, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct._NormEffect, ptr %107, i32 0, i32 6
  %109 = load i32, ptr %108, align 8, !tbaa !20
  %110 = icmp slt i32 %106, %109
  br i1 %110, label %111, label %170

111:                                              ; preds = %105
  %112 = load ptr, ptr %2, align 8, !tbaa !5
  %113 = getelementptr inbounds %struct._NormEffect, ptr %112, i32 0, i32 5
  %114 = load ptr, ptr %113, align 8, !tbaa !21
  %115 = load i32, ptr %3, align 4, !tbaa !14
  %116 = sext i32 %115 to i64
  %117 = getelementptr inbounds %struct._Fact, ptr %114, i64 %116
  %118 = getelementptr inbounds %struct._Fact, ptr %117, i32 0, i32 0
  %119 = load i32, ptr %118, align 4, !tbaa !15
  %120 = load ptr, ptr %5, align 8, !tbaa !5
  %121 = getelementptr inbounds %struct._NormEffect, ptr %120, i32 0, i32 5
  %122 = load ptr, ptr %121, align 8, !tbaa !21
  %123 = load i32, ptr %3, align 4, !tbaa !14
  %124 = sext i32 %123 to i64
  %125 = getelementptr inbounds %struct._Fact, ptr %122, i64 %124
  %126 = getelementptr inbounds %struct._Fact, ptr %125, i32 0, i32 0
  store i32 %119, ptr %126, align 4, !tbaa !15
  store i32 0, ptr %4, align 4, !tbaa !14
  br label %127

127:                                              ; preds = %163, %111
  %128 = load i32, ptr %4, align 4, !tbaa !14
  %129 = load ptr, ptr %2, align 8, !tbaa !5
  %130 = getelementptr inbounds %struct._NormEffect, ptr %129, i32 0, i32 5
  %131 = load ptr, ptr %130, align 8, !tbaa !21
  %132 = load i32, ptr %3, align 4, !tbaa !14
  %133 = sext i32 %132 to i64
  %134 = getelementptr inbounds %struct._Fact, ptr %131, i64 %133
  %135 = getelementptr inbounds %struct._Fact, ptr %134, i32 0, i32 0
  %136 = load i32, ptr %135, align 4, !tbaa !15
  %137 = sext i32 %136 to i64
  %138 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %137
  %139 = load i32, ptr %138, align 4, !tbaa !14
  %140 = icmp slt i32 %128, %139
  br i1 %140, label %141, label %166

141:                                              ; preds = %127
  %142 = load ptr, ptr %2, align 8, !tbaa !5
  %143 = getelementptr inbounds %struct._NormEffect, ptr %142, i32 0, i32 5
  %144 = load ptr, ptr %143, align 8, !tbaa !21
  %145 = load i32, ptr %3, align 4, !tbaa !14
  %146 = sext i32 %145 to i64
  %147 = getelementptr inbounds %struct._Fact, ptr %144, i64 %146
  %148 = getelementptr inbounds %struct._Fact, ptr %147, i32 0, i32 1
  %149 = load i32, ptr %4, align 4, !tbaa !14
  %150 = sext i32 %149 to i64
  %151 = getelementptr inbounds [5 x i32], ptr %148, i64 0, i64 %150
  %152 = load i32, ptr %151, align 4, !tbaa !14
  %153 = load ptr, ptr %5, align 8, !tbaa !5
  %154 = getelementptr inbounds %struct._NormEffect, ptr %153, i32 0, i32 5
  %155 = load ptr, ptr %154, align 8, !tbaa !21
  %156 = load i32, ptr %3, align 4, !tbaa !14
  %157 = sext i32 %156 to i64
  %158 = getelementptr inbounds %struct._Fact, ptr %155, i64 %157
  %159 = getelementptr inbounds %struct._Fact, ptr %158, i32 0, i32 1
  %160 = load i32, ptr %4, align 4, !tbaa !14
  %161 = sext i32 %160 to i64
  %162 = getelementptr inbounds [5 x i32], ptr %159, i64 0, i64 %161
  store i32 %152, ptr %162, align 4, !tbaa !14
  br label %163

163:                                              ; preds = %141
  %164 = load i32, ptr %4, align 4, !tbaa !14
  %165 = add nsw i32 %164, 1
  store i32 %165, ptr %4, align 4, !tbaa !14
  br label %127, !llvm.loop !22

166:                                              ; preds = %127
  br label %167

167:                                              ; preds = %166
  %168 = load i32, ptr %3, align 4, !tbaa !14
  %169 = add nsw i32 %168, 1
  store i32 %169, ptr %3, align 4, !tbaa !14
  br label %105, !llvm.loop !23

170:                                              ; preds = %105
  %171 = load ptr, ptr %2, align 8, !tbaa !5
  %172 = getelementptr inbounds %struct._NormEffect, ptr %171, i32 0, i32 8
  %173 = load i32, ptr %172, align 8, !tbaa !24
  %174 = sext i32 %173 to i64
  %175 = call noalias ptr @calloc(i64 noundef %174, i64 noundef 24) #7
  %176 = load ptr, ptr %5, align 8, !tbaa !5
  %177 = getelementptr inbounds %struct._NormEffect, ptr %176, i32 0, i32 7
  store ptr %175, ptr %177, align 8, !tbaa !25
  %178 = load ptr, ptr %2, align 8, !tbaa !5
  %179 = getelementptr inbounds %struct._NormEffect, ptr %178, i32 0, i32 8
  %180 = load i32, ptr %179, align 8, !tbaa !24
  %181 = load ptr, ptr %5, align 8, !tbaa !5
  %182 = getelementptr inbounds %struct._NormEffect, ptr %181, i32 0, i32 8
  store i32 %180, ptr %182, align 8, !tbaa !24
  store i32 0, ptr %3, align 4, !tbaa !14
  br label %183

183:                                              ; preds = %245, %170
  %184 = load i32, ptr %3, align 4, !tbaa !14
  %185 = load ptr, ptr %2, align 8, !tbaa !5
  %186 = getelementptr inbounds %struct._NormEffect, ptr %185, i32 0, i32 8
  %187 = load i32, ptr %186, align 8, !tbaa !24
  %188 = icmp slt i32 %184, %187
  br i1 %188, label %189, label %248

189:                                              ; preds = %183
  %190 = load ptr, ptr %2, align 8, !tbaa !5
  %191 = getelementptr inbounds %struct._NormEffect, ptr %190, i32 0, i32 7
  %192 = load ptr, ptr %191, align 8, !tbaa !25
  %193 = load i32, ptr %3, align 4, !tbaa !14
  %194 = sext i32 %193 to i64
  %195 = getelementptr inbounds %struct._Fact, ptr %192, i64 %194
  %196 = getelementptr inbounds %struct._Fact, ptr %195, i32 0, i32 0
  %197 = load i32, ptr %196, align 4, !tbaa !15
  %198 = load ptr, ptr %5, align 8, !tbaa !5
  %199 = getelementptr inbounds %struct._NormEffect, ptr %198, i32 0, i32 7
  %200 = load ptr, ptr %199, align 8, !tbaa !25
  %201 = load i32, ptr %3, align 4, !tbaa !14
  %202 = sext i32 %201 to i64
  %203 = getelementptr inbounds %struct._Fact, ptr %200, i64 %202
  %204 = getelementptr inbounds %struct._Fact, ptr %203, i32 0, i32 0
  store i32 %197, ptr %204, align 4, !tbaa !15
  store i32 0, ptr %4, align 4, !tbaa !14
  br label %205

205:                                              ; preds = %241, %189
  %206 = load i32, ptr %4, align 4, !tbaa !14
  %207 = load ptr, ptr %2, align 8, !tbaa !5
  %208 = getelementptr inbounds %struct._NormEffect, ptr %207, i32 0, i32 7
  %209 = load ptr, ptr %208, align 8, !tbaa !25
  %210 = load i32, ptr %3, align 4, !tbaa !14
  %211 = sext i32 %210 to i64
  %212 = getelementptr inbounds %struct._Fact, ptr %209, i64 %211
  %213 = getelementptr inbounds %struct._Fact, ptr %212, i32 0, i32 0
  %214 = load i32, ptr %213, align 4, !tbaa !15
  %215 = sext i32 %214 to i64
  %216 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %215
  %217 = load i32, ptr %216, align 4, !tbaa !14
  %218 = icmp slt i32 %206, %217
  br i1 %218, label %219, label %244

219:                                              ; preds = %205
  %220 = load ptr, ptr %2, align 8, !tbaa !5
  %221 = getelementptr inbounds %struct._NormEffect, ptr %220, i32 0, i32 7
  %222 = load ptr, ptr %221, align 8, !tbaa !25
  %223 = load i32, ptr %3, align 4, !tbaa !14
  %224 = sext i32 %223 to i64
  %225 = getelementptr inbounds %struct._Fact, ptr %222, i64 %224
  %226 = getelementptr inbounds %struct._Fact, ptr %225, i32 0, i32 1
  %227 = load i32, ptr %4, align 4, !tbaa !14
  %228 = sext i32 %227 to i64
  %229 = getelementptr inbounds [5 x i32], ptr %226, i64 0, i64 %228
  %230 = load i32, ptr %229, align 4, !tbaa !14
  %231 = load ptr, ptr %5, align 8, !tbaa !5
  %232 = getelementptr inbounds %struct._NormEffect, ptr %231, i32 0, i32 7
  %233 = load ptr, ptr %232, align 8, !tbaa !25
  %234 = load i32, ptr %3, align 4, !tbaa !14
  %235 = sext i32 %234 to i64
  %236 = getelementptr inbounds %struct._Fact, ptr %233, i64 %235
  %237 = getelementptr inbounds %struct._Fact, ptr %236, i32 0, i32 1
  %238 = load i32, ptr %4, align 4, !tbaa !14
  %239 = sext i32 %238 to i64
  %240 = getelementptr inbounds [5 x i32], ptr %237, i64 0, i64 %239
  store i32 %230, ptr %240, align 4, !tbaa !14
  br label %241

241:                                              ; preds = %219
  %242 = load i32, ptr %4, align 4, !tbaa !14
  %243 = add nsw i32 %242, 1
  store i32 %243, ptr %4, align 4, !tbaa !14
  br label %205, !llvm.loop !26

244:                                              ; preds = %205
  br label %245

245:                                              ; preds = %244
  %246 = load i32, ptr %3, align 4, !tbaa !14
  %247 = add nsw i32 %246, 1
  store i32 %247, ptr %3, align 4, !tbaa !14
  br label %183, !llvm.loop !27

248:                                              ; preds = %183
  %249 = load ptr, ptr %2, align 8, !tbaa !5
  %250 = getelementptr inbounds %struct._NormEffect, ptr %249, i32 0, i32 12
  %251 = load i32, ptr %250, align 8, !tbaa !28
  %252 = sext i32 %251 to i64
  %253 = call noalias ptr @calloc(i64 noundef %252, i64 noundef 4) #7
  %254 = load ptr, ptr %5, align 8, !tbaa !5
  %255 = getelementptr inbounds %struct._NormEffect, ptr %254, i32 0, i32 9
  store ptr %253, ptr %255, align 8, !tbaa !29
  %256 = load ptr, ptr %2, align 8, !tbaa !5
  %257 = getelementptr inbounds %struct._NormEffect, ptr %256, i32 0, i32 12
  %258 = load i32, ptr %257, align 8, !tbaa !28
  %259 = sext i32 %258 to i64
  %260 = call noalias ptr @calloc(i64 noundef %259, i64 noundef 8) #7
  %261 = load ptr, ptr %5, align 8, !tbaa !5
  %262 = getelementptr inbounds %struct._NormEffect, ptr %261, i32 0, i32 10
  store ptr %260, ptr %262, align 8, !tbaa !30
  %263 = load ptr, ptr %2, align 8, !tbaa !5
  %264 = getelementptr inbounds %struct._NormEffect, ptr %263, i32 0, i32 12
  %265 = load i32, ptr %264, align 8, !tbaa !28
  %266 = sext i32 %265 to i64
  %267 = call noalias ptr @calloc(i64 noundef %266, i64 noundef 8) #7
  %268 = load ptr, ptr %5, align 8, !tbaa !5
  %269 = getelementptr inbounds %struct._NormEffect, ptr %268, i32 0, i32 11
  store ptr %267, ptr %269, align 8, !tbaa !31
  store i32 0, ptr %3, align 4, !tbaa !14
  br label %270

270:                                              ; preds = %318, %248
  %271 = load i32, ptr %3, align 4, !tbaa !14
  %272 = load ptr, ptr %2, align 8, !tbaa !5
  %273 = getelementptr inbounds %struct._NormEffect, ptr %272, i32 0, i32 12
  %274 = load i32, ptr %273, align 8, !tbaa !28
  %275 = icmp slt i32 %271, %274
  br i1 %275, label %276, label %321

276:                                              ; preds = %270
  %277 = load ptr, ptr %2, align 8, !tbaa !5
  %278 = getelementptr inbounds %struct._NormEffect, ptr %277, i32 0, i32 9
  %279 = load ptr, ptr %278, align 8, !tbaa !29
  %280 = load i32, ptr %3, align 4, !tbaa !14
  %281 = sext i32 %280 to i64
  %282 = getelementptr inbounds i32, ptr %279, i64 %281
  %283 = load i32, ptr %282, align 4, !tbaa !14
  %284 = load ptr, ptr %5, align 8, !tbaa !5
  %285 = getelementptr inbounds %struct._NormEffect, ptr %284, i32 0, i32 9
  %286 = load ptr, ptr %285, align 8, !tbaa !29
  %287 = load i32, ptr %3, align 4, !tbaa !14
  %288 = sext i32 %287 to i64
  %289 = getelementptr inbounds i32, ptr %286, i64 %288
  store i32 %283, ptr %289, align 4, !tbaa !14
  %290 = load ptr, ptr %2, align 8, !tbaa !5
  %291 = getelementptr inbounds %struct._NormEffect, ptr %290, i32 0, i32 10
  %292 = load ptr, ptr %291, align 8, !tbaa !30
  %293 = load i32, ptr %3, align 4, !tbaa !14
  %294 = sext i32 %293 to i64
  %295 = getelementptr inbounds ptr, ptr %292, i64 %294
  %296 = load ptr, ptr %295, align 8, !tbaa !5
  %297 = call ptr @copy_Exp(ptr noundef %296)
  %298 = load ptr, ptr %5, align 8, !tbaa !5
  %299 = getelementptr inbounds %struct._NormEffect, ptr %298, i32 0, i32 10
  %300 = load ptr, ptr %299, align 8, !tbaa !30
  %301 = load i32, ptr %3, align 4, !tbaa !14
  %302 = sext i32 %301 to i64
  %303 = getelementptr inbounds ptr, ptr %300, i64 %302
  store ptr %297, ptr %303, align 8, !tbaa !5
  %304 = load ptr, ptr %2, align 8, !tbaa !5
  %305 = getelementptr inbounds %struct._NormEffect, ptr %304, i32 0, i32 11
  %306 = load ptr, ptr %305, align 8, !tbaa !31
  %307 = load i32, ptr %3, align 4, !tbaa !14
  %308 = sext i32 %307 to i64
  %309 = getelementptr inbounds ptr, ptr %306, i64 %308
  %310 = load ptr, ptr %309, align 8, !tbaa !5
  %311 = call ptr @copy_Exp(ptr noundef %310)
  %312 = load ptr, ptr %5, align 8, !tbaa !5
  %313 = getelementptr inbounds %struct._NormEffect, ptr %312, i32 0, i32 11
  %314 = load ptr, ptr %313, align 8, !tbaa !31
  %315 = load i32, ptr %3, align 4, !tbaa !14
  %316 = sext i32 %315 to i64
  %317 = getelementptr inbounds ptr, ptr %314, i64 %316
  store ptr %311, ptr %317, align 8, !tbaa !5
  br label %318

318:                                              ; preds = %276
  %319 = load i32, ptr %3, align 4, !tbaa !14
  %320 = add nsw i32 %319, 1
  store i32 %320, ptr %3, align 4, !tbaa !14
  br label %270, !llvm.loop !32

321:                                              ; preds = %270
  %322 = load ptr, ptr %2, align 8, !tbaa !5
  %323 = getelementptr inbounds %struct._NormEffect, ptr %322, i32 0, i32 12
  %324 = load i32, ptr %323, align 8, !tbaa !28
  %325 = load ptr, ptr %5, align 8, !tbaa !5
  %326 = getelementptr inbounds %struct._NormEffect, ptr %325, i32 0, i32 12
  store i32 %324, ptr %326, align 8, !tbaa !28
  %327 = load ptr, ptr %2, align 8, !tbaa !5
  %328 = getelementptr inbounds %struct._NormEffect, ptr %327, i32 0, i32 16
  %329 = load i32, ptr %328, align 8, !tbaa !33
  %330 = sext i32 %329 to i64
  %331 = call noalias ptr @calloc(i64 noundef %330, i64 noundef 4) #7
  %332 = load ptr, ptr %5, align 8, !tbaa !5
  %333 = getelementptr inbounds %struct._NormEffect, ptr %332, i32 0, i32 13
  store ptr %331, ptr %333, align 8, !tbaa !34
  %334 = load ptr, ptr %2, align 8, !tbaa !5
  %335 = getelementptr inbounds %struct._NormEffect, ptr %334, i32 0, i32 16
  %336 = load i32, ptr %335, align 8, !tbaa !33
  %337 = sext i32 %336 to i64
  %338 = call noalias ptr @calloc(i64 noundef %337, i64 noundef 24) #7
  %339 = load ptr, ptr %5, align 8, !tbaa !5
  %340 = getelementptr inbounds %struct._NormEffect, ptr %339, i32 0, i32 14
  store ptr %338, ptr %340, align 8, !tbaa !35
  %341 = load ptr, ptr %2, align 8, !tbaa !5
  %342 = getelementptr inbounds %struct._NormEffect, ptr %341, i32 0, i32 16
  %343 = load i32, ptr %342, align 8, !tbaa !33
  %344 = sext i32 %343 to i64
  %345 = call noalias ptr @calloc(i64 noundef %344, i64 noundef 8) #7
  %346 = load ptr, ptr %5, align 8, !tbaa !5
  %347 = getelementptr inbounds %struct._NormEffect, ptr %346, i32 0, i32 15
  store ptr %345, ptr %347, align 8, !tbaa !36
  store i32 0, ptr %3, align 4, !tbaa !14
  br label %348

348:                                              ; preds = %437, %321
  %349 = load i32, ptr %3, align 4, !tbaa !14
  %350 = load ptr, ptr %2, align 8, !tbaa !5
  %351 = getelementptr inbounds %struct._NormEffect, ptr %350, i32 0, i32 16
  %352 = load i32, ptr %351, align 8, !tbaa !33
  %353 = icmp slt i32 %349, %352
  br i1 %353, label %354, label %440

354:                                              ; preds = %348
  %355 = load ptr, ptr %2, align 8, !tbaa !5
  %356 = getelementptr inbounds %struct._NormEffect, ptr %355, i32 0, i32 13
  %357 = load ptr, ptr %356, align 8, !tbaa !34
  %358 = load i32, ptr %3, align 4, !tbaa !14
  %359 = sext i32 %358 to i64
  %360 = getelementptr inbounds i32, ptr %357, i64 %359
  %361 = load i32, ptr %360, align 4, !tbaa !14
  %362 = load ptr, ptr %5, align 8, !tbaa !5
  %363 = getelementptr inbounds %struct._NormEffect, ptr %362, i32 0, i32 13
  %364 = load ptr, ptr %363, align 8, !tbaa !34
  %365 = load i32, ptr %3, align 4, !tbaa !14
  %366 = sext i32 %365 to i64
  %367 = getelementptr inbounds i32, ptr %364, i64 %366
  store i32 %361, ptr %367, align 4, !tbaa !14
  %368 = load ptr, ptr %2, align 8, !tbaa !5
  %369 = getelementptr inbounds %struct._NormEffect, ptr %368, i32 0, i32 14
  %370 = load ptr, ptr %369, align 8, !tbaa !35
  %371 = load i32, ptr %3, align 4, !tbaa !14
  %372 = sext i32 %371 to i64
  %373 = getelementptr inbounds %struct._Fluent, ptr %370, i64 %372
  %374 = getelementptr inbounds %struct._Fluent, ptr %373, i32 0, i32 0
  %375 = load i32, ptr %374, align 4, !tbaa !37
  %376 = load ptr, ptr %5, align 8, !tbaa !5
  %377 = getelementptr inbounds %struct._NormEffect, ptr %376, i32 0, i32 14
  %378 = load ptr, ptr %377, align 8, !tbaa !35
  %379 = load i32, ptr %3, align 4, !tbaa !14
  %380 = sext i32 %379 to i64
  %381 = getelementptr inbounds %struct._Fluent, ptr %378, i64 %380
  %382 = getelementptr inbounds %struct._Fluent, ptr %381, i32 0, i32 0
  store i32 %375, ptr %382, align 4, !tbaa !37
  store i32 0, ptr %4, align 4, !tbaa !14
  br label %383

383:                                              ; preds = %419, %354
  %384 = load i32, ptr %4, align 4, !tbaa !14
  %385 = load ptr, ptr %2, align 8, !tbaa !5
  %386 = getelementptr inbounds %struct._NormEffect, ptr %385, i32 0, i32 14
  %387 = load ptr, ptr %386, align 8, !tbaa !35
  %388 = load i32, ptr %3, align 4, !tbaa !14
  %389 = sext i32 %388 to i64
  %390 = getelementptr inbounds %struct._Fluent, ptr %387, i64 %389
  %391 = getelementptr inbounds %struct._Fluent, ptr %390, i32 0, i32 0
  %392 = load i32, ptr %391, align 4, !tbaa !37
  %393 = sext i32 %392 to i64
  %394 = getelementptr inbounds [50 x i32], ptr @gf_arity, i64 0, i64 %393
  %395 = load i32, ptr %394, align 4, !tbaa !14
  %396 = icmp slt i32 %384, %395
  br i1 %396, label %397, label %422

397:                                              ; preds = %383
  %398 = load ptr, ptr %2, align 8, !tbaa !5
  %399 = getelementptr inbounds %struct._NormEffect, ptr %398, i32 0, i32 14
  %400 = load ptr, ptr %399, align 8, !tbaa !35
  %401 = load i32, ptr %3, align 4, !tbaa !14
  %402 = sext i32 %401 to i64
  %403 = getelementptr inbounds %struct._Fluent, ptr %400, i64 %402
  %404 = getelementptr inbounds %struct._Fluent, ptr %403, i32 0, i32 1
  %405 = load i32, ptr %4, align 4, !tbaa !14
  %406 = sext i32 %405 to i64
  %407 = getelementptr inbounds [5 x i32], ptr %404, i64 0, i64 %406
  %408 = load i32, ptr %407, align 4, !tbaa !14
  %409 = load ptr, ptr %5, align 8, !tbaa !5
  %410 = getelementptr inbounds %struct._NormEffect, ptr %409, i32 0, i32 14
  %411 = load ptr, ptr %410, align 8, !tbaa !35
  %412 = load i32, ptr %3, align 4, !tbaa !14
  %413 = sext i32 %412 to i64
  %414 = getelementptr inbounds %struct._Fluent, ptr %411, i64 %413
  %415 = getelementptr inbounds %struct._Fluent, ptr %414, i32 0, i32 1
  %416 = load i32, ptr %4, align 4, !tbaa !14
  %417 = sext i32 %416 to i64
  %418 = getelementptr inbounds [5 x i32], ptr %415, i64 0, i64 %417
  store i32 %408, ptr %418, align 4, !tbaa !14
  br label %419

419:                                              ; preds = %397
  %420 = load i32, ptr %4, align 4, !tbaa !14
  %421 = add nsw i32 %420, 1
  store i32 %421, ptr %4, align 4, !tbaa !14
  br label %383, !llvm.loop !39

422:                                              ; preds = %383
  %423 = load ptr, ptr %2, align 8, !tbaa !5
  %424 = getelementptr inbounds %struct._NormEffect, ptr %423, i32 0, i32 15
  %425 = load ptr, ptr %424, align 8, !tbaa !36
  %426 = load i32, ptr %3, align 4, !tbaa !14
  %427 = sext i32 %426 to i64
  %428 = getelementptr inbounds ptr, ptr %425, i64 %427
  %429 = load ptr, ptr %428, align 8, !tbaa !5
  %430 = call ptr @copy_Exp(ptr noundef %429)
  %431 = load ptr, ptr %5, align 8, !tbaa !5
  %432 = getelementptr inbounds %struct._NormEffect, ptr %431, i32 0, i32 15
  %433 = load ptr, ptr %432, align 8, !tbaa !36
  %434 = load i32, ptr %3, align 4, !tbaa !14
  %435 = sext i32 %434 to i64
  %436 = getelementptr inbounds ptr, ptr %433, i64 %435
  store ptr %430, ptr %436, align 8, !tbaa !5
  br label %437

437:                                              ; preds = %422
  %438 = load i32, ptr %3, align 4, !tbaa !14
  %439 = add nsw i32 %438, 1
  store i32 %439, ptr %3, align 4, !tbaa !14
  br label %348, !llvm.loop !40

440:                                              ; preds = %348
  %441 = load ptr, ptr %2, align 8, !tbaa !5
  %442 = getelementptr inbounds %struct._NormEffect, ptr %441, i32 0, i32 16
  %443 = load i32, ptr %442, align 8, !tbaa !33
  %444 = load ptr, ptr %5, align 8, !tbaa !5
  %445 = getelementptr inbounds %struct._NormEffect, ptr %444, i32 0, i32 16
  store i32 %443, ptr %445, align 8, !tbaa !33
  %446 = load ptr, ptr %5, align 8, !tbaa !5
  %447 = getelementptr inbounds %struct._NormEffect, ptr %446, i32 0, i32 18
  store ptr null, ptr %447, align 8, !tbaa !41
  %448 = load ptr, ptr %5, align 8, !tbaa !5
  %449 = getelementptr inbounds %struct._NormEffect, ptr %448, i32 0, i32 17
  store ptr null, ptr %449, align 8, !tbaa !42
  %450 = load ptr, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #6
  ret ptr %450
}

declare ptr @copy_Exp(ptr noundef) #5

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !11, i64 0}
!10 = !{!"_NormEffect", !11, i64 0, !7, i64 4, !7, i64 64, !6, i64 128, !11, i64 136, !6, i64 144, !11, i64 152, !6, i64 160, !11, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !11, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !11, i64 232, !6, i64 240, !6, i64 248}
!11 = !{!"int", !7, i64 0}
!12 = !{!10, !11, i64 136}
!13 = !{!10, !6, i64 128}
!14 = !{!11, !11, i64 0}
!15 = !{!16, !11, i64 0}
!16 = !{!"_Fact", !11, i64 0, !7, i64 4}
!17 = distinct !{!17, !18}
!18 = !{!"llvm.loop.mustprogress"}
!19 = distinct !{!19, !18}
!20 = !{!10, !11, i64 152}
!21 = !{!10, !6, i64 144}
!22 = distinct !{!22, !18}
!23 = distinct !{!23, !18}
!24 = !{!10, !11, i64 168}
!25 = !{!10, !6, i64 160}
!26 = distinct !{!26, !18}
!27 = distinct !{!27, !18}
!28 = !{!10, !11, i64 200}
!29 = !{!10, !6, i64 176}
!30 = !{!10, !6, i64 184}
!31 = !{!10, !6, i64 192}
!32 = distinct !{!32, !18}
!33 = !{!10, !11, i64 232}
!34 = !{!10, !6, i64 208}
!35 = !{!10, !6, i64 216}
!36 = !{!10, !6, i64 224}
!37 = !{!38, !11, i64 0}
!38 = !{!"_Fluent", !11, i64 0, !7, i64 4}
!39 = distinct !{!39, !18}
!40 = distinct !{!40, !18}
!41 = !{!10, !6, i64 248}
!42 = !{!10, !6, i64 240}


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

%struct._Fact = type { i32, [5 x i32] }
%struct._Fluent = type { i32, [5 x i32] }

@stdout = external local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [28 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [77 x i8], align 1
@garity = external local_unnamed_addr global [50 x i32], align 16
@gf_arity = external local_unnamed_addr global [50 x i32], align 16

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @calloc(i64 noundef, i64 noundef) local_unnamed_addr #0

; Function Attrs: nofree nounwind
declare noundef i32 @fprintf(ptr nocapture noundef, ptr nocapture noundef readonly, ...) local_unnamed_addr #1

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) local_unnamed_addr #2

; Function Attrs: nounwind uwtable
define dso_local noalias noundef ptr @new_NormEffect2(ptr nocapture noundef readonly %0) local_unnamed_addr #3 {
  %2 = tail call noalias dereferenceable_or_null(256) ptr @calloc(i64 noundef 1, i64 noundef 256) #5
  %3 = icmp eq ptr %2, null
  br i1 %3, label %4, label %7

4:                                                ; preds = %1
  %5 = load ptr, ptr @stdout, align 8, !tbaa !5
  %6 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %5, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, i32 noundef 538) #6
  tail call void @exit(i32 noundef 1) #7
  unreachable

7:                                                ; preds = %1
  %8 = getelementptr inbounds i8, ptr %0, i64 136
  %9 = load i32, ptr %8, align 8, !tbaa !9
  %10 = sext i32 %9 to i64
  %11 = tail call noalias ptr @calloc(i64 noundef %10, i64 noundef 24) #5
  %12 = getelementptr inbounds i8, ptr %2, i64 128
  store ptr %11, ptr %12, align 8, !tbaa !12
  %13 = getelementptr inbounds i8, ptr %2, i64 136
  store i32 %9, ptr %13, align 8, !tbaa !9
  %14 = icmp sgt i32 %9, 0
  br i1 %14, label %.lr.ph134, label %._crit_edge135

.lr.ph134:                                        ; preds = %7
  %15 = getelementptr inbounds i8, ptr %0, i64 128
  %16 = load ptr, ptr %15, align 8, !tbaa !12
  %wide.trip.count = zext nneg i32 %9 to i64
  br label %17

17:                                               ; preds = %.lr.ph134, %._crit_edge
  %indvars.iv168 = phi i64 [ 0, %.lr.ph134 ], [ %indvars.iv.next169, %._crit_edge ]
  %18 = getelementptr inbounds %struct._Fact, ptr %16, i64 %indvars.iv168
  %19 = load i32, ptr %18, align 4, !tbaa !13
  %20 = getelementptr inbounds %struct._Fact, ptr %11, i64 %indvars.iv168
  store i32 %19, ptr %20, align 4, !tbaa !13
  %21 = sext i32 %19 to i64
  %22 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %21
  %23 = load i32, ptr %22, align 4, !tbaa !15
  %24 = icmp sgt i32 %23, 0
  br i1 %24, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %17
  %25 = getelementptr inbounds i8, ptr %18, i64 4
  br label %26

26:                                               ; preds = %.lr.ph, %26
  %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %26 ]
  %27 = getelementptr inbounds [5 x i32], ptr %25, i64 0, i64 %indvars.iv
  %28 = load i32, ptr %27, align 4, !tbaa !15
  %29 = getelementptr inbounds %struct._Fact, ptr %11, i64 %indvars.iv168, i32 1, i64 %indvars.iv
  store i32 %28, ptr %29, align 4, !tbaa !15
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %30 = load i32, ptr %18, align 4, !tbaa !13
  %31 = sext i32 %30 to i64
  %32 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %31
  %33 = load i32, ptr %32, align 4, !tbaa !15
  %34 = sext i32 %33 to i64
  %35 = icmp slt i64 %indvars.iv.next, %34
  br i1 %35, label %26, label %._crit_edge, !llvm.loop !16

._crit_edge:                                      ; preds = %26, %17
  %indvars.iv.next169 = add nuw nsw i64 %indvars.iv168, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next169, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge135, label %17, !llvm.loop !18

._crit_edge135:                                   ; preds = %._crit_edge, %7
  %36 = getelementptr inbounds i8, ptr %0, i64 152
  %37 = load i32, ptr %36, align 8, !tbaa !19
  %38 = sext i32 %37 to i64
  %39 = tail call noalias ptr @calloc(i64 noundef %38, i64 noundef 24) #5
  %40 = getelementptr inbounds i8, ptr %2, i64 144
  store ptr %39, ptr %40, align 8, !tbaa !20
  %41 = getelementptr inbounds i8, ptr %2, i64 152
  store i32 %37, ptr %41, align 8, !tbaa !19
  %42 = icmp sgt i32 %37, 0
  br i1 %42, label %.lr.ph142, label %._crit_edge143

.lr.ph142:                                        ; preds = %._crit_edge135
  %43 = getelementptr inbounds i8, ptr %0, i64 144
  %44 = load ptr, ptr %43, align 8, !tbaa !20
  %wide.trip.count177 = zext nneg i32 %37 to i64
  br label %45

45:                                               ; preds = %.lr.ph142, %._crit_edge139
  %indvars.iv174 = phi i64 [ 0, %.lr.ph142 ], [ %indvars.iv.next175, %._crit_edge139 ]
  %46 = getelementptr inbounds %struct._Fact, ptr %44, i64 %indvars.iv174
  %47 = load i32, ptr %46, align 4, !tbaa !13
  %48 = getelementptr inbounds %struct._Fact, ptr %39, i64 %indvars.iv174
  store i32 %47, ptr %48, align 4, !tbaa !13
  %49 = sext i32 %47 to i64
  %50 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %49
  %51 = load i32, ptr %50, align 4, !tbaa !15
  %52 = icmp sgt i32 %51, 0
  br i1 %52, label %.lr.ph138, label %._crit_edge139

.lr.ph138:                                        ; preds = %45
  %53 = getelementptr inbounds i8, ptr %46, i64 4
  br label %54

54:                                               ; preds = %.lr.ph138, %54
  %indvars.iv171 = phi i64 [ 0, %.lr.ph138 ], [ %indvars.iv.next172, %54 ]
  %55 = getelementptr inbounds [5 x i32], ptr %53, i64 0, i64 %indvars.iv171
  %56 = load i32, ptr %55, align 4, !tbaa !15
  %57 = getelementptr inbounds %struct._Fact, ptr %39, i64 %indvars.iv174, i32 1, i64 %indvars.iv171
  store i32 %56, ptr %57, align 4, !tbaa !15
  %indvars.iv.next172 = add nuw nsw i64 %indvars.iv171, 1
  %58 = load i32, ptr %46, align 4, !tbaa !13
  %59 = sext i32 %58 to i64
  %60 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %59
  %61 = load i32, ptr %60, align 4, !tbaa !15
  %62 = sext i32 %61 to i64
  %63 = icmp slt i64 %indvars.iv.next172, %62
  br i1 %63, label %54, label %._crit_edge139, !llvm.loop !21

._crit_edge139:                                   ; preds = %54, %45
  %indvars.iv.next175 = add nuw nsw i64 %indvars.iv174, 1
  %exitcond178.not = icmp eq i64 %indvars.iv.next175, %wide.trip.count177
  br i1 %exitcond178.not, label %._crit_edge143, label %45, !llvm.loop !22

._crit_edge143:                                   ; preds = %._crit_edge139, %._crit_edge135
  %64 = getelementptr inbounds i8, ptr %0, i64 168
  %65 = load i32, ptr %64, align 8, !tbaa !23
  %66 = sext i32 %65 to i64
  %67 = tail call noalias ptr @calloc(i64 noundef %66, i64 noundef 24) #5
  %68 = getelementptr inbounds i8, ptr %2, i64 160
  store ptr %67, ptr %68, align 8, !tbaa !24
  %69 = getelementptr inbounds i8, ptr %2, i64 168
  store i32 %65, ptr %69, align 8, !tbaa !23
  %70 = icmp sgt i32 %65, 0
  br i1 %70, label %.lr.ph150, label %._crit_edge151

.lr.ph150:                                        ; preds = %._crit_edge143
  %71 = getelementptr inbounds i8, ptr %0, i64 160
  %72 = load ptr, ptr %71, align 8, !tbaa !24
  %wide.trip.count185 = zext nneg i32 %65 to i64
  br label %73

73:                                               ; preds = %.lr.ph150, %._crit_edge147
  %indvars.iv182 = phi i64 [ 0, %.lr.ph150 ], [ %indvars.iv.next183, %._crit_edge147 ]
  %74 = getelementptr inbounds %struct._Fact, ptr %72, i64 %indvars.iv182
  %75 = load i32, ptr %74, align 4, !tbaa !13
  %76 = getelementptr inbounds %struct._Fact, ptr %67, i64 %indvars.iv182
  store i32 %75, ptr %76, align 4, !tbaa !13
  %77 = sext i32 %75 to i64
  %78 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %77
  %79 = load i32, ptr %78, align 4, !tbaa !15
  %80 = icmp sgt i32 %79, 0
  br i1 %80, label %.lr.ph146, label %._crit_edge147

.lr.ph146:                                        ; preds = %73
  %81 = getelementptr inbounds i8, ptr %74, i64 4
  br label %82

82:                                               ; preds = %.lr.ph146, %82
  %indvars.iv179 = phi i64 [ 0, %.lr.ph146 ], [ %indvars.iv.next180, %82 ]
  %83 = getelementptr inbounds [5 x i32], ptr %81, i64 0, i64 %indvars.iv179
  %84 = load i32, ptr %83, align 4, !tbaa !15
  %85 = getelementptr inbounds %struct._Fact, ptr %67, i64 %indvars.iv182, i32 1, i64 %indvars.iv179
  store i32 %84, ptr %85, align 4, !tbaa !15
  %indvars.iv.next180 = add nuw nsw i64 %indvars.iv179, 1
  %86 = load i32, ptr %74, align 4, !tbaa !13
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds [50 x i32], ptr @garity, i64 0, i64 %87
  %89 = load i32, ptr %88, align 4, !tbaa !15
  %90 = sext i32 %89 to i64
  %91 = icmp slt i64 %indvars.iv.next180, %90
  br i1 %91, label %82, label %._crit_edge147, !llvm.loop !25

._crit_edge147:                                   ; preds = %82, %73
  %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_edge151, label %73, !llvm.loop !26

._crit_edge151:                                   ; preds = %._crit_edge147, %._crit_edge143
  %92 = getelementptr inbounds i8, ptr %0, i64 200
  %93 = load i32, ptr %92, align 8, !tbaa !27
  %94 = sext i32 %93 to i64
  %95 = tail call noalias ptr @calloc(i64 noundef %94, i64 noundef 4) #5
  %96 = getelementptr inbounds i8, ptr %2, i64 176
  store ptr %95, ptr %96, align 8, !tbaa !28
  %97 = tail call noalias ptr @calloc(i64 noundef %94, i64 noundef 8) #5
  %98 = getelementptr inbounds i8, ptr %2, i64 184
  store ptr %97, ptr %98, align 8, !tbaa !29
  %99 = tail call noalias ptr @calloc(i64 noundef %94, i64 noundef 8) #5
  %100 = getelementptr inbounds i8, ptr %2, i64 192
  store ptr %99, ptr %100, align 8, !tbaa !30
  %101 = icmp sgt i32 %93, 0
  br i1 %101, label %.lr.ph154, label %._crit_edge155

.lr.ph154:                                        ; preds = %._crit_edge151
  %102 = getelementptr inbounds i8, ptr %0, i64 176
  %103 = getelementptr inbounds i8, ptr %0, i64 184
  %104 = getelementptr inbounds i8, ptr %0, i64 192
  br label %105

105:                                              ; preds = %.lr.ph154, %105
  %indvars.iv187 = phi i64 [ 0, %.lr.ph154 ], [ %indvars.iv.next188, %105 ]
  %106 = load ptr, ptr %102, align 8, !tbaa !28
  %107 = getelementptr inbounds i32, ptr %106, i64 %indvars.iv187
  %108 = load i32, ptr %107, align 4, !tbaa !15
  %109 = getelementptr inbounds i32, ptr %95, i64 %indvars.iv187
  store i32 %108, ptr %109, align 4, !tbaa !15
  %110 = load ptr, ptr %103, align 8, !tbaa !29
  %111 = getelementptr inbounds ptr, ptr %110, i64 %indvars.iv187
  %112 = load ptr, ptr %111, align 8, !tbaa !5
  %113 = tail call ptr @copy_Exp(ptr noundef %112) #6
  %114 = getelementptr inbounds ptr, ptr %97, i64 %indvars.iv187
  store ptr %113, ptr %114, align 8, !tbaa !5
  %115 = load ptr, ptr %104, align 8, !tbaa !30
  %116 = getelementptr inbounds ptr, ptr %115, i64 %indvars.iv187
  %117 = load ptr, ptr %116, align 8, !tbaa !5
  %118 = tail call ptr @copy_Exp(ptr noundef %117) #6
  %119 = getelementptr inbounds ptr, ptr %99, i64 %indvars.iv187
  store ptr %118, ptr %119, align 8, !tbaa !5
  %indvars.iv.next188 = add nuw nsw i64 %indvars.iv187, 1
  %120 = load i32, ptr %92, align 8, !tbaa !27
  %121 = sext i32 %120 to i64
  %122 = icmp slt i64 %indvars.iv.next188, %121
  br i1 %122, label %105, label %._crit_edge155, !llvm.loop !31

._crit_edge155:                                   ; preds = %105, %._crit_edge151
  %.lcssa130 = phi i32 [ %93, %._crit_edge151 ], [ %120, %105 ]
  %123 = getelementptr inbounds i8, ptr %2, i64 200
  store i32 %.lcssa130, ptr %123, align 8, !tbaa !27
  %124 = getelementptr inbounds i8, ptr %0, i64 232
  %125 = load i32, ptr %124, align 8, !tbaa !32
  %126 = sext i32 %125 to i64
  %127 = tail call noalias ptr @calloc(i64 noundef %126, i64 noundef 4) #5
  %128 = getelementptr inbounds i8, ptr %2, i64 208
  store ptr %127, ptr %128, align 8, !tbaa !33
  %129 = tail call noalias ptr @calloc(i64 noundef %126, i64 noundef 24) #5
  %130 = getelementptr inbounds i8, ptr %2, i64 216
  store ptr %129, ptr %130, align 8, !tbaa !34
  %131 = tail call noalias ptr @calloc(i64 noundef %126, i64 noundef 8) #5
  %132 = getelementptr inbounds i8, ptr %2, i64 224
  store ptr %131, ptr %132, align 8, !tbaa !35
  %133 = icmp sgt i32 %125, 0
  br i1 %133, label %.lr.ph162, label %._crit_edge163

.lr.ph162:                                        ; preds = %._crit_edge155
  %134 = getelementptr inbounds i8, ptr %0, i64 208
  %135 = getelementptr inbounds i8, ptr %0, i64 216
  %136 = getelementptr inbounds i8, ptr %0, i64 224
  br label %137

137:                                              ; preds = %.lr.ph162, %._crit_edge159
  %indvars.iv193 = phi i64 [ 0, %.lr.ph162 ], [ %indvars.iv.next194, %._crit_edge159 ]
  %138 = load ptr, ptr %134, align 8, !tbaa !33
  %139 = getelementptr inbounds i32, ptr %138, i64 %indvars.iv193
  %140 = load i32, ptr %139, align 4, !tbaa !15
  %141 = getelementptr inbounds i32, ptr %127, i64 %indvars.iv193
  store i32 %140, ptr %141, align 4, !tbaa !15
  %142 = load ptr, ptr %135, align 8, !tbaa !34
  %143 = getelementptr inbounds %struct._Fluent, ptr %142, i64 %indvars.iv193
  %144 = load i32, ptr %143, align 4, !tbaa !36
  %145 = getelementptr inbounds %struct._Fluent, ptr %129, i64 %indvars.iv193
  store i32 %144, ptr %145, align 4, !tbaa !36
  %146 = sext i32 %144 to i64
  %147 = getelementptr inbounds [50 x i32], ptr @gf_arity, i64 0, i64 %146
  %148 = load i32, ptr %147, align 4, !tbaa !15
  %149 = icmp sgt i32 %148, 0
  br i1 %149, label %.lr.ph158, label %._crit_edge159

.lr.ph158:                                        ; preds = %137
  %150 = getelementptr inbounds i8, ptr %143, i64 4
  br label %151

151:                                              ; preds = %.lr.ph158, %151
  %indvars.iv190 = phi i64 [ 0, %.lr.ph158 ], [ %indvars.iv.next191, %151 ]
  %152 = getelementptr inbounds [5 x i32], ptr %150, i64 0, i64 %indvars.iv190
  %153 = load i32, ptr %152, align 4, !tbaa !15
  %154 = getelementptr inbounds %struct._Fluent, ptr %129, i64 %indvars.iv193, i32 1, i64 %indvars.iv190
  store i32 %153, ptr %154, align 4, !tbaa !15
  %indvars.iv.next191 = add nuw nsw i64 %indvars.iv190, 1
  %155 = load i32, ptr %143, align 4, !tbaa !36
  %156 = sext i32 %155 to i64
  %157 = getelementptr inbounds [50 x i32], ptr @gf_arity, i64 0, i64 %156
  %158 = load i32, ptr %157, align 4, !tbaa !15
  %159 = sext i32 %158 to i64
  %160 = icmp slt i64 %indvars.iv.next191, %159
  br i1 %160, label %151, label %._crit_edge159, !llvm.loop !38

._crit_edge159:                                   ; preds = %151, %137
  %161 = load ptr, ptr %136, align 8, !tbaa !35
  %162 = getelementptr inbounds ptr, ptr %161, i64 %indvars.iv193
  %163 = load ptr, ptr %162, align 8, !tbaa !5
  %164 = tail call ptr @copy_Exp(ptr noundef %163) #6
  %165 = getelementptr inbounds ptr, ptr %131, i64 %indvars.iv193
  store ptr %164, ptr %165, align 8, !tbaa !5
  %indvars.iv.next194 = add nuw nsw i64 %indvars.iv193, 1
  %166 = load i32, ptr %124, align 8, !tbaa !32
  %167 = sext i32 %166 to i64
  %168 = icmp slt i64 %indvars.iv.next194, %167
  br i1 %168, label %137, label %._crit_edge163, !llvm.loop !39

._crit_edge163:                                   ; preds = %._crit_edge159, %._crit_edge155
  %.lcssa = phi i32 [ %125, %._crit_edge155 ], [ %166, %._crit_edge159 ]
  %169 = getelementptr inbounds i8, ptr %2, i64 232
  store i32 %.lcssa, ptr %169, align 8, !tbaa !32
  ret ptr %2
}

declare ptr @copy_Exp(ptr noundef) local_unnamed_addr #4

attributes #0 = { mustprogress nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nofree 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 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = { "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 allocsize(0,1) }
attributes #6 = { nounwind }
attributes #7 = { noreturn nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !11, i64 136}
!10 = !{!"_NormEffect", !11, i64 0, !7, i64 4, !7, i64 64, !6, i64 128, !11, i64 136, !6, i64 144, !11, i64 152, !6, i64 160, !11, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !11, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !11, i64 232, !6, i64 240, !6, i64 248}
!11 = !{!"int", !7, i64 0}
!12 = !{!10, !6, i64 128}
!13 = !{!14, !11, i64 0}
!14 = !{!"_Fact", !11, i64 0, !7, i64 4}
!15 = !{!11, !11, i64 0}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = distinct !{!18, !17}
!19 = !{!10, !11, i64 152}
!20 = !{!10, !6, i64 144}
!21 = distinct !{!21, !17}
!22 = distinct !{!22, !17}
!23 = !{!10, !11, i64 168}
!24 = !{!10, !6, i64 160}
!25 = distinct !{!25, !17}
!26 = distinct !{!26, !17}
!27 = !{!10, !11, i64 200}
!28 = !{!10, !6, i64 176}
!29 = !{!10, !6, i64 184}
!30 = !{!10, !6, i64 192}
!31 = distinct !{!31, !17}
!32 = !{!10, !11, i64 232}
!33 = !{!10, !6, i64 208}
!34 = !{!10, !6, i64 216}
!35 = !{!10, !6, i64 224}
!36 = !{!37, !11, i64 0}
!37 = !{!"_Fluent", !11, i64 0, !7, i64 4}
!38 = distinct !{!38, !17}
!39 = distinct !{!39, !17}


; Effective O3 passes: DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,MemCpyOptPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass