; LLVM IR from siconos/siconos :: externals/lbl/metis4/match.ll_ (Match_HEM)

; 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.controldef = type { i32, i32, i32, i32, i32, i32, float, i32, i32, i32, i32, %struct.workspacedef, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double }
%struct.workspacedef = type { ptr, i32, i32, ptr, ptr, i32, ptr, ptr }
%struct.graphdef = type { ptr, ptr, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, ptr, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, ptr, ptr, ptr, ptr }

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

declare double @__seconds() #1

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

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

declare void @__RandomPermute(i32 noundef, ptr noundef, i32 noundef) #1

declare void @__CreateCoarseGraph(ptr noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef) #1

declare void @__idxwspacefree(ptr noundef, i32 noundef) #1

; 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 void @__Match_HEM(ptr noundef %0, ptr noundef %1) #2 {
  %3 = alloca ptr, align 8
  %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 i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca ptr, align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #3
  %20 = load ptr, ptr %3, align 8, !tbaa !5
  %21 = getelementptr inbounds %struct.controldef, ptr %20, i32 0, i32 1
  %22 = load i32, ptr %21, align 4, !tbaa !9
  %23 = and i32 %22, 1
  %24 = icmp ne i32 %23, 0
  br i1 %24, label %25, label %31

25:                                               ; preds = %2
  %26 = call double @__seconds()
  %27 = load ptr, ptr %3, align 8, !tbaa !5
  %28 = getelementptr inbounds %struct.controldef, ptr %27, i32 0, i32 14
  %29 = load double, ptr %28, align 8, !tbaa !15
  %30 = fsub double %29, %26
  store double %30, ptr %28, align 8, !tbaa !15
  br label %31

31:                                               ; preds = %25, %2
  %32 = load ptr, ptr %4, align 8, !tbaa !5
  %33 = getelementptr inbounds %struct.graphdef, ptr %32, i32 0, i32 2
  %34 = load i32, ptr %33, align 8, !tbaa !16
  store i32 %34, ptr %9, align 4, !tbaa !18
  %35 = load ptr, ptr %4, align 8, !tbaa !5
  %36 = getelementptr inbounds %struct.graphdef, ptr %35, i32 0, i32 4
  %37 = load ptr, ptr %36, align 8, !tbaa !19
  store ptr %37, ptr %13, align 8, !tbaa !5
  %38 = load ptr, ptr %4, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.graphdef, ptr %38, i32 0, i32 5
  %40 = load ptr, ptr %39, align 8, !tbaa !20
  store ptr %40, ptr %14, align 8, !tbaa !5
  %41 = load ptr, ptr %4, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.graphdef, ptr %41, i32 0, i32 7
  %43 = load ptr, ptr %42, align 8, !tbaa !21
  store ptr %43, ptr %15, align 8, !tbaa !5
  %44 = load ptr, ptr %4, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.graphdef, ptr %44, i32 0, i32 8
  %46 = load ptr, ptr %45, align 8, !tbaa !22
  store ptr %46, ptr %16, align 8, !tbaa !5
  %47 = load ptr, ptr %4, align 8, !tbaa !5
  %48 = getelementptr inbounds %struct.graphdef, ptr %47, i32 0, i32 11
  %49 = load ptr, ptr %48, align 8, !tbaa !23
  store ptr %49, ptr %18, align 8, !tbaa !5
  %50 = load i32, ptr %9, align 4, !tbaa !18
  %51 = load ptr, ptr %3, align 8, !tbaa !5
  %52 = load i32, ptr %9, align 4, !tbaa !18
  %53 = call ptr @__idxwspacemalloc(ptr noundef %51, i32 noundef %52)
  %54 = call ptr @__idxset(i32 noundef %50, i32 noundef -1, ptr noundef %53)
  store ptr %54, ptr %17, align 8, !tbaa !5
  %55 = load ptr, ptr %3, align 8, !tbaa !5
  %56 = load i32, ptr %9, align 4, !tbaa !18
  %57 = call ptr @__idxwspacemalloc(ptr noundef %55, i32 noundef %56)
  store ptr %57, ptr %19, align 8, !tbaa !5
  %58 = load i32, ptr %9, align 4, !tbaa !18
  %59 = load ptr, ptr %19, align 8, !tbaa !5
  call void @__RandomPermute(i32 noundef %58, ptr noundef %59, i32 noundef 1)
  store i32 0, ptr %10, align 4, !tbaa !18
  store i32 0, ptr %6, align 4, !tbaa !18
  br label %60

60:                                               ; preds = %165, %31
  %61 = load i32, ptr %6, align 4, !tbaa !18
  %62 = load i32, ptr %9, align 4, !tbaa !18
  %63 = icmp slt i32 %61, %62
  br i1 %63, label %64, label %168

64:                                               ; preds = %60
  %65 = load ptr, ptr %19, align 8, !tbaa !5
  %66 = load i32, ptr %6, align 4, !tbaa !18
  %67 = sext i32 %66 to i64
  %68 = getelementptr inbounds i32, ptr %65, i64 %67
  %69 = load i32, ptr %68, align 4, !tbaa !18
  store i32 %69, ptr %5, align 4, !tbaa !18
  %70 = load ptr, ptr %17, align 8, !tbaa !5
  %71 = load i32, ptr %5, align 4, !tbaa !18
  %72 = sext i32 %71 to i64
  %73 = getelementptr inbounds i32, ptr %70, i64 %72
  %74 = load i32, ptr %73, align 4, !tbaa !18
  %75 = icmp eq i32 %74, -1
  br i1 %75, label %76, label %164

76:                                               ; preds = %64
  %77 = load i32, ptr %5, align 4, !tbaa !18
  store i32 %77, ptr %11, align 4, !tbaa !18
  store i32 0, ptr %12, align 4, !tbaa !18
  %78 = load ptr, ptr %13, align 8, !tbaa !5
  %79 = load i32, ptr %5, align 4, !tbaa !18
  %80 = sext i32 %79 to i64
  %81 = getelementptr inbounds i32, ptr %78, i64 %80
  %82 = load i32, ptr %81, align 4, !tbaa !18
  store i32 %82, ptr %7, align 4, !tbaa !18
  br label %83

83:                                               ; preds = %140, %76
  %84 = load i32, ptr %7, align 4, !tbaa !18
  %85 = load ptr, ptr %13, align 8, !tbaa !5
  %86 = load i32, ptr %5, align 4, !tbaa !18
  %87 = add nsw i32 %86, 1
  %88 = sext i32 %87 to i64
  %89 = getelementptr inbounds i32, ptr %85, i64 %88
  %90 = load i32, ptr %89, align 4, !tbaa !18
  %91 = icmp slt i32 %84, %90
  br i1 %91, label %92, label %143

92:                                               ; preds = %83
  %93 = load ptr, ptr %15, align 8, !tbaa !5
  %94 = load i32, ptr %7, align 4, !tbaa !18
  %95 = sext i32 %94 to i64
  %96 = getelementptr inbounds i32, ptr %93, i64 %95
  %97 = load i32, ptr %96, align 4, !tbaa !18
  store i32 %97, ptr %8, align 4, !tbaa !18
  %98 = load ptr, ptr %17, align 8, !tbaa !5
  %99 = load i32, ptr %8, align 4, !tbaa !18
  %100 = sext i32 %99 to i64
  %101 = getelementptr inbounds i32, ptr %98, i64 %100
  %102 = load i32, ptr %101, align 4, !tbaa !18
  %103 = icmp eq i32 %102, -1
  br i1 %103, label %104, label %139

104:                                              ; preds = %92
  %105 = load i32, ptr %12, align 4, !tbaa !18
  %106 = load ptr, ptr %16, align 8, !tbaa !5
  %107 = load i32, ptr %7, align 4, !tbaa !18
  %108 = sext i32 %107 to i64
  %109 = getelementptr inbounds i32, ptr %106, i64 %108
  %110 = load i32, ptr %109, align 4, !tbaa !18
  %111 = icmp slt i32 %105, %110
  br i1 %111, label %112, label %139

112:                                              ; preds = %104
  %113 = load ptr, ptr %14, align 8, !tbaa !5
  %114 = load i32, ptr %5, align 4, !tbaa !18
  %115 = sext i32 %114 to i64
  %116 = getelementptr inbounds i32, ptr %113, i64 %115
  %117 = load i32, ptr %116, align 4, !tbaa !18
  %118 = load ptr, ptr %14, align 8, !tbaa !5
  %119 = load i32, ptr %8, align 4, !tbaa !18
  %120 = sext i32 %119 to i64
  %121 = getelementptr inbounds i32, ptr %118, i64 %120
  %122 = load i32, ptr %121, align 4, !tbaa !18
  %123 = add nsw i32 %117, %122
  %124 = load ptr, ptr %3, align 8, !tbaa !5
  %125 = getelementptr inbounds %struct.controldef, ptr %124, i32 0, i32 5
  %126 = load i32, ptr %125, align 4, !tbaa !24
  %127 = icmp sle i32 %123, %126
  br i1 %127, label %128, label %139

128:                                              ; preds = %112
  %129 = load ptr, ptr %16, align 8, !tbaa !5
  %130 = load i32, ptr %7, align 4, !tbaa !18
  %131 = sext i32 %130 to i64
  %132 = getelementptr inbounds i32, ptr %129, i64 %131
  %133 = load i32, ptr %132, align 4, !tbaa !18
  store i32 %133, ptr %12, align 4, !tbaa !18
  %134 = load ptr, ptr %15, align 8, !tbaa !5
  %135 = load i32, ptr %7, align 4, !tbaa !18
  %136 = sext i32 %135 to i64
  %137 = getelementptr inbounds i32, ptr %134, i64 %136
  %138 = load i32, ptr %137, align 4, !tbaa !18
  store i32 %138, ptr %11, align 4, !tbaa !18
  br label %139

139:                                              ; preds = %128, %112, %104, %92
  br label %140

140:                                              ; preds = %139
  %141 = load i32, ptr %7, align 4, !tbaa !18
  %142 = add nsw i32 %141, 1
  store i32 %142, ptr %7, align 4, !tbaa !18
  br label %83, !llvm.loop !25

143:                                              ; preds = %83
  %144 = load i32, ptr %10, align 4, !tbaa !18
  %145 = add nsw i32 %144, 1
  store i32 %145, ptr %10, align 4, !tbaa !18
  %146 = load ptr, ptr %18, align 8, !tbaa !5
  %147 = load i32, ptr %11, align 4, !tbaa !18
  %148 = sext i32 %147 to i64
  %149 = getelementptr inbounds i32, ptr %146, i64 %148
  store i32 %144, ptr %149, align 4, !tbaa !18
  %150 = load ptr, ptr %18, align 8, !tbaa !5
  %151 = load i32, ptr %5, align 4, !tbaa !18
  %152 = sext i32 %151 to i64
  %153 = getelementptr inbounds i32, ptr %150, i64 %152
  store i32 %144, ptr %153, align 4, !tbaa !18
  %154 = load i32, ptr %11, align 4, !tbaa !18
  %155 = load ptr, ptr %17, align 8, !tbaa !5
  %156 = load i32, ptr %5, align 4, !tbaa !18
  %157 = sext i32 %156 to i64
  %158 = getelementptr inbounds i32, ptr %155, i64 %157
  store i32 %154, ptr %158, align 4, !tbaa !18
  %159 = load i32, ptr %5, align 4, !tbaa !18
  %160 = load ptr, ptr %17, align 8, !tbaa !5
  %161 = load i32, ptr %11, align 4, !tbaa !18
  %162 = sext i32 %161 to i64
  %163 = getelementptr inbounds i32, ptr %160, i64 %162
  store i32 %159, ptr %163, align 4, !tbaa !18
  br label %164

164:                                              ; preds = %143, %64
  br label %165

165:                                              ; preds = %164
  %166 = load i32, ptr %6, align 4, !tbaa !18
  %167 = add nsw i32 %166, 1
  store i32 %167, ptr %6, align 4, !tbaa !18
  br label %60, !llvm.loop !27

168:                                              ; preds = %60
  %169 = load ptr, ptr %3, align 8, !tbaa !5
  %170 = getelementptr inbounds %struct.controldef, ptr %169, i32 0, i32 1
  %171 = load i32, ptr %170, align 4, !tbaa !9
  %172 = and i32 %171, 1
  %173 = icmp ne i32 %172, 0
  br i1 %173, label %174, label %180

174:                                              ; preds = %168
  %175 = call double @__seconds()
  %176 = load ptr, ptr %3, align 8, !tbaa !5
  %177 = getelementptr inbounds %struct.controldef, ptr %176, i32 0, i32 14
  %178 = load double, ptr %177, align 8, !tbaa !15
  %179 = fadd double %178, %175
  store double %179, ptr %177, align 8, !tbaa !15
  br label %180

180:                                              ; preds = %174, %168
  %181 = load ptr, ptr %3, align 8, !tbaa !5
  %182 = load ptr, ptr %4, align 8, !tbaa !5
  %183 = load i32, ptr %10, align 4, !tbaa !18
  %184 = load ptr, ptr %17, align 8, !tbaa !5
  %185 = load ptr, ptr %19, align 8, !tbaa !5
  call void @__CreateCoarseGraph(ptr noundef %181, ptr noundef %182, i32 noundef %183, ptr noundef %184, ptr noundef %185)
  %186 = load ptr, ptr %3, align 8, !tbaa !5
  %187 = load i32, ptr %9, align 4, !tbaa !18
  call void @__idxwspacefree(ptr noundef %186, i32 noundef %187)
  %188 = load ptr, ptr %3, align 8, !tbaa !5
  %189 = load i32, ptr %9, align 4, !tbaa !18
  call void @__idxwspacefree(ptr noundef %188, i32 noundef %189)
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #3
  ret void
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !11, i64 4}
!10 = !{!"controldef", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20, !12, i64 24, !11, i64 28, !11, i64 32, !11, i64 36, !11, i64 40, !13, i64 48, !14, i64 104, !14, i64 112, !14, i64 120, !14, i64 128, !14, i64 136, !14, i64 144, !14, i64 152, !14, i64 160, !14, i64 168, !14, i64 176, !14, i64 184, !14, i64 192, !14, i64 200, !14, i64 208, !14, i64 216, !14, i64 224}
!11 = !{!"int", !7, i64 0}
!12 = !{!"float", !7, i64 0}
!13 = !{!"workspacedef", !6, i64 0, !11, i64 8, !11, i64 12, !6, i64 16, !6, i64 24, !11, i64 32, !6, i64 40, !6, i64 48}
!14 = !{!"double", !7, i64 0}
!15 = !{!10, !14, i64 120}
!16 = !{!17, !11, i64 16}
!17 = !{!"graphdef", !6, i64 0, !6, i64 8, !11, i64 16, !11, i64 20, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !11, i64 88, !11, i64 92, !6, i64 96, !6, i64 104, !11, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !11, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208}
!18 = !{!11, !11, i64 0}
!19 = !{!17, !6, i64 24}
!20 = !{!17, !6, i64 32}
!21 = !{!17, !6, i64 48}
!22 = !{!17, !6, i64 56}
!23 = !{!17, !6, i64 80}
!24 = !{!10, !11, i64 20}
!25 = distinct !{!25, !26}
!26 = !{!"llvm.loop.mustprogress"}
!27 = distinct !{!27, !26}


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

declare double @__seconds() local_unnamed_addr #0

declare ptr @__idxset(i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #0

declare ptr @__idxwspacemalloc(ptr noundef, i32 noundef) local_unnamed_addr #0

declare void @__RandomPermute(i32 noundef, ptr noundef, i32 noundef) local_unnamed_addr #0

declare void @__CreateCoarseGraph(ptr noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

declare void @__idxwspacefree(ptr noundef, i32 noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local void @__Match_HEM(ptr noundef %0, ptr noundef %1) local_unnamed_addr #1 {
  %3 = getelementptr inbounds i8, ptr %0, i64 4
  %4 = load i32, ptr %3, align 4, !tbaa !5
  %5 = and i32 %4, 1
  %.not = icmp eq i32 %5, 0
  br i1 %.not, label %11, label %6

6:                                                ; preds = %2
  %7 = tail call double @__seconds() #2
  %8 = getelementptr inbounds i8, ptr %0, i64 120
  %9 = load double, ptr %8, align 8, !tbaa !14
  %10 = fsub double %9, %7
  store double %10, ptr %8, align 8, !tbaa !14
  br label %11

11:                                               ; preds = %6, %2
  %12 = getelementptr inbounds i8, ptr %1, i64 16
  %13 = load i32, ptr %12, align 8, !tbaa !15
  %14 = getelementptr inbounds i8, ptr %1, i64 24
  %15 = load ptr, ptr %14, align 8, !tbaa !17
  %16 = getelementptr inbounds i8, ptr %1, i64 32
  %17 = load ptr, ptr %16, align 8, !tbaa !18
  %18 = getelementptr inbounds i8, ptr %1, i64 48
  %19 = load ptr, ptr %18, align 8, !tbaa !19
  %20 = getelementptr inbounds i8, ptr %1, i64 56
  %21 = load ptr, ptr %20, align 8, !tbaa !20
  %22 = getelementptr inbounds i8, ptr %1, i64 80
  %23 = load ptr, ptr %22, align 8, !tbaa !21
  %24 = tail call ptr @__idxwspacemalloc(ptr noundef nonnull %0, i32 noundef %13) #2
  %25 = tail call ptr @__idxset(i32 noundef %13, i32 noundef -1, ptr noundef %24) #2
  %26 = tail call ptr @__idxwspacemalloc(ptr noundef nonnull %0, i32 noundef %13) #2
  tail call void @__RandomPermute(i32 noundef %13, ptr noundef %26, i32 noundef 1) #2
  %27 = icmp sgt i32 %13, 0
  br i1 %27, label %.lr.ph83, label %._crit_edge84

.lr.ph83:                                         ; preds = %11
  %28 = getelementptr inbounds i8, ptr %0, i64 20
  %wide.trip.count90 = zext nneg i32 %13 to i64
  br label %29

29:                                               ; preds = %.lr.ph83, %66
  %indvars.iv87 = phi i64 [ 0, %.lr.ph83 ], [ %indvars.iv.next88, %66 ]
  %.06780 = phi i32 [ 0, %.lr.ph83 ], [ %.1, %66 ]
  %30 = getelementptr inbounds i32, ptr %26, i64 %indvars.iv87
  %31 = load i32, ptr %30, align 4, !tbaa !22
  %32 = sext i32 %31 to i64
  %33 = getelementptr inbounds i32, ptr %25, i64 %32
  %34 = load i32, ptr %33, align 4, !tbaa !22
  %35 = icmp eq i32 %34, -1
  br i1 %35, label %36, label %66

36:                                               ; preds = %29
  %37 = getelementptr inbounds i32, ptr %15, i64 %32
  %38 = load i32, ptr %37, align 4, !tbaa !22
  %39 = getelementptr i8, ptr %37, i64 4
  %40 = load i32, ptr %39, align 4, !tbaa !22
  %41 = icmp slt i32 %38, %40
  br i1 %41, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %36
  %42 = getelementptr inbounds i32, ptr %17, i64 %32
  %43 = sext i32 %38 to i64
  %wide.trip.count = sext i32 %40 to i64
  br label %44

44:                                               ; preds = %.lr.ph, %61
  %indvars.iv = phi i64 [ %43, %.lr.ph ], [ %indvars.iv.next, %61 ]
  %.06878 = phi i32 [ %31, %.lr.ph ], [ %.169, %61 ]
  %.07077 = phi i32 [ 0, %.lr.ph ], [ %.171, %61 ]
  %45 = getelementptr inbounds i32, ptr %19, i64 %indvars.iv
  %46 = load i32, ptr %45, align 4, !tbaa !22
  %47 = sext i32 %46 to i64
  %48 = getelementptr inbounds i32, ptr %25, i64 %47
  %49 = load i32, ptr %48, align 4, !tbaa !22
  %50 = icmp eq i32 %49, -1
  br i1 %50, label %51, label %61

51:                                               ; preds = %44
  %52 = getelementptr inbounds i32, ptr %21, i64 %indvars.iv
  %53 = load i32, ptr %52, align 4, !tbaa !22
  %54 = icmp slt i32 %.07077, %53
  br i1 %54, label %55, label %61

55:                                               ; preds = %51
  %56 = load i32, ptr %42, align 4, !tbaa !22
  %57 = getelementptr inbounds i32, ptr %17, i64 %47
  %58 = load i32, ptr %57, align 4, !tbaa !22
  %59 = add nsw i32 %58, %56
  %60 = load i32, ptr %28, align 4, !tbaa !23
  %.not75 = icmp sgt i32 %59, %60
  %spec.select = select i1 %.not75, i32 %.07077, i32 %53
  %spec.select76 = select i1 %.not75, i32 %.06878, i32 %46
  br label %61

61:                                               ; preds = %55, %44, %51
  %.171 = phi i32 [ %.07077, %51 ], [ %.07077, %44 ], [ %spec.select, %55 ]
  %.169 = phi i32 [ %.06878, %51 ], [ %.06878, %44 ], [ %spec.select76, %55 ]
  %indvars.iv.next = add nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge.loopexit, label %44, !llvm.loop !24

._crit_edge.loopexit:                             ; preds = %61
  %.pre = sext i32 %.169 to i64
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit, %36
  %.pre-phi = phi i64 [ %.pre, %._crit_edge.loopexit ], [ %32, %36 ]
  %.068.lcssa = phi i32 [ %.169, %._crit_edge.loopexit ], [ %31, %36 ]
  %62 = add nsw i32 %.06780, 1
  %63 = getelementptr inbounds i32, ptr %23, i64 %.pre-phi
  store i32 %.06780, ptr %63, align 4, !tbaa !22
  %64 = getelementptr inbounds i32, ptr %23, i64 %32
  store i32 %.06780, ptr %64, align 4, !tbaa !22
  store i32 %.068.lcssa, ptr %33, align 4, !tbaa !22
  %65 = getelementptr inbounds i32, ptr %25, i64 %.pre-phi
  store i32 %31, ptr %65, align 4, !tbaa !22
  br label %66

66:                                               ; preds = %29, %._crit_edge
  %.1 = phi i32 [ %62, %._crit_edge ], [ %.06780, %29 ]
  %indvars.iv.next88 = add nuw nsw i64 %indvars.iv87, 1
  %exitcond91.not = icmp eq i64 %indvars.iv.next88, %wide.trip.count90
  br i1 %exitcond91.not, label %._crit_edge84, label %29, !llvm.loop !26

._crit_edge84:                                    ; preds = %66, %11
  %.067.lcssa = phi i32 [ 0, %11 ], [ %.1, %66 ]
  %67 = load i32, ptr %3, align 4, !tbaa !5
  %68 = and i32 %67, 1
  %.not74 = icmp eq i32 %68, 0
  br i1 %.not74, label %74, label %69

69:                                               ; preds = %._crit_edge84
  %70 = tail call double @__seconds() #2
  %71 = getelementptr inbounds i8, ptr %0, i64 120
  %72 = load double, ptr %71, align 8, !tbaa !14
  %73 = fadd double %70, %72
  store double %73, ptr %71, align 8, !tbaa !14
  br label %74

74:                                               ; preds = %69, %._crit_edge84
  tail call void @__CreateCoarseGraph(ptr noundef nonnull %0, ptr noundef %1, i32 noundef %.067.lcssa, ptr noundef %25, ptr noundef %26) #2
  tail call void @__idxwspacefree(ptr noundef nonnull %0, i32 noundef %13) #2
  tail call void @__idxwspacefree(ptr noundef nonnull %0, i32 noundef %13) #2
  ret void
}

attributes #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 = { 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 #2 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !7, i64 4}
!6 = !{!"controldef", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !10, i64 24, !7, i64 28, !7, i64 32, !7, i64 36, !7, i64 40, !11, i64 48, !13, i64 104, !13, i64 112, !13, i64 120, !13, i64 128, !13, i64 136, !13, i64 144, !13, i64 152, !13, i64 160, !13, i64 168, !13, i64 176, !13, i64 184, !13, i64 192, !13, i64 200, !13, i64 208, !13, i64 216, !13, i64 224}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"float", !8, i64 0}
!11 = !{!"workspacedef", !12, i64 0, !7, i64 8, !7, i64 12, !12, i64 16, !12, i64 24, !7, i64 32, !12, i64 40, !12, i64 48}
!12 = !{!"any pointer", !8, i64 0}
!13 = !{!"double", !8, i64 0}
!14 = !{!6, !13, i64 120}
!15 = !{!16, !7, i64 16}
!16 = !{!"graphdef", !12, i64 0, !12, i64 8, !7, i64 16, !7, i64 20, !12, i64 24, !12, i64 32, !12, i64 40, !12, i64 48, !12, i64 56, !12, i64 64, !12, i64 72, !12, i64 80, !7, i64 88, !7, i64 92, !12, i64 96, !12, i64 104, !7, i64 112, !12, i64 120, !12, i64 128, !12, i64 136, !12, i64 144, !12, i64 152, !12, i64 160, !12, i64 168, !7, i64 176, !12, i64 184, !12, i64 192, !12, i64 200, !12, i64 208}
!17 = !{!16, !12, i64 24}
!18 = !{!16, !12, i64 32}
!19 = !{!16, !12, i64 48}
!20 = !{!16, !12, i64 56}
!21 = !{!16, !12, i64 80}
!22 = !{!7, !7, i64 0}
!23 = !{!6, !7, i64 20}
!24 = distinct !{!24, !25}
!25 = !{!"llvm.loop.mustprogress"}
!26 = distinct !{!26, !25}


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