; LLVM IR from istoony/winograd-convolutional-nn :: main (main)

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

@A = external hidden global ptr, align 8
@B = external hidden global ptr, align 8
@G = external hidden global ptr, align 8
@.str = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [38 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @main(i32 noundef %0, ptr noundef %1) #0 {
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %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 ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca i32, align 4
  %14 = alloca [10 x i8], align 1
  %15 = alloca [10 x i8], align 1
  %16 = alloca [10 x i8], align 1
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca i32, align 4
  %20 = alloca ptr, align 8
  %21 = alloca i64, align 8
  %22 = alloca i32, align 4
  %23 = alloca i64, align 8
  %24 = alloca float, align 4
  store i32 %0, ptr %3, align 4, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #6
  %25 = load ptr, ptr %4, align 8, !tbaa !9
  %26 = getelementptr inbounds ptr, ptr %25, i64 1
  %27 = load ptr, ptr %26, align 8, !tbaa !9
  %28 = call i32 @atoi(ptr noundef %27) #7
  store i32 %28, ptr %5, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #6
  %29 = load ptr, ptr %4, align 8, !tbaa !9
  %30 = getelementptr inbounds ptr, ptr %29, i64 2
  %31 = load ptr, ptr %30, align 8, !tbaa !9
  %32 = call i32 @atoi(ptr noundef %31) #7
  store i32 %32, ptr %6, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #6
  %33 = load ptr, ptr %4, align 8, !tbaa !9
  %34 = getelementptr inbounds ptr, ptr %33, i64 3
  %35 = load ptr, ptr %34, align 8, !tbaa !9
  %36 = call i32 @atoi(ptr noundef %35) #7
  store i32 %36, ptr %7, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #6
  %37 = load ptr, ptr %4, align 8, !tbaa !9
  %38 = getelementptr inbounds ptr, ptr %37, i64 4
  %39 = load ptr, ptr %38, align 8, !tbaa !9
  %40 = call i32 @atoi(ptr noundef %39) #7
  store i32 %40, ptr %8, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  %41 = load ptr, ptr %4, align 8, !tbaa !9
  %42 = getelementptr inbounds ptr, ptr %41, i64 5
  %43 = load ptr, ptr %42, align 8, !tbaa !9
  %44 = call i32 @atoi(ptr noundef %43) #7
  store i32 %44, ptr %9, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  %45 = load ptr, ptr %4, align 8, !tbaa !9
  %46 = getelementptr inbounds ptr, ptr %45, i64 6
  %47 = load ptr, ptr %46, align 8, !tbaa !9
  %48 = call i32 @atoi(ptr noundef %47) #7
  store i32 %48, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  %49 = load ptr, ptr %4, align 8, !tbaa !9
  %50 = getelementptr inbounds ptr, ptr %49, i64 7
  %51 = load ptr, ptr %50, align 8, !tbaa !9
  store ptr %51, ptr %11, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  %52 = load ptr, ptr %4, align 8, !tbaa !9
  %53 = getelementptr inbounds ptr, ptr %52, i64 8
  %54 = load ptr, ptr %53, align 8, !tbaa !9
  store ptr %54, ptr %12, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  %55 = load i32, ptr %5, align 4, !tbaa !5
  %56 = load i32, ptr %6, align 4, !tbaa !5
  %57 = add nsw i32 %55, %56
  %58 = sub nsw i32 %57, 1
  store i32 %58, ptr %13, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 10, ptr %14) #6
  call void @llvm.lifetime.start.p0(i64 10, ptr %15) #6
  call void @llvm.lifetime.start.p0(i64 10, ptr %16) #6
  %59 = getelementptr inbounds [10 x i8], ptr %14, i64 0, i64 0
  %60 = load i32, ptr %5, align 4, !tbaa !5
  %61 = load i32, ptr %6, align 4, !tbaa !5
  call void @generateNameAT(ptr noundef %59, i32 noundef %60, i32 noundef %61)
  %62 = getelementptr inbounds [10 x i8], ptr %15, i64 0, i64 0
  %63 = load i32, ptr %5, align 4, !tbaa !5
  %64 = load i32, ptr %6, align 4, !tbaa !5
  call void @generateNameG(ptr noundef %62, i32 noundef %63, i32 noundef %64)
  %65 = getelementptr inbounds [10 x i8], ptr %16, i64 0, i64 0
  %66 = load i32, ptr %5, align 4, !tbaa !5
  %67 = load i32, ptr %6, align 4, !tbaa !5
  call void @generateNameBT(ptr noundef %65, i32 noundef %66, i32 noundef %67)
  %68 = load i32, ptr %5, align 4, !tbaa !5
  %69 = load i32, ptr %13, align 4, !tbaa !5
  %70 = call ptr @generateMatrix(i32 noundef %68, i32 noundef %69)
  store ptr %70, ptr @A, align 8, !tbaa !9
  %71 = load i32, ptr %13, align 4, !tbaa !5
  %72 = load i32, ptr %13, align 4, !tbaa !5
  %73 = call ptr @generateMatrix(i32 noundef %71, i32 noundef %72)
  store ptr %73, ptr @B, align 8, !tbaa !9
  %74 = load i32, ptr %6, align 4, !tbaa !5
  %75 = load i32, ptr %13, align 4, !tbaa !5
  %76 = call ptr @generateMatrix(i32 noundef %74, i32 noundef %75)
  store ptr %76, ptr @G, align 8, !tbaa !9
  %77 = load ptr, ptr @A, align 8, !tbaa !9
  %78 = getelementptr inbounds [10 x i8], ptr %14, i64 0, i64 0
  call void @readFile(ptr noundef %77, ptr noundef %78)
  %79 = load ptr, ptr @B, align 8, !tbaa !9
  %80 = getelementptr inbounds [10 x i8], ptr %16, i64 0, i64 0
  call void @readFile(ptr noundef %79, ptr noundef %80)
  %81 = load ptr, ptr @G, align 8, !tbaa !9
  %82 = getelementptr inbounds [10 x i8], ptr %15, i64 0, i64 0
  call void @readFile(ptr noundef %81, ptr noundef %82)
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #6
  %83 = load i32, ptr %9, align 4, !tbaa !5
  %84 = load i32, ptr %10, align 4, !tbaa !5
  %85 = load i32, ptr %7, align 4, !tbaa !5
  %86 = load ptr, ptr %11, align 8, !tbaa !9
  %87 = call ptr @readInput(i32 noundef %83, i32 noundef %84, i32 noundef %85, ptr noundef %86)
  store ptr %87, ptr %17, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #6
  %88 = load i32, ptr %6, align 4, !tbaa !5
  %89 = load i32, ptr %6, align 4, !tbaa !5
  %90 = load i32, ptr %7, align 4, !tbaa !5
  %91 = load i32, ptr %8, align 4, !tbaa !5
  %92 = load ptr, ptr %12, align 8, !tbaa !9
  %93 = call ptr @readKernels(i32 noundef %88, i32 noundef %89, i32 noundef %90, i32 noundef %91, ptr noundef %92)
  store ptr %93, ptr %18, align 8, !tbaa !9
  %94 = call i32 (ptr, ...) @printf(ptr noundef @.str)
  %95 = load ptr, ptr %17, align 8, !tbaa !9
  %96 = load i32, ptr %9, align 4, !tbaa !5
  %97 = load i32, ptr %7, align 4, !tbaa !5
  call void @printCube(ptr noundef %95, i32 noundef %96, i32 noundef %97)
  %98 = call i32 (ptr, ...) @printf(ptr noundef @.str.1)
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #6
  store i32 0, ptr %19, align 4, !tbaa !5
  br label %99

99:                                               ; preds = %114, %2
  %100 = load i32, ptr %19, align 4, !tbaa !5
  %101 = load i32, ptr %8, align 4, !tbaa !5
  %102 = icmp slt i32 %100, %101
  br i1 %102, label %104, label %103

103:                                              ; preds = %99
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #6
  br label %117

104:                                              ; preds = %99
  %105 = load i32, ptr %19, align 4, !tbaa !5
  %106 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, i32 noundef %105)
  %107 = load ptr, ptr %18, align 8, !tbaa !9
  %108 = load i32, ptr %19, align 4, !tbaa !5
  %109 = sext i32 %108 to i64
  %110 = getelementptr inbounds ptr, ptr %107, i64 %109
  %111 = load ptr, ptr %110, align 8, !tbaa !9
  %112 = load i32, ptr %6, align 4, !tbaa !5
  %113 = load i32, ptr %7, align 4, !tbaa !5
  call void @printCube(ptr noundef %111, i32 noundef %112, i32 noundef %113)
  br label %114

114:                                              ; preds = %104
  %115 = load i32, ptr %19, align 4, !tbaa !5
  %116 = add nsw i32 %115, 1
  store i32 %116, ptr %19, align 4, !tbaa !5
  br label %99, !llvm.loop !11

117:                                              ; preds = %103
  %118 = call i32 (ptr, ...) @printf(ptr noundef @.str.3)
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #6
  %119 = load i32, ptr %8, align 4, !tbaa !5
  %120 = sext i32 %119 to i64
  %121 = mul i64 %120, 8
  %122 = call noalias ptr @malloc(i64 noundef %121) #8
  store ptr %122, ptr %20, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #6
  %123 = call i64 @clock() #6
  store i64 %123, ptr %21, align 8, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #6
  store i32 0, ptr %22, align 4, !tbaa !5
  br label %124

124:                                              ; preds = %147, %117
  %125 = load i32, ptr %22, align 4, !tbaa !5
  %126 = load i32, ptr %8, align 4, !tbaa !5
  %127 = icmp slt i32 %125, %126
  br i1 %127, label %129, label %128

128:                                              ; preds = %124
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #6
  br label %150

129:                                              ; preds = %124
  %130 = load ptr, ptr %17, align 8, !tbaa !9
  %131 = load ptr, ptr %18, align 8, !tbaa !9
  %132 = load i32, ptr %22, align 4, !tbaa !5
  %133 = sext i32 %132 to i64
  %134 = getelementptr inbounds ptr, ptr %131, i64 %133
  %135 = load ptr, ptr %134, align 8, !tbaa !9
  %136 = load i32, ptr %5, align 4, !tbaa !5
  %137 = load i32, ptr %6, align 4, !tbaa !5
  %138 = load i32, ptr %7, align 4, !tbaa !5
  %139 = load i32, ptr %9, align 4, !tbaa !5
  %140 = load i32, ptr %10, align 4, !tbaa !5
  %141 = load i32, ptr %13, align 4, !tbaa !5
  %142 = call ptr @elaborateKernel(ptr noundef %130, ptr noundef %135, i32 noundef %136, i32 noundef %137, i32 noundef %138, i32 noundef %139, i32 noundef %140, i32 noundef %141)
  %143 = load ptr, ptr %20, align 8, !tbaa !9
  %144 = load i32, ptr %22, align 4, !tbaa !5
  %145 = sext i32 %144 to i64
  %146 = getelementptr inbounds ptr, ptr %143, i64 %145
  store ptr %142, ptr %146, align 8, !tbaa !9
  br label %147

147:                                              ; preds = %129
  %148 = load i32, ptr %22, align 4, !tbaa !5
  %149 = add nsw i32 %148, 1
  store i32 %149, ptr %22, align 4, !tbaa !5
  br label %124, !llvm.loop !15

150:                                              ; preds = %128
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #6
  %151 = call i64 @clock() #6
  store i64 %151, ptr %23, align 8, !tbaa !13
  %152 = call i32 (ptr, ...) @printf(ptr noundef @.str.4)
  %153 = load ptr, ptr %20, align 8, !tbaa !9
  %154 = load i32, ptr %5, align 4, !tbaa !5
  %155 = load i32, ptr %9, align 4, !tbaa !5
  %156 = load i32, ptr %13, align 4, !tbaa !5
  %157 = sdiv i32 %155, %156
  %158 = mul nsw i32 %154, %157
  %159 = load i32, ptr %8, align 4, !tbaa !5
  call void @printCube(ptr noundef %153, i32 noundef %158, i32 noundef %159)
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #6
  %160 = load i64, ptr %23, align 8, !tbaa !13
  %161 = load i64, ptr %21, align 8, !tbaa !13
  %162 = sub nsw i64 %160, %161
  %163 = sitofp i64 %162 to float
  %164 = fdiv float %163, 1.000000e+06
  store float %164, ptr %24, align 4, !tbaa !16
  %165 = load i32, ptr %5, align 4, !tbaa !5
  %166 = load i32, ptr %6, align 4, !tbaa !5
  %167 = load float, ptr %24, align 4, !tbaa !16
  %168 = fpext float %167 to double
  %169 = call i32 (ptr, ...) @printf(ptr noundef @.str.5, i32 noundef %165, i32 noundef %166, double noundef %168)
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 10, ptr %16) #6
  call void @llvm.lifetime.end.p0(i64 10, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 10, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #6
  ret void
}

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

; Function Attrs: inlinehint nounwind willreturn memory(read) uwtable
declare i32 @atoi(ptr noundef nonnull) #2

; Function Attrs: nounwind uwtable
declare dso_local void @generateNameAT(ptr noundef, i32 noundef, i32 noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local void @generateNameG(ptr noundef, i32 noundef, i32 noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local void @generateNameBT(ptr noundef, i32 noundef, i32 noundef) #0

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

; Function Attrs: nounwind uwtable
declare dso_local void @readFile(ptr noundef, ptr noundef) #0

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

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

declare i32 @printf(ptr noundef, ...) #3

; Function Attrs: nounwind uwtable
declare dso_local void @printCube(ptr noundef, i32 noundef, i32 noundef) #0

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

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #4

; Function Attrs: nounwind
declare i64 @clock() #5

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

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

!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 = !{!"int", !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 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !14, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = distinct !{!15, !12}
!16 = !{!17, !17, i64 0}
!17 = !{!"float", !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"

@A = external hidden local_unnamed_addr global ptr, align 8
@B = external hidden local_unnamed_addr global ptr, align 8
@G = external hidden local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [38 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @main(i32 noundef %0, ptr nocapture noundef readonly %1) local_unnamed_addr #0 {
  %3 = alloca [10 x i8], align 1
  %4 = alloca [10 x i8], align 1
  %5 = alloca [10 x i8], align 1
  %6 = getelementptr inbounds i8, ptr %1, i64 8
  %7 = load ptr, ptr %6, align 8, !tbaa !5
  %8 = tail call i32 @atoi(ptr nocapture noundef %7) #6
  %9 = getelementptr inbounds i8, ptr %1, i64 16
  %10 = load ptr, ptr %9, align 8, !tbaa !5
  %11 = tail call i32 @atoi(ptr nocapture noundef %10) #6
  %12 = getelementptr inbounds i8, ptr %1, i64 24
  %13 = load ptr, ptr %12, align 8, !tbaa !5
  %14 = tail call i32 @atoi(ptr nocapture noundef %13) #6
  %15 = getelementptr inbounds i8, ptr %1, i64 32
  %16 = load ptr, ptr %15, align 8, !tbaa !5
  %17 = tail call i32 @atoi(ptr nocapture noundef %16) #6
  %18 = getelementptr inbounds i8, ptr %1, i64 40
  %19 = load ptr, ptr %18, align 8, !tbaa !5
  %20 = tail call i32 @atoi(ptr nocapture noundef %19) #6
  %21 = getelementptr inbounds i8, ptr %1, i64 48
  %22 = load ptr, ptr %21, align 8, !tbaa !5
  %23 = tail call i32 @atoi(ptr nocapture noundef %22) #6
  %24 = getelementptr inbounds i8, ptr %1, i64 56
  %25 = load ptr, ptr %24, align 8, !tbaa !5
  %26 = getelementptr inbounds i8, ptr %1, i64 64
  %27 = load ptr, ptr %26, align 8, !tbaa !5
  %28 = add i32 %8, -1
  %29 = add i32 %28, %11
  call void @llvm.lifetime.start.p0(i64 10, ptr nonnull %3) #7
  call void @llvm.lifetime.start.p0(i64 10, ptr nonnull %4) #7
  call void @llvm.lifetime.start.p0(i64 10, ptr nonnull %5) #7
  call void @generateNameAT(ptr noundef nonnull %3, i32 noundef %8, i32 noundef %11)
  call void @generateNameG(ptr noundef nonnull %4, i32 noundef %8, i32 noundef %11)
  call void @generateNameBT(ptr noundef nonnull %5, i32 noundef %8, i32 noundef %11)
  %30 = call ptr @generateMatrix(i32 noundef %8, i32 noundef %29)
  store ptr %30, ptr @A, align 8, !tbaa !5
  %31 = call ptr @generateMatrix(i32 noundef %29, i32 noundef %29)
  store ptr %31, ptr @B, align 8, !tbaa !5
  %32 = call ptr @generateMatrix(i32 noundef %11, i32 noundef %29)
  store ptr %32, ptr @G, align 8, !tbaa !5
  %33 = load ptr, ptr @A, align 8, !tbaa !5
  call void @readFile(ptr noundef %33, ptr noundef nonnull %3)
  %34 = load ptr, ptr @B, align 8, !tbaa !5
  call void @readFile(ptr noundef %34, ptr noundef nonnull %5)
  %35 = load ptr, ptr @G, align 8, !tbaa !5
  call void @readFile(ptr noundef %35, ptr noundef nonnull %4)
  %36 = call ptr @readInput(i32 noundef %20, i32 noundef %23, i32 noundef %14, ptr noundef %25)
  %37 = call ptr @readKernels(i32 noundef %11, i32 noundef %11, i32 noundef %14, i32 noundef %17, ptr noundef %27)
  %38 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str)
  call void @printCube(ptr noundef %36, i32 noundef %20, i32 noundef %14)
  %39 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1)
  %40 = icmp sgt i32 %17, 0
  br i1 %40, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %2
  %wide.trip.count = zext nneg i32 %17 to i64
  br label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph, %2
  %41 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3)
  %42 = sext i32 %17 to i64
  %43 = shl nsw i64 %42, 3
  %44 = call noalias ptr @malloc(i64 noundef %43) #8
  %45 = call i64 @clock() #7
  br i1 %40, label %.lr.ph71.preheader, label %._crit_edge72

.lr.ph71.preheader:                               ; preds = %._crit_edge
  %wide.trip.count77 = zext nneg i32 %17 to i64
  br label %.lr.ph71

.lr.ph:                                           ; preds = %.lr.ph.preheader, %.lr.ph
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %.lr.ph ]
  %46 = trunc nuw nsw i64 %indvars.iv to i32
  %47 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, i32 noundef %46)
  %48 = getelementptr inbounds ptr, ptr %37, i64 %indvars.iv
  %49 = load ptr, ptr %48, align 8, !tbaa !5
  call void @printCube(ptr noundef %49, i32 noundef %11, i32 noundef %14)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !9

._crit_edge72:                                    ; preds = %.lr.ph71, %._crit_edge
  %50 = call i64 @clock() #7
  %51 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4)
  %52 = sdiv i32 %20, %29
  %53 = mul nsw i32 %52, %8
  call void @printCube(ptr noundef %44, i32 noundef %53, i32 noundef %17)
  %54 = sub nsw i64 %50, %45
  %55 = sitofp i64 %54 to float
  %56 = fdiv float %55, 1.000000e+06
  %57 = fpext float %56 to double
  %58 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5, i32 noundef %8, i32 noundef %11, double noundef %57)
  call void @llvm.lifetime.end.p0(i64 10, ptr nonnull %5) #7
  call void @llvm.lifetime.end.p0(i64 10, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 10, ptr nonnull %3) #7
  ret void

.lr.ph71:                                         ; preds = %.lr.ph71.preheader, %.lr.ph71
  %indvars.iv74 = phi i64 [ 0, %.lr.ph71.preheader ], [ %indvars.iv.next75, %.lr.ph71 ]
  %59 = getelementptr inbounds ptr, ptr %37, i64 %indvars.iv74
  %60 = load ptr, ptr %59, align 8, !tbaa !5
  %61 = call ptr @elaborateKernel(ptr noundef %36, ptr noundef %60, i32 noundef %8, i32 noundef %11, i32 noundef %14, i32 noundef %20, i32 noundef %23, i32 noundef %29)
  %62 = getelementptr inbounds ptr, ptr %44, i64 %indvars.iv74
  store ptr %61, ptr %62, align 8, !tbaa !5
  %indvars.iv.next75 = add nuw nsw i64 %indvars.iv74, 1
  %exitcond78.not = icmp eq i64 %indvars.iv.next75, %wide.trip.count77
  br i1 %exitcond78.not, label %._crit_edge72, label %.lr.ph71, !llvm.loop !11
}

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

; Function Attrs: inlinehint mustprogress nofree nounwind willreturn memory(read) uwtable
declare i32 @atoi(ptr nocapture noundef nonnull) local_unnamed_addr #2

; Function Attrs: nounwind uwtable
declare dso_local void @generateNameAT(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
declare dso_local void @generateNameG(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
declare dso_local void @generateNameBT(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #0

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

; Function Attrs: nounwind uwtable
declare dso_local void @readFile(ptr noundef, ptr noundef) local_unnamed_addr #0

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local void @printCube(ptr noundef, i32 noundef, i32 noundef) local_unnamed_addr #0

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

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

; Function Attrs: nounwind
declare i64 @clock() local_unnamed_addr #5

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { inlinehint mustprogress nofree nounwind willreturn memory(read) 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 = { 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 #4 = { mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) 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 #5 = { 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 #6 = { nounwind willreturn memory(read) }
attributes #7 = { nounwind }
attributes #8 = { nounwind allocsize(0) }

!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 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = distinct !{!11, !10}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass