; LLVM IR from blat-blatnik/GPU-Life :: main (onKey)

; 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.GLFWvidmode = type { i32, i32, i32, i32, i32, i32 }

@scale = external dso_local global float, align 4
@scaleX = external dso_local global float, align 4
@scaleY = external dso_local global float, align 4
@offsetX = external dso_local global float, align 4
@offsetY = external dso_local global float, align 4
@cellBorderIsOn = external dso_local global i8, align 1
@vsyncIsOn = external dso_local global i8, align 1
@backgroundColor = external dso_local global float, align 4
@deadColor = external dso_local global float, align 4
@aliveColor = external dso_local global float, align 4
@windowWidth = external dso_local global i32, align 4
@isRunning = external dso_local global 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: 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 void @updateCells() #1

; Function Attrs: nounwind uwtable
declare dso_local void @centerCellsOnScreen() #1

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare float @llvm.fmuladd.f32(float, float, float) #2

; Function Attrs: nounwind uwtable
declare dso_local void @clearCells() #1

; Function Attrs: nounwind uwtable
declare dso_local void @onMouseWheel(ptr noundef, double noundef, double noundef) #1

; Function Attrs: nounwind uwtable
define dso_local void @onKey(ptr noundef %0, i32 noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4) #1 {
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca ptr, align 8
  store ptr %0, ptr %6, align 8, !tbaa !5
  store i32 %1, ptr %7, align 4, !tbaa !9
  store i32 %2, ptr %8, align 4, !tbaa !9
  store i32 %3, ptr %9, align 4, !tbaa !9
  store i32 %4, ptr %10, align 4, !tbaa !9
  %19 = load i32, ptr %9, align 4, !tbaa !9
  %20 = icmp ne i32 %19, 1
  br i1 %20, label %21, label %25

21:                                               ; preds = %5
  %22 = load i32, ptr %9, align 4, !tbaa !9
  %23 = icmp ne i32 %22, 2
  br i1 %23, label %24, label %25

24:                                               ; preds = %21
  br label %129

25:                                               ; preds = %21, %5
  %26 = load i32, ptr %7, align 4, !tbaa !9
  switch i32 %26, label %128 [
    i32 256, label %27
    i32 257, label %44
    i32 284, label %44
    i32 67, label %50
    i32 268, label %50
    i32 66, label %51
    i32 86, label %57
    i32 61, label %65
    i32 334, label %65
    i32 45, label %67
    i32 333, label %67
    i32 263, label %69
    i32 262, label %76
    i32 265, label %82
    i32 264, label %88
    i32 76, label %95
    i32 68, label %96
    i32 32, label %97
    i32 335, label %97
    i32 46, label %97
    i32 258, label %97
    i32 83, label %97
    i32 300, label %98
    i32 70, label %98
    i32 259, label %127
    i32 261, label %127
  ]

27:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  %28 = load ptr, ptr %6, align 8, !tbaa !5
  %29 = call ptr @glfwGetWindowMonitor(ptr noundef %28)
  store ptr %29, ptr %11, align 8, !tbaa !5
  %30 = load ptr, ptr %11, align 8, !tbaa !5
  %31 = icmp ne ptr %30, null
  br i1 %31, label %32, label %41

32:                                               ; preds = %27
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  %33 = load ptr, ptr %11, align 8, !tbaa !5
  call void @glfwGetMonitorWorkarea(ptr noundef %33, ptr noundef null, ptr noundef null, ptr noundef %12, ptr noundef %13)
  %34 = load ptr, ptr %6, align 8, !tbaa !5
  %35 = load i32, ptr @windowWidth, align 4, !tbaa !9
  %36 = sub nsw i32 %35, 1280
  %37 = sdiv i32 %36, 2
  %38 = load i32, ptr %13, align 4, !tbaa !9
  %39 = sub nsw i32 %38, 720
  %40 = sdiv i32 %39, 2
  call void @glfwSetWindowMonitor(ptr noundef %34, ptr noundef null, i32 noundef %37, i32 noundef %40, i32 noundef 1280, i32 noundef 720, i32 noundef 60)
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  br label %43

41:                                               ; preds = %27
  %42 = load ptr, ptr %6, align 8, !tbaa !5
  call void @glfwSetWindowShouldClose(ptr noundef %42, i32 noundef 1)
  br label %43

43:                                               ; preds = %41, %32
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  br label %129

44:                                               ; preds = %25, %25
  %45 = load i8, ptr @isRunning, align 1, !tbaa !11
  %46 = icmp ne i8 %45, 0
  %47 = xor i1 %46, true
  %48 = zext i1 %47 to i32
  %49 = trunc i32 %48 to i8
  store i8 %49, ptr @isRunning, align 1, !tbaa !11
  br label %129

50:                                               ; preds = %25, %25
  call void @centerCellsOnScreen()
  br label %129

51:                                               ; preds = %25
  %52 = load i8, ptr @cellBorderIsOn, align 1, !tbaa !11
  %53 = icmp ne i8 %52, 0
  %54 = xor i1 %53, true
  %55 = zext i1 %54 to i32
  %56 = trunc i32 %55 to i8
  store i8 %56, ptr @cellBorderIsOn, align 1, !tbaa !11
  br label %129

57:                                               ; preds = %25
  %58 = load i8, ptr @vsyncIsOn, align 1, !tbaa !11
  %59 = icmp ne i8 %58, 0
  %60 = xor i1 %59, true
  %61 = zext i1 %60 to i32
  %62 = trunc i32 %61 to i8
  store i8 %62, ptr @vsyncIsOn, align 1, !tbaa !11
  %63 = load i8, ptr @vsyncIsOn, align 1, !tbaa !11
  %64 = zext i8 %63 to i32
  call void @glfwSwapInterval(i32 noundef %64)
  br label %129

65:                                               ; preds = %25, %25
  %66 = load ptr, ptr %6, align 8, !tbaa !5
  call void @onMouseWheel(ptr noundef %66, double noundef 0.000000e+00, double noundef 1.000000e+00)
  br label %129

67:                                               ; preds = %25, %25
  %68 = load ptr, ptr %6, align 8, !tbaa !5
  call void @onMouseWheel(ptr noundef %68, double noundef 0.000000e+00, double noundef -1.000000e+00)
  br label %129

69:                                               ; preds = %25
  %70 = load float, ptr @scale, align 4, !tbaa !12
  %71 = load float, ptr @scaleX, align 4, !tbaa !12
  %72 = fmul float %70, %71
  %73 = load float, ptr @offsetX, align 4, !tbaa !12
  %74 = fneg float %72
  %75 = call float @llvm.fmuladd.f32(float %74, float 0x3FA99999A0000000, float %73)
  store float %75, ptr @offsetX, align 4, !tbaa !12
  br label %129

76:                                               ; preds = %25
  %77 = load float, ptr @scale, align 4, !tbaa !12
  %78 = load float, ptr @scaleX, align 4, !tbaa !12
  %79 = fmul float %77, %78
  %80 = load float, ptr @offsetX, align 4, !tbaa !12
  %81 = call float @llvm.fmuladd.f32(float %79, float 0x3FA99999A0000000, float %80)
  store float %81, ptr @offsetX, align 4, !tbaa !12
  br label %129

82:                                               ; preds = %25
  %83 = load float, ptr @scale, align 4, !tbaa !12
  %84 = load float, ptr @scaleY, align 4, !tbaa !12
  %85 = fmul float %83, %84
  %86 = load float, ptr @offsetY, align 4, !tbaa !12
  %87 = call float @llvm.fmuladd.f32(float %85, float 0x3FA99999A0000000, float %86)
  store float %87, ptr @offsetY, align 4, !tbaa !12
  br label %129

88:                                               ; preds = %25
  %89 = load float, ptr @scale, align 4, !tbaa !12
  %90 = load float, ptr @scaleY, align 4, !tbaa !12
  %91 = fmul float %89, %90
  %92 = load float, ptr @offsetY, align 4, !tbaa !12
  %93 = fneg float %91
  %94 = call float @llvm.fmuladd.f32(float %93, float 0x3FA99999A0000000, float %92)
  store float %94, ptr @offsetY, align 4, !tbaa !12
  br label %129

95:                                               ; preds = %25
  store float 0x3FECCCCCC0000000, ptr @backgroundColor, align 4, !tbaa !12
  store float 1.000000e+00, ptr @deadColor, align 4, !tbaa !12
  store float 0.000000e+00, ptr @aliveColor, align 4, !tbaa !12
  br label %129

96:                                               ; preds = %25
  store float 0.000000e+00, ptr @backgroundColor, align 4, !tbaa !12
  store float 0x3FB99999A0000000, ptr @deadColor, align 4, !tbaa !12
  store float 1.000000e+00, ptr @aliveColor, align 4, !tbaa !12
  br label %129

97:                                               ; preds = %25, %25, %25, %25, %25
  call void @updateCells()
  br label %129

98:                                               ; preds = %25, %25
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #4
  %99 = load ptr, ptr %6, align 8, !tbaa !5
  %100 = call ptr @glfwGetWindowMonitor(ptr noundef %99)
  store ptr %100, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  %101 = call ptr @glfwGetPrimaryMonitor()
  store ptr %101, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #4
  %102 = load ptr, ptr %15, align 8, !tbaa !5
  call void @glfwGetMonitorWorkarea(ptr noundef %102, ptr noundef null, ptr noundef null, ptr noundef %16, ptr noundef %17)
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #4
  %103 = load ptr, ptr %15, align 8, !tbaa !5
  %104 = call ptr @glfwGetVideoMode(ptr noundef %103)
  store ptr %104, ptr %18, align 8, !tbaa !5
  %105 = load ptr, ptr %14, align 8, !tbaa !5
  %106 = icmp ne ptr %105, null
  br i1 %106, label %115, label %107

107:                                              ; preds = %98
  %108 = load ptr, ptr %6, align 8, !tbaa !5
  %109 = load ptr, ptr %15, align 8, !tbaa !5
  %110 = load i32, ptr %16, align 4, !tbaa !9
  %111 = load i32, ptr %17, align 4, !tbaa !9
  %112 = load ptr, ptr %18, align 8, !tbaa !5
  %113 = getelementptr inbounds %struct.GLFWvidmode, ptr %112, i32 0, i32 5
  %114 = load i32, ptr %113, align 4, !tbaa !14
  call void @glfwSetWindowMonitor(ptr noundef %108, ptr noundef %109, i32 noundef 0, i32 noundef 0, i32 noundef %110, i32 noundef %111, i32 noundef %114)
  br label %126

115:                                              ; preds = %98
  %116 = load ptr, ptr %6, align 8, !tbaa !5
  %117 = load i32, ptr %16, align 4, !tbaa !9
  %118 = sub nsw i32 %117, 1280
  %119 = sdiv i32 %118, 2
  %120 = load i32, ptr %17, align 4, !tbaa !9
  %121 = sub nsw i32 %120, 720
  %122 = sdiv i32 %121, 2
  %123 = load ptr, ptr %18, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.GLFWvidmode, ptr %123, i32 0, i32 5
  %125 = load i32, ptr %124, align 4, !tbaa !14
  call void @glfwSetWindowMonitor(ptr noundef %116, ptr noundef null, i32 noundef %119, i32 noundef %122, i32 noundef 1280, i32 noundef 720, i32 noundef %125)
  br label %126

126:                                              ; preds = %115, %107
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  br label %129

127:                                              ; preds = %25, %25
  call void @clearCells()
  br label %129

128:                                              ; preds = %25
  br label %129

129:                                              ; preds = %128, %127, %126, %97, %96, %95, %88, %82, %76, %69, %67, %65, %57, %51, %50, %44, %43, %24
  ret void
}

declare ptr @glfwGetWindowMonitor(ptr noundef) #3

declare void @glfwGetMonitorWorkarea(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #3

declare void @glfwSetWindowMonitor(ptr noundef, ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #3

declare void @glfwSetWindowShouldClose(ptr noundef, i32 noundef) #3

declare void @glfwSwapInterval(i32 noundef) #3

declare ptr @glfwGetPrimaryMonitor() #3

declare ptr @glfwGetVideoMode(ptr noundef) #3

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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 }

!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 = !{!7, !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"float", !7, i64 0}
!14 = !{!15, !10, i64 20}
!15 = !{!"GLFWvidmode", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20}


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

@scale = external dso_local local_unnamed_addr global float, align 4
@scaleX = external dso_local local_unnamed_addr global float, align 4
@scaleY = external dso_local local_unnamed_addr global float, align 4
@offsetX = external dso_local local_unnamed_addr global float, align 4
@offsetY = external dso_local local_unnamed_addr global float, align 4
@cellBorderIsOn = external dso_local local_unnamed_addr global i8, align 1
@vsyncIsOn = external dso_local local_unnamed_addr global i8, align 1
@backgroundColor = external dso_local local_unnamed_addr global float, align 4
@deadColor = external dso_local local_unnamed_addr global float, align 4
@aliveColor = external dso_local local_unnamed_addr global float, align 4
@windowWidth = external dso_local local_unnamed_addr global i32, align 4
@isRunning = external dso_local local_unnamed_addr global i8, align 1

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

; Function Attrs: mustprogress 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 void @updateCells() local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local void @centerCellsOnScreen() local_unnamed_addr #1

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare float @llvm.fmuladd.f32(float, float, float) #2

; Function Attrs: nounwind uwtable
declare dso_local void @clearCells() local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local void @onMouseWheel(ptr noundef, double noundef, double noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local void @onKey(ptr noundef %0, i32 noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4) local_unnamed_addr #1 {
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = add i32 %3, -3
  %or.cond = icmp ult i32 %10, -2
  br i1 %or.cond, label %83, label %11

11:                                               ; preds = %5
  switch i32 %1, label %83 [
    i32 256, label %12
    i32 257, label %22
    i32 284, label %22
    i32 67, label %25
    i32 268, label %25
    i32 66, label %26
    i32 86, label %29
    i32 61, label %33
    i32 334, label %33
    i32 45, label %34
    i32 333, label %34
    i32 263, label %35
    i32 262, label %42
    i32 265, label %48
    i32 264, label %54
    i32 76, label %61
    i32 68, label %62
    i32 32, label %63
    i32 335, label %63
    i32 46, label %63
    i32 258, label %63
    i32 83, label %63
    i32 300, label %64
    i32 70, label %64
    i32 259, label %82
    i32 261, label %82
  ]

12:                                               ; preds = %11
  %13 = tail call ptr @glfwGetWindowMonitor(ptr noundef %0) #4
  %.not22 = icmp eq ptr %13, null
  br i1 %.not22, label %21, label %14

14:                                               ; preds = %12
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #4
  call void @glfwGetMonitorWorkarea(ptr noundef nonnull %13, ptr noundef null, ptr noundef null, ptr noundef nonnull %6, ptr noundef nonnull %7) #4
  %15 = load i32, ptr @windowWidth, align 4, !tbaa !5
  %16 = add nsw i32 %15, -1280
  %17 = sdiv i32 %16, 2
  %18 = load i32, ptr %7, align 4, !tbaa !5
  %19 = add nsw i32 %18, -720
  %20 = sdiv i32 %19, 2
  call void @glfwSetWindowMonitor(ptr noundef %0, ptr noundef null, i32 noundef %17, i32 noundef %20, i32 noundef 1280, i32 noundef 720, i32 noundef 60) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #4
  br label %83

21:                                               ; preds = %12
  tail call void @glfwSetWindowShouldClose(ptr noundef %0, i32 noundef 1) #4
  br label %83

22:                                               ; preds = %11, %11
  %23 = load i8, ptr @isRunning, align 1, !tbaa !9
  %.not21 = icmp eq i8 %23, 0
  %24 = zext i1 %.not21 to i8
  store i8 %24, ptr @isRunning, align 1, !tbaa !9
  br label %83

25:                                               ; preds = %11, %11
  tail call void @centerCellsOnScreen()
  br label %83

26:                                               ; preds = %11
  %27 = load i8, ptr @cellBorderIsOn, align 1, !tbaa !9
  %.not20 = icmp eq i8 %27, 0
  %28 = zext i1 %.not20 to i8
  store i8 %28, ptr @cellBorderIsOn, align 1, !tbaa !9
  br label %83

29:                                               ; preds = %11
  %30 = load i8, ptr @vsyncIsOn, align 1, !tbaa !9
  %.not19 = icmp eq i8 %30, 0
  %31 = zext i1 %.not19 to i8
  store i8 %31, ptr @vsyncIsOn, align 1, !tbaa !9
  %32 = zext i1 %.not19 to i32
  tail call void @glfwSwapInterval(i32 noundef %32) #4
  br label %83

33:                                               ; preds = %11, %11
  tail call void @onMouseWheel(ptr noundef %0, double noundef 0.000000e+00, double noundef 1.000000e+00)
  br label %83

34:                                               ; preds = %11, %11
  tail call void @onMouseWheel(ptr noundef %0, double noundef 0.000000e+00, double noundef -1.000000e+00)
  br label %83

35:                                               ; preds = %11
  %36 = load float, ptr @scale, align 4, !tbaa !10
  %37 = load float, ptr @scaleX, align 4, !tbaa !10
  %38 = load float, ptr @offsetX, align 4, !tbaa !10
  %39 = fneg float %36
  %40 = fmul float %37, %39
  %41 = tail call float @llvm.fmuladd.f32(float %40, float 0x3FA99999A0000000, float %38)
  store float %41, ptr @offsetX, align 4, !tbaa !10
  br label %83

42:                                               ; preds = %11
  %43 = load float, ptr @scale, align 4, !tbaa !10
  %44 = load float, ptr @scaleX, align 4, !tbaa !10
  %45 = fmul float %43, %44
  %46 = load float, ptr @offsetX, align 4, !tbaa !10
  %47 = tail call float @llvm.fmuladd.f32(float %45, float 0x3FA99999A0000000, float %46)
  store float %47, ptr @offsetX, align 4, !tbaa !10
  br label %83

48:                                               ; preds = %11
  %49 = load float, ptr @scale, align 4, !tbaa !10
  %50 = load float, ptr @scaleY, align 4, !tbaa !10
  %51 = fmul float %49, %50
  %52 = load float, ptr @offsetY, align 4, !tbaa !10
  %53 = tail call float @llvm.fmuladd.f32(float %51, float 0x3FA99999A0000000, float %52)
  store float %53, ptr @offsetY, align 4, !tbaa !10
  br label %83

54:                                               ; preds = %11
  %55 = load float, ptr @scale, align 4, !tbaa !10
  %56 = load float, ptr @scaleY, align 4, !tbaa !10
  %57 = load float, ptr @offsetY, align 4, !tbaa !10
  %58 = fneg float %55
  %59 = fmul float %56, %58
  %60 = tail call float @llvm.fmuladd.f32(float %59, float 0x3FA99999A0000000, float %57)
  store float %60, ptr @offsetY, align 4, !tbaa !10
  br label %83

61:                                               ; preds = %11
  store float 0x3FECCCCCC0000000, ptr @backgroundColor, align 4, !tbaa !10
  store float 1.000000e+00, ptr @deadColor, align 4, !tbaa !10
  store float 0.000000e+00, ptr @aliveColor, align 4, !tbaa !10
  br label %83

62:                                               ; preds = %11
  store float 0.000000e+00, ptr @backgroundColor, align 4, !tbaa !10
  store float 0x3FB99999A0000000, ptr @deadColor, align 4, !tbaa !10
  store float 1.000000e+00, ptr @aliveColor, align 4, !tbaa !10
  br label %83

63:                                               ; preds = %11, %11, %11, %11, %11
  tail call void @updateCells()
  br label %83

64:                                               ; preds = %11, %11
  %65 = tail call ptr @glfwGetWindowMonitor(ptr noundef %0) #4
  %66 = tail call ptr @glfwGetPrimaryMonitor() #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %8) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #4
  call void @glfwGetMonitorWorkarea(ptr noundef %66, ptr noundef null, ptr noundef null, ptr noundef nonnull %8, ptr noundef nonnull %9) #4
  %67 = call ptr @glfwGetVideoMode(ptr noundef %66) #4
  %.not = icmp eq ptr %65, null
  %68 = load i32, ptr %8, align 4, !tbaa !5
  br i1 %.not, label %69, label %73

69:                                               ; preds = %64
  %70 = load i32, ptr %9, align 4, !tbaa !5
  %71 = getelementptr inbounds i8, ptr %67, i64 20
  %72 = load i32, ptr %71, align 4, !tbaa !12
  call void @glfwSetWindowMonitor(ptr noundef %0, ptr noundef %66, i32 noundef 0, i32 noundef 0, i32 noundef %68, i32 noundef %70, i32 noundef %72) #4
  br label %81

73:                                               ; preds = %64
  %74 = add nsw i32 %68, -1280
  %75 = sdiv i32 %74, 2
  %76 = load i32, ptr %9, align 4, !tbaa !5
  %77 = add nsw i32 %76, -720
  %78 = sdiv i32 %77, 2
  %79 = getelementptr inbounds i8, ptr %67, i64 20
  %80 = load i32, ptr %79, align 4, !tbaa !12
  call void @glfwSetWindowMonitor(ptr noundef %0, ptr noundef null, i32 noundef %75, i32 noundef %78, i32 noundef 1280, i32 noundef 720, i32 noundef %80) #4
  br label %81

81:                                               ; preds = %73, %69
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #4
  br label %83

82:                                               ; preds = %11, %11
  tail call void @clearCells()
  br label %83

83:                                               ; preds = %14, %21, %11, %5, %82, %81, %63, %62, %61, %54, %48, %42, %35, %34, %33, %29, %26, %25, %22
  ret void
}

declare ptr @glfwGetWindowMonitor(ptr noundef) local_unnamed_addr #3

declare void @glfwGetMonitorWorkarea(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @glfwSetWindowMonitor(ptr noundef, ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #3

declare void @glfwSetWindowShouldClose(ptr noundef, i32 noundef) local_unnamed_addr #3

declare void @glfwSwapInterval(i32 noundef) local_unnamed_addr #3

declare ptr @glfwGetPrimaryMonitor() local_unnamed_addr #3

declare ptr @glfwGetVideoMode(ptr noundef) local_unnamed_addr #3

attributes #0 = { mustprogress 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 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 }

!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 = !{!7, !7, i64 0}
!10 = !{!11, !11, i64 0}
!11 = !{!"float", !7, i64 0}
!12 = !{!13, !6, i64 20}
!13 = !{!"GLFWvidmode", !6, i64 0, !6, i64 4, !6, i64 8, !6, i64 12, !6, i64 16, !6, i64 20}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass