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

; 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.player_s = type { ptr, i32, %struct.ticcmd_t, i32, i32, i32, i32, i32, i32, i32, [6 x i32], [6 x i32], i32, [4 x i32], i32, i32, [9 x i32], [4 x i32], [4 x i32], i32, i32, i32, i32, i32, i32, i32, ptr, i32, i32, ptr, i32, i32, i32, [2 x %struct.pspdef_t], i32 }
%struct.ticcmd_t = type { i8, i8, i16, i16, i8, i8 }
%struct.pspdef_t = type { ptr, i32, i32, i32 }
%struct.mapthing_t = type { i16, i16, i16, i16, i16 }
%struct.mobj_s = type { %struct.thinker_s, i32, i32, i32, ptr, ptr, i32, i32, i32, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, ptr, i32, ptr, i32, i32, i32, i32, ptr, i32, i32, ptr, i32, %struct.mapthing_t, ptr }
%struct.thinker_s = type { ptr, ptr, %union.actionf_t }
%union.actionf_t = type { ptr }

@deathmatch = external global i32, align 4
@playeringame = external global [4 x i32], align 16
@players = external global [4 x %struct.player_s], align 16
@consoleplayer = external global i32, align 4

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

; 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
declare dso_local ptr @P_SpawnMobj(i32 noundef, i32 noundef, i32 noundef, i32 noundef) #1

; Function Attrs: nounwind uwtable
define dso_local void @P_SpawnPlayer(ptr noundef %0) #1 {
  %2 = alloca ptr, align 8
  %3 = alloca ptr, align 8
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  store ptr %0, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %4) #3
  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 8, ptr %7) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  %10 = load ptr, ptr %2, align 8, !tbaa !5
  %11 = getelementptr inbounds %struct.mapthing_t, ptr %10, i32 0, i32 3
  %12 = load i16, ptr %11, align 2, !tbaa !9
  %13 = sext i16 %12 to i32
  %14 = sub nsw i32 %13, 1
  %15 = sext i32 %14 to i64
  %16 = getelementptr inbounds [4 x i32], ptr @playeringame, i64 0, i64 %15
  %17 = load i32, ptr %16, align 4, !tbaa !12
  %18 = icmp ne i32 %17, 0
  br i1 %18, label %20, label %19

19:                                               ; preds = %1
  store i32 1, ptr %9, align 4
  br label %132

20:                                               ; preds = %1
  %21 = load ptr, ptr %2, align 8, !tbaa !5
  %22 = getelementptr inbounds %struct.mapthing_t, ptr %21, i32 0, i32 3
  %23 = load i16, ptr %22, align 2, !tbaa !9
  %24 = sext i16 %23 to i32
  %25 = sub nsw i32 %24, 1
  %26 = sext i32 %25 to i64
  %27 = getelementptr inbounds [4 x %struct.player_s], ptr @players, i64 0, i64 %26
  store ptr %27, ptr %3, align 8, !tbaa !5
  %28 = load ptr, ptr %3, align 8, !tbaa !5
  %29 = getelementptr inbounds %struct.player_s, ptr %28, i32 0, i32 1
  %30 = load i32, ptr %29, align 8, !tbaa !14
  %31 = icmp eq i32 %30, 2
  br i1 %31, label %32, label %38

32:                                               ; preds = %20
  %33 = load ptr, ptr %2, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.mapthing_t, ptr %33, i32 0, i32 3
  %35 = load i16, ptr %34, align 2, !tbaa !9
  %36 = sext i16 %35 to i32
  %37 = sub nsw i32 %36, 1
  call void @G_PlayerReborn(i32 noundef %37)
  br label %38

38:                                               ; preds = %32, %20
  %39 = load ptr, ptr %2, align 8, !tbaa !5
  %40 = getelementptr inbounds %struct.mapthing_t, ptr %39, i32 0, i32 0
  %41 = load i16, ptr %40, align 2, !tbaa !17
  %42 = sext i16 %41 to i32
  %43 = shl i32 %42, 16
  store i32 %43, ptr %4, align 4, !tbaa !12
  %44 = load ptr, ptr %2, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.mapthing_t, ptr %44, i32 0, i32 1
  %46 = load i16, ptr %45, align 2, !tbaa !18
  %47 = sext i16 %46 to i32
  %48 = shl i32 %47, 16
  store i32 %48, ptr %5, align 4, !tbaa !12
  store i32 -2147483648, ptr %6, align 4, !tbaa !12
  %49 = load i32, ptr %4, align 4, !tbaa !12
  %50 = load i32, ptr %5, align 4, !tbaa !12
  %51 = load i32, ptr %6, align 4, !tbaa !12
  %52 = call ptr @P_SpawnMobj(i32 noundef %49, i32 noundef %50, i32 noundef %51, i32 noundef 0)
  store ptr %52, ptr %7, align 8, !tbaa !5
  %53 = load ptr, ptr %2, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.mapthing_t, ptr %53, i32 0, i32 3
  %55 = load i16, ptr %54, align 2, !tbaa !9
  %56 = sext i16 %55 to i32
  %57 = icmp sgt i32 %56, 1
  br i1 %57, label %58, label %69

58:                                               ; preds = %38
  %59 = load ptr, ptr %2, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.mapthing_t, ptr %59, i32 0, i32 3
  %61 = load i16, ptr %60, align 2, !tbaa !9
  %62 = sext i16 %61 to i32
  %63 = sub nsw i32 %62, 1
  %64 = shl i32 %63, 26
  %65 = load ptr, ptr %7, align 8, !tbaa !5
  %66 = getelementptr inbounds %struct.mobj_s, ptr %65, i32 0, i32 24
  %67 = load i32, ptr %66, align 8, !tbaa !19
  %68 = or i32 %67, %64
  store i32 %68, ptr %66, align 8, !tbaa !19
  br label %69

69:                                               ; preds = %58, %38
  %70 = load ptr, ptr %2, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.mapthing_t, ptr %70, i32 0, i32 2
  %72 = load i16, ptr %71, align 2, !tbaa !22
  %73 = sext i16 %72 to i32
  %74 = sdiv i32 %73, 45
  %75 = mul nsw i32 536870912, %74
  %76 = load ptr, ptr %7, align 8, !tbaa !5
  %77 = getelementptr inbounds %struct.mobj_s, ptr %76, i32 0, i32 6
  store i32 %75, ptr %77, align 8, !tbaa !23
  %78 = load ptr, ptr %3, align 8, !tbaa !5
  %79 = load ptr, ptr %7, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.mobj_s, ptr %79, i32 0, i32 31
  store ptr %78, ptr %80, align 8, !tbaa !24
  %81 = load ptr, ptr %3, align 8, !tbaa !5
  %82 = getelementptr inbounds %struct.player_s, ptr %81, i32 0, i32 7
  %83 = load i32, ptr %82, align 4, !tbaa !25
  %84 = load ptr, ptr %7, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.mobj_s, ptr %84, i32 0, i32 25
  store i32 %83, ptr %85, align 4, !tbaa !26
  %86 = load ptr, ptr %7, align 8, !tbaa !5
  %87 = load ptr, ptr %3, align 8, !tbaa !5
  %88 = getelementptr inbounds %struct.player_s, ptr %87, i32 0, i32 0
  store ptr %86, ptr %88, align 8, !tbaa !27
  %89 = load ptr, ptr %3, align 8, !tbaa !5
  %90 = getelementptr inbounds %struct.player_s, ptr %89, i32 0, i32 1
  store i32 0, ptr %90, align 8, !tbaa !14
  %91 = load ptr, ptr %3, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.player_s, ptr %91, i32 0, i32 22
  store i32 0, ptr %92, align 4, !tbaa !28
  %93 = load ptr, ptr %3, align 8, !tbaa !5
  %94 = getelementptr inbounds %struct.player_s, ptr %93, i32 0, i32 26
  store ptr null, ptr %94, align 8, !tbaa !29
  %95 = load ptr, ptr %3, align 8, !tbaa !5
  %96 = getelementptr inbounds %struct.player_s, ptr %95, i32 0, i32 27
  store i32 0, ptr %96, align 8, !tbaa !30
  %97 = load ptr, ptr %3, align 8, !tbaa !5
  %98 = getelementptr inbounds %struct.player_s, ptr %97, i32 0, i32 28
  store i32 0, ptr %98, align 4, !tbaa !31
  %99 = load ptr, ptr %3, align 8, !tbaa !5
  %100 = getelementptr inbounds %struct.player_s, ptr %99, i32 0, i32 30
  store i32 0, ptr %100, align 8, !tbaa !32
  %101 = load ptr, ptr %3, align 8, !tbaa !5
  %102 = getelementptr inbounds %struct.player_s, ptr %101, i32 0, i32 31
  store i32 0, ptr %102, align 4, !tbaa !33
  %103 = load ptr, ptr %3, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct.player_s, ptr %103, i32 0, i32 4
  store i32 2686976, ptr %104, align 8, !tbaa !34
  %105 = load ptr, ptr %3, align 8, !tbaa !5
  call void @P_SetupPsprites(ptr noundef %105)
  %106 = load i32, ptr @deathmatch, align 4, !tbaa !12
  %107 = icmp ne i32 %106, 0
  br i1 %107, label %108, label %122

108:                                              ; preds = %69
  store i32 0, ptr %8, align 4, !tbaa !12
  br label %109

109:                                              ; preds = %118, %108
  %110 = load i32, ptr %8, align 4, !tbaa !12
  %111 = icmp slt i32 %110, 6
  br i1 %111, label %112, label %121

112:                                              ; preds = %109
  %113 = load ptr, ptr %3, align 8, !tbaa !5
  %114 = getelementptr inbounds %struct.player_s, ptr %113, i32 0, i32 11
  %115 = load i32, ptr %8, align 4, !tbaa !12
  %116 = sext i32 %115 to i64
  %117 = getelementptr inbounds [6 x i32], ptr %114, i64 0, i64 %116
  store i32 1, ptr %117, align 4, !tbaa !12
  br label %118

118:                                              ; preds = %112
  %119 = load i32, ptr %8, align 4, !tbaa !12
  %120 = add nsw i32 %119, 1
  store i32 %120, ptr %8, align 4, !tbaa !12
  br label %109, !llvm.loop !35

121:                                              ; preds = %109
  br label %122

122:                                              ; preds = %121, %69
  %123 = load ptr, ptr %2, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.mapthing_t, ptr %123, i32 0, i32 3
  %125 = load i16, ptr %124, align 2, !tbaa !9
  %126 = sext i16 %125 to i32
  %127 = sub nsw i32 %126, 1
  %128 = load i32, ptr @consoleplayer, align 4, !tbaa !12
  %129 = icmp eq i32 %127, %128
  br i1 %129, label %130, label %131

130:                                              ; preds = %122
  call void @ST_Start()
  call void @HU_Start()
  br label %131

131:                                              ; preds = %130, %122
  store i32 0, ptr %9, align 4
  br label %132

132:                                              ; preds = %131, %19
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 8, 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
  call void @llvm.lifetime.end.p0(i64 4, ptr %4) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #3
  %133 = load i32, ptr %9, align 4
  switch i32 %133, label %135 [
    i32 0, label %134
    i32 1, label %134
  ]

134:                                              ; preds = %132, %132
  ret void

135:                                              ; preds = %132
  unreachable
}

declare void @G_PlayerReborn(i32 noundef) #2

declare void @P_SetupPsprites(ptr noundef) #2

declare void @ST_Start() #2

declare void @HU_Start() #2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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 6}
!10 = !{!"", !11, i64 0, !11, i64 2, !11, i64 4, !11, i64 6, !11, i64 8}
!11 = !{!"short", !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{!15, !13, i64 8}
!15 = !{!"player_s", !6, i64 0, !13, i64 8, !16, i64 12, !13, i64 20, !13, i64 24, !13, i64 28, !13, i64 32, !13, i64 36, !13, i64 40, !13, i64 44, !7, i64 48, !7, i64 72, !13, i64 96, !7, i64 100, !13, i64 116, !13, i64 120, !7, i64 124, !7, i64 160, !7, i64 176, !13, i64 192, !13, i64 196, !13, i64 200, !13, i64 204, !13, i64 208, !13, i64 212, !13, i64 216, !6, i64 224, !13, i64 232, !13, i64 236, !6, i64 240, !13, i64 248, !13, i64 252, !13, i64 256, !7, i64 264, !13, i64 312}
!16 = !{!"", !7, i64 0, !7, i64 1, !11, i64 2, !11, i64 4, !7, i64 6, !7, i64 7}
!17 = !{!10, !11, i64 0}
!18 = !{!10, !11, i64 2}
!19 = !{!20, !13, i64 160}
!20 = !{!"mobj_s", !21, i64 0, !13, i64 24, !13, i64 28, !13, i64 32, !6, i64 40, !6, i64 48, !13, i64 56, !13, i64 60, !13, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !13, i64 96, !13, i64 100, !13, i64 104, !13, i64 108, !13, i64 112, !13, i64 116, !13, i64 120, !13, i64 124, !13, i64 128, !6, i64 136, !13, i64 144, !6, i64 152, !13, i64 160, !13, i64 164, !13, i64 168, !13, i64 172, !6, i64 176, !13, i64 184, !13, i64 188, !6, i64 192, !13, i64 200, !10, i64 204, !6, i64 216}
!21 = !{!"thinker_s", !6, i64 0, !6, i64 8, !7, i64 16}
!22 = !{!10, !11, i64 4}
!23 = !{!20, !13, i64 56}
!24 = !{!20, !6, i64 192}
!25 = !{!15, !13, i64 36}
!26 = !{!20, !13, i64 164}
!27 = !{!15, !6, i64 0}
!28 = !{!15, !13, i64 204}
!29 = !{!15, !6, i64 224}
!30 = !{!15, !13, i64 232}
!31 = !{!15, !13, i64 236}
!32 = !{!15, !13, i64 248}
!33 = !{!15, !13, i64 252}
!34 = !{!15, !13, i64 24}
!35 = distinct !{!35, !36}
!36 = !{!"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.player_s = type { ptr, i32, %struct.ticcmd_t, i32, i32, i32, i32, i32, i32, i32, [6 x i32], [6 x i32], i32, [4 x i32], i32, i32, [9 x i32], [4 x i32], [4 x i32], i32, i32, i32, i32, i32, i32, i32, ptr, i32, i32, ptr, i32, i32, i32, [2 x %struct.pspdef_t], i32 }
%struct.ticcmd_t = type { i8, i8, i16, i16, i8, i8 }
%struct.pspdef_t = type { ptr, i32, i32, i32 }

@deathmatch = external local_unnamed_addr global i32, align 4
@playeringame = external local_unnamed_addr global [4 x i32], align 16
@players = external global [4 x %struct.player_s], align 16
@consoleplayer = external local_unnamed_addr global i32, align 4

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

; Function Attrs: nounwind uwtable
define dso_local void @P_SpawnPlayer(ptr nocapture noundef readonly %0) local_unnamed_addr #0 {
  %2 = getelementptr inbounds i8, ptr %0, i64 6
  %3 = load i16, ptr %2, align 2, !tbaa !5
  %4 = sext i16 %3 to i32
  %5 = add nsw i32 %4, -1
  %6 = sext i32 %5 to i64
  %7 = getelementptr inbounds [4 x i32], ptr @playeringame, i64 0, i64 %6
  %8 = load i32, ptr %7, align 4, !tbaa !10
  %.not = icmp eq i32 %8, 0
  br i1 %.not, label %58, label %9

9:                                                ; preds = %1
  %10 = getelementptr inbounds [4 x %struct.player_s], ptr @players, i64 0, i64 %6
  %11 = getelementptr inbounds i8, ptr %10, i64 8
  %12 = load i32, ptr %11, align 8, !tbaa !12
  %13 = icmp eq i32 %12, 2
  br i1 %13, label %14, label %15

14:                                               ; preds = %9
  tail call void @G_PlayerReborn(i32 noundef %5) #3
  br label %15

15:                                               ; preds = %14, %9
  %16 = load i16, ptr %0, align 2, !tbaa !16
  %17 = sext i16 %16 to i32
  %18 = shl nsw i32 %17, 16
  %19 = getelementptr inbounds i8, ptr %0, i64 2
  %20 = load i16, ptr %19, align 2, !tbaa !17
  %21 = sext i16 %20 to i32
  %22 = shl nsw i32 %21, 16
  %23 = tail call ptr @P_SpawnMobj(i32 noundef %18, i32 noundef %22, i32 noundef -2147483648, i32 noundef 0)
  %24 = load i16, ptr %2, align 2, !tbaa !5
  %25 = icmp sgt i16 %24, 1
  br i1 %25, label %26, label %32

26:                                               ; preds = %15
  %narrow = add nuw i16 %24, 63
  %27 = zext i16 %narrow to i32
  %28 = shl i32 %27, 26
  %29 = getelementptr inbounds i8, ptr %23, i64 160
  %30 = load i32, ptr %29, align 8, !tbaa !18
  %31 = or i32 %30, %28
  store i32 %31, ptr %29, align 8, !tbaa !18
  br label %32

32:                                               ; preds = %26, %15
  %33 = getelementptr inbounds i8, ptr %0, i64 4
  %34 = load i16, ptr %33, align 2, !tbaa !21
  %35 = sdiv i16 %34, 45
  %36 = sext i16 %35 to i32
  %37 = shl nsw i32 %36, 29
  %38 = getelementptr inbounds i8, ptr %23, i64 56
  store i32 %37, ptr %38, align 8, !tbaa !22
  %39 = getelementptr inbounds i8, ptr %23, i64 192
  store ptr %10, ptr %39, align 8, !tbaa !23
  %40 = getelementptr inbounds i8, ptr %10, i64 36
  %41 = load i32, ptr %40, align 4, !tbaa !24
  %42 = getelementptr inbounds i8, ptr %23, i64 164
  store i32 %41, ptr %42, align 4, !tbaa !25
  store ptr %23, ptr %10, align 16, !tbaa !26
  store i32 0, ptr %11, align 8, !tbaa !12
  %43 = getelementptr inbounds i8, ptr %10, i64 204
  store i32 0, ptr %43, align 4, !tbaa !27
  %44 = getelementptr inbounds i8, ptr %10, i64 224
  %45 = getelementptr inbounds i8, ptr %10, i64 248
  store i32 0, ptr %45, align 8, !tbaa !28
  %46 = getelementptr inbounds i8, ptr %10, i64 252
  store i32 0, ptr %46, align 4, !tbaa !29
  %47 = getelementptr inbounds i8, ptr %10, i64 24
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %44, i8 0, i64 16, i1 false)
  store i32 2686976, ptr %47, align 8, !tbaa !30
  tail call void @P_SetupPsprites(ptr noundef nonnull %10) #3
  %48 = load i32, ptr @deathmatch, align 4, !tbaa !10
  %.not34 = icmp eq i32 %48, 0
  br i1 %.not34, label %.loopexit, label %.preheader

.preheader:                                       ; preds = %32
  %49 = getelementptr inbounds i8, ptr %10, i64 72
  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %49, align 8, !tbaa !10
  %50 = getelementptr inbounds i8, ptr %10, i64 88
  store i32 1, ptr %50, align 8, !tbaa !10
  %51 = getelementptr inbounds i8, ptr %10, i64 92
  store i32 1, ptr %51, align 4, !tbaa !10
  br label %.loopexit

.loopexit:                                        ; preds = %.preheader, %32
  %52 = load i16, ptr %2, align 2, !tbaa !5
  %53 = sext i16 %52 to i32
  %54 = add nsw i32 %53, -1
  %55 = load i32, ptr @consoleplayer, align 4, !tbaa !10
  %56 = icmp eq i32 %54, %55
  br i1 %56, label %57, label %58

57:                                               ; preds = %.loopexit
  tail call void @ST_Start() #3
  tail call void @HU_Start() #3
  br label %58

58:                                               ; preds = %.loopexit, %57, %1
  ret void
}

declare void @G_PlayerReborn(i32 noundef) local_unnamed_addr #1

declare void @P_SetupPsprites(ptr noundef) local_unnamed_addr #1

declare void @ST_Start() local_unnamed_addr #1

declare void @HU_Start() local_unnamed_addr #1

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

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 = { 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, !7, i64 6}
!6 = !{!"", !7, i64 0, !7, i64 2, !7, i64 4, !7, i64 6, !7, i64 8}
!7 = !{!"short", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!11, !11, i64 0}
!11 = !{!"int", !8, i64 0}
!12 = !{!13, !11, i64 8}
!13 = !{!"player_s", !14, i64 0, !11, i64 8, !15, i64 12, !11, i64 20, !11, i64 24, !11, i64 28, !11, i64 32, !11, i64 36, !11, i64 40, !11, i64 44, !8, i64 48, !8, i64 72, !11, i64 96, !8, i64 100, !11, i64 116, !11, i64 120, !8, i64 124, !8, i64 160, !8, i64 176, !11, i64 192, !11, i64 196, !11, i64 200, !11, i64 204, !11, i64 208, !11, i64 212, !11, i64 216, !14, i64 224, !11, i64 232, !11, i64 236, !14, i64 240, !11, i64 248, !11, i64 252, !11, i64 256, !8, i64 264, !11, i64 312}
!14 = !{!"any pointer", !8, i64 0}
!15 = !{!"", !8, i64 0, !8, i64 1, !7, i64 2, !7, i64 4, !8, i64 6, !8, i64 7}
!16 = !{!6, !7, i64 0}
!17 = !{!6, !7, i64 2}
!18 = !{!19, !11, i64 160}
!19 = !{!"mobj_s", !20, i64 0, !11, i64 24, !11, i64 28, !11, i64 32, !14, i64 40, !14, i64 48, !11, i64 56, !11, i64 60, !11, i64 64, !14, i64 72, !14, i64 80, !14, i64 88, !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, !14, i64 136, !11, i64 144, !14, i64 152, !11, i64 160, !11, i64 164, !11, i64 168, !11, i64 172, !14, i64 176, !11, i64 184, !11, i64 188, !14, i64 192, !11, i64 200, !6, i64 204, !14, i64 216}
!20 = !{!"thinker_s", !14, i64 0, !14, i64 8, !8, i64 16}
!21 = !{!6, !7, i64 4}
!22 = !{!19, !11, i64 56}
!23 = !{!19, !14, i64 192}
!24 = !{!13, !11, i64 36}
!25 = !{!19, !11, i64 164}
!26 = !{!13, !14, i64 0}
!27 = !{!13, !11, i64 204}
!28 = !{!13, !11, i64 248}
!29 = !{!13, !11, i64 252}
!30 = !{!13, !11, i64 24}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,LICMPass,LoopRotatePass,LoopSimplifyPass,MemCpyOptPass,PostOrderFunctionAttrsPass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass