; LLVM IR from clangen/musikcube :: src/3rdparty/win32_src/pdcurses (initscr)

; 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.SCREEN = type { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i16, i16, i32, i32, i32, i32, i32, i32, i64, i32, i32, ptr, i32, i32, i32, i8, i32, i64, i8, i8, %struct.MOUSE_STATUS, i16, i64, ptr, ptr, i8, i8, i32, i32, ptr, i32, i32, ptr, i32, i32, ptr }
%struct.MOUSE_STATUS = type { i32, i32, [9 x i16], i32 }
%struct._opaque_screen_t = type { ptr, i32, i32, i8, ptr, i32, i32, i32, ptr, i32, i8, ptr, ptr }
%struct._win = type { i32, i32, i32, i32, i32, i32, i32, i64, i64, i8, i8, i8, i8, i8, i8, i8, ptr, ptr, ptr, i32, i32, i32, i32, i32, ptr, i32, i32, i32, i32, i32, i32 }

@SP = external dso_local global ptr, align 8
@curscr = external dso_local global ptr, align 8
@stdscr = external dso_local global ptr, align 8
@.str.1 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [93 x i8], align 1
@__PRETTY_FUNCTION__.delscreen = external hidden unnamed_addr constant [25 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [19 x i8], align 1

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, 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 @delscreen(ptr noundef %0) #2 {
  %2 = alloca ptr, align 8
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  store ptr %0, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #5
  store i32 0, ptr %3, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #5
  %6 = load ptr, ptr @SP, align 8, !tbaa !5
  %7 = icmp ne ptr %6, null
  br i1 %7, label %8, label %9

8:                                                ; preds = %1
  br label %10

9:                                                ; preds = %1
  call void @__assert_fail(ptr noundef @.str.1, ptr noundef @.str.2, i32 noundef 352, ptr noundef @__PRETTY_FUNCTION__.delscreen) #6
  unreachable

10:                                               ; preds = %8
  %11 = load ptr, ptr @SP, align 8, !tbaa !5
  %12 = icmp ne ptr %11, null
  br i1 %12, label %13, label %17

13:                                               ; preds = %10
  %14 = load ptr, ptr %2, align 8, !tbaa !5
  %15 = load ptr, ptr @SP, align 8, !tbaa !5
  %16 = icmp ne ptr %14, %15
  br i1 %16, label %17, label %18

17:                                               ; preds = %13, %10
  store i32 1, ptr %5, align 4
  br label %72

18:                                               ; preds = %13
  call void @traceoff()
  %19 = load ptr, ptr @SP, align 8, !tbaa !5
  %20 = getelementptr inbounds %struct.SCREEN, ptr %19, i32 0, i32 42
  %21 = load ptr, ptr %20, align 8, !tbaa !11
  call void @free(ptr noundef %21) #5
  %22 = load ptr, ptr @SP, align 8, !tbaa !5
  %23 = getelementptr inbounds %struct.SCREEN, ptr %22, i32 0, i32 39
  %24 = load ptr, ptr %23, align 8, !tbaa !17
  call void @free(ptr noundef %24) #5
  call void @PDC_slk_free()
  %25 = load ptr, ptr @SP, align 8, !tbaa !5
  %26 = getelementptr inbounds %struct.SCREEN, ptr %25, i32 0, i32 45
  %27 = load ptr, ptr %26, align 8, !tbaa !18
  store ptr %27, ptr %4, align 8, !tbaa !5
  store i32 0, ptr %3, align 4, !tbaa !9
  br label %28

28:                                               ; preds = %43, %18
  %29 = load i32, ptr %3, align 4, !tbaa !9
  %30 = load ptr, ptr %4, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct._opaque_screen_t, ptr %30, i32 0, i32 7
  %32 = load i32, ptr %31, align 8, !tbaa !19
  %33 = icmp slt i32 %29, %32
  br i1 %33, label %34, label %46

34:                                               ; preds = %28
  %35 = load ptr, ptr %4, align 8, !tbaa !5
  %36 = getelementptr inbounds %struct._opaque_screen_t, ptr %35, i32 0, i32 8
  %37 = load ptr, ptr %36, align 8, !tbaa !21
  %38 = load i32, ptr %3, align 4, !tbaa !9
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds ptr, ptr %37, i64 %39
  %41 = load ptr, ptr %40, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct._win, ptr %41, i32 0, i32 24
  store ptr null, ptr %42, align 8, !tbaa !22
  br label %43

43:                                               ; preds = %34
  %44 = load i32, ptr %3, align 4, !tbaa !9
  %45 = add nsw i32 %44, 1
  store i32 %45, ptr %3, align 4, !tbaa !9
  br label %28, !llvm.loop !24

46:                                               ; preds = %28
  br label %47

47:                                               ; preds = %52, %46
  %48 = load ptr, ptr %4, align 8, !tbaa !5
  %49 = getelementptr inbounds %struct._opaque_screen_t, ptr %48, i32 0, i32 7
  %50 = load i32, ptr %49, align 8, !tbaa !19
  %51 = icmp ne i32 %50, 0
  br i1 %51, label %52, label %59

52:                                               ; preds = %47
  %53 = load ptr, ptr %4, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct._opaque_screen_t, ptr %53, i32 0, i32 8
  %55 = load ptr, ptr %54, align 8, !tbaa !21
  %56 = getelementptr inbounds ptr, ptr %55, i64 0
  %57 = load ptr, ptr %56, align 8, !tbaa !5
  %58 = call i32 @delwin(ptr noundef %57)
  br label %47, !llvm.loop !26

59:                                               ; preds = %47
  %60 = load ptr, ptr %4, align 8, !tbaa !5
  %61 = getelementptr inbounds %struct._opaque_screen_t, ptr %60, i32 0, i32 8
  %62 = load ptr, ptr %61, align 8, !tbaa !21
  %63 = icmp ne ptr %62, null
  br i1 %63, label %65, label %64

64:                                               ; preds = %59
  br label %66

65:                                               ; preds = %59
  call void @__assert_fail(ptr noundef @.str.8, ptr noundef @.str.2, i32 noundef 371, ptr noundef @__PRETTY_FUNCTION__.delscreen) #6
  unreachable

66:                                               ; preds = %64
  call void @PDC_free_atrtab()
  store ptr null, ptr @stdscr, align 8, !tbaa !5
  store ptr null, ptr @curscr, align 8, !tbaa !5
  %67 = load ptr, ptr @SP, align 8, !tbaa !5
  %68 = getelementptr inbounds %struct.SCREEN, ptr %67, i32 0, i32 33
  store ptr null, ptr %68, align 8, !tbaa !27
  %69 = load ptr, ptr @SP, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.SCREEN, ptr %69, i32 0, i32 0
  store i8 0, ptr %70, align 8, !tbaa !28
  call void @PDC_scr_free()
  %71 = load ptr, ptr @SP, align 8, !tbaa !5
  call void @free(ptr noundef %71) #5
  store ptr null, ptr @SP, align 8, !tbaa !5
  store i32 0, ptr %5, align 4
  br label %72

72:                                               ; preds = %66, %17
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #5
  %73 = load i32, ptr %5, align 4
  switch i32 %73, label %75 [
    i32 0, label %74
    i32 1, label %74
  ]

74:                                               ; preds = %72, %72
  ret void

75:                                               ; preds = %72
  unreachable
}

declare void @traceoff() #3

; Function Attrs: nounwind
declare void @free(ptr noundef) #4

declare void @PDC_slk_free() #3

declare i32 @delwin(ptr noundef) #3

declare void @PDC_free_atrtab() #3

declare void @PDC_scr_free() #3

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !6, i64 192}
!12 = !{!"", !13, i64 0, !13, i64 1, !13, i64 2, !13, i64 3, !13, i64 4, !13, i64 5, !13, i64 6, !13, i64 7, !13, i64 8, !13, i64 9, !14, i64 10, !14, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28, !10, i64 32, !10, i64 36, !15, i64 40, !10, i64 48, !10, i64 52, !6, i64 56, !10, i64 64, !10, i64 68, !10, i64 72, !13, i64 76, !10, i64 80, !15, i64 88, !13, i64 96, !13, i64 97, !16, i64 100, !14, i64 132, !15, i64 136, !6, i64 144, !6, i64 152, !13, i64 160, !13, i64 161, !10, i64 164, !10, i64 168, !6, i64 176, !10, i64 184, !10, i64 188, !6, i64 192, !10, i64 200, !10, i64 204, !6, i64 208}
!13 = !{!"_Bool", !7, i64 0}
!14 = !{!"short", !7, i64 0}
!15 = !{!"long", !7, i64 0}
!16 = !{!"", !10, i64 0, !10, i64 4, !7, i64 8, !10, i64 28}
!17 = !{!12, !6, i64 176}
!18 = !{!12, !6, i64 208}
!19 = !{!20, !10, i64 40}
!20 = !{!"_opaque_screen_t", !6, i64 0, !10, i64 8, !10, i64 12, !13, i64 16, !6, i64 24, !10, i64 32, !10, i64 36, !10, i64 40, !6, i64 48, !10, i64 56, !13, i64 60, !6, i64 64, !6, i64 72}
!21 = !{!20, !6, i64 48}
!22 = !{!23, !6, i64 104}
!23 = !{!"_win", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !15, i64 32, !15, i64 40, !13, i64 48, !13, i64 49, !13, i64 50, !13, i64 51, !13, i64 52, !13, i64 53, !13, i64 54, !6, i64 56, !6, i64 64, !6, i64 72, !10, i64 80, !10, i64 84, !10, i64 88, !10, i64 92, !10, i64 96, !6, i64 104, !10, i64 112, !10, i64 116, !10, i64 120, !10, i64 124, !10, i64 128, !10, i64 132}
!24 = distinct !{!24, !25}
!25 = !{!"llvm.loop.mustprogress"}
!26 = distinct !{!26, !25}
!27 = !{!12, !6, i64 144}
!28 = !{!12, !13, 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"

@SP = external dso_local local_unnamed_addr global ptr, align 8
@curscr = external dso_local local_unnamed_addr global ptr, align 8
@stdscr = external dso_local local_unnamed_addr global ptr, align 8
@.str.1 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [93 x i8], align 1
@__PRETTY_FUNCTION__.delscreen = external hidden unnamed_addr constant [25 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [19 x i8], align 1

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #0

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

3:                                                ; preds = %1
  tail call void @__assert_fail(ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2, i32 noundef 352, ptr noundef nonnull @__PRETTY_FUNCTION__.delscreen) #4
  unreachable

4:                                                ; preds = %1
  %.not9 = icmp eq ptr %2, %0
  br i1 %.not9, label %5, label %61

5:                                                ; preds = %4
  tail call void @traceoff() #5
  %6 = load ptr, ptr @SP, align 8, !tbaa !5
  %7 = getelementptr inbounds i8, ptr %6, i64 192
  %8 = load ptr, ptr %7, align 8, !tbaa !9
  tail call void @free(ptr noundef %8) #5
  %9 = load ptr, ptr @SP, align 8, !tbaa !5
  %10 = getelementptr inbounds i8, ptr %9, i64 176
  %11 = load ptr, ptr %10, align 8, !tbaa !16
  tail call void @free(ptr noundef %11) #5
  tail call void @PDC_slk_free() #5
  %12 = load ptr, ptr @SP, align 8, !tbaa !5
  %13 = getelementptr inbounds i8, ptr %12, i64 208
  %14 = load ptr, ptr %13, align 8, !tbaa !17
  %15 = getelementptr inbounds i8, ptr %14, i64 40
  %16 = load i32, ptr %15, align 8, !tbaa !18
  %17 = icmp sgt i32 %16, 0
  br i1 %17, label %.lr.ph, label %.preheader

.lr.ph:                                           ; preds = %5
  %18 = getelementptr inbounds i8, ptr %14, i64 48
  %19 = load ptr, ptr %18, align 8, !tbaa !20
  %wide.trip.count = zext nneg i32 %16 to i64
  %xtraiter = and i64 %wide.trip.count, 7
  %20 = icmp ult i32 %16, 8
  br i1 %20, label %.preheader.loopexit.unr-lcssa, label %.lr.ph.new

.lr.ph.new:                                       ; preds = %.lr.ph
  %unroll_iter = and i64 %wide.trip.count, 2147483640
  br label %25

.preheader.loopexit.unr-lcssa:                    ; preds = %25, %.lr.ph
  %indvars.iv.unr = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next.7, %25 ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.preheader, label %.epil.preheader

.epil.preheader:                                  ; preds = %.preheader.loopexit.unr-lcssa, %.epil.preheader
  %indvars.iv.epil = phi i64 [ %indvars.iv.next.epil, %.epil.preheader ], [ %indvars.iv.unr, %.preheader.loopexit.unr-lcssa ]
  %epil.iter = phi i64 [ %epil.iter.next, %.epil.preheader ], [ 0, %.preheader.loopexit.unr-lcssa ]
  %21 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv.epil
  %22 = load ptr, ptr %21, align 8, !tbaa !5
  %23 = getelementptr inbounds i8, ptr %22, i64 104
  store ptr null, ptr %23, align 8, !tbaa !21
  %indvars.iv.next.epil = add nuw nsw i64 %indvars.iv.epil, 1
  %epil.iter.next = add i64 %epil.iter, 1
  %epil.iter.cmp.not = icmp eq i64 %epil.iter.next, %xtraiter
  br i1 %epil.iter.cmp.not, label %.preheader, label %.epil.preheader, !llvm.loop !23

.preheader:                                       ; preds = %.preheader.loopexit.unr-lcssa, %.epil.preheader, %5
  %.not1014 = icmp eq i32 %16, 0
  br i1 %.not1014, label %._crit_edge, label %.lr.ph15

.lr.ph15:                                         ; preds = %.preheader
  %24 = getelementptr inbounds i8, ptr %14, i64 48
  br label %50

25:                                               ; preds = %25, %.lr.ph.new
  %indvars.iv = phi i64 [ 0, %.lr.ph.new ], [ %indvars.iv.next.7, %25 ]
  %niter = phi i64 [ 0, %.lr.ph.new ], [ %niter.next.7, %25 ]
  %26 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv
  %27 = load ptr, ptr %26, align 8, !tbaa !5
  %28 = getelementptr inbounds i8, ptr %27, i64 104
  store ptr null, ptr %28, align 8, !tbaa !21
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %29 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv.next
  %30 = load ptr, ptr %29, align 8, !tbaa !5
  %31 = getelementptr inbounds i8, ptr %30, i64 104
  store ptr null, ptr %31, align 8, !tbaa !21
  %indvars.iv.next.1 = or disjoint i64 %indvars.iv, 2
  %32 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv.next.1
  %33 = load ptr, ptr %32, align 8, !tbaa !5
  %34 = getelementptr inbounds i8, ptr %33, i64 104
  store ptr null, ptr %34, align 8, !tbaa !21
  %indvars.iv.next.2 = or disjoint i64 %indvars.iv, 3
  %35 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv.next.2
  %36 = load ptr, ptr %35, align 8, !tbaa !5
  %37 = getelementptr inbounds i8, ptr %36, i64 104
  store ptr null, ptr %37, align 8, !tbaa !21
  %indvars.iv.next.3 = or disjoint i64 %indvars.iv, 4
  %38 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv.next.3
  %39 = load ptr, ptr %38, align 8, !tbaa !5
  %40 = getelementptr inbounds i8, ptr %39, i64 104
  store ptr null, ptr %40, align 8, !tbaa !21
  %indvars.iv.next.4 = or disjoint i64 %indvars.iv, 5
  %41 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv.next.4
  %42 = load ptr, ptr %41, align 8, !tbaa !5
  %43 = getelementptr inbounds i8, ptr %42, i64 104
  store ptr null, ptr %43, align 8, !tbaa !21
  %indvars.iv.next.5 = or disjoint i64 %indvars.iv, 6
  %44 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv.next.5
  %45 = load ptr, ptr %44, align 8, !tbaa !5
  %46 = getelementptr inbounds i8, ptr %45, i64 104
  store ptr null, ptr %46, align 8, !tbaa !21
  %indvars.iv.next.6 = or disjoint i64 %indvars.iv, 7
  %47 = getelementptr inbounds ptr, ptr %19, i64 %indvars.iv.next.6
  %48 = load ptr, ptr %47, align 8, !tbaa !5
  %49 = getelementptr inbounds i8, ptr %48, i64 104
  store ptr null, ptr %49, align 8, !tbaa !21
  %indvars.iv.next.7 = add nuw nsw i64 %indvars.iv, 8
  %niter.next.7 = add i64 %niter, 8
  %niter.ncmp.7 = icmp eq i64 %niter.next.7, %unroll_iter
  br i1 %niter.ncmp.7, label %.preheader.loopexit.unr-lcssa, label %25, !llvm.loop !25

50:                                               ; preds = %.lr.ph15, %50
  %51 = load ptr, ptr %24, align 8, !tbaa !20
  %52 = load ptr, ptr %51, align 8, !tbaa !5
  %53 = tail call i32 @delwin(ptr noundef %52) #5
  %.pr = load i32, ptr %15, align 8, !tbaa !18
  %.not10 = icmp eq i32 %.pr, 0
  br i1 %.not10, label %._crit_edge, label %50, !llvm.loop !27

._crit_edge:                                      ; preds = %50, %.preheader
  %54 = getelementptr inbounds i8, ptr %14, i64 48
  %55 = load ptr, ptr %54, align 8, !tbaa !20
  %.not11 = icmp eq ptr %55, null
  br i1 %.not11, label %57, label %56

56:                                               ; preds = %._crit_edge
  tail call void @__assert_fail(ptr noundef nonnull @.str.8, ptr noundef nonnull @.str.2, i32 noundef 371, ptr noundef nonnull @__PRETTY_FUNCTION__.delscreen) #4
  unreachable

57:                                               ; preds = %._crit_edge
  tail call void @PDC_free_atrtab() #5
  store ptr null, ptr @stdscr, align 8, !tbaa !5
  store ptr null, ptr @curscr, align 8, !tbaa !5
  %58 = load ptr, ptr @SP, align 8, !tbaa !5
  %59 = getelementptr inbounds i8, ptr %58, i64 144
  store ptr null, ptr %59, align 8, !tbaa !28
  store i8 0, ptr %58, align 8, !tbaa !29
  tail call void @PDC_scr_free() #5
  %60 = load ptr, ptr @SP, align 8, !tbaa !5
  tail call void @free(ptr noundef %60) #5
  store ptr null, ptr @SP, align 8, !tbaa !5
  br label %61

61:                                               ; preds = %4, %57
  ret void
}

declare void @traceoff() local_unnamed_addr #2

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) local_unnamed_addr #3

declare void @PDC_slk_free() local_unnamed_addr #2

declare i32 @delwin(ptr noundef) local_unnamed_addr #2

declare void @PDC_free_atrtab() local_unnamed_addr #2

declare void @PDC_scr_free() local_unnamed_addr #2

attributes #0 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = { "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 = { mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, 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 #4 = { noreturn nounwind }
attributes #5 = { 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, !6, i64 192}
!10 = !{!"", !11, i64 0, !11, i64 1, !11, i64 2, !11, i64 3, !11, i64 4, !11, i64 5, !11, i64 6, !11, i64 7, !11, i64 8, !11, i64 9, !12, i64 10, !12, i64 12, !13, i64 16, !13, i64 20, !13, i64 24, !13, i64 28, !13, i64 32, !13, i64 36, !14, i64 40, !13, i64 48, !13, i64 52, !6, i64 56, !13, i64 64, !13, i64 68, !13, i64 72, !11, i64 76, !13, i64 80, !14, i64 88, !11, i64 96, !11, i64 97, !15, i64 100, !12, i64 132, !14, i64 136, !6, i64 144, !6, i64 152, !11, i64 160, !11, i64 161, !13, i64 164, !13, i64 168, !6, i64 176, !13, i64 184, !13, i64 188, !6, i64 192, !13, i64 200, !13, i64 204, !6, i64 208}
!11 = !{!"_Bool", !7, i64 0}
!12 = !{!"short", !7, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!"", !13, i64 0, !13, i64 4, !7, i64 8, !13, i64 28}
!16 = !{!10, !6, i64 176}
!17 = !{!10, !6, i64 208}
!18 = !{!19, !13, i64 40}
!19 = !{!"_opaque_screen_t", !6, i64 0, !13, i64 8, !13, i64 12, !11, i64 16, !6, i64 24, !13, i64 32, !13, i64 36, !13, i64 40, !6, i64 48, !13, i64 56, !11, i64 60, !6, i64 64, !6, i64 72}
!20 = !{!19, !6, i64 48}
!21 = !{!22, !6, i64 104}
!22 = !{!"_win", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20, !13, i64 24, !14, i64 32, !14, i64 40, !11, i64 48, !11, i64 49, !11, i64 50, !11, i64 51, !11, i64 52, !11, i64 53, !11, i64 54, !6, i64 56, !6, i64 64, !6, i64 72, !13, i64 80, !13, i64 84, !13, i64 88, !13, i64 92, !13, i64 96, !6, i64 104, !13, i64 112, !13, i64 116, !13, i64 120, !13, i64 124, !13, i64 128, !13, i64 132}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.unroll.disable"}
!25 = distinct !{!25, !26}
!26 = !{!"llvm.loop.mustprogress"}
!27 = distinct !{!27, !26}
!28 = !{!10, !6, i64 144}
!29 = !{!10, !11, i64 0}


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