; LLVM IR from paroj/gltut :: Tut 09 Lights on/AmbientLighting.ll (Z7displayv)

; 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.ProgramData = type { i32, i32, i32, i32, i32, i32 }
%"class.glutil::ViewPole" = type <{ %"class.glutil::ViewProvider", %"struct.glutil::ViewData", %"struct.glutil::ViewScale", %"struct.glutil::ViewData", i32, i8, i8, [2 x i8], i32, float, %"struct.glm::detail::tvec2", %"struct.glm::detail::tquat", [4 x i8] }>
%"class.glutil::ViewProvider" = type { ptr }
%"struct.glutil::ViewScale" = type { float, float, float, float, float, float, float }
%"struct.glutil::ViewData" = type { %"struct.glm::detail::tvec3", %"struct.glm::detail::tquat", float, float }
%"struct.glm::detail::tvec3" = type { %union.anon.3 }
%union.anon.3 = type { %struct.anon }
%struct.anon = type { float, float, float }
%"struct.glm::detail::tvec2" = type { %union.anon.6 }
%union.anon.6 = type { %struct.anon.7 }
%struct.anon.7 = type { i32, i32 }
%"struct.glm::detail::tquat" = type { float, float, float, float }
%"class.glutil::ObjectPole" = type { ptr, %"struct.glutil::ObjectData", %"struct.glutil::ObjectData", float, i32, i32, i8, %"struct.glm::detail::tvec2", %"struct.glm::detail::tvec2", %"struct.glm::detail::tquat" }
%"struct.glutil::ObjectData" = type { %"struct.glm::detail::tvec3", %"struct.glm::detail::tquat" }
%"struct.glm::detail::tvec4" = type { %union.anon.10 }
%union.anon.10 = type { %struct.anon.11 }
%struct.anon.11 = type { float, float, float, float }
%"class.glutil::MatrixStack" = type { %"class.std::stack", %"struct.glm::detail::tmat4x4" }
%"class.std::stack" = type { %"class.std::vector.14" }
%"class.std::vector.14" = type { %"struct.std::_Vector_base.15" }
%"struct.std::_Vector_base.15" = type { %"struct.std::_Vector_base<glm::detail::tmat4x4<float>, std::allocator<glm::detail::tmat4x4<float>>>::_Vector_impl" }
%"struct.std::_Vector_base<glm::detail::tmat4x4<float>, std::allocator<glm::detail::tmat4x4<float>>>::_Vector_impl" = type { %"struct.std::_Vector_base<glm::detail::tmat4x4<float>, std::allocator<glm::detail::tmat4x4<float>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<glm::detail::tmat4x4<float>, std::allocator<glm::detail::tmat4x4<float>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.glm::detail::tmat4x4" = type { [4 x %"struct.glm::detail::tvec4"] }
%"class.glutil::PushStack" = type { ptr }
%"struct.glm::detail::tmat3x3" = type { [3 x %"struct.glm::detail::tvec3"] }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator.0" = type { i8 }

@g_WhiteDiffuseColor = external dso_local global %struct.ProgramData, align 4
@g_VertexDiffuseColor = external dso_local global %struct.ProgramData, align 4
@g_WhiteAmbDiffuseColor = external dso_local global %struct.ProgramData, align 4
@g_VertexAmbDiffuseColor = external dso_local global %struct.ProgramData, align 4
@g_pCylinderMesh = external dso_local global ptr, align 8
@g_pPlaneMesh = external dso_local global ptr, align 8
@g_viewPole = external dso_local global %"class.glutil::ViewPole", align 8
@g_objtPole = external dso_local global %"class.glutil::ObjectPole", align 8
@g_lightDirection = external dso_local global %"struct.glm::detail::tvec4", align 4
@_funcptr_glClearColor = external global ptr, align 8
@_funcptr_glClearDepth = external global ptr, align 8
@_funcptr_glClear = external global ptr, align 8
@_ZL14g_bShowAmbient = external hidden global i8, align 1
@_funcptr_glUseProgram = external global ptr, align 8
@_funcptr_glUniform4f = external global ptr, align 8
@_funcptr_glUniform3fv = external global ptr, align 8
@_funcptr_glUniformMatrix4fv = external global ptr, align 8
@_funcptr_glUniformMatrix3fv = external global ptr, align 8
@_ZL17g_bDrawColoredCyl = external hidden global i8, align 1
@.str.18 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [4 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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_Z7displayv() #2 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.glutil::MatrixStack", align 8
  %2 = alloca %"struct.glm::detail::tmat4x4", align 4
  %3 = alloca ptr, align 8
  %4 = alloca i32, align 4
  %5 = alloca %"struct.glm::detail::tvec4", align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca %"class.glutil::PushStack", align 8
  %9 = alloca %"class.glutil::PushStack", align 8
  %10 = alloca %"struct.glm::detail::tmat3x3", align 4
  %11 = alloca %"class.glutil::PushStack", align 8
  %12 = alloca %"struct.glm::detail::tmat4x4", align 4
  %13 = alloca %"struct.glm::detail::tmat3x3", align 4
  %14 = alloca %"class.std::__cxx11::basic_string", align 8
  %15 = alloca %"class.std::allocator.0", align 1
  %16 = alloca %"struct.glm::detail::tmat3x3", align 4
  %17 = alloca %"class.std::__cxx11::basic_string", align 8
  %18 = alloca %"class.std::allocator.0", align 1
  %19 = load ptr, ptr @_funcptr_glClearColor, align 8, !tbaa !5
  call void %19(float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %20 = load ptr, ptr @_funcptr_glClearDepth, align 8, !tbaa !5
  call void %20(double noundef 1.000000e+00)
  %21 = load ptr, ptr @_funcptr_glClear, align 8, !tbaa !5
  call void %21(i32 noundef 16640)
  %22 = load ptr, ptr @g_pPlaneMesh, align 8, !tbaa !5
  %23 = icmp ne ptr %22, null
  br i1 %23, label %24, label %297

24:                                               ; preds = %0
  %25 = load ptr, ptr @g_pCylinderMesh, align 8, !tbaa !5
  %26 = icmp ne ptr %25, null
  br i1 %26, label %27, label %297

27:                                               ; preds = %24
  call void @llvm.lifetime.start.p0(i64 88, ptr %1) #6
  call void @_ZN6glutil11MatrixStackC2Ev(ptr noundef nonnull align 8 dereferenceable(88) %1)
  call void @llvm.lifetime.start.p0(i64 64, ptr %2) #6
  invoke void @_ZNK6glutil8ViewPole10CalcMatrixEv(ptr dead_on_unwind writable sret(%"struct.glm::detail::tmat4x4") align 4 %2, ptr noundef nonnull align 8 dereferenceable(148) @g_viewPole)
          to label %28 unwind label %78

28:                                               ; preds = %27
  invoke void @_ZN6glutil11MatrixStack9SetMatrixERKN3glm6detail7tmat4x4IfEE(ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 4 dereferenceable(64) %2)
          to label %29 unwind label %78

29:                                               ; preds = %28
  call void @llvm.lifetime.end.p0(i64 64, ptr %2) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr %5) #6
  %30 = invoke noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %31 unwind label %82

31:                                               ; preds = %29
  invoke void @_ZN3glm6detailmlIfEENS0_7tmat4x4IT_E8col_typeERKS4_RKNS4_8row_typeE(ptr dead_on_unwind writable sret(%"struct.glm::detail::tvec4") align 4 %5, ptr noundef nonnull align 4 dereferenceable(64) %30, ptr noundef nonnull align 4 dereferenceable(16) @g_lightDirection)
          to label %32 unwind label %82

32:                                               ; preds = %31
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #6
  %33 = load i8, ptr @_ZL14g_bShowAmbient, align 1, !tbaa !9, !range !11, !noundef !12
  %34 = trunc i8 %33 to i1
  br i1 %34, label %35, label %36

35:                                               ; preds = %32
  br label %37

36:                                               ; preds = %32
  br label %37

37:                                               ; preds = %36, %35
  %38 = phi ptr [ @g_WhiteAmbDiffuseColor, %35 ], [ @g_WhiteDiffuseColor, %36 ]
  store ptr %38, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #6
  %39 = load i8, ptr @_ZL14g_bShowAmbient, align 1, !tbaa !9, !range !11, !noundef !12
  %40 = trunc i8 %39 to i1
  br i1 %40, label %41, label %42

41:                                               ; preds = %37
  br label %43

42:                                               ; preds = %37
  br label %43

43:                                               ; preds = %42, %41
  %44 = phi ptr [ @g_VertexAmbDiffuseColor, %41 ], [ @g_VertexDiffuseColor, %42 ]
  store ptr %44, ptr %7, align 8, !tbaa !5
  %45 = load i8, ptr @_ZL14g_bShowAmbient, align 1, !tbaa !9, !range !11, !noundef !12
  %46 = trunc i8 %45 to i1
  br i1 %46, label %47, label %90

47:                                               ; preds = %43
  %48 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %49 = load ptr, ptr %6, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.ProgramData, ptr %49, i32 0, i32 0
  %51 = load i32, ptr %50, align 4, !tbaa !13
  invoke void %48(i32 noundef %51)
          to label %52 unwind label %86

52:                                               ; preds = %47
  %53 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %54 = load ptr, ptr %6, align 8, !tbaa !5
  %55 = getelementptr inbounds %struct.ProgramData, ptr %54, i32 0, i32 2
  %56 = load i32, ptr %55, align 4, !tbaa !16
  invoke void %53(i32 noundef %56, float noundef 0x3FE99999A0000000, float noundef 0x3FE99999A0000000, float noundef 0x3FE99999A0000000, float noundef 1.000000e+00)
          to label %57 unwind label %86

57:                                               ; preds = %52
  %58 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %59 = load ptr, ptr %6, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.ProgramData, ptr %59, i32 0, i32 3
  %61 = load i32, ptr %60, align 4, !tbaa !17
  invoke void %58(i32 noundef %61, float noundef 0x3FC99999A0000000, float noundef 0x3FC99999A0000000, float noundef 0x3FC99999A0000000, float noundef 1.000000e+00)
          to label %62 unwind label %86

62:                                               ; preds = %57
  %63 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %64 = load ptr, ptr %7, align 8, !tbaa !5
  %65 = getelementptr inbounds %struct.ProgramData, ptr %64, i32 0, i32 0
  %66 = load i32, ptr %65, align 4, !tbaa !13
  invoke void %63(i32 noundef %66)
          to label %67 unwind label %86

67:                                               ; preds = %62
  %68 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %69 = load ptr, ptr %7, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.ProgramData, ptr %69, i32 0, i32 2
  %71 = load i32, ptr %70, align 4, !tbaa !16
  invoke void %68(i32 noundef %71, float noundef 0x3FE99999A0000000, float noundef 0x3FE99999A0000000, float noundef 0x3FE99999A0000000, float noundef 1.000000e+00)
          to label %72 unwind label %86

72:                                               ; preds = %67
  %73 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %74 = load ptr, ptr %7, align 8, !tbaa !5
  %75 = getelementptr inbounds %struct.ProgramData, ptr %74, i32 0, i32 3
  %76 = load i32, ptr %75, align 4, !tbaa !17
  invoke void %73(i32 noundef %76, float noundef 0x3FC99999A0000000, float noundef 0x3FC99999A0000000, float noundef 0x3FC99999A0000000, float noundef 1.000000e+00)
          to label %77 unwind label %86

77:                                               ; preds = %72
  br label %111

78:                                               ; preds = %28, %27
  %79 = landingpad { ptr, i32 }
          cleanup
  %80 = extractvalue { ptr, i32 } %79, 0
  store ptr %80, ptr %3, align 8
  %81 = extractvalue { ptr, i32 } %79, 1
  store i32 %81, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 64, ptr %2) #6
  br label %296

82:                                               ; preds = %31, %29
  %83 = landingpad { ptr, i32 }
          cleanup
  %84 = extractvalue { ptr, i32 } %83, 0
  store ptr %84, ptr %3, align 8
  %85 = extractvalue { ptr, i32 } %83, 1
  store i32 %85, ptr %4, align 4
  br label %295

86:                                               ; preds = %135, %134, %128, %123, %122, %116, %111, %105, %100, %95, %90, %72, %67, %62, %57, %52, %47
  %87 = landingpad { ptr, i32 }
          cleanup
  %88 = extractvalue { ptr, i32 } %87, 0
  store ptr %88, ptr %3, align 8
  %89 = extractvalue { ptr, i32 } %87, 1
  store i32 %89, ptr %4, align 4
  br label %294

90:                                               ; preds = %43
  %91 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %92 = load ptr, ptr %6, align 8, !tbaa !5
  %93 = getelementptr inbounds %struct.ProgramData, ptr %92, i32 0, i32 0
  %94 = load i32, ptr %93, align 4, !tbaa !13
  invoke void %91(i32 noundef %94)
          to label %95 unwind label %86

95:                                               ; preds = %90
  %96 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %97 = load ptr, ptr %6, align 8, !tbaa !5
  %98 = getelementptr inbounds %struct.ProgramData, ptr %97, i32 0, i32 2
  %99 = load i32, ptr %98, align 4, !tbaa !16
  invoke void %96(i32 noundef %99, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00)
          to label %100 unwind label %86

100:                                              ; preds = %95
  %101 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %102 = load ptr, ptr %7, align 8, !tbaa !5
  %103 = getelementptr inbounds %struct.ProgramData, ptr %102, i32 0, i32 0
  %104 = load i32, ptr %103, align 4, !tbaa !13
  invoke void %101(i32 noundef %104)
          to label %105 unwind label %86

105:                                              ; preds = %100
  %106 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %107 = load ptr, ptr %7, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.ProgramData, ptr %107, i32 0, i32 2
  %109 = load i32, ptr %108, align 4, !tbaa !16
  invoke void %106(i32 noundef %109, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00)
          to label %110 unwind label %86

110:                                              ; preds = %105
  br label %111

111:                                              ; preds = %110, %77
  %112 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %113 = load ptr, ptr %6, align 8, !tbaa !5
  %114 = getelementptr inbounds %struct.ProgramData, ptr %113, i32 0, i32 0
  %115 = load i32, ptr %114, align 4, !tbaa !13
  invoke void %112(i32 noundef %115)
          to label %116 unwind label %86

116:                                              ; preds = %111
  %117 = load ptr, ptr @_funcptr_glUniform3fv, align 8, !tbaa !5
  %118 = load ptr, ptr %6, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.ProgramData, ptr %118, i32 0, i32 1
  %120 = load i32, ptr %119, align 4, !tbaa !18
  %121 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail5tvec4IS1_EE(ptr noundef nonnull align 4 dereferenceable(16) %5)
          to label %122 unwind label %86

122:                                              ; preds = %116
  invoke void %117(i32 noundef %120, i32 noundef 1, ptr noundef %121)
          to label %123 unwind label %86

123:                                              ; preds = %122
  %124 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %125 = load ptr, ptr %7, align 8, !tbaa !5
  %126 = getelementptr inbounds %struct.ProgramData, ptr %125, i32 0, i32 0
  %127 = load i32, ptr %126, align 4, !tbaa !13
  invoke void %124(i32 noundef %127)
          to label %128 unwind label %86

128:                                              ; preds = %123
  %129 = load ptr, ptr @_funcptr_glUniform3fv, align 8, !tbaa !5
  %130 = load ptr, ptr %7, align 8, !tbaa !5
  %131 = getelementptr inbounds %struct.ProgramData, ptr %130, i32 0, i32 1
  %132 = load i32, ptr %131, align 4, !tbaa !18
  %133 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail5tvec4IS1_EE(ptr noundef nonnull align 4 dereferenceable(16) %5)
          to label %134 unwind label %86

134:                                              ; preds = %128
  invoke void %129(i32 noundef %132, i32 noundef 1, ptr noundef %133)
          to label %135 unwind label %86

135:                                              ; preds = %134
  %136 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  invoke void %136(i32 noundef 0)
          to label %137 unwind label %86

137:                                              ; preds = %135
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #6
  invoke void @_ZN6glutil9PushStackC2ERNS_11MatrixStackE(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %138 unwind label %201

138:                                              ; preds = %137
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  invoke void @_ZN6glutil9PushStackC2ERNS_11MatrixStackE(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %139 unwind label %205

139:                                              ; preds = %138
  %140 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %141 = load ptr, ptr %6, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.ProgramData, ptr %141, i32 0, i32 0
  %143 = load i32, ptr %142, align 4, !tbaa !13
  invoke void %140(i32 noundef %143)
          to label %144 unwind label %209

144:                                              ; preds = %139
  %145 = load ptr, ptr @_funcptr_glUniformMatrix4fv, align 8, !tbaa !5
  %146 = load ptr, ptr %6, align 8, !tbaa !5
  %147 = getelementptr inbounds %struct.ProgramData, ptr %146, i32 0, i32 4
  %148 = load i32, ptr %147, align 4, !tbaa !19
  %149 = invoke noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %150 unwind label %209

150:                                              ; preds = %144
  %151 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPKT_RKNS_6detail7tmat4x4IS1_EE(ptr noundef nonnull align 4 dereferenceable(64) %149)
          to label %152 unwind label %209

152:                                              ; preds = %150
  invoke void %145(i32 noundef %148, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %151)
          to label %153 unwind label %209

153:                                              ; preds = %152
  call void @llvm.lifetime.start.p0(i64 36, ptr %10) #6
  %154 = invoke noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %155 unwind label %213

155:                                              ; preds = %153
  invoke void @_ZN3glm6detail7tmat3x3IfEC2ERKNS0_7tmat4x4IfEE(ptr noundef nonnull align 4 dereferenceable(36) %10, ptr noundef nonnull align 4 dereferenceable(64) %154)
          to label %156 unwind label %213

156:                                              ; preds = %155
  %157 = load ptr, ptr @_funcptr_glUniformMatrix3fv, align 8, !tbaa !5
  %158 = load ptr, ptr %6, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.ProgramData, ptr %158, i32 0, i32 5
  %160 = load i32, ptr %159, align 4, !tbaa !20
  %161 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail7tmat3x3IS1_EE(ptr noundef nonnull align 4 dereferenceable(36) %10)
          to label %162 unwind label %213

162:                                              ; preds = %156
  invoke void %157(i32 noundef %160, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %161)
          to label %163 unwind label %213

163:                                              ; preds = %162
  %164 = load ptr, ptr @g_pPlaneMesh, align 8, !tbaa !5
  invoke void @_ZNK9Framework4Mesh6RenderEv(ptr noundef nonnull align 8 dereferenceable(8) %164)
          to label %165 unwind label %213

165:                                              ; preds = %163
  %166 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  invoke void %166(i32 noundef 0)
          to label %167 unwind label %213

167:                                              ; preds = %165
  call void @llvm.lifetime.end.p0(i64 36, ptr %10) #6
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  invoke void @_ZN6glutil9PushStackC2ERNS_11MatrixStackE(ptr noundef nonnull align 8 dereferenceable(8) %11, ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %168 unwind label %219

168:                                              ; preds = %167
  call void @llvm.lifetime.start.p0(i64 64, ptr %12) #6
  invoke void @_ZNK6glutil10ObjectPole10CalcMatrixEv(ptr dead_on_unwind writable sret(%"struct.glm::detail::tmat4x4") align 4 %12, ptr noundef nonnull align 8 dereferenceable(112) @g_objtPole)
          to label %169 unwind label %223

169:                                              ; preds = %168
  invoke void @_ZN6glutil11MatrixStack11ApplyMatrixERKN3glm6detail7tmat4x4IfEE(ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 4 dereferenceable(64) %12)
          to label %170 unwind label %223

170:                                              ; preds = %169
  call void @llvm.lifetime.end.p0(i64 64, ptr %12) #6
  %171 = load i8, ptr @_ZL17g_bDrawColoredCyl, align 1, !tbaa !9, !range !11, !noundef !12
  %172 = trunc i8 %171 to i1
  br i1 %172, label %173, label %245

173:                                              ; preds = %170
  %174 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %175 = load ptr, ptr %7, align 8, !tbaa !5
  %176 = getelementptr inbounds %struct.ProgramData, ptr %175, i32 0, i32 0
  %177 = load i32, ptr %176, align 4, !tbaa !13
  invoke void %174(i32 noundef %177)
          to label %178 unwind label %227

178:                                              ; preds = %173
  %179 = load ptr, ptr @_funcptr_glUniformMatrix4fv, align 8, !tbaa !5
  %180 = load ptr, ptr %7, align 8, !tbaa !5
  %181 = getelementptr inbounds %struct.ProgramData, ptr %180, i32 0, i32 4
  %182 = load i32, ptr %181, align 4, !tbaa !19
  %183 = invoke noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %184 unwind label %227

184:                                              ; preds = %178
  %185 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPKT_RKNS_6detail7tmat4x4IS1_EE(ptr noundef nonnull align 4 dereferenceable(64) %183)
          to label %186 unwind label %227

186:                                              ; preds = %184
  invoke void %179(i32 noundef %182, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %185)
          to label %187 unwind label %227

187:                                              ; preds = %186
  call void @llvm.lifetime.start.p0(i64 36, ptr %13) #6
  %188 = invoke noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %189 unwind label %231

189:                                              ; preds = %187
  invoke void @_ZN3glm6detail7tmat3x3IfEC2ERKNS0_7tmat4x4IfEE(ptr noundef nonnull align 4 dereferenceable(36) %13, ptr noundef nonnull align 4 dereferenceable(64) %188)
          to label %190 unwind label %231

190:                                              ; preds = %189
  %191 = load ptr, ptr @_funcptr_glUniformMatrix3fv, align 8, !tbaa !5
  %192 = load ptr, ptr %7, align 8, !tbaa !5
  %193 = getelementptr inbounds %struct.ProgramData, ptr %192, i32 0, i32 5
  %194 = load i32, ptr %193, align 4, !tbaa !20
  %195 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail7tmat3x3IS1_EE(ptr noundef nonnull align 4 dereferenceable(36) %13)
          to label %196 unwind label %231

196:                                              ; preds = %190
  invoke void %191(i32 noundef %194, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %195)
          to label %197 unwind label %231

197:                                              ; preds = %196
  %198 = load ptr, ptr @g_pCylinderMesh, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %14) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %15) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %15) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %14, ptr noundef @.str.18, ptr noundef nonnull align 1 dereferenceable(1) %15)
          to label %199 unwind label %235

199:                                              ; preds = %197
  invoke void @_ZNK9Framework4Mesh6RenderERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(8) %198, ptr noundef nonnull align 8 dereferenceable(32) %14)
          to label %200 unwind label %239

200:                                              ; preds = %199
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %14) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %15) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 36, ptr %13) #6
  br label %287

201:                                              ; preds = %137
  %202 = landingpad { ptr, i32 }
          cleanup
  %203 = extractvalue { ptr, i32 } %202, 0
  store ptr %203, ptr %3, align 8
  %204 = extractvalue { ptr, i32 } %202, 1
  store i32 %204, ptr %4, align 4
  br label %293

205:                                              ; preds = %138
  %206 = landingpad { ptr, i32 }
          cleanup
  %207 = extractvalue { ptr, i32 } %206, 0
  store ptr %207, ptr %3, align 8
  %208 = extractvalue { ptr, i32 } %206, 1
  store i32 %208, ptr %4, align 4
  br label %218

209:                                              ; preds = %152, %150, %144, %139
  %210 = landingpad { ptr, i32 }
          cleanup
  %211 = extractvalue { ptr, i32 } %210, 0
  store ptr %211, ptr %3, align 8
  %212 = extractvalue { ptr, i32 } %210, 1
  store i32 %212, ptr %4, align 4
  br label %217

213:                                              ; preds = %165, %163, %162, %156, %155, %153
  %214 = landingpad { ptr, i32 }
          cleanup
  %215 = extractvalue { ptr, i32 } %214, 0
  store ptr %215, ptr %3, align 8
  %216 = extractvalue { ptr, i32 } %214, 1
  store i32 %216, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 36, ptr %10) #6
  br label %217

217:                                              ; preds = %213, %209
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %9) #6
  br label %218

218:                                              ; preds = %217, %205
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  br label %292

219:                                              ; preds = %167
  %220 = landingpad { ptr, i32 }
          cleanup
  %221 = extractvalue { ptr, i32 } %220, 0
  store ptr %221, ptr %3, align 8
  %222 = extractvalue { ptr, i32 } %220, 1
  store i32 %222, ptr %4, align 4
  br label %291

223:                                              ; preds = %169, %168
  %224 = landingpad { ptr, i32 }
          cleanup
  %225 = extractvalue { ptr, i32 } %224, 0
  store ptr %225, ptr %3, align 8
  %226 = extractvalue { ptr, i32 } %224, 1
  store i32 %226, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 64, ptr %12) #6
  br label %290

227:                                              ; preds = %287, %258, %256, %250, %245, %186, %184, %178, %173
  %228 = landingpad { ptr, i32 }
          cleanup
  %229 = extractvalue { ptr, i32 } %228, 0
  store ptr %229, ptr %3, align 8
  %230 = extractvalue { ptr, i32 } %228, 1
  store i32 %230, ptr %4, align 4
  br label %290

231:                                              ; preds = %196, %190, %189, %187
  %232 = landingpad { ptr, i32 }
          cleanup
  %233 = extractvalue { ptr, i32 } %232, 0
  store ptr %233, ptr %3, align 8
  %234 = extractvalue { ptr, i32 } %232, 1
  store i32 %234, ptr %4, align 4
  br label %244

235:                                              ; preds = %197
  %236 = landingpad { ptr, i32 }
          cleanup
  %237 = extractvalue { ptr, i32 } %236, 0
  store ptr %237, ptr %3, align 8
  %238 = extractvalue { ptr, i32 } %236, 1
  store i32 %238, ptr %4, align 4
  br label %243

239:                                              ; preds = %199
  %240 = landingpad { ptr, i32 }
          cleanup
  %241 = extractvalue { ptr, i32 } %240, 0
  store ptr %241, ptr %3, align 8
  %242 = extractvalue { ptr, i32 } %240, 1
  store i32 %242, ptr %4, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %14) #6
  br label %243

243:                                              ; preds = %239, %235
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %15) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %14) #6
  br label %244

244:                                              ; preds = %243, %231
  call void @llvm.lifetime.end.p0(i64 36, ptr %13) #6
  br label %290

245:                                              ; preds = %170
  %246 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %247 = load ptr, ptr %6, align 8, !tbaa !5
  %248 = getelementptr inbounds %struct.ProgramData, ptr %247, i32 0, i32 0
  %249 = load i32, ptr %248, align 4, !tbaa !13
  invoke void %246(i32 noundef %249)
          to label %250 unwind label %227

250:                                              ; preds = %245
  %251 = load ptr, ptr @_funcptr_glUniformMatrix4fv, align 8, !tbaa !5
  %252 = load ptr, ptr %6, align 8, !tbaa !5
  %253 = getelementptr inbounds %struct.ProgramData, ptr %252, i32 0, i32 4
  %254 = load i32, ptr %253, align 4, !tbaa !19
  %255 = invoke noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %256 unwind label %227

256:                                              ; preds = %250
  %257 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPKT_RKNS_6detail7tmat4x4IS1_EE(ptr noundef nonnull align 4 dereferenceable(64) %255)
          to label %258 unwind label %227

258:                                              ; preds = %256
  invoke void %251(i32 noundef %254, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %257)
          to label %259 unwind label %227

259:                                              ; preds = %258
  call void @llvm.lifetime.start.p0(i64 36, ptr %16) #6
  %260 = invoke noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %261 unwind label %273

261:                                              ; preds = %259
  invoke void @_ZN3glm6detail7tmat3x3IfEC2ERKNS0_7tmat4x4IfEE(ptr noundef nonnull align 4 dereferenceable(36) %16, ptr noundef nonnull align 4 dereferenceable(64) %260)
          to label %262 unwind label %273

262:                                              ; preds = %261
  %263 = load ptr, ptr @_funcptr_glUniformMatrix3fv, align 8, !tbaa !5
  %264 = load ptr, ptr %6, align 8, !tbaa !5
  %265 = getelementptr inbounds %struct.ProgramData, ptr %264, i32 0, i32 5
  %266 = load i32, ptr %265, align 4, !tbaa !20
  %267 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail7tmat3x3IS1_EE(ptr noundef nonnull align 4 dereferenceable(36) %16)
          to label %268 unwind label %273

268:                                              ; preds = %262
  invoke void %263(i32 noundef %266, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %267)
          to label %269 unwind label %273

269:                                              ; preds = %268
  %270 = load ptr, ptr @g_pCylinderMesh, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %17) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %18) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %17, ptr noundef @.str.19, ptr noundef nonnull align 1 dereferenceable(1) %18)
          to label %271 unwind label %277

271:                                              ; preds = %269
  invoke void @_ZNK9Framework4Mesh6RenderERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(8) %270, ptr noundef nonnull align 8 dereferenceable(32) %17)
          to label %272 unwind label %281

272:                                              ; preds = %271
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #6
  call void @llvm.lifetime.end.p0(i64 36, ptr %16) #6
  br label %287

273:                                              ; preds = %268, %262, %261, %259
  %274 = landingpad { ptr, i32 }
          cleanup
  %275 = extractvalue { ptr, i32 } %274, 0
  store ptr %275, ptr %3, align 8
  %276 = extractvalue { ptr, i32 } %274, 1
  store i32 %276, ptr %4, align 4
  br label %286

277:                                              ; preds = %269
  %278 = landingpad { ptr, i32 }
          cleanup
  %279 = extractvalue { ptr, i32 } %278, 0
  store ptr %279, ptr %3, align 8
  %280 = extractvalue { ptr, i32 } %278, 1
  store i32 %280, ptr %4, align 4
  br label %285

281:                                              ; preds = %271
  %282 = landingpad { ptr, i32 }
          cleanup
  %283 = extractvalue { ptr, i32 } %282, 0
  store ptr %283, ptr %3, align 8
  %284 = extractvalue { ptr, i32 } %282, 1
  store i32 %284, ptr %4, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #6
  br label %285

285:                                              ; preds = %281, %277
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %18) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #6
  br label %286

286:                                              ; preds = %285, %273
  call void @llvm.lifetime.end.p0(i64 36, ptr %16) #6
  br label %290

287:                                              ; preds = %272, %200
  %288 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  invoke void %288(i32 noundef 0)
          to label %289 unwind label %227

289:                                              ; preds = %287
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %5) #6
  call void @_ZN6glutil11MatrixStackD2Ev(ptr noundef nonnull align 8 dereferenceable(88) %1) #6
  call void @llvm.lifetime.end.p0(i64 88, ptr %1) #6
  br label %297

290:                                              ; preds = %286, %244, %227, %223
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %11) #6
  br label %291

291:                                              ; preds = %290, %219
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  br label %292

292:                                              ; preds = %291, %218
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %8) #6
  br label %293

293:                                              ; preds = %292, %201
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  br label %294

294:                                              ; preds = %293, %86
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #6
  br label %295

295:                                              ; preds = %294, %82
  call void @llvm.lifetime.end.p0(i64 16, ptr %5) #6
  br label %296

296:                                              ; preds = %295, %78
  call void @_ZN6glutil11MatrixStackD2Ev(ptr noundef nonnull align 8 dereferenceable(88) %1) #6
  call void @llvm.lifetime.end.p0(i64 88, ptr %1) #6
  br label %298

297:                                              ; preds = %289, %24, %0
  call void @glutSwapBuffers()
  ret void

298:                                              ; preds = %296
  %299 = load ptr, ptr %3, align 8
  %300 = load i32, ptr %4, align 4
  %301 = insertvalue { ptr, i32 } poison, ptr %299, 0
  %302 = insertvalue { ptr, i32 } %301, i32 %300, 1
  resume { ptr, i32 } %302
}

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6glutil11MatrixStackC2Ev(ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #2 align 2

declare void @_ZN6glutil11MatrixStack9SetMatrixERKN3glm6detail7tmat4x4IfEE(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 4 dereferenceable(64)) #3

declare void @_ZNK6glutil8ViewPole10CalcMatrixEv(ptr dead_on_unwind writable sret(%"struct.glm::detail::tmat4x4") align 4, ptr noundef nonnull align 8 dereferenceable(148)) unnamed_addr #3

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3glm6detailmlIfEENS0_7tmat4x4IT_E8col_typeERKS4_RKNS4_8row_typeE(ptr dead_on_unwind noalias writable sret(%"struct.glm::detail::tvec4") align 4, ptr noundef nonnull align 4 dereferenceable(64), ptr noundef nonnull align 4 dereferenceable(16)) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88)) #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail5tvec4IS1_EE(ptr noundef nonnull align 4 dereferenceable(16)) #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6glutil9PushStackC2ERNS_11MatrixStackE(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN3glm9value_ptrIfEEPKT_RKNS_6detail7tmat4x4IS1_EE(ptr noundef nonnull align 4 dereferenceable(64)) #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3glm6detail7tmat3x3IfEC2ERKNS0_7tmat4x4IfEE(ptr noundef nonnull align 4 dereferenceable(36), ptr noundef nonnull align 4 dereferenceable(64)) unnamed_addr #4 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail7tmat3x3IS1_EE(ptr noundef nonnull align 4 dereferenceable(36)) #4

declare void @_ZNK9Framework4Mesh6RenderEv(ptr noundef nonnull align 8 dereferenceable(8)) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #1 align 2

declare void @_ZN6glutil11MatrixStack11ApplyMatrixERKN3glm6detail7tmat4x4IfEE(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 4 dereferenceable(64)) #3

declare void @_ZNK6glutil10ObjectPole10CalcMatrixEv(ptr dead_on_unwind writable sret(%"struct.glm::detail::tmat4x4") align 4, ptr noundef nonnull align 8 dereferenceable(112)) #3

declare void @_ZNK9Framework4Mesh6RenderERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(32)) #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN6glutil11MatrixStackD2Ev(ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #5 align 2

declare void @glutSwapBuffers() #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress 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 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 = { inlinehint mustprogress 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 #5 = { inlinehint mustprogress 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 #6 = { 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++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = !{i8 0, i8 2}
!12 = !{}
!13 = !{!14, !15, i64 0}
!14 = !{!"_ZTS11ProgramData", !15, i64 0, !15, i64 4, !15, i64 8, !15, i64 12, !15, i64 16, !15, i64 20}
!15 = !{!"int", !7, i64 0}
!16 = !{!14, !15, i64 8}
!17 = !{!14, !15, i64 12}
!18 = !{!14, !15, i64 4}
!19 = !{!14, !15, i64 16}
!20 = !{!14, !15, 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"

%struct.ProgramData = type { i32, i32, i32, i32, i32, i32 }
%"class.glutil::ViewPole" = type <{ %"class.glutil::ViewProvider", %"struct.glutil::ViewData", %"struct.glutil::ViewScale", %"struct.glutil::ViewData", i32, i8, i8, [2 x i8], i32, float, %"struct.glm::detail::tvec2", %"struct.glm::detail::tquat", [4 x i8] }>
%"class.glutil::ViewProvider" = type { ptr }
%"struct.glutil::ViewScale" = type { float, float, float, float, float, float, float }
%"struct.glutil::ViewData" = type { %"struct.glm::detail::tvec3", %"struct.glm::detail::tquat", float, float }
%"struct.glm::detail::tvec3" = type { %union.anon.3 }
%union.anon.3 = type { %struct.anon }
%struct.anon = type { float, float, float }
%"struct.glm::detail::tvec2" = type { %union.anon.6 }
%union.anon.6 = type { %struct.anon.7 }
%struct.anon.7 = type { i32, i32 }
%"struct.glm::detail::tquat" = type { float, float, float, float }
%"class.glutil::ObjectPole" = type { ptr, %"struct.glutil::ObjectData", %"struct.glutil::ObjectData", float, i32, i32, i8, %"struct.glm::detail::tvec2", %"struct.glm::detail::tvec2", %"struct.glm::detail::tquat" }
%"struct.glutil::ObjectData" = type { %"struct.glm::detail::tvec3", %"struct.glm::detail::tquat" }
%"struct.glm::detail::tvec4" = type { %union.anon.10 }
%union.anon.10 = type { %struct.anon.11 }
%struct.anon.11 = type { float, float, float, float }
%"class.glutil::MatrixStack" = type { %"class.std::stack", %"struct.glm::detail::tmat4x4" }
%"class.std::stack" = type { %"class.std::vector.14" }
%"class.std::vector.14" = type { %"struct.std::_Vector_base.15" }
%"struct.std::_Vector_base.15" = type { %"struct.std::_Vector_base<glm::detail::tmat4x4<float>, std::allocator<glm::detail::tmat4x4<float>>>::_Vector_impl" }
%"struct.std::_Vector_base<glm::detail::tmat4x4<float>, std::allocator<glm::detail::tmat4x4<float>>>::_Vector_impl" = type { %"struct.std::_Vector_base<glm::detail::tmat4x4<float>, std::allocator<glm::detail::tmat4x4<float>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<glm::detail::tmat4x4<float>, std::allocator<glm::detail::tmat4x4<float>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.glm::detail::tmat4x4" = type { [4 x %"struct.glm::detail::tvec4"] }
%"class.glutil::PushStack" = type { ptr }
%"struct.glm::detail::tmat3x3" = type { [3 x %"struct.glm::detail::tvec3"] }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator.0" = type { i8 }

@g_WhiteDiffuseColor = external dso_local local_unnamed_addr global %struct.ProgramData, align 4
@g_VertexDiffuseColor = external dso_local local_unnamed_addr global %struct.ProgramData, align 4
@g_WhiteAmbDiffuseColor = external dso_local local_unnamed_addr global %struct.ProgramData, align 4
@g_VertexAmbDiffuseColor = external dso_local local_unnamed_addr global %struct.ProgramData, align 4
@g_pCylinderMesh = external dso_local local_unnamed_addr global ptr, align 8
@g_pPlaneMesh = external dso_local local_unnamed_addr global ptr, align 8
@g_viewPole = external dso_local global %"class.glutil::ViewPole", align 8
@g_objtPole = external dso_local global %"class.glutil::ObjectPole", align 8
@g_lightDirection = external dso_local global %"struct.glm::detail::tvec4", align 4
@_funcptr_glClearColor = external local_unnamed_addr global ptr, align 8
@_funcptr_glClearDepth = external local_unnamed_addr global ptr, align 8
@_funcptr_glClear = external local_unnamed_addr global ptr, align 8
@_ZL14g_bShowAmbient = external hidden local_unnamed_addr global i8, align 1
@_funcptr_glUseProgram = external local_unnamed_addr global ptr, align 8
@_funcptr_glUniform4f = external local_unnamed_addr global ptr, align 8
@_funcptr_glUniform3fv = external local_unnamed_addr global ptr, align 8
@_funcptr_glUniformMatrix4fv = external local_unnamed_addr global ptr, align 8
@_funcptr_glUniformMatrix3fv = external local_unnamed_addr global ptr, align 8
@_ZL17g_bDrawColoredCyl = external hidden local_unnamed_addr global i8, align 1
@.str.18 = external hidden unnamed_addr constant [10 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [4 x 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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_Z7displayv() local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.glutil::MatrixStack", align 8
  %2 = alloca %"struct.glm::detail::tmat4x4", align 4
  %3 = alloca %"struct.glm::detail::tvec4", align 4
  %4 = alloca %"class.glutil::PushStack", align 8
  %5 = alloca %"class.glutil::PushStack", align 8
  %6 = alloca %"struct.glm::detail::tmat3x3", align 4
  %7 = alloca %"class.glutil::PushStack", align 8
  %8 = alloca %"struct.glm::detail::tmat4x4", align 4
  %9 = alloca %"struct.glm::detail::tmat3x3", align 4
  %10 = alloca %"class.std::__cxx11::basic_string", align 8
  %11 = alloca %"class.std::allocator.0", align 1
  %12 = alloca %"struct.glm::detail::tmat3x3", align 4
  %13 = alloca %"class.std::__cxx11::basic_string", align 8
  %14 = alloca %"class.std::allocator.0", align 1
  %15 = load ptr, ptr @_funcptr_glClearColor, align 8, !tbaa !5
  tail call void %15(float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %16 = load ptr, ptr @_funcptr_glClearDepth, align 8, !tbaa !5
  tail call void %16(double noundef 1.000000e+00)
  %17 = load ptr, ptr @_funcptr_glClear, align 8, !tbaa !5
  tail call void %17(i32 noundef 16640)
  %18 = load ptr, ptr @g_pPlaneMesh, align 8, !tbaa !5
  %19 = icmp ne ptr %18, null
  %20 = load ptr, ptr @g_pCylinderMesh, align 8
  %21 = icmp ne ptr %20, null
  %or.cond = select i1 %19, i1 %21, i1 false
  br i1 %or.cond, label %22, label %183

22:                                               ; preds = %0
  call void @llvm.lifetime.start.p0(i64 88, ptr nonnull %1) #6
  call void @_ZN6glutil11MatrixStackC2Ev(ptr noundef nonnull align 8 dereferenceable(88) %1)
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %2) #6
  invoke void @_ZNK6glutil8ViewPole10CalcMatrixEv(ptr dead_on_unwind nonnull writable sret(%"struct.glm::detail::tmat4x4") align 4 %2, ptr noundef nonnull align 8 dereferenceable(148) @g_viewPole)
          to label %23 unwind label %42

23:                                               ; preds = %22
  invoke void @_ZN6glutil11MatrixStack9SetMatrixERKN3glm6detail7tmat4x4IfEE(ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 4 dereferenceable(64) %2)
          to label %24 unwind label %42

24:                                               ; preds = %23
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %2) #6
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %3) #6
  %25 = call noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
  invoke void @_ZN3glm6detailmlIfEENS0_7tmat4x4IT_E8col_typeERKS4_RKNS4_8row_typeE(ptr dead_on_unwind nonnull writable sret(%"struct.glm::detail::tvec4") align 4 %3, ptr noundef nonnull align 4 dereferenceable(64) %25, ptr noundef nonnull align 4 dereferenceable(16) @g_lightDirection)
          to label %26 unwind label %44

26:                                               ; preds = %24
  %27 = load i8, ptr @_ZL14g_bShowAmbient, align 1, !tbaa !9, !range !11, !noundef !12
  %28 = trunc nuw i8 %27 to i1
  %g_WhiteAmbDiffuseColor.g_WhiteDiffuseColor = select i1 %28, ptr @g_WhiteAmbDiffuseColor, ptr @g_WhiteDiffuseColor
  %29 = select i1 %28, ptr @g_VertexAmbDiffuseColor, ptr @g_VertexDiffuseColor
  %30 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  br i1 %28, label %31, label %48

31:                                               ; preds = %26
  %32 = load i32, ptr @g_WhiteAmbDiffuseColor, align 4, !tbaa !13
  invoke void %30(i32 noundef %32)
          to label %33 unwind label %46

33:                                               ; preds = %31
  %34 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %.val41 = load i32, ptr getelementptr inbounds (i8, ptr @g_WhiteAmbDiffuseColor, i64 8), align 4
  invoke void %34(i32 noundef %.val41, float noundef 0x3FE99999A0000000, float noundef 0x3FE99999A0000000, float noundef 0x3FE99999A0000000, float noundef 1.000000e+00)
          to label %35 unwind label %46

35:                                               ; preds = %33
  %36 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %.val43 = load i32, ptr getelementptr inbounds (i8, ptr @g_WhiteAmbDiffuseColor, i64 12), align 4
  invoke void %36(i32 noundef %.val43, float noundef 0x3FC99999A0000000, float noundef 0x3FC99999A0000000, float noundef 0x3FC99999A0000000, float noundef 1.000000e+00)
          to label %37 unwind label %46

37:                                               ; preds = %35
  %38 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %39 = load i32, ptr @g_VertexAmbDiffuseColor, align 4, !tbaa !13
  invoke void %38(i32 noundef %39)
          to label %40 unwind label %46

40:                                               ; preds = %37
  %41 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %.val45 = load i32, ptr getelementptr inbounds (i8, ptr @g_VertexAmbDiffuseColor, i64 8), align 4
  invoke void %41(i32 noundef %.val45, float noundef 0x3FE99999A0000000, float noundef 0x3FE99999A0000000, float noundef 0x3FE99999A0000000, float noundef 1.000000e+00)
          to label %.invoke unwind label %46

42:                                               ; preds = %23, %22
  %43 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %2) #6
  br label %182

44:                                               ; preds = %24
  %45 = landingpad { ptr, i32 }
          cleanup
  br label %181

46:                                               ; preds = %.invoke, %71, %67, %64, %60, %57, %52, %50, %48, %40, %37, %35, %33, %31
  %47 = landingpad { ptr, i32 }
          cleanup
  br label %181

48:                                               ; preds = %26
  %49 = load i32, ptr @g_WhiteDiffuseColor, align 4, !tbaa !13
  invoke void %30(i32 noundef %49)
          to label %50 unwind label %46

50:                                               ; preds = %48
  %51 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %.val38 = load i32, ptr getelementptr inbounds (i8, ptr @g_WhiteDiffuseColor, i64 8), align 4
  invoke void %51(i32 noundef %.val38, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef 1.000000e+00)
          to label %52 unwind label %46

52:                                               ; preds = %50
  %53 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %54 = load i32, ptr @g_VertexDiffuseColor, align 4, !tbaa !13
  invoke void %53(i32 noundef %54)
          to label %.invoke unwind label %46

.invoke:                                          ; preds = %52, %40
  %.sink = phi ptr [ getelementptr inbounds (i8, ptr @g_VertexAmbDiffuseColor, i64 12), %40 ], [ getelementptr inbounds (i8, ptr @g_VertexDiffuseColor, i64 8), %52 ]
  %55 = phi float [ 0x3FC99999A0000000, %40 ], [ 1.000000e+00, %52 ]
  %56 = load ptr, ptr @_funcptr_glUniform4f, align 8, !tbaa !5
  %.val47 = load i32, ptr %.sink, align 4
  invoke void %56(i32 noundef %.val47, float noundef %55, float noundef %55, float noundef %55, float noundef 1.000000e+00)
          to label %57 unwind label %46

57:                                               ; preds = %.invoke
  %58 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %59 = load i32, ptr %g_WhiteAmbDiffuseColor.g_WhiteDiffuseColor, align 4, !tbaa !13
  invoke void %58(i32 noundef %59)
          to label %60 unwind label %46

60:                                               ; preds = %57
  %61 = load ptr, ptr @_funcptr_glUniform3fv, align 8, !tbaa !5
  %.val49 = load i32, ptr getelementptr inbounds (i8, ptr @g_WhiteAmbDiffuseColor, i64 4), align 4
  %.val50 = load i32, ptr getelementptr inbounds (i8, ptr @g_WhiteDiffuseColor, i64 4), align 4
  %62 = select i1 %28, i32 %.val49, i32 %.val50
  %63 = call noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail5tvec4IS1_EE(ptr noundef nonnull align 4 dereferenceable(16) %3)
  invoke void %61(i32 noundef %62, i32 noundef 1, ptr noundef %63)
          to label %64 unwind label %46

64:                                               ; preds = %60
  %65 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %66 = load i32, ptr %29, align 4, !tbaa !13
  invoke void %65(i32 noundef %66)
          to label %67 unwind label %46

67:                                               ; preds = %64
  %68 = load ptr, ptr @_funcptr_glUniform3fv, align 8, !tbaa !5
  %.val51 = load i32, ptr getelementptr inbounds (i8, ptr @g_VertexAmbDiffuseColor, i64 4), align 4
  %.val52 = load i32, ptr getelementptr inbounds (i8, ptr @g_VertexDiffuseColor, i64 4), align 4
  %69 = select i1 %28, i32 %.val51, i32 %.val52
  %70 = call noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail5tvec4IS1_EE(ptr noundef nonnull align 4 dereferenceable(16) %3)
  invoke void %68(i32 noundef %69, i32 noundef 1, ptr noundef %70)
          to label %71 unwind label %46

71:                                               ; preds = %67
  %72 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  invoke void %72(i32 noundef 0)
          to label %73 unwind label %46

73:                                               ; preds = %71
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #6
  invoke void @_ZN6glutil9PushStackC2ERNS_11MatrixStackE(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %74 unwind label %123

74:                                               ; preds = %73
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #6
  invoke void @_ZN6glutil9PushStackC2ERNS_11MatrixStackE(ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %75 unwind label %125

75:                                               ; preds = %74
  %76 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  %77 = load i32, ptr %g_WhiteAmbDiffuseColor.g_WhiteDiffuseColor, align 4, !tbaa !13
  invoke void %76(i32 noundef %77)
          to label %78 unwind label %127

78:                                               ; preds = %75
  %79 = load ptr, ptr @_funcptr_glUniformMatrix4fv, align 8, !tbaa !5
  %80 = select i1 %28, ptr getelementptr inbounds (i8, ptr @g_WhiteAmbDiffuseColor, i64 16), ptr getelementptr inbounds (i8, ptr @g_WhiteDiffuseColor, i64 16)
  %81 = load i32, ptr %80, align 4, !tbaa !16
  %82 = call noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
  %83 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPKT_RKNS_6detail7tmat4x4IS1_EE(ptr noundef nonnull align 4 dereferenceable(64) %82)
          to label %84 unwind label %127

84:                                               ; preds = %78
  invoke void %79(i32 noundef %81, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %83)
          to label %85 unwind label %127

85:                                               ; preds = %84
  call void @llvm.lifetime.start.p0(i64 36, ptr nonnull %6) #6
  %86 = call noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
  invoke void @_ZN3glm6detail7tmat3x3IfEC2ERKNS0_7tmat4x4IfEE(ptr noundef nonnull align 4 dereferenceable(36) %6, ptr noundef nonnull align 4 dereferenceable(64) %86)
          to label %87 unwind label %129

87:                                               ; preds = %85
  %88 = load ptr, ptr @_funcptr_glUniformMatrix3fv, align 8, !tbaa !5
  %89 = select i1 %28, ptr getelementptr inbounds (i8, ptr @g_WhiteAmbDiffuseColor, i64 20), ptr getelementptr inbounds (i8, ptr @g_WhiteDiffuseColor, i64 20)
  %90 = load i32, ptr %89, align 4, !tbaa !17
  %91 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail7tmat3x3IS1_EE(ptr noundef nonnull align 4 dereferenceable(36) %6)
          to label %92 unwind label %129

92:                                               ; preds = %87
  invoke void %88(i32 noundef %90, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %91)
          to label %93 unwind label %129

93:                                               ; preds = %92
  %94 = load ptr, ptr @g_pPlaneMesh, align 8, !tbaa !5
  invoke void @_ZNK9Framework4Mesh6RenderEv(ptr noundef nonnull align 8 dereferenceable(8) %94)
          to label %95 unwind label %129

95:                                               ; preds = %93
  %96 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  invoke void %96(i32 noundef 0)
          to label %97 unwind label %129

97:                                               ; preds = %95
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %6) #6
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %5) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #6
  invoke void @_ZN6glutil9PushStackC2ERNS_11MatrixStackE(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(88) %1)
          to label %98 unwind label %133

98:                                               ; preds = %97
  call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %8) #6
  invoke void @_ZNK6glutil10ObjectPole10CalcMatrixEv(ptr dead_on_unwind nonnull writable sret(%"struct.glm::detail::tmat4x4") align 4 %8, ptr noundef nonnull align 8 dereferenceable(112) @g_objtPole)
          to label %99 unwind label %135

99:                                               ; preds = %98
  invoke void @_ZN6glutil11MatrixStack11ApplyMatrixERKN3glm6detail7tmat4x4IfEE(ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 4 dereferenceable(64) %8)
          to label %100 unwind label %135

100:                                              ; preds = %99
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %8) #6
  %101 = load i8, ptr @_ZL17g_bDrawColoredCyl, align 1, !tbaa !9, !range !11, !noundef !12
  %102 = trunc nuw i8 %101 to i1
  %103 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  br i1 %102, label %104, label %147

104:                                              ; preds = %100
  %105 = load i32, ptr %29, align 4, !tbaa !13
  invoke void %103(i32 noundef %105)
          to label %106 unwind label %137

106:                                              ; preds = %104
  %107 = load ptr, ptr @_funcptr_glUniformMatrix4fv, align 8, !tbaa !5
  %.val58 = load i32, ptr getelementptr inbounds (i8, ptr @g_VertexAmbDiffuseColor, i64 16), align 4
  %.val59 = load i32, ptr getelementptr inbounds (i8, ptr @g_VertexDiffuseColor, i64 16), align 4
  %108 = call noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
  %109 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPKT_RKNS_6detail7tmat4x4IS1_EE(ptr noundef nonnull align 4 dereferenceable(64) %108)
          to label %110 unwind label %137

110:                                              ; preds = %106
  %111 = select i1 %28, i32 %.val58, i32 %.val59
  invoke void %107(i32 noundef %111, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %109)
          to label %112 unwind label %137

112:                                              ; preds = %110
  call void @llvm.lifetime.start.p0(i64 36, ptr nonnull %9) #6
  %113 = call noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
  invoke void @_ZN3glm6detail7tmat3x3IfEC2ERKNS0_7tmat4x4IfEE(ptr noundef nonnull align 4 dereferenceable(36) %9, ptr noundef nonnull align 4 dereferenceable(64) %113)
          to label %114 unwind label %139

114:                                              ; preds = %112
  %115 = load ptr, ptr @_funcptr_glUniformMatrix3fv, align 8, !tbaa !5
  %.val60 = load i32, ptr getelementptr inbounds (i8, ptr @g_VertexAmbDiffuseColor, i64 20), align 4
  %.val61 = load i32, ptr getelementptr inbounds (i8, ptr @g_VertexDiffuseColor, i64 20), align 4
  %116 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail7tmat3x3IS1_EE(ptr noundef nonnull align 4 dereferenceable(36) %9)
          to label %117 unwind label %139

117:                                              ; preds = %114
  %118 = select i1 %28, i32 %.val60, i32 %.val61
  invoke void %115(i32 noundef %118, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %116)
          to label %119 unwind label %139

119:                                              ; preds = %117
  %120 = load ptr, ptr @g_pCylinderMesh, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %10) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %11) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %10, ptr noundef nonnull @.str.18, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %121 unwind label %141

121:                                              ; preds = %119
  invoke void @_ZNK9Framework4Mesh6RenderERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(8) %120, ptr noundef nonnull align 8 dereferenceable(32) %10)
          to label %122 unwind label %143

122:                                              ; preds = %121
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %10) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %10) #6
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %9) #6
  br label %174

123:                                              ; preds = %73
  %124 = landingpad { ptr, i32 }
          cleanup
  br label %180

125:                                              ; preds = %74
  %126 = landingpad { ptr, i32 }
          cleanup
  br label %132

127:                                              ; preds = %84, %78, %75
  %128 = landingpad { ptr, i32 }
          cleanup
  br label %131

129:                                              ; preds = %95, %93, %92, %87, %85
  %130 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %6) #6
  br label %131

131:                                              ; preds = %129, %127
  %.pn = phi { ptr, i32 } [ %130, %129 ], [ %128, %127 ]
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %5) #6
  br label %132

132:                                              ; preds = %131, %125
  %.pn.pn = phi { ptr, i32 } [ %.pn, %131 ], [ %126, %125 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #6
  br label %179

133:                                              ; preds = %97
  %134 = landingpad { ptr, i32 }
          cleanup
  br label %178

135:                                              ; preds = %99, %98
  %136 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %8) #6
  br label %177

137:                                              ; preds = %174, %154, %149, %147, %110, %106, %104
  %138 = landingpad { ptr, i32 }
          cleanup
  br label %177

139:                                              ; preds = %117, %114, %112
  %140 = landingpad { ptr, i32 }
          cleanup
  br label %146

141:                                              ; preds = %119
  %142 = landingpad { ptr, i32 }
          cleanup
  br label %145

143:                                              ; preds = %121
  %144 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %10) #6
  br label %145

145:                                              ; preds = %143, %141
  %.pn62 = phi { ptr, i32 } [ %144, %143 ], [ %142, %141 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %10) #6
  br label %146

146:                                              ; preds = %145, %139
  %.pn62.pn = phi { ptr, i32 } [ %.pn62, %145 ], [ %140, %139 ]
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %9) #6
  br label %177

147:                                              ; preds = %100
  %148 = load i32, ptr %g_WhiteAmbDiffuseColor.g_WhiteDiffuseColor, align 4, !tbaa !13
  invoke void %103(i32 noundef %148)
          to label %149 unwind label %137

149:                                              ; preds = %147
  %150 = load ptr, ptr @_funcptr_glUniformMatrix4fv, align 8, !tbaa !5
  %151 = load i32, ptr %80, align 4, !tbaa !16
  %152 = call noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
  %153 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPKT_RKNS_6detail7tmat4x4IS1_EE(ptr noundef nonnull align 4 dereferenceable(64) %152)
          to label %154 unwind label %137

154:                                              ; preds = %149
  invoke void %150(i32 noundef %151, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %153)
          to label %155 unwind label %137

155:                                              ; preds = %154
  call void @llvm.lifetime.start.p0(i64 36, ptr nonnull %12) #6
  %156 = call noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
  invoke void @_ZN3glm6detail7tmat3x3IfEC2ERKNS0_7tmat4x4IfEE(ptr noundef nonnull align 4 dereferenceable(36) %12, ptr noundef nonnull align 4 dereferenceable(64) %156)
          to label %157 unwind label %166

157:                                              ; preds = %155
  %158 = load ptr, ptr @_funcptr_glUniformMatrix3fv, align 8, !tbaa !5
  %159 = load i32, ptr %89, align 4, !tbaa !17
  %160 = invoke noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail7tmat3x3IS1_EE(ptr noundef nonnull align 4 dereferenceable(36) %12)
          to label %161 unwind label %166

161:                                              ; preds = %157
  invoke void %158(i32 noundef %159, i32 noundef 1, i8 noundef zeroext 0, ptr noundef %160)
          to label %162 unwind label %166

162:                                              ; preds = %161
  %163 = load ptr, ptr @g_pCylinderMesh, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %13) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %14) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %13, ptr noundef nonnull @.str.19, ptr noundef nonnull align 1 dereferenceable(1) %14)
          to label %164 unwind label %168

164:                                              ; preds = %162
  invoke void @_ZNK9Framework4Mesh6RenderERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(8) %163, ptr noundef nonnull align 8 dereferenceable(32) %13)
          to label %165 unwind label %170

165:                                              ; preds = %164
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %13) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %14) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %13) #6
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %12) #6
  br label %174

166:                                              ; preds = %161, %157, %155
  %167 = landingpad { ptr, i32 }
          cleanup
  br label %173

168:                                              ; preds = %162
  %169 = landingpad { ptr, i32 }
          cleanup
  br label %172

170:                                              ; preds = %164
  %171 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %13) #6
  br label %172

172:                                              ; preds = %170, %168
  %.pn55 = phi { ptr, i32 } [ %171, %170 ], [ %169, %168 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %14) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %13) #6
  br label %173

173:                                              ; preds = %172, %166
  %.pn55.pn = phi { ptr, i32 } [ %.pn55, %172 ], [ %167, %166 ]
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %12) #6
  br label %177

174:                                              ; preds = %165, %122
  %175 = load ptr, ptr @_funcptr_glUseProgram, align 8, !tbaa !5
  invoke void %175(i32 noundef 0)
          to label %176 unwind label %137

176:                                              ; preds = %174
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #6
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %4) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #6
  call void @_ZN6glutil11MatrixStackD2Ev(ptr noundef nonnull align 8 dereferenceable(88) %1) #6
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %1) #6
  br label %183

177:                                              ; preds = %173, %146, %137, %135
  %.pn65 = phi { ptr, i32 } [ %138, %137 ], [ %.pn62.pn, %146 ], [ %.pn55.pn, %173 ], [ %136, %135 ]
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %7) #6
  br label %178

178:                                              ; preds = %177, %133
  %.pn65.pn = phi { ptr, i32 } [ %.pn65, %177 ], [ %134, %133 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #6
  br label %179

179:                                              ; preds = %178, %132
  %.pn65.pn.pn = phi { ptr, i32 } [ %.pn65.pn, %178 ], [ %.pn.pn, %132 ]
  call void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %4) #6
  br label %180

180:                                              ; preds = %179, %123
  %.pn65.pn.pn.pn = phi { ptr, i32 } [ %.pn65.pn.pn, %179 ], [ %124, %123 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #6
  br label %181

181:                                              ; preds = %46, %180, %44
  %.pn65.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %45, %44 ], [ %.pn65.pn.pn.pn, %180 ], [ %47, %46 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #6
  br label %182

182:                                              ; preds = %181, %42
  %.pn65.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn65.pn.pn.pn.pn.pn, %181 ], [ %43, %42 ]
  call void @_ZN6glutil11MatrixStackD2Ev(ptr noundef nonnull align 8 dereferenceable(88) %1) #6
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %1) #6
  resume { ptr, i32 } %.pn65.pn.pn.pn.pn.pn.pn

183:                                              ; preds = %176, %0
  call void @glutSwapBuffers()
  ret void
}

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6glutil11MatrixStackC2Ev(ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #2 align 2

declare void @_ZN6glutil11MatrixStack9SetMatrixERKN3glm6detail7tmat4x4IfEE(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 4 dereferenceable(64)) local_unnamed_addr #3

declare void @_ZNK6glutil8ViewPole10CalcMatrixEv(ptr dead_on_unwind writable sret(%"struct.glm::detail::tmat4x4") align 4, ptr noundef nonnull align 8 dereferenceable(148)) unnamed_addr #3

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3glm6detailmlIfEENS0_7tmat4x4IT_E8col_typeERKS4_RKNS4_8row_typeE(ptr dead_on_unwind noalias writable sret(%"struct.glm::detail::tvec4") align 4, ptr noundef nonnull align 4 dereferenceable(64), ptr noundef nonnull align 4 dereferenceable(16)) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(64) ptr @_ZNK6glutil11MatrixStack3TopEv(ptr noundef nonnull align 8 dereferenceable(88)) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail5tvec4IS1_EE(ptr noundef nonnull align 4 dereferenceable(16)) local_unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6glutil9PushStackC2ERNS_11MatrixStackE(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN3glm9value_ptrIfEEPKT_RKNS_6detail7tmat4x4IS1_EE(ptr noundef nonnull align 4 dereferenceable(64)) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3glm6detail7tmat3x3IfEC2ERKNS0_7tmat4x4IfEE(ptr noundef nonnull align 4 dereferenceable(36), ptr noundef nonnull align 4 dereferenceable(64)) unnamed_addr #4 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZN3glm9value_ptrIfEEPT_RNS_6detail7tmat3x3IS1_EE(ptr noundef nonnull align 4 dereferenceable(36)) local_unnamed_addr #4

declare void @_ZNK9Framework4Mesh6RenderEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN6glutil9PushStackD2Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #1 align 2

declare void @_ZN6glutil11MatrixStack11ApplyMatrixERKN3glm6detail7tmat4x4IfEE(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 4 dereferenceable(64)) local_unnamed_addr #3

declare void @_ZNK6glutil10ObjectPole10CalcMatrixEv(ptr dead_on_unwind writable sret(%"struct.glm::detail::tmat4x4") align 4, ptr noundef nonnull align 8 dereferenceable(112)) local_unnamed_addr #3

declare void @_ZNK9Framework4Mesh6RenderERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #3

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN6glutil11MatrixStackD2Ev(ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #5 align 2

declare void @glutSwapBuffers() local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress 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 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 = { inlinehint mustprogress 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 #5 = { inlinehint mustprogress 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 #6 = { 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++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = !{i8 0, i8 2}
!12 = !{}
!13 = !{!14, !15, i64 0}
!14 = !{!"_ZTS11ProgramData", !15, i64 0, !15, i64 4, !15, i64 8, !15, i64 12, !15, i64 16, !15, i64 20}
!15 = !{!"int", !7, i64 0}
!16 = !{!14, !15, i64 16}
!17 = !{!14, !15, i64 20}


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