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

; 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.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 }
%struct.mapthing_t = type { i16, i16, i16, i16, i16 }
%struct.subsector_s = type { ptr, i16, i16 }
%struct.sector_t = type { i32, i32, i16, i16, i16, i16, i16, i32, ptr, [4 x i32], %struct.degenmobj_t, i32, ptr, ptr, i32, ptr }
%struct.degenmobj_t = type { %struct.thinker_s, i32, i32, i32 }

@tmthing = external dso_local global ptr, align 8
@tmx = external dso_local global i32, align 4
@tmy = external dso_local global i32, align 4
@tmflags = external dso_local global i32, align 4
@tmbbox = external dso_local global [4 x i32], align 16
@ceilingline = external dso_local global ptr, align 8
@tmdropoffz = external dso_local global i32, align 4
@tmfloorz = external dso_local global i32, align 4
@tmceilingz = external dso_local global i32, align 4
@validcount = external global i32, align 4
@numspechit = external dso_local global i32, align 4
@bmaporgx = external global i32, align 4
@bmaporgy = external global i32, align 4

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

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

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

; Function Attrs: nounwind uwtable
define dso_local i32 @P_TeleportMove(ptr noundef %0, i32 noundef %1, i32 noundef %2) #0 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i32 %1, ptr %6, align 4, !tbaa !9
  store i32 %2, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #3
  %16 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %16, ptr @tmthing, align 8, !tbaa !5
  %17 = load ptr, ptr %5, align 8, !tbaa !5
  %18 = getelementptr inbounds %struct.mobj_s, ptr %17, i32 0, i32 24
  %19 = load i32, ptr %18, align 8, !tbaa !11
  store i32 %19, ptr @tmflags, align 4, !tbaa !9
  %20 = load i32, ptr %6, align 4, !tbaa !9
  store i32 %20, ptr @tmx, align 4, !tbaa !9
  %21 = load i32, ptr %7, align 4, !tbaa !9
  store i32 %21, ptr @tmy, align 4, !tbaa !9
  %22 = load i32, ptr %7, align 4, !tbaa !9
  %23 = load ptr, ptr @tmthing, align 8, !tbaa !5
  %24 = getelementptr inbounds %struct.mobj_s, ptr %23, i32 0, i32 14
  %25 = load i32, ptr %24, align 8, !tbaa !16
  %26 = add nsw i32 %22, %25
  store i32 %26, ptr @tmbbox, align 16, !tbaa !9
  %27 = load i32, ptr %7, align 4, !tbaa !9
  %28 = load ptr, ptr @tmthing, align 8, !tbaa !5
  %29 = getelementptr inbounds %struct.mobj_s, ptr %28, i32 0, i32 14
  %30 = load i32, ptr %29, align 8, !tbaa !16
  %31 = sub nsw i32 %27, %30
  store i32 %31, ptr getelementptr inbounds ([4 x i32], ptr @tmbbox, i64 0, i64 1), align 4, !tbaa !9
  %32 = load i32, ptr %6, align 4, !tbaa !9
  %33 = load ptr, ptr @tmthing, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.mobj_s, ptr %33, i32 0, i32 14
  %35 = load i32, ptr %34, align 8, !tbaa !16
  %36 = add nsw i32 %32, %35
  store i32 %36, ptr getelementptr inbounds ([4 x i32], ptr @tmbbox, i64 0, i64 3), align 4, !tbaa !9
  %37 = load i32, ptr %6, align 4, !tbaa !9
  %38 = load ptr, ptr @tmthing, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.mobj_s, ptr %38, i32 0, i32 14
  %40 = load i32, ptr %39, align 8, !tbaa !16
  %41 = sub nsw i32 %37, %40
  store i32 %41, ptr getelementptr inbounds ([4 x i32], ptr @tmbbox, i64 0, i64 2), align 8, !tbaa !9
  %42 = load i32, ptr %6, align 4, !tbaa !9
  %43 = load i32, ptr %7, align 4, !tbaa !9
  %44 = call ptr @R_PointInSubsector(i32 noundef %42, i32 noundef %43)
  store ptr %44, ptr %14, align 8, !tbaa !5
  store ptr null, ptr @ceilingline, align 8, !tbaa !5
  %45 = load ptr, ptr %14, align 8, !tbaa !5
  %46 = getelementptr inbounds %struct.subsector_s, ptr %45, i32 0, i32 0
  %47 = load ptr, ptr %46, align 8, !tbaa !17
  %48 = getelementptr inbounds %struct.sector_t, ptr %47, i32 0, i32 0
  %49 = load i32, ptr %48, align 8, !tbaa !19
  store i32 %49, ptr @tmdropoffz, align 4, !tbaa !9
  store i32 %49, ptr @tmfloorz, align 4, !tbaa !9
  %50 = load ptr, ptr %14, align 8, !tbaa !5
  %51 = getelementptr inbounds %struct.subsector_s, ptr %50, i32 0, i32 0
  %52 = load ptr, ptr %51, align 8, !tbaa !17
  %53 = getelementptr inbounds %struct.sector_t, ptr %52, i32 0, i32 1
  %54 = load i32, ptr %53, align 4, !tbaa !22
  store i32 %54, ptr @tmceilingz, align 4, !tbaa !9
  %55 = load i32, ptr @validcount, align 4, !tbaa !9
  %56 = add nsw i32 %55, 1
  store i32 %56, ptr @validcount, align 4, !tbaa !9
  store i32 0, ptr @numspechit, align 4, !tbaa !9
  %57 = load i32, ptr getelementptr inbounds ([4 x i32], ptr @tmbbox, i64 0, i64 2), align 8, !tbaa !9
  %58 = load i32, ptr @bmaporgx, align 4, !tbaa !9
  %59 = sub nsw i32 %57, %58
  %60 = sub nsw i32 %59, 2097152
  %61 = ashr i32 %60, 23
  store i32 %61, ptr %8, align 4, !tbaa !9
  %62 = load i32, ptr getelementptr inbounds ([4 x i32], ptr @tmbbox, i64 0, i64 3), align 4, !tbaa !9
  %63 = load i32, ptr @bmaporgx, align 4, !tbaa !9
  %64 = sub nsw i32 %62, %63
  %65 = add nsw i32 %64, 2097152
  %66 = ashr i32 %65, 23
  store i32 %66, ptr %9, align 4, !tbaa !9
  %67 = load i32, ptr getelementptr inbounds ([4 x i32], ptr @tmbbox, i64 0, i64 1), align 4, !tbaa !9
  %68 = load i32, ptr @bmaporgy, align 4, !tbaa !9
  %69 = sub nsw i32 %67, %68
  %70 = sub nsw i32 %69, 2097152
  %71 = ashr i32 %70, 23
  store i32 %71, ptr %10, align 4, !tbaa !9
  %72 = load i32, ptr @tmbbox, align 16, !tbaa !9
  %73 = load i32, ptr @bmaporgy, align 4, !tbaa !9
  %74 = sub nsw i32 %72, %73
  %75 = add nsw i32 %74, 2097152
  %76 = ashr i32 %75, 23
  store i32 %76, ptr %11, align 4, !tbaa !9
  %77 = load i32, ptr %8, align 4, !tbaa !9
  store i32 %77, ptr %12, align 4, !tbaa !9
  br label %78

78:                                               ; preds = %99, %3
  %79 = load i32, ptr %12, align 4, !tbaa !9
  %80 = load i32, ptr %9, align 4, !tbaa !9
  %81 = icmp sle i32 %79, %80
  br i1 %81, label %82, label %102

82:                                               ; preds = %78
  %83 = load i32, ptr %10, align 4, !tbaa !9
  store i32 %83, ptr %13, align 4, !tbaa !9
  br label %84

84:                                               ; preds = %95, %82
  %85 = load i32, ptr %13, align 4, !tbaa !9
  %86 = load i32, ptr %11, align 4, !tbaa !9
  %87 = icmp sle i32 %85, %86
  br i1 %87, label %88, label %98

88:                                               ; preds = %84
  %89 = load i32, ptr %12, align 4, !tbaa !9
  %90 = load i32, ptr %13, align 4, !tbaa !9
  %91 = call i32 @P_BlockThingsIterator(i32 noundef %89, i32 noundef %90, ptr noundef @PIT_StompThing)
  %92 = icmp ne i32 %91, 0
  br i1 %92, label %94, label %93

93:                                               ; preds = %88
  store i32 0, ptr %4, align 4
  store i32 1, ptr %15, align 4
  br label %117

94:                                               ; preds = %88
  br label %95

95:                                               ; preds = %94
  %96 = load i32, ptr %13, align 4, !tbaa !9
  %97 = add nsw i32 %96, 1
  store i32 %97, ptr %13, align 4, !tbaa !9
  br label %84, !llvm.loop !23

98:                                               ; preds = %84
  br label %99

99:                                               ; preds = %98
  %100 = load i32, ptr %12, align 4, !tbaa !9
  %101 = add nsw i32 %100, 1
  store i32 %101, ptr %12, align 4, !tbaa !9
  br label %78, !llvm.loop !25

102:                                              ; preds = %78
  %103 = load ptr, ptr %5, align 8, !tbaa !5
  call void @P_UnsetThingPosition(ptr noundef %103)
  %104 = load i32, ptr @tmfloorz, align 4, !tbaa !9
  %105 = load ptr, ptr %5, align 8, !tbaa !5
  %106 = getelementptr inbounds %struct.mobj_s, ptr %105, i32 0, i32 12
  store i32 %104, ptr %106, align 8, !tbaa !26
  %107 = load i32, ptr @tmceilingz, align 4, !tbaa !9
  %108 = load ptr, ptr %5, align 8, !tbaa !5
  %109 = getelementptr inbounds %struct.mobj_s, ptr %108, i32 0, i32 13
  store i32 %107, ptr %109, align 4, !tbaa !27
  %110 = load i32, ptr %6, align 4, !tbaa !9
  %111 = load ptr, ptr %5, align 8, !tbaa !5
  %112 = getelementptr inbounds %struct.mobj_s, ptr %111, i32 0, i32 1
  store i32 %110, ptr %112, align 8, !tbaa !28
  %113 = load i32, ptr %7, align 4, !tbaa !9
  %114 = load ptr, ptr %5, align 8, !tbaa !5
  %115 = getelementptr inbounds %struct.mobj_s, ptr %114, i32 0, i32 2
  store i32 %113, ptr %115, align 4, !tbaa !29
  %116 = load ptr, ptr %5, align 8, !tbaa !5
  call void @P_SetThingPosition(ptr noundef %116)
  store i32 1, ptr %4, align 4
  store i32 1, ptr %15, align 4
  br label %117

117:                                              ; preds = %102, %93
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  %118 = load i32, ptr %4, align 4
  ret i32 %118
}

declare ptr @R_PointInSubsector(i32 noundef, i32 noundef) #2

declare i32 @P_BlockThingsIterator(i32 noundef, i32 noundef, ptr noundef) #2

declare void @P_UnsetThingPosition(ptr noundef) #2

declare void @P_SetThingPosition(ptr noundef) #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 = { 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 160}
!12 = !{!"mobj_s", !13, i64 0, !10, i64 24, !10, i64 28, !10, i64 32, !6, i64 40, !6, i64 48, !10, i64 56, !10, i64 60, !10, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !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, !6, i64 136, !10, i64 144, !6, i64 152, !10, i64 160, !10, i64 164, !10, i64 168, !10, i64 172, !6, i64 176, !10, i64 184, !10, i64 188, !6, i64 192, !10, i64 200, !14, i64 204, !6, i64 216}
!13 = !{!"thinker_s", !6, i64 0, !6, i64 8, !7, i64 16}
!14 = !{!"", !15, i64 0, !15, i64 2, !15, i64 4, !15, i64 6, !15, i64 8}
!15 = !{!"short", !7, i64 0}
!16 = !{!12, !10, i64 104}
!17 = !{!18, !6, i64 0}
!18 = !{!"subsector_s", !6, i64 0, !15, i64 8, !15, i64 10}
!19 = !{!20, !10, i64 0}
!20 = !{!"", !10, i64 0, !10, i64 4, !15, i64 8, !15, i64 10, !15, i64 12, !15, i64 14, !15, i64 16, !10, i64 20, !6, i64 24, !7, i64 32, !21, i64 48, !10, i64 88, !6, i64 96, !6, i64 104, !10, i64 112, !6, i64 120}
!21 = !{!"", !13, i64 0, !10, i64 24, !10, i64 28, !10, i64 32}
!22 = !{!20, !10, i64 4}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}
!25 = distinct !{!25, !24}
!26 = !{!12, !10, i64 96}
!27 = !{!12, !10, i64 100}
!28 = !{!12, !10, i64 24}
!29 = !{!12, !10, i64 28}


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

@tmthing = external dso_local local_unnamed_addr global ptr, align 8
@tmx = external dso_local local_unnamed_addr global i32, align 4
@tmy = external dso_local local_unnamed_addr global i32, align 4
@tmflags = external dso_local local_unnamed_addr global i32, align 4
@tmbbox = external dso_local local_unnamed_addr global [4 x i32], align 16
@ceilingline = external dso_local local_unnamed_addr global ptr, align 8
@tmdropoffz = external dso_local local_unnamed_addr global i32, align 4
@tmfloorz = external dso_local local_unnamed_addr global i32, align 4
@tmceilingz = external dso_local local_unnamed_addr global i32, align 4
@validcount = external local_unnamed_addr global i32, align 4
@numspechit = external dso_local local_unnamed_addr global i32, align 4
@bmaporgx = external local_unnamed_addr global i32, align 4
@bmaporgy = external local_unnamed_addr global i32, align 4

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

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 2) i32 @P_TeleportMove(ptr noundef %0, i32 noundef %1, i32 noundef %2) local_unnamed_addr #0 {
  store ptr %0, ptr @tmthing, align 8, !tbaa !5
  %4 = getelementptr inbounds i8, ptr %0, i64 160
  %5 = load i32, ptr %4, align 8, !tbaa !9
  store i32 %5, ptr @tmflags, align 4, !tbaa !15
  store i32 %1, ptr @tmx, align 4, !tbaa !15
  store i32 %2, ptr @tmy, align 4, !tbaa !15
  %6 = getelementptr inbounds i8, ptr %0, i64 104
  %7 = load i32, ptr %6, align 8, !tbaa !16
  %8 = add nsw i32 %7, %2
  store i32 %8, ptr @tmbbox, align 16, !tbaa !15
  %9 = sub nsw i32 %2, %7
  store i32 %9, ptr getelementptr inbounds (i8, ptr @tmbbox, i64 4), align 4, !tbaa !15
  %10 = add nsw i32 %7, %1
  store i32 %10, ptr getelementptr inbounds (i8, ptr @tmbbox, i64 12), align 4, !tbaa !15
  %11 = sub nsw i32 %1, %7
  store i32 %11, ptr getelementptr inbounds (i8, ptr @tmbbox, i64 8), align 8, !tbaa !15
  %12 = tail call ptr @R_PointInSubsector(i32 noundef %1, i32 noundef %2) #2
  store ptr null, ptr @ceilingline, align 8, !tbaa !5
  %13 = load ptr, ptr %12, align 8, !tbaa !17
  %14 = load i32, ptr %13, align 8, !tbaa !19
  store i32 %14, ptr @tmdropoffz, align 4, !tbaa !15
  store i32 %14, ptr @tmfloorz, align 4, !tbaa !15
  %15 = getelementptr inbounds i8, ptr %13, i64 4
  %16 = load i32, ptr %15, align 4, !tbaa !22
  store i32 %16, ptr @tmceilingz, align 4, !tbaa !15
  %17 = load i32, ptr @validcount, align 4, !tbaa !15
  %18 = add nsw i32 %17, 1
  store i32 %18, ptr @validcount, align 4, !tbaa !15
  store i32 0, ptr @numspechit, align 4, !tbaa !15
  %19 = load i32, ptr getelementptr inbounds (i8, ptr @tmbbox, i64 8), align 8, !tbaa !15
  %20 = load i32, ptr @bmaporgx, align 4, !tbaa !15
  %21 = add i32 %19, -2097152
  %22 = sub i32 %21, %20
  %23 = ashr i32 %22, 23
  %24 = load i32, ptr getelementptr inbounds (i8, ptr @tmbbox, i64 12), align 4, !tbaa !15
  %reass.sub = sub i32 %24, %20
  %25 = add i32 %reass.sub, 2097152
  %26 = ashr i32 %25, 23
  %27 = load i32, ptr getelementptr inbounds (i8, ptr @tmbbox, i64 4), align 4, !tbaa !15
  %28 = load i32, ptr @bmaporgy, align 4, !tbaa !15
  %29 = add i32 %27, -2097152
  %30 = sub i32 %29, %28
  %31 = ashr i32 %30, 23
  %32 = load i32, ptr @tmbbox, align 16, !tbaa !15
  %reass.sub40 = sub i32 %32, %28
  %33 = add i32 %reass.sub40, 2097152
  %34 = ashr i32 %33, 23
  %.not37 = icmp sgt i32 %23, %26
  %.not3235 = icmp sgt i32 %31, %34
  %or.cond = select i1 %.not37, i1 true, i1 %.not3235
  br i1 %or.cond, label %._crit_edge39, label %.preheader

.preheader:                                       ; preds = %3, %._crit_edge
  %.03138 = phi i32 [ %39, %._crit_edge ], [ %23, %3 ]
  br label %37

35:                                               ; preds = %37
  %36 = add nsw i32 %.03036, 1
  %exitcond.not = icmp eq i32 %.03036, %34
  br i1 %exitcond.not, label %._crit_edge, label %37, !llvm.loop !23

37:                                               ; preds = %.preheader, %35
  %.03036 = phi i32 [ %31, %.preheader ], [ %36, %35 ]
  %38 = tail call i32 @P_BlockThingsIterator(i32 noundef %.03138, i32 noundef %.03036, ptr noundef nonnull @PIT_StompThing) #2
  %.not33 = icmp eq i32 %38, 0
  br i1 %.not33, label %.loopexit, label %35

._crit_edge:                                      ; preds = %35
  %39 = add nsw i32 %.03138, 1
  %exitcond43.not = icmp eq i32 %.03138, %26
  br i1 %exitcond43.not, label %._crit_edge39, label %.preheader, !llvm.loop !25

._crit_edge39:                                    ; preds = %._crit_edge, %3
  tail call void @P_UnsetThingPosition(ptr noundef %0) #2
  %40 = load i32, ptr @tmfloorz, align 4, !tbaa !15
  %41 = getelementptr inbounds i8, ptr %0, i64 96
  store i32 %40, ptr %41, align 8, !tbaa !26
  %42 = load i32, ptr @tmceilingz, align 4, !tbaa !15
  %43 = getelementptr inbounds i8, ptr %0, i64 100
  store i32 %42, ptr %43, align 4, !tbaa !27
  %44 = getelementptr inbounds i8, ptr %0, i64 24
  store i32 %1, ptr %44, align 8, !tbaa !28
  %45 = getelementptr inbounds i8, ptr %0, i64 28
  store i32 %2, ptr %45, align 4, !tbaa !29
  tail call void @P_SetThingPosition(ptr noundef %0) #2
  br label %.loopexit

.loopexit:                                        ; preds = %37, %._crit_edge39
  %.0 = phi i32 [ 1, %._crit_edge39 ], [ 0, %37 ]
  ret i32 %.0
}

declare ptr @R_PointInSubsector(i32 noundef, i32 noundef) local_unnamed_addr #1

declare i32 @P_BlockThingsIterator(i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

declare void @P_UnsetThingPosition(ptr noundef) local_unnamed_addr #1

declare void @P_SetThingPosition(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, !12, i64 160}
!10 = !{!"mobj_s", !11, i64 0, !12, i64 24, !12, i64 28, !12, i64 32, !6, i64 40, !6, i64 48, !12, i64 56, !12, i64 60, !12, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !12, i64 96, !12, i64 100, !12, i64 104, !12, i64 108, !12, i64 112, !12, i64 116, !12, i64 120, !12, i64 124, !12, i64 128, !6, i64 136, !12, i64 144, !6, i64 152, !12, i64 160, !12, i64 164, !12, i64 168, !12, i64 172, !6, i64 176, !12, i64 184, !12, i64 188, !6, i64 192, !12, i64 200, !13, i64 204, !6, i64 216}
!11 = !{!"thinker_s", !6, i64 0, !6, i64 8, !7, i64 16}
!12 = !{!"int", !7, i64 0}
!13 = !{!"", !14, i64 0, !14, i64 2, !14, i64 4, !14, i64 6, !14, i64 8}
!14 = !{!"short", !7, i64 0}
!15 = !{!12, !12, i64 0}
!16 = !{!10, !12, i64 104}
!17 = !{!18, !6, i64 0}
!18 = !{!"subsector_s", !6, i64 0, !14, i64 8, !14, i64 10}
!19 = !{!20, !12, i64 0}
!20 = !{!"", !12, i64 0, !12, i64 4, !14, i64 8, !14, i64 10, !14, i64 12, !14, i64 14, !14, i64 16, !12, i64 20, !6, i64 24, !7, i64 32, !21, i64 48, !12, i64 88, !6, i64 96, !6, i64 104, !12, i64 112, !6, i64 120}
!21 = !{!"", !11, i64 0, !12, i64 24, !12, i64 28, !12, i64 32}
!22 = !{!20, !12, i64 4}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}
!25 = distinct !{!25, !24}
!26 = !{!10, !12, i64 96}
!27 = !{!10, !12, i64 100}
!28 = !{!10, !12, i64 24}
!29 = !{!10, !12, i64 28}


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