; LLVM IR from jrl-umi3218/mc_rtc :: 3rd-party/qhull/src/libqhull_r (qset_r)

; 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.setT = type { i32, [1 x %union.setelemT] }
%union.setelemT = type { ptr }
%struct.qhT = type { i32, i32, i32, i32, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, i32, i32, ptr, i32, i32, ptr, i32, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, double, double, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, [29 x i32], i32, i32, i32, i32, i32, i32, i32, i32, double, double, double, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, double, i32, ptr, ptr, i32, i32, i32, i32, i32, ptr, i32, ptr, i32, [256 x i8], i32, [256 x i8], [512 x i8], i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, double, double, double, double, double, double, double, double, double, double, double, double, double, double, ptr, double, double, double, double, i32, [6 x i8], [1 x %struct.__jmp_buf_tag], [40 x i8], [1 x %struct.__jmp_buf_tag], [40 x i8], ptr, ptr, ptr, ptr, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, i32, ptr, i32, ptr, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i64, i32, i32, i32, i32, i32, ptr, ptr, i32, i32, i32, double, i32, double, double, double, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, ptr, ptr, i32, i32, i32, ptr, double, double, double, double, i32, i32, i32, i32, i32, i32, ptr, i32, i32, [1 x %struct.__jmp_buf_tag], [40 x i8], i32, double, ptr, ptr, ptr, %struct.qhmemT, %struct.qhstatT }
%struct.__jmp_buf_tag = type { [8 x i64], i32, %struct.__sigset_t }
%struct.__sigset_t = type { [16 x i64] }
%struct.qhmemT = type { i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 }
%struct.qhstatT = type { [249 x %union.intrealT], [259 x i8], [249 x ptr], [249 x i16], [249 x i8], [249 x i8], [9 x %union.intrealT], i32, i32, i32, i32, double }
%union.intrealT = type { double }

@.str = external hidden unnamed_addr constant [71 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @qh_setaddnth(ptr noundef %0, ptr noundef %1, i32 noundef %2, ptr noundef %3) #0 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store i32 %2, ptr %7, align 4, !tbaa !9
  store ptr %3, ptr %8, align 8, !tbaa !5
  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 8, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #3
  %14 = load ptr, ptr %6, align 8, !tbaa !5
  %15 = load ptr, ptr %14, align 8, !tbaa !5
  %16 = icmp ne ptr %15, null
  br i1 %16, label %17, label %29

17:                                               ; preds = %4
  %18 = load ptr, ptr %6, align 8, !tbaa !5
  %19 = load ptr, ptr %18, align 8, !tbaa !5
  %20 = getelementptr inbounds %struct.setT, ptr %19, i32 0, i32 1
  %21 = load ptr, ptr %6, align 8, !tbaa !5
  %22 = load ptr, ptr %21, align 8, !tbaa !5
  %23 = getelementptr inbounds %struct.setT, ptr %22, i32 0, i32 0
  %24 = load i32, ptr %23, align 8, !tbaa !11
  %25 = sext i32 %24 to i64
  %26 = getelementptr inbounds [1 x %union.setelemT], ptr %20, i64 0, i64 %25
  store ptr %26, ptr %11, align 8, !tbaa !5
  %27 = load i32, ptr %26, align 8, !tbaa !13
  %28 = icmp eq i32 %27, 0
  br i1 %28, label %29, label %41

29:                                               ; preds = %17, %4
  %30 = load ptr, ptr %5, align 8, !tbaa !5
  %31 = load ptr, ptr %6, align 8, !tbaa !5
  call void @qh_setlarger(ptr noundef %30, ptr noundef %31)
  %32 = load ptr, ptr %6, align 8, !tbaa !5
  %33 = load ptr, ptr %32, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.setT, ptr %33, i32 0, i32 1
  %35 = load ptr, ptr %6, align 8, !tbaa !5
  %36 = load ptr, ptr %35, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.setT, ptr %36, i32 0, i32 0
  %38 = load i32, ptr %37, align 8, !tbaa !11
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [1 x %union.setelemT], ptr %34, i64 0, i64 %39
  store ptr %40, ptr %11, align 8, !tbaa !5
  br label %41

41:                                               ; preds = %29, %17
  %42 = load ptr, ptr %11, align 8, !tbaa !5
  %43 = load i32, ptr %42, align 8, !tbaa !13
  %44 = sub nsw i32 %43, 1
  store i32 %44, ptr %9, align 4, !tbaa !9
  %45 = load i32, ptr %7, align 4, !tbaa !9
  %46 = icmp slt i32 %45, 0
  br i1 %46, label %51, label %47

47:                                               ; preds = %41
  %48 = load i32, ptr %7, align 4, !tbaa !9
  %49 = load i32, ptr %9, align 4, !tbaa !9
  %50 = icmp sgt i32 %48, %49
  br i1 %50, label %51, label %66

51:                                               ; preds = %47, %41
  %52 = load ptr, ptr %5, align 8, !tbaa !5
  %53 = load ptr, ptr %5, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.qhT, ptr %53, i32 0, i32 257
  %55 = getelementptr inbounds %struct.qhmemT, ptr %54, i32 0, i32 13
  %56 = load ptr, ptr %55, align 8, !tbaa !14
  %57 = load i32, ptr %7, align 4, !tbaa !9
  call void (ptr, ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %52, ptr noundef %56, i32 noundef 6171, ptr noundef @.str, i32 noundef %57)
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  %59 = load ptr, ptr %5, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.qhT, ptr %59, i32 0, i32 257
  %61 = getelementptr inbounds %struct.qhmemT, ptr %60, i32 0, i32 13
  %62 = load ptr, ptr %61, align 8, !tbaa !14
  %63 = load ptr, ptr %6, align 8, !tbaa !5
  %64 = load ptr, ptr %63, align 8, !tbaa !5
  call void @qh_setprint(ptr noundef %58, ptr noundef %62, ptr noundef @.str.1, ptr noundef %64)
  %65 = load ptr, ptr %5, align 8, !tbaa !5
  call void @qh_errexit(ptr noundef %65, i32 noundef 5, ptr noundef null, ptr noundef null)
  br label %66

66:                                               ; preds = %51, %47
  %67 = load ptr, ptr %11, align 8, !tbaa !5
  %68 = load i32, ptr %67, align 8, !tbaa !13
  %69 = add nsw i32 %68, 1
  store i32 %69, ptr %67, align 8, !tbaa !13
  %70 = load ptr, ptr %6, align 8, !tbaa !5
  %71 = load ptr, ptr %70, align 8, !tbaa !5
  %72 = getelementptr inbounds %struct.setT, ptr %71, i32 0, i32 1
  %73 = load i32, ptr %9, align 4, !tbaa !9
  %74 = sext i32 %73 to i64
  %75 = getelementptr inbounds [1 x %union.setelemT], ptr %72, i64 0, i64 %74
  store ptr %75, ptr %12, align 8, !tbaa !5
  %76 = load ptr, ptr %12, align 8, !tbaa !5
  %77 = getelementptr inbounds %union.setelemT, ptr %76, i64 1
  store ptr %77, ptr %13, align 8, !tbaa !5
  %78 = load i32, ptr %9, align 4, !tbaa !9
  %79 = load i32, ptr %7, align 4, !tbaa !9
  %80 = sub nsw i32 %78, %79
  %81 = add nsw i32 %80, 1
  store i32 %81, ptr %10, align 4, !tbaa !9
  br label %82

82:                                               ; preds = %86, %66
  %83 = load i32, ptr %10, align 4, !tbaa !9
  %84 = add nsw i32 %83, -1
  store i32 %84, ptr %10, align 4, !tbaa !9
  %85 = icmp ne i32 %83, 0
  br i1 %85, label %86, label %92

86:                                               ; preds = %82
  %87 = load ptr, ptr %12, align 8, !tbaa !5
  %88 = getelementptr inbounds %union.setelemT, ptr %87, i32 -1
  store ptr %88, ptr %12, align 8, !tbaa !5
  %89 = load ptr, ptr %87, align 8, !tbaa !13
  %90 = load ptr, ptr %13, align 8, !tbaa !5
  %91 = getelementptr inbounds %union.setelemT, ptr %90, i32 -1
  store ptr %91, ptr %13, align 8, !tbaa !5
  store ptr %89, ptr %90, align 8, !tbaa !13
  br label %82, !llvm.loop !20

92:                                               ; preds = %82
  %93 = load ptr, ptr %8, align 8, !tbaa !5
  %94 = load ptr, ptr %13, align 8, !tbaa !5
  store ptr %93, ptr %94, align 8, !tbaa !13
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 8, 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
  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: nounwind uwtable
declare dso_local void @qh_setlarger(ptr noundef, ptr noundef) #0

declare void @qh_fprintf(ptr noundef, ptr noundef, i32 noundef, ptr noundef, ...) #2

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

declare void @qh_errexit(ptr noundef, i32 noundef, ptr noundef, ptr noundef) #2

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

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 = { "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, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 0}
!12 = !{!"setT", !10, i64 0, !7, i64 8}
!13 = !{!7, !7, i64 0}
!14 = !{!15, !6, i64 3352}
!15 = !{!"qhT", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !16, i64 24, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !10, i64 48, !10, i64 52, !10, i64 56, !10, i64 60, !16, i64 64, !16, i64 72, !10, i64 80, !10, i64 84, !10, i64 88, !10, i64 92, !10, i64 96, !10, i64 100, !6, i64 104, !10, i64 112, !10, i64 116, !6, i64 120, !10, i64 128, !10, i64 132, !10, i64 136, !10, i64 140, !10, i64 144, !10, i64 148, !10, i64 152, !16, i64 160, !16, i64 168, !10, i64 176, !10, i64 180, !10, i64 184, !10, i64 188, !16, i64 192, !16, i64 200, !10, i64 208, !10, i64 212, !16, i64 216, !10, i64 224, !10, i64 228, !10, i64 232, !10, i64 236, !10, i64 240, !10, i64 244, !10, i64 248, !10, i64 252, !10, i64 256, !10, i64 260, !10, i64 264, !10, i64 268, !10, i64 272, !10, i64 276, !10, i64 280, !10, i64 284, !10, i64 288, !10, i64 292, !10, i64 296, !7, i64 300, !10, i64 416, !10, i64 420, !10, i64 424, !10, i64 428, !10, i64 432, !10, i64 436, !10, i64 440, !10, i64 444, !16, i64 448, !16, i64 456, !16, i64 464, !10, i64 472, !10, i64 476, !10, i64 480, !10, i64 484, !10, i64 488, !10, i64 492, !10, i64 496, !10, i64 500, !10, i64 504, !10, i64 508, !10, i64 512, !10, i64 516, !10, i64 520, !10, i64 524, !10, i64 528, !10, i64 532, !10, i64 536, !10, i64 540, !10, i64 544, !16, i64 552, !10, i64 560, !10, i64 564, !10, i64 568, !10, i64 572, !10, i64 576, !10, i64 580, !10, i64 584, !10, i64 588, !16, i64 592, !10, i64 600, !6, i64 608, !6, i64 616, !10, i64 624, !10, i64 628, !10, i64 632, !10, i64 636, !10, i64 640, !6, i64 648, !10, i64 656, !6, i64 664, !10, i64 672, !7, i64 676, !10, i64 932, !7, i64 936, !7, i64 1192, !10, i64 1704, !10, i64 1708, !10, i64 1712, !10, i64 1716, !10, i64 1720, !10, i64 1724, !6, i64 1728, !6, i64 1736, !6, i64 1744, !6, i64 1752, !16, i64 1760, !16, i64 1768, !16, i64 1776, !16, i64 1784, !16, i64 1792, !16, i64 1800, !16, i64 1808, !16, i64 1816, !16, i64 1824, !16, i64 1832, !16, i64 1840, !16, i64 1848, !16, i64 1856, !16, i64 1864, !6, i64 1872, !16, i64 1880, !16, i64 1888, !16, i64 1896, !16, i64 1904, !10, i64 1912, !7, i64 1916, !7, i64 1928, !7, i64 2128, !7, i64 2168, !7, i64 2368, !6, i64 2408, !6, i64 2416, !6, i64 2424, !6, i64 2432, !10, i64 2440, !10, i64 2444, !10, i64 2448, !6, i64 2456, !6, i64 2464, !6, i64 2472, !6, i64 2480, !6, i64 2488, !10, i64 2496, !10, i64 2500, !6, i64 2504, !10, i64 2512, !6, i64 2520, !10, i64 2528, !6, i64 2536, !6, i64 2544, !6, i64 2552, !6, i64 2560, !10, i64 2568, !10, i64 2572, !10, i64 2576, !10, i64 2580, !10, i64 2584, !10, i64 2588, !10, i64 2592, !10, i64 2596, !17, i64 2600, !10, i64 2608, !10, i64 2612, !10, i64 2616, !10, i64 2620, !10, i64 2624, !6, i64 2632, !6, i64 2640, !10, i64 2648, !10, i64 2652, !10, i64 2656, !16, i64 2664, !10, i64 2672, !16, i64 2680, !16, i64 2688, !16, i64 2696, !10, i64 2704, !10, i64 2708, !10, i64 2712, !10, i64 2716, !10, i64 2720, !16, i64 2728, !16, i64 2736, !10, i64 2744, !10, i64 2748, !10, i64 2752, !10, i64 2756, !10, i64 2760, !10, i64 2764, !16, i64 2768, !16, i64 2776, !10, i64 2784, !10, i64 2788, !10, i64 2792, !10, i64 2796, !6, i64 2800, !6, i64 2808, !6, i64 2816, !6, i64 2824, !6, i64 2832, !6, i64 2840, !6, i64 2848, !6, i64 2856, !6, i64 2864, !10, i64 2872, !6, i64 2880, !6, i64 2888, !10, i64 2896, !10, i64 2900, !10, i64 2904, !6, i64 2912, !16, i64 2920, !16, i64 2928, !16, i64 2936, !16, i64 2944, !10, i64 2952, !10, i64 2956, !10, i64 2960, !10, i64 2964, !10, i64 2968, !10, i64 2972, !6, i64 2976, !10, i64 2984, !10, i64 2988, !7, i64 2992, !7, i64 3192, !10, i64 3232, !16, i64 3240, !6, i64 3248, !6, i64 3256, !6, i64 3264, !18, i64 3272, !19, i64 3424}
!16 = !{!"double", !7, i64 0}
!17 = !{!"long", !7, i64 0}
!18 = !{!"qhmemT", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !10, i64 64, !6, i64 72, !6, i64 80, !10, i64 88, !10, i64 92, !10, i64 96, !10, i64 100, !10, i64 104, !10, i64 108, !10, i64 112, !10, i64 116, !10, i64 120, !10, i64 124, !10, i64 128, !10, i64 132, !10, i64 136, !10, i64 140, !10, i64 144}
!19 = !{!"qhstatT", !7, i64 0, !7, i64 1992, !7, i64 2256, !7, i64 4248, !7, i64 4746, !7, i64 4995, !7, i64 5248, !10, i64 5320, !10, i64 5324, !10, i64 5328, !10, i64 5332, !16, i64 5336}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}


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

%union.setelemT = type { ptr }

@.str = external hidden unnamed_addr constant [71 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [1 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @qh_setaddnth(ptr noundef %0, ptr noundef %1, i32 noundef %2, ptr noundef %3) local_unnamed_addr #0 {
  %5 = load ptr, ptr %1, align 8, !tbaa !5
  %.not = icmp eq ptr %5, null
  br i1 %.not, label %13, label %6

6:                                                ; preds = %4
  %7 = getelementptr inbounds i8, ptr %5, i64 8
  %8 = load i32, ptr %5, align 8, !tbaa !9
  %9 = sext i32 %8 to i64
  %10 = getelementptr inbounds [1 x %union.setelemT], ptr %7, i64 0, i64 %9
  %11 = load i32, ptr %10, align 8, !tbaa !12
  %12 = icmp eq i32 %11, 0
  br i1 %12, label %13, label %19

13:                                               ; preds = %6, %4
  tail call void @qh_setlarger(ptr noundef %0, ptr noundef nonnull %1)
  %14 = load ptr, ptr %1, align 8, !tbaa !5
  %15 = getelementptr inbounds i8, ptr %14, i64 8
  %16 = load i32, ptr %14, align 8, !tbaa !9
  %17 = sext i32 %16 to i64
  %18 = getelementptr inbounds [1 x %union.setelemT], ptr %15, i64 0, i64 %17
  %.pre = load i32, ptr %18, align 8, !tbaa !12
  br label %19

19:                                               ; preds = %13, %6
  %20 = phi i32 [ %.pre, %13 ], [ %11, %6 ]
  %.029 = phi ptr [ %18, %13 ], [ %10, %6 ]
  %21 = add nsw i32 %20, -1
  %22 = icmp sgt i32 %2, -1
  %.not33 = icmp sgt i32 %20, %2
  %or.cond = select i1 %22, i1 %.not33, i1 false
  br i1 %or.cond, label %28, label %23

23:                                               ; preds = %19
  %24 = getelementptr inbounds i8, ptr %0, i64 3352
  %25 = load ptr, ptr %24, align 8, !tbaa !13
  tail call void (ptr, ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %0, ptr noundef %25, i32 noundef 6171, ptr noundef nonnull @.str, i32 noundef %2) #2
  %26 = load ptr, ptr %24, align 8, !tbaa !13
  %27 = load ptr, ptr %1, align 8, !tbaa !5
  tail call void @qh_setprint(ptr noundef %0, ptr noundef %26, ptr noundef nonnull @.str.1, ptr noundef %27)
  tail call void @qh_errexit(ptr noundef %0, i32 noundef 5, ptr noundef null, ptr noundef null) #2
  %.pre40 = load i32, ptr %.029, align 8, !tbaa !12
  br label %28

28:                                               ; preds = %19, %23
  %29 = phi i32 [ %20, %19 ], [ %.pre40, %23 ]
  %30 = add nsw i32 %29, 1
  store i32 %30, ptr %.029, align 8, !tbaa !12
  %31 = load ptr, ptr %1, align 8, !tbaa !5
  %32 = getelementptr inbounds i8, ptr %31, i64 8
  %33 = sext i32 %21 to i64
  %34 = getelementptr inbounds [1 x %union.setelemT], ptr %32, i64 0, i64 %33
  %35 = getelementptr inbounds i8, ptr %34, i64 8
  %36 = sub i32 %20, %2
  %.not3435 = icmp eq i32 %36, 0
  br i1 %.not3435, label %._crit_edge, label %.lr.ph.preheader

.lr.ph.preheader:                                 ; preds = %28
  %37 = xor i32 %2, -1
  %38 = add i32 %20, %37
  %39 = zext i32 %38 to i64
  %40 = add nuw nsw i64 %39, 1
  %min.iters.check = icmp ult i32 %38, 3
  br i1 %min.iters.check, label %.lr.ph.preheader53, label %vector.ph

vector.ph:                                        ; preds = %.lr.ph.preheader
  %n.vec = and i64 %40, 8589934588
  %41 = mul nsw i64 %n.vec, -8
  %ind.end = getelementptr i8, ptr %35, i64 %41
  %42 = mul nsw i64 %n.vec, -8
  %ind.end41 = getelementptr i8, ptr %34, i64 %42
  %.cast = trunc i64 %n.vec to i32
  %ind.end43 = sub i32 %36, %.cast
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %offset.idx = mul i64 %index, -8
  %next.gep = getelementptr i8, ptr %35, i64 %offset.idx
  %offset.idx46 = mul i64 %index, -8
  %next.gep47 = getelementptr i8, ptr %34, i64 %offset.idx46
  %43 = getelementptr i8, ptr %next.gep47, i64 -8
  %44 = getelementptr i8, ptr %next.gep47, i64 -24
  %wide.load = load <2 x ptr>, ptr %43, align 8, !tbaa !12
  %wide.load49 = load <2 x ptr>, ptr %44, align 8, !tbaa !12
  %45 = getelementptr i8, ptr %next.gep, i64 -8
  %46 = getelementptr i8, ptr %next.gep, i64 -24
  store <2 x ptr> %wide.load, ptr %45, align 8, !tbaa !12
  store <2 x ptr> %wide.load49, ptr %46, align 8, !tbaa !12
  %index.next = add nuw i64 %index, 4
  %47 = icmp eq i64 %index.next, %n.vec
  br i1 %47, label %middle.block, label %vector.body, !llvm.loop !19

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %40, %n.vec
  br i1 %cmp.n, label %._crit_edge, label %.lr.ph.preheader53

.lr.ph.preheader53:                               ; preds = %middle.block, %.lr.ph.preheader
  %.038.ph = phi ptr [ %35, %.lr.ph.preheader ], [ %ind.end, %middle.block ]
  %.02837.ph = phi ptr [ %34, %.lr.ph.preheader ], [ %ind.end41, %middle.block ]
  %.03036.ph = phi i32 [ %36, %.lr.ph.preheader ], [ %ind.end43, %middle.block ]
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader53, %.lr.ph
  %.038 = phi ptr [ %51, %.lr.ph ], [ %.038.ph, %.lr.ph.preheader53 ]
  %.02837 = phi ptr [ %49, %.lr.ph ], [ %.02837.ph, %.lr.ph.preheader53 ]
  %.03036 = phi i32 [ %48, %.lr.ph ], [ %.03036.ph, %.lr.ph.preheader53 ]
  %48 = add nsw i32 %.03036, -1
  %49 = getelementptr inbounds i8, ptr %.02837, i64 -8
  %50 = load ptr, ptr %.02837, align 8, !tbaa !12
  %51 = getelementptr inbounds i8, ptr %.038, i64 -8
  store ptr %50, ptr %.038, align 8, !tbaa !12
  %.not34 = icmp eq i32 %48, 0
  br i1 %.not34, label %._crit_edge, label %.lr.ph, !llvm.loop !23

._crit_edge:                                      ; preds = %.lr.ph, %middle.block, %28
  %.0.lcssa = phi ptr [ %35, %28 ], [ %ind.end, %middle.block ], [ %51, %.lr.ph ]
  store ptr %3, ptr %.0.lcssa, align 8, !tbaa !12
  ret void
}

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

declare void @qh_fprintf(ptr noundef, ptr noundef, i32 noundef, ptr noundef, ...) local_unnamed_addr #1

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

declare void @qh_errexit(ptr noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

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 = { "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, !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 = !{!"setT", !11, i64 0, !7, i64 8}
!11 = !{!"int", !7, i64 0}
!12 = !{!7, !7, i64 0}
!13 = !{!14, !6, i64 3352}
!14 = !{!"qhT", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20, !15, i64 24, !11, i64 32, !11, i64 36, !11, i64 40, !11, i64 44, !11, i64 48, !11, i64 52, !11, i64 56, !11, i64 60, !15, i64 64, !15, i64 72, !11, i64 80, !11, i64 84, !11, i64 88, !11, i64 92, !11, i64 96, !11, i64 100, !6, i64 104, !11, i64 112, !11, i64 116, !6, i64 120, !11, i64 128, !11, i64 132, !11, i64 136, !11, i64 140, !11, i64 144, !11, i64 148, !11, i64 152, !15, i64 160, !15, i64 168, !11, i64 176, !11, i64 180, !11, i64 184, !11, i64 188, !15, i64 192, !15, i64 200, !11, i64 208, !11, i64 212, !15, i64 216, !11, i64 224, !11, i64 228, !11, i64 232, !11, i64 236, !11, i64 240, !11, i64 244, !11, i64 248, !11, i64 252, !11, i64 256, !11, i64 260, !11, i64 264, !11, i64 268, !11, i64 272, !11, i64 276, !11, i64 280, !11, i64 284, !11, i64 288, !11, i64 292, !11, i64 296, !7, i64 300, !11, i64 416, !11, i64 420, !11, i64 424, !11, i64 428, !11, i64 432, !11, i64 436, !11, i64 440, !11, i64 444, !15, i64 448, !15, i64 456, !15, i64 464, !11, i64 472, !11, i64 476, !11, i64 480, !11, i64 484, !11, i64 488, !11, i64 492, !11, i64 496, !11, i64 500, !11, i64 504, !11, i64 508, !11, i64 512, !11, i64 516, !11, i64 520, !11, i64 524, !11, i64 528, !11, i64 532, !11, i64 536, !11, i64 540, !11, i64 544, !15, i64 552, !11, i64 560, !11, i64 564, !11, i64 568, !11, i64 572, !11, i64 576, !11, i64 580, !11, i64 584, !11, i64 588, !15, i64 592, !11, i64 600, !6, i64 608, !6, i64 616, !11, i64 624, !11, i64 628, !11, i64 632, !11, i64 636, !11, i64 640, !6, i64 648, !11, i64 656, !6, i64 664, !11, i64 672, !7, i64 676, !11, i64 932, !7, i64 936, !7, i64 1192, !11, i64 1704, !11, i64 1708, !11, i64 1712, !11, i64 1716, !11, i64 1720, !11, i64 1724, !6, i64 1728, !6, i64 1736, !6, i64 1744, !6, i64 1752, !15, i64 1760, !15, i64 1768, !15, i64 1776, !15, i64 1784, !15, i64 1792, !15, i64 1800, !15, i64 1808, !15, i64 1816, !15, i64 1824, !15, i64 1832, !15, i64 1840, !15, i64 1848, !15, i64 1856, !15, i64 1864, !6, i64 1872, !15, i64 1880, !15, i64 1888, !15, i64 1896, !15, i64 1904, !11, i64 1912, !7, i64 1916, !7, i64 1928, !7, i64 2128, !7, i64 2168, !7, i64 2368, !6, i64 2408, !6, i64 2416, !6, i64 2424, !6, i64 2432, !11, i64 2440, !11, i64 2444, !11, i64 2448, !6, i64 2456, !6, i64 2464, !6, i64 2472, !6, i64 2480, !6, i64 2488, !11, i64 2496, !11, i64 2500, !6, i64 2504, !11, i64 2512, !6, i64 2520, !11, i64 2528, !6, i64 2536, !6, i64 2544, !6, i64 2552, !6, i64 2560, !11, i64 2568, !11, i64 2572, !11, i64 2576, !11, i64 2580, !11, i64 2584, !11, i64 2588, !11, i64 2592, !11, i64 2596, !16, i64 2600, !11, i64 2608, !11, i64 2612, !11, i64 2616, !11, i64 2620, !11, i64 2624, !6, i64 2632, !6, i64 2640, !11, i64 2648, !11, i64 2652, !11, i64 2656, !15, i64 2664, !11, i64 2672, !15, i64 2680, !15, i64 2688, !15, i64 2696, !11, i64 2704, !11, i64 2708, !11, i64 2712, !11, i64 2716, !11, i64 2720, !15, i64 2728, !15, i64 2736, !11, i64 2744, !11, i64 2748, !11, i64 2752, !11, i64 2756, !11, i64 2760, !11, i64 2764, !15, i64 2768, !15, i64 2776, !11, i64 2784, !11, i64 2788, !11, i64 2792, !11, i64 2796, !6, i64 2800, !6, i64 2808, !6, i64 2816, !6, i64 2824, !6, i64 2832, !6, i64 2840, !6, i64 2848, !6, i64 2856, !6, i64 2864, !11, i64 2872, !6, i64 2880, !6, i64 2888, !11, i64 2896, !11, i64 2900, !11, i64 2904, !6, i64 2912, !15, i64 2920, !15, i64 2928, !15, i64 2936, !15, i64 2944, !11, i64 2952, !11, i64 2956, !11, i64 2960, !11, i64 2964, !11, i64 2968, !11, i64 2972, !6, i64 2976, !11, i64 2984, !11, i64 2988, !7, i64 2992, !7, i64 3192, !11, i64 3232, !15, i64 3240, !6, i64 3248, !6, i64 3256, !6, i64 3264, !17, i64 3272, !18, i64 3424}
!15 = !{!"double", !7, i64 0}
!16 = !{!"long", !7, i64 0}
!17 = !{!"qhmemT", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !11, i64 64, !6, i64 72, !6, i64 80, !11, i64 88, !11, i64 92, !11, i64 96, !11, i64 100, !11, i64 104, !11, i64 108, !11, i64 112, !11, i64 116, !11, i64 120, !11, i64 124, !11, i64 128, !11, i64 132, !11, i64 136, !11, i64 140, !11, i64 144}
!18 = !{!"qhstatT", !7, i64 0, !7, i64 1992, !7, i64 2256, !7, i64 4248, !7, i64 4746, !7, i64 4995, !7, i64 5248, !11, i64 5320, !11, i64 5324, !11, i64 5328, !11, i64 5332, !15, i64 5336}
!19 = distinct !{!19, !20, !21, !22}
!20 = !{!"llvm.loop.mustprogress"}
!21 = !{!"llvm.loop.isvectorized", i32 1}
!22 = !{!"llvm.loop.unroll.runtime.disable"}
!23 = distinct !{!23, !20, !22, !21}


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