; LLVM IR from BrunoLevy/learn-fpga :: LiteX/software/Doom/mc1-doom/src (p_setup)

; 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.mapseg_t = type { i16, i16, i16, i16, i16, i16 }
%struct.vertex_t = type { i32, i32 }
%struct.seg_t = type { ptr, ptr, i32, i32, ptr, ptr, ptr, ptr }
%struct.line_s = type { ptr, ptr, i32, i32, i16, i16, i16, [2 x i16], [4 x i32], i32, ptr, ptr, i32, ptr }
%struct.side_t = type { i32, i32, i16, i16, i16, ptr }

@vertexes = external dso_local global ptr, align 8
@numsegs = external dso_local global i32, align 4
@segs = external dso_local global ptr, align 8
@lines = external dso_local global ptr, align 8
@sides = external dso_local global ptr, align 8

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

declare i32 @W_LumpLength(i32 noundef) #1

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

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

declare void @Z_Free(ptr 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 @P_LoadSegs(i32 noundef %0) #2 {
  %2 = alloca i32, align 4
  %3 = alloca ptr, align 8
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  store i32 %0, ptr %2, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #4
  %10 = load i32, ptr %2, align 4, !tbaa !5
  %11 = call i32 @W_LumpLength(i32 noundef %10)
  %12 = sext i32 %11 to i64
  %13 = udiv i64 %12, 12
  %14 = trunc i64 %13 to i32
  store i32 %14, ptr @numsegs, align 4, !tbaa !5
  %15 = load i32, ptr @numsegs, align 4, !tbaa !5
  %16 = sext i32 %15 to i64
  %17 = mul i64 %16, 56
  %18 = trunc i64 %17 to i32
  %19 = call ptr @Z_Malloc(i32 noundef %18, i32 noundef 50, ptr noundef null)
  store ptr %19, ptr @segs, align 8, !tbaa !9
  %20 = load ptr, ptr @segs, align 8, !tbaa !9
  %21 = load i32, ptr @numsegs, align 4, !tbaa !5
  %22 = sext i32 %21 to i64
  %23 = mul i64 %22, 56
  call void @llvm.memset.p0.i64(ptr align 8 %20, i8 0, i64 %23, i1 false)
  %24 = load i32, ptr %2, align 4, !tbaa !5
  %25 = call ptr @W_CacheLumpNum(i32 noundef %24, i32 noundef 1)
  store ptr %25, ptr %3, align 8, !tbaa !9
  %26 = load ptr, ptr %3, align 8, !tbaa !9
  store ptr %26, ptr %5, align 8, !tbaa !9
  %27 = load ptr, ptr @segs, align 8, !tbaa !9
  store ptr %27, ptr %6, align 8, !tbaa !9
  store i32 0, ptr %4, align 4, !tbaa !5
  br label %28

28:                                               ; preds = %127, %1
  %29 = load i32, ptr %4, align 4, !tbaa !5
  %30 = load i32, ptr @numsegs, align 4, !tbaa !5
  %31 = icmp slt i32 %29, %30
  br i1 %31, label %32, label %134

32:                                               ; preds = %28
  %33 = load ptr, ptr @vertexes, align 8, !tbaa !9
  %34 = load ptr, ptr %5, align 8, !tbaa !9
  %35 = getelementptr inbounds %struct.mapseg_t, ptr %34, i32 0, i32 0
  %36 = load i16, ptr %35, align 2, !tbaa !11
  %37 = sext i16 %36 to i64
  %38 = getelementptr inbounds %struct.vertex_t, ptr %33, i64 %37
  %39 = load ptr, ptr %6, align 8, !tbaa !9
  %40 = getelementptr inbounds %struct.seg_t, ptr %39, i32 0, i32 0
  store ptr %38, ptr %40, align 8, !tbaa !14
  %41 = load ptr, ptr @vertexes, align 8, !tbaa !9
  %42 = load ptr, ptr %5, align 8, !tbaa !9
  %43 = getelementptr inbounds %struct.mapseg_t, ptr %42, i32 0, i32 1
  %44 = load i16, ptr %43, align 2, !tbaa !16
  %45 = sext i16 %44 to i64
  %46 = getelementptr inbounds %struct.vertex_t, ptr %41, i64 %45
  %47 = load ptr, ptr %6, align 8, !tbaa !9
  %48 = getelementptr inbounds %struct.seg_t, ptr %47, i32 0, i32 1
  store ptr %46, ptr %48, align 8, !tbaa !17
  %49 = load ptr, ptr %5, align 8, !tbaa !9
  %50 = getelementptr inbounds %struct.mapseg_t, ptr %49, i32 0, i32 2
  %51 = load i16, ptr %50, align 2, !tbaa !18
  %52 = sext i16 %51 to i32
  %53 = shl i32 %52, 16
  %54 = load ptr, ptr %6, align 8, !tbaa !9
  %55 = getelementptr inbounds %struct.seg_t, ptr %54, i32 0, i32 3
  store i32 %53, ptr %55, align 4, !tbaa !19
  %56 = load ptr, ptr %5, align 8, !tbaa !9
  %57 = getelementptr inbounds %struct.mapseg_t, ptr %56, i32 0, i32 5
  %58 = load i16, ptr %57, align 2, !tbaa !20
  %59 = sext i16 %58 to i32
  %60 = shl i32 %59, 16
  %61 = load ptr, ptr %6, align 8, !tbaa !9
  %62 = getelementptr inbounds %struct.seg_t, ptr %61, i32 0, i32 2
  store i32 %60, ptr %62, align 8, !tbaa !21
  %63 = load ptr, ptr %5, align 8, !tbaa !9
  %64 = getelementptr inbounds %struct.mapseg_t, ptr %63, i32 0, i32 3
  %65 = load i16, ptr %64, align 2, !tbaa !22
  %66 = sext i16 %65 to i32
  store i32 %66, ptr %8, align 4, !tbaa !5
  %67 = load ptr, ptr @lines, align 8, !tbaa !9
  %68 = load i32, ptr %8, align 4, !tbaa !5
  %69 = sext i32 %68 to i64
  %70 = getelementptr inbounds %struct.line_s, ptr %67, i64 %69
  store ptr %70, ptr %7, align 8, !tbaa !9
  %71 = load ptr, ptr %7, align 8, !tbaa !9
  %72 = load ptr, ptr %6, align 8, !tbaa !9
  %73 = getelementptr inbounds %struct.seg_t, ptr %72, i32 0, i32 5
  store ptr %71, ptr %73, align 8, !tbaa !23
  %74 = load ptr, ptr %5, align 8, !tbaa !9
  %75 = getelementptr inbounds %struct.mapseg_t, ptr %74, i32 0, i32 4
  %76 = load i16, ptr %75, align 2, !tbaa !24
  %77 = sext i16 %76 to i32
  store i32 %77, ptr %9, align 4, !tbaa !5
  %78 = load ptr, ptr @sides, align 8, !tbaa !9
  %79 = load ptr, ptr %7, align 8, !tbaa !9
  %80 = getelementptr inbounds %struct.line_s, ptr %79, i32 0, i32 7
  %81 = load i32, ptr %9, align 4, !tbaa !5
  %82 = sext i32 %81 to i64
  %83 = getelementptr inbounds [2 x i16], ptr %80, i64 0, i64 %82
  %84 = load i16, ptr %83, align 2, !tbaa !25
  %85 = sext i16 %84 to i64
  %86 = getelementptr inbounds %struct.side_t, ptr %78, i64 %85
  %87 = load ptr, ptr %6, align 8, !tbaa !9
  %88 = getelementptr inbounds %struct.seg_t, ptr %87, i32 0, i32 4
  store ptr %86, ptr %88, align 8, !tbaa !26
  %89 = load ptr, ptr @sides, align 8, !tbaa !9
  %90 = load ptr, ptr %7, align 8, !tbaa !9
  %91 = getelementptr inbounds %struct.line_s, ptr %90, i32 0, i32 7
  %92 = load i32, ptr %9, align 4, !tbaa !5
  %93 = sext i32 %92 to i64
  %94 = getelementptr inbounds [2 x i16], ptr %91, i64 0, i64 %93
  %95 = load i16, ptr %94, align 2, !tbaa !25
  %96 = sext i16 %95 to i64
  %97 = getelementptr inbounds %struct.side_t, ptr %89, i64 %96
  %98 = getelementptr inbounds %struct.side_t, ptr %97, i32 0, i32 5
  %99 = load ptr, ptr %98, align 8, !tbaa !27
  %100 = load ptr, ptr %6, align 8, !tbaa !9
  %101 = getelementptr inbounds %struct.seg_t, ptr %100, i32 0, i32 6
  store ptr %99, ptr %101, align 8, !tbaa !29
  %102 = load ptr, ptr %7, align 8, !tbaa !9
  %103 = getelementptr inbounds %struct.line_s, ptr %102, i32 0, i32 4
  %104 = load i16, ptr %103, align 8, !tbaa !30
  %105 = sext i16 %104 to i32
  %106 = and i32 %105, 4
  %107 = icmp ne i32 %106, 0
  br i1 %107, label %108, label %123

108:                                              ; preds = %32
  %109 = load ptr, ptr @sides, align 8, !tbaa !9
  %110 = load ptr, ptr %7, align 8, !tbaa !9
  %111 = getelementptr inbounds %struct.line_s, ptr %110, i32 0, i32 7
  %112 = load i32, ptr %9, align 4, !tbaa !5
  %113 = xor i32 %112, 1
  %114 = sext i32 %113 to i64
  %115 = getelementptr inbounds [2 x i16], ptr %111, i64 0, i64 %114
  %116 = load i16, ptr %115, align 2, !tbaa !25
  %117 = sext i16 %116 to i64
  %118 = getelementptr inbounds %struct.side_t, ptr %109, i64 %117
  %119 = getelementptr inbounds %struct.side_t, ptr %118, i32 0, i32 5
  %120 = load ptr, ptr %119, align 8, !tbaa !27
  %121 = load ptr, ptr %6, align 8, !tbaa !9
  %122 = getelementptr inbounds %struct.seg_t, ptr %121, i32 0, i32 7
  store ptr %120, ptr %122, align 8, !tbaa !32
  br label %126

123:                                              ; preds = %32
  %124 = load ptr, ptr %6, align 8, !tbaa !9
  %125 = getelementptr inbounds %struct.seg_t, ptr %124, i32 0, i32 7
  store ptr null, ptr %125, align 8, !tbaa !32
  br label %126

126:                                              ; preds = %123, %108
  br label %127

127:                                              ; preds = %126
  %128 = load i32, ptr %4, align 4, !tbaa !5
  %129 = add nsw i32 %128, 1
  store i32 %129, ptr %4, align 4, !tbaa !5
  %130 = load ptr, ptr %6, align 8, !tbaa !9
  %131 = getelementptr inbounds %struct.seg_t, ptr %130, i32 1
  store ptr %131, ptr %6, align 8, !tbaa !9
  %132 = load ptr, ptr %5, align 8, !tbaa !9
  %133 = getelementptr inbounds %struct.mapseg_t, ptr %132, i32 1
  store ptr %133, ptr %5, align 8, !tbaa !9
  br label %28, !llvm.loop !33

134:                                              ; preds = %28
  %135 = load ptr, ptr %3, align 8, !tbaa !9
  call void @Z_Free(ptr noundef %135)
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #4
  ret void
}

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #3

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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #4 = { 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 = !{!"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 = !{!12, !13, i64 0}
!12 = !{!"", !13, i64 0, !13, i64 2, !13, i64 4, !13, i64 6, !13, i64 8, !13, i64 10}
!13 = !{!"short", !7, i64 0}
!14 = !{!15, !10, i64 0}
!15 = !{!"", !10, i64 0, !10, i64 8, !6, i64 16, !6, i64 20, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48}
!16 = !{!12, !13, i64 2}
!17 = !{!15, !10, i64 8}
!18 = !{!12, !13, i64 4}
!19 = !{!15, !6, i64 20}
!20 = !{!12, !13, i64 10}
!21 = !{!15, !6, i64 16}
!22 = !{!12, !13, i64 6}
!23 = !{!15, !10, i64 32}
!24 = !{!12, !13, i64 8}
!25 = !{!13, !13, i64 0}
!26 = !{!15, !10, i64 24}
!27 = !{!28, !10, i64 16}
!28 = !{!"", !6, i64 0, !6, i64 4, !13, i64 8, !13, i64 10, !13, i64 12, !10, i64 16}
!29 = !{!15, !10, i64 40}
!30 = !{!31, !13, i64 24}
!31 = !{!"line_s", !10, i64 0, !10, i64 8, !6, i64 16, !6, i64 20, !13, i64 24, !13, i64 26, !13, i64 28, !7, i64 30, !7, i64 36, !6, i64 52, !10, i64 56, !10, i64 64, !6, i64 72, !10, i64 80}
!32 = !{!15, !10, i64 48}
!33 = distinct !{!33, !34}
!34 = !{!"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"

%struct.vertex_t = type { i32, i32 }
%struct.line_s = type { ptr, ptr, i32, i32, i16, i16, i16, [2 x i16], [4 x i32], i32, ptr, ptr, i32, ptr }
%struct.side_t = type { i32, i32, i16, i16, i16, ptr }

@vertexes = external dso_local local_unnamed_addr global ptr, align 8
@numsegs = external dso_local local_unnamed_addr global i32, align 4
@segs = external dso_local local_unnamed_addr global ptr, align 8
@lines = external dso_local local_unnamed_addr global ptr, align 8
@sides = external dso_local local_unnamed_addr global ptr, align 8

declare i32 @W_LumpLength(i32 noundef) local_unnamed_addr #0

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

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

declare void @Z_Free(ptr noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local void @P_LoadSegs(i32 noundef %0) local_unnamed_addr #1 {
  %2 = tail call i32 @W_LumpLength(i32 noundef %0) #3
  %3 = sext i32 %2 to i64
  %4 = udiv i64 %3, 12
  %5 = trunc i64 %4 to i32
  store i32 %5, ptr @numsegs, align 4, !tbaa !5
  %6 = mul i32 %5, 56
  %7 = tail call ptr @Z_Malloc(i32 noundef %6, i32 noundef 50, ptr noundef null) #3
  store ptr %7, ptr @segs, align 8, !tbaa !9
  %8 = load i32, ptr @numsegs, align 4, !tbaa !5
  %9 = sext i32 %8 to i64
  %10 = mul nsw i64 %9, 56
  tail call void @llvm.memset.p0.i64(ptr align 8 %7, i8 0, i64 %10, i1 false)
  %11 = tail call ptr @W_CacheLumpNum(i32 noundef %0, i32 noundef 1) #3
  %12 = load i32, ptr @numsegs, align 4, !tbaa !5
  %13 = icmp sgt i32 %12, 0
  br i1 %13, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %1
  %14 = load ptr, ptr @segs, align 8, !tbaa !9
  %.pre = load ptr, ptr @vertexes, align 8, !tbaa !9
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader, %65
  %15 = phi ptr [ %19, %65 ], [ %.pre, %.lr.ph.preheader ]
  %.035 = phi i32 [ %67, %65 ], [ 0, %.lr.ph.preheader ]
  %.03134 = phi ptr [ %69, %65 ], [ %11, %.lr.ph.preheader ]
  %.03233 = phi ptr [ %68, %65 ], [ %14, %.lr.ph.preheader ]
  %16 = load i16, ptr %.03134, align 2, !tbaa !11
  %17 = sext i16 %16 to i64
  %18 = getelementptr inbounds %struct.vertex_t, ptr %15, i64 %17
  store ptr %18, ptr %.03233, align 8, !tbaa !14
  %19 = load ptr, ptr @vertexes, align 8, !tbaa !9
  %20 = getelementptr inbounds i8, ptr %.03134, i64 2
  %21 = load i16, ptr %20, align 2, !tbaa !16
  %22 = sext i16 %21 to i64
  %23 = getelementptr inbounds %struct.vertex_t, ptr %19, i64 %22
  %24 = getelementptr inbounds i8, ptr %.03233, i64 8
  store ptr %23, ptr %24, align 8, !tbaa !17
  %25 = getelementptr inbounds i8, ptr %.03134, i64 4
  %26 = load i16, ptr %25, align 2, !tbaa !18
  %27 = sext i16 %26 to i32
  %28 = shl nsw i32 %27, 16
  %29 = getelementptr inbounds i8, ptr %.03233, i64 20
  store i32 %28, ptr %29, align 4, !tbaa !19
  %30 = getelementptr inbounds i8, ptr %.03134, i64 10
  %31 = load i16, ptr %30, align 2, !tbaa !20
  %32 = sext i16 %31 to i32
  %33 = shl nsw i32 %32, 16
  %34 = getelementptr inbounds i8, ptr %.03233, i64 16
  store i32 %33, ptr %34, align 8, !tbaa !21
  %35 = getelementptr inbounds i8, ptr %.03134, i64 6
  %36 = load i16, ptr %35, align 2, !tbaa !22
  %37 = load ptr, ptr @lines, align 8, !tbaa !9
  %38 = sext i16 %36 to i64
  %39 = getelementptr inbounds %struct.line_s, ptr %37, i64 %38
  %40 = getelementptr inbounds i8, ptr %.03233, i64 32
  store ptr %39, ptr %40, align 8, !tbaa !23
  %41 = getelementptr inbounds i8, ptr %.03134, i64 8
  %42 = load i16, ptr %41, align 2, !tbaa !24
  %43 = load ptr, ptr @sides, align 8, !tbaa !9
  %44 = getelementptr inbounds i8, ptr %39, i64 30
  %45 = sext i16 %42 to i64
  %46 = getelementptr inbounds [2 x i16], ptr %44, i64 0, i64 %45
  %47 = load i16, ptr %46, align 2, !tbaa !25
  %48 = sext i16 %47 to i64
  %49 = getelementptr inbounds %struct.side_t, ptr %43, i64 %48
  %50 = getelementptr inbounds i8, ptr %.03233, i64 24
  store ptr %49, ptr %50, align 8, !tbaa !26
  %51 = getelementptr inbounds %struct.side_t, ptr %43, i64 %48, i32 5
  %52 = load ptr, ptr %51, align 8, !tbaa !27
  %53 = getelementptr inbounds i8, ptr %.03233, i64 40
  store ptr %52, ptr %53, align 8, !tbaa !29
  %54 = getelementptr inbounds i8, ptr %39, i64 24
  %55 = load i16, ptr %54, align 8, !tbaa !30
  %56 = and i16 %55, 4
  %.not = icmp eq i16 %56, 0
  br i1 %.not, label %65, label %57

57:                                               ; preds = %.lr.ph
  %58 = xor i16 %42, 1
  %59 = sext i16 %58 to i64
  %60 = getelementptr inbounds [2 x i16], ptr %44, i64 0, i64 %59
  %61 = load i16, ptr %60, align 2, !tbaa !25
  %62 = sext i16 %61 to i64
  %63 = getelementptr inbounds %struct.side_t, ptr %43, i64 %62, i32 5
  %64 = load ptr, ptr %63, align 8, !tbaa !27
  br label %65

65:                                               ; preds = %.lr.ph, %57
  %.sink = phi ptr [ %64, %57 ], [ null, %.lr.ph ]
  %66 = getelementptr inbounds i8, ptr %.03233, i64 48
  store ptr %.sink, ptr %66, align 8
  %67 = add nuw nsw i32 %.035, 1
  %68 = getelementptr inbounds i8, ptr %.03233, i64 56
  %69 = getelementptr inbounds i8, ptr %.03134, i64 12
  %exitcond.not = icmp eq i32 %67, %12
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !32

._crit_edge:                                      ; preds = %65, %1
  tail call void @Z_Free(ptr noundef %11) #3
  ret void
}

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

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 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
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 = !{!"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 = !{!12, !13, i64 0}
!12 = !{!"", !13, i64 0, !13, i64 2, !13, i64 4, !13, i64 6, !13, i64 8, !13, i64 10}
!13 = !{!"short", !7, i64 0}
!14 = !{!15, !10, i64 0}
!15 = !{!"", !10, i64 0, !10, i64 8, !6, i64 16, !6, i64 20, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48}
!16 = !{!12, !13, i64 2}
!17 = !{!15, !10, i64 8}
!18 = !{!12, !13, i64 4}
!19 = !{!15, !6, i64 20}
!20 = !{!12, !13, i64 10}
!21 = !{!15, !6, i64 16}
!22 = !{!12, !13, i64 6}
!23 = !{!15, !10, i64 32}
!24 = !{!12, !13, i64 8}
!25 = !{!13, !13, i64 0}
!26 = !{!15, !10, i64 24}
!27 = !{!28, !10, i64 16}
!28 = !{!"", !6, i64 0, !6, i64 4, !13, i64 8, !13, i64 10, !13, i64 12, !10, i64 16}
!29 = !{!15, !10, i64 40}
!30 = !{!31, !13, i64 24}
!31 = !{!"line_s", !10, i64 0, !10, i64 8, !6, i64 16, !6, i64 20, !13, i64 24, !13, i64 26, !13, i64 28, !7, i64 30, !7, i64 36, !6, i64 52, !10, i64 56, !10, i64 64, !6, i64 72, !10, i64 80}
!32 = distinct !{!32, !33}
!33 = !{!"llvm.loop.mustprogress"}


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