; LLVM IR from achilles288/robot-monitor-graphics :: src/base/cylinder.ll (ZN3rmg10Cylinder3D10createMeshEv)

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

%"class.rmg::Mesh" = type <{ ptr, ptr, ptr, ptr, i32, [4 x i8], ptr, i32, [4 x i8] }>
%"struct.rmg::Vec3" = type { %union.anon.0 }
%union.anon.0 = type { %struct.anon }
%struct.anon = type { float, float, float }
%"struct.rmg::Vec2" = type { %union.anon.1 }
%union.anon.1 = type { %struct.anon.2 }
%struct.anon.2 = type { float, float }
%"class.rmg::Cylinder3D" = type { %"class.rmg::Object3D", float, float }
%"class.rmg::Object3D" = type { %"class.rmg::Object", %"struct.rmg::Mat4", %"struct.rmg::Vec3", ptr, float, float, float, ptr, ptr, %"class.rmg::internal::Pending", ptr, ptr, %"class.rmg::internal::Pending" }
%"class.rmg::Object" = type { ptr, i64, ptr, %"struct.rmg::ColorRGBA", i8, i32 }
%"struct.rmg::ColorRGBA" = type { float, float, float, float }
%"struct.rmg::Mat4" = type { %union.anon }
%union.anon = type { [4 x [4 x float]] }
%"class.rmg::internal::Pending" = type { ptr, ptr }

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3rmg10Cylinder3D10createMeshEv(ptr dead_on_unwind noalias writable sret(%"class.rmg::Mesh") align 8 %0, ptr noundef nonnull align 8 dereferenceable(224) %1) #1 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca [33 x [4 x %"struct.rmg::Vec3"]], align 16
  %6 = alloca [33 x [4 x %"struct.rmg::Vec3"]], align 16
  %7 = alloca [33 x [4 x %"struct.rmg::Vec2"]], align 16
  %8 = alloca [32 x [12 x i32]], align 16
  %9 = alloca float, align 4
  %10 = alloca %"struct.rmg::Vec2", align 4
  %11 = alloca %"struct.rmg::Vec2", align 4
  %12 = alloca float, align 4
  %13 = alloca float, align 4
  %14 = alloca %"struct.rmg::Vec3", align 4
  %15 = alloca %"struct.rmg::Vec3", align 4
  %16 = alloca %"struct.rmg::Vec3", align 4
  %17 = alloca %"struct.rmg::Vec3", align 4
  %18 = alloca i32, align 4
  %19 = alloca float, align 4
  %20 = alloca float, align 4
  %21 = alloca float, align 4
  %22 = alloca %"struct.rmg::Vec3", align 4
  %23 = alloca %"struct.rmg::Vec3", align 4
  %24 = alloca %"struct.rmg::Vec3", align 4
  %25 = alloca %"struct.rmg::Vec3", align 4
  %26 = alloca %"struct.rmg::Vec3", align 4
  %27 = alloca %"struct.rmg::Vec3", align 4
  %28 = alloca %"struct.rmg::Vec3", align 4
  %29 = alloca %"struct.rmg::Vec3", align 4
  %30 = alloca %"struct.rmg::Vec2", align 4
  %31 = alloca %"struct.rmg::Vec2", align 4
  %32 = alloca %"struct.rmg::Vec2", align 4
  %33 = alloca %"struct.rmg::Vec2", align 4
  %34 = alloca %"struct.rmg::Vec2", align 4
  %35 = alloca %"struct.rmg::Vec2", align 4
  %36 = alloca float, align 4
  %37 = alloca float, align 4
  %38 = alloca i32, align 4
  %39 = alloca i32, align 4
  %40 = alloca i32, align 4
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  %41 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 1584, ptr %5) #8
  %42 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %5, i32 0, i32 0, i32 0
  %43 = getelementptr inbounds %"struct.rmg::Vec3", ptr %42, i64 132
  br label %44

44:                                               ; preds = %44, %2
  %45 = phi ptr [ %42, %2 ], [ %46, %44 ]
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %45)
  %46 = getelementptr inbounds %"struct.rmg::Vec3", ptr %45, i64 1
  %47 = icmp eq ptr %46, %43
  br i1 %47, label %48, label %44

48:                                               ; preds = %44
  call void @llvm.lifetime.start.p0(i64 1584, ptr %6) #8
  %49 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %6, i32 0, i32 0, i32 0
  %50 = getelementptr inbounds %"struct.rmg::Vec3", ptr %49, i64 132
  br label %51

51:                                               ; preds = %51, %48
  %52 = phi ptr [ %49, %48 ], [ %53, %51 ]
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %52)
  %53 = getelementptr inbounds %"struct.rmg::Vec3", ptr %52, i64 1
  %54 = icmp eq ptr %53, %50
  br i1 %54, label %55, label %51

55:                                               ; preds = %51
  call void @llvm.lifetime.start.p0(i64 1056, ptr %7) #8
  %56 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i32 0, i32 0, i32 0
  %57 = getelementptr inbounds %"struct.rmg::Vec2", ptr %56, i64 132
  br label %58

58:                                               ; preds = %58, %55
  %59 = phi ptr [ %56, %55 ], [ %60, %58 ]
  call void @_ZN3rmg4Vec2C2Ev(ptr noundef nonnull align 4 dereferenceable(8) %59)
  %60 = getelementptr inbounds %"struct.rmg::Vec2", ptr %59, i64 1
  %61 = icmp eq ptr %60, %57
  br i1 %61, label %62, label %58

62:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 1536, ptr %8) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #8
  %63 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 1
  %64 = load float, ptr %63, align 8, !tbaa !9
  %65 = fdiv float %64, 2.000000e+00
  store float %65, ptr %9, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #8
  %66 = load float, ptr %9, align 4, !tbaa !21
  %67 = load float, ptr %9, align 4, !tbaa !21
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %10, float noundef %66, float noundef %67)
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #8
  %68 = load float, ptr %9, align 4, !tbaa !21
  %69 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 1
  %70 = load float, ptr %69, align 8, !tbaa !9
  %71 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %72 = load float, ptr %71, align 4, !tbaa !22
  %73 = fadd float %70, %72
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %11, float noundef %68, float noundef %73)
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #8
  %74 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 1
  %75 = load float, ptr %74, align 8, !tbaa !9
  %76 = fpext float %75 to double
  %77 = fmul double 0x400921FB54442D18, %76
  %78 = fptrunc double %77 to float
  store float %78, ptr %12, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #8
  %79 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 1
  %80 = load float, ptr %79, align 8, !tbaa !9
  %81 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %82 = load float, ptr %81, align 4, !tbaa !22
  %83 = call float @llvm.fmuladd.f32(float 2.000000e+00, float %80, float %82)
  store float %83, ptr %13, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 12, ptr %14) #8
  %84 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %85 = load float, ptr %84, align 4, !tbaa !22
  %86 = fneg float %85
  %87 = fdiv float %86, 2.000000e+00
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %14, float noundef %87, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %88 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %5, i64 0, i64 32
  %89 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %88, i64 0, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %89, ptr align 4 %14, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %14) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %15) #8
  %90 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %91 = load float, ptr %90, align 4, !tbaa !22
  %92 = fdiv float %91, 2.000000e+00
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %15, float noundef %92, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %93 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %5, i64 0, i64 32
  %94 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %93, i64 0, i64 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %94, ptr align 4 %15, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %15) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %16) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %16, float noundef -1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %95 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %6, i64 0, i64 32
  %96 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %95, i64 0, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %96, ptr align 4 %16, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %16) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %17) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %17, float noundef 1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %97 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %6, i64 0, i64 32
  %98 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %97, i64 0, i64 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %98, ptr align 4 %17, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %17) #8
  %99 = getelementptr inbounds %"struct.rmg::Vec2", ptr %10, i32 0, i32 0
  %100 = getelementptr inbounds %struct.anon.2, ptr %99, i32 0, i32 0
  %101 = load float, ptr %100, align 4, !tbaa !24
  %102 = load float, ptr %12, align 4, !tbaa !21
  %103 = fdiv float %101, %102
  %104 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 32
  %105 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %104, i64 0, i64 0
  %106 = getelementptr inbounds %"struct.rmg::Vec2", ptr %105, i32 0, i32 0
  %107 = getelementptr inbounds %struct.anon.2, ptr %106, i32 0, i32 0
  store float %103, ptr %107, align 16, !tbaa !24
  %108 = getelementptr inbounds %"struct.rmg::Vec2", ptr %10, i32 0, i32 0
  %109 = getelementptr inbounds %struct.anon.2, ptr %108, i32 0, i32 1
  %110 = load float, ptr %109, align 4, !tbaa !24
  %111 = load float, ptr %13, align 4, !tbaa !21
  %112 = fdiv float %110, %111
  %113 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 32
  %114 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %113, i64 0, i64 0
  %115 = getelementptr inbounds %"struct.rmg::Vec2", ptr %114, i32 0, i32 0
  %116 = getelementptr inbounds %struct.anon.2, ptr %115, i32 0, i32 1
  store float %112, ptr %116, align 4, !tbaa !24
  %117 = getelementptr inbounds %"struct.rmg::Vec2", ptr %11, i32 0, i32 0
  %118 = getelementptr inbounds %struct.anon.2, ptr %117, i32 0, i32 0
  %119 = load float, ptr %118, align 4, !tbaa !24
  %120 = load float, ptr %12, align 4, !tbaa !21
  %121 = fdiv float %119, %120
  %122 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 32
  %123 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %122, i64 0, i64 1
  %124 = getelementptr inbounds %"struct.rmg::Vec2", ptr %123, i32 0, i32 0
  %125 = getelementptr inbounds %struct.anon.2, ptr %124, i32 0, i32 0
  store float %121, ptr %125, align 8, !tbaa !24
  %126 = getelementptr inbounds %"struct.rmg::Vec2", ptr %11, i32 0, i32 0
  %127 = getelementptr inbounds %struct.anon.2, ptr %126, i32 0, i32 1
  %128 = load float, ptr %127, align 4, !tbaa !24
  %129 = load float, ptr %13, align 4, !tbaa !21
  %130 = fdiv float %128, %129
  %131 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 32
  %132 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %131, i64 0, i64 1
  %133 = getelementptr inbounds %"struct.rmg::Vec2", ptr %132, i32 0, i32 0
  %134 = getelementptr inbounds %struct.anon.2, ptr %133, i32 0, i32 1
  store float %130, ptr %134, align 4, !tbaa !24
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #8
  store i32 0, ptr %18, align 4, !tbaa !25
  br label %135

135:                                              ; preds = %384, %62
  %136 = load i32, ptr %18, align 4, !tbaa !25
  %137 = icmp slt i32 %136, 32
  br i1 %137, label %139, label %138

138:                                              ; preds = %135
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #8
  br label %387

139:                                              ; preds = %135
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #8
  %140 = load i32, ptr %18, align 4, !tbaa !25
  %141 = sitofp i32 %140 to float
  %142 = fdiv float %141, 3.200000e+01
  %143 = fpext float %142 to double
  %144 = call double @llvm.fmuladd.f64(double 0x401921FB54442D18, double %143, double 0xC00490FDAA22168C)
  %145 = fptrunc double %144 to float
  store float %145, ptr %19, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #8
  %146 = load float, ptr %19, align 4, !tbaa !21
  %147 = fpext float %146 to double
  %148 = call double @cos(double noundef %147) #8
  %149 = fptrunc double %148 to float
  store float %149, ptr %20, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #8
  %150 = load float, ptr %19, align 4, !tbaa !21
  %151 = fpext float %150 to double
  %152 = call double @sin(double noundef %151) #8
  %153 = fptrunc double %152 to float
  store float %153, ptr %21, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 12, ptr %22) #8
  %154 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %155 = load float, ptr %154, align 4, !tbaa !22
  %156 = fneg float %155
  %157 = fdiv float %156, 2.000000e+00
  %158 = load float, ptr %9, align 4, !tbaa !21
  %159 = load float, ptr %20, align 4, !tbaa !21
  %160 = fmul float %158, %159
  %161 = load float, ptr %9, align 4, !tbaa !21
  %162 = load float, ptr %21, align 4, !tbaa !21
  %163 = fmul float %161, %162
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %22, float noundef %157, float noundef %160, float noundef %163)
  %164 = load i32, ptr %18, align 4, !tbaa !25
  %165 = sext i32 %164 to i64
  %166 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %5, i64 0, i64 %165
  %167 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %166, i64 0, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %167, ptr align 4 %22, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %22) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %23) #8
  %168 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %169 = load float, ptr %168, align 4, !tbaa !22
  %170 = fneg float %169
  %171 = fdiv float %170, 2.000000e+00
  %172 = load float, ptr %9, align 4, !tbaa !21
  %173 = load float, ptr %20, align 4, !tbaa !21
  %174 = fmul float %172, %173
  %175 = load float, ptr %9, align 4, !tbaa !21
  %176 = load float, ptr %21, align 4, !tbaa !21
  %177 = fmul float %175, %176
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %23, float noundef %171, float noundef %174, float noundef %177)
  %178 = load i32, ptr %18, align 4, !tbaa !25
  %179 = sext i32 %178 to i64
  %180 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %5, i64 0, i64 %179
  %181 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %180, i64 0, i64 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %181, ptr align 4 %23, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %23) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %24) #8
  %182 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %183 = load float, ptr %182, align 4, !tbaa !22
  %184 = fdiv float %183, 2.000000e+00
  %185 = load float, ptr %9, align 4, !tbaa !21
  %186 = load float, ptr %20, align 4, !tbaa !21
  %187 = fmul float %185, %186
  %188 = load float, ptr %9, align 4, !tbaa !21
  %189 = load float, ptr %21, align 4, !tbaa !21
  %190 = fmul float %188, %189
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %24, float noundef %184, float noundef %187, float noundef %190)
  %191 = load i32, ptr %18, align 4, !tbaa !25
  %192 = sext i32 %191 to i64
  %193 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %5, i64 0, i64 %192
  %194 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %193, i64 0, i64 2
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %194, ptr align 4 %24, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %24) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %25) #8
  %195 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %196 = load float, ptr %195, align 4, !tbaa !22
  %197 = fdiv float %196, 2.000000e+00
  %198 = load float, ptr %9, align 4, !tbaa !21
  %199 = load float, ptr %20, align 4, !tbaa !21
  %200 = fmul float %198, %199
  %201 = load float, ptr %9, align 4, !tbaa !21
  %202 = load float, ptr %21, align 4, !tbaa !21
  %203 = fmul float %201, %202
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %25, float noundef %197, float noundef %200, float noundef %203)
  %204 = load i32, ptr %18, align 4, !tbaa !25
  %205 = sext i32 %204 to i64
  %206 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %5, i64 0, i64 %205
  %207 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %206, i64 0, i64 3
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %207, ptr align 4 %25, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %25) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %26) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %26, float noundef -1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %208 = load i32, ptr %18, align 4, !tbaa !25
  %209 = sext i32 %208 to i64
  %210 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %6, i64 0, i64 %209
  %211 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %210, i64 0, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %211, ptr align 4 %26, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %26) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %27) #8
  %212 = load float, ptr %20, align 4, !tbaa !21
  %213 = load float, ptr %21, align 4, !tbaa !21
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %27, float noundef 0.000000e+00, float noundef %212, float noundef %213)
  %214 = load i32, ptr %18, align 4, !tbaa !25
  %215 = sext i32 %214 to i64
  %216 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %6, i64 0, i64 %215
  %217 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %216, i64 0, i64 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %217, ptr align 4 %27, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %27) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %28) #8
  %218 = load float, ptr %20, align 4, !tbaa !21
  %219 = load float, ptr %21, align 4, !tbaa !21
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %28, float noundef 0.000000e+00, float noundef %218, float noundef %219)
  %220 = load i32, ptr %18, align 4, !tbaa !25
  %221 = sext i32 %220 to i64
  %222 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %6, i64 0, i64 %221
  %223 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %222, i64 0, i64 2
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %223, ptr align 4 %28, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %28) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %29) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %29, float noundef 1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %224 = load i32, ptr %18, align 4, !tbaa !25
  %225 = sext i32 %224 to i64
  %226 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %6, i64 0, i64 %225
  %227 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %226, i64 0, i64 3
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %227, ptr align 4 %29, i64 12, i1 false), !tbaa.struct !23
  call void @llvm.lifetime.end.p0(i64 12, ptr %29) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #8
  %228 = load float, ptr %9, align 4, !tbaa !21
  %229 = load float, ptr %20, align 4, !tbaa !21
  %230 = fmul float %228, %229
  %231 = load float, ptr %9, align 4, !tbaa !21
  %232 = load float, ptr %21, align 4, !tbaa !21
  %233 = fmul float %231, %232
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %31, float noundef %230, float noundef %233)
  %234 = call <2 x float> @_ZNK3rmg4Vec2plERKS0_(ptr noundef nonnull align 4 dereferenceable(8) %10, ptr noundef nonnull align 4 dereferenceable(8) %31)
  %235 = getelementptr inbounds %"struct.rmg::Vec2", ptr %30, i32 0, i32 0
  %236 = getelementptr inbounds %union.anon.1, ptr %235, i32 0, i32 0
  store <2 x float> %234, ptr %236, align 4
  %237 = load i32, ptr %18, align 4, !tbaa !25
  %238 = sext i32 %237 to i64
  %239 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 %238
  %240 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %239, i64 0, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 16 %240, ptr align 4 %30, i64 8, i1 false), !tbaa.struct !27
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #8
  %241 = load float, ptr %9, align 4, !tbaa !21
  %242 = load float, ptr %19, align 4, !tbaa !21
  %243 = fmul float %241, %242
  %244 = load float, ptr %9, align 4, !tbaa !21
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %32, float noundef %243, float noundef %244)
  %245 = load i32, ptr %18, align 4, !tbaa !25
  %246 = sext i32 %245 to i64
  %247 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 %246
  %248 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %247, i64 0, i64 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %248, ptr align 4 %32, i64 8, i1 false), !tbaa.struct !27
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #8
  %249 = load float, ptr %9, align 4, !tbaa !21
  %250 = load float, ptr %19, align 4, !tbaa !21
  %251 = fmul float %249, %250
  %252 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 1
  %253 = load float, ptr %252, align 8, !tbaa !9
  %254 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %255 = load float, ptr %254, align 4, !tbaa !22
  %256 = fadd float %253, %255
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %33, float noundef %251, float noundef %256)
  %257 = load i32, ptr %18, align 4, !tbaa !25
  %258 = sext i32 %257 to i64
  %259 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 %258
  %260 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %259, i64 0, i64 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %260, ptr align 4 %33, i64 8, i1 false), !tbaa.struct !27
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #8
  %261 = load float, ptr %9, align 4, !tbaa !21
  %262 = load float, ptr %20, align 4, !tbaa !21
  %263 = fmul float %261, %262
  %264 = load float, ptr %9, align 4, !tbaa !21
  %265 = load float, ptr %21, align 4, !tbaa !21
  %266 = fmul float %264, %265
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %35, float noundef %263, float noundef %266)
  %267 = call <2 x float> @_ZNK3rmg4Vec2plERKS0_(ptr noundef nonnull align 4 dereferenceable(8) %11, ptr noundef nonnull align 4 dereferenceable(8) %35)
  %268 = getelementptr inbounds %"struct.rmg::Vec2", ptr %34, i32 0, i32 0
  %269 = getelementptr inbounds %union.anon.1, ptr %268, i32 0, i32 0
  store <2 x float> %267, ptr %269, align 4
  %270 = load i32, ptr %18, align 4, !tbaa !25
  %271 = sext i32 %270 to i64
  %272 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 %271
  %273 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %272, i64 0, i64 3
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %273, ptr align 4 %34, i64 8, i1 false), !tbaa.struct !27
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #8
  %274 = load i32, ptr %18, align 4, !tbaa !25
  %275 = icmp eq i32 %274, 0
  br i1 %275, label %276, label %301

276:                                              ; preds = %139
  %277 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %278 = getelementptr inbounds [12 x i32], ptr %277, i64 0, i64 0
  store i32 124, ptr %278, align 16, !tbaa !25
  %279 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %280 = getelementptr inbounds [12 x i32], ptr %279, i64 0, i64 1
  store i32 128, ptr %280, align 4, !tbaa !25
  %281 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %282 = getelementptr inbounds [12 x i32], ptr %281, i64 0, i64 2
  store i32 0, ptr %282, align 8, !tbaa !25
  %283 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %284 = getelementptr inbounds [12 x i32], ptr %283, i64 0, i64 3
  store i32 126, ptr %284, align 4, !tbaa !25
  %285 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %286 = getelementptr inbounds [12 x i32], ptr %285, i64 0, i64 4
  store i32 125, ptr %286, align 16, !tbaa !25
  %287 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %288 = getelementptr inbounds [12 x i32], ptr %287, i64 0, i64 5
  store i32 1, ptr %288, align 4, !tbaa !25
  %289 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %290 = getelementptr inbounds [12 x i32], ptr %289, i64 0, i64 6
  store i32 1, ptr %290, align 8, !tbaa !25
  %291 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %292 = getelementptr inbounds [12 x i32], ptr %291, i64 0, i64 7
  store i32 2, ptr %292, align 4, !tbaa !25
  %293 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %294 = getelementptr inbounds [12 x i32], ptr %293, i64 0, i64 8
  store i32 126, ptr %294, align 16, !tbaa !25
  %295 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %296 = getelementptr inbounds [12 x i32], ptr %295, i64 0, i64 9
  store i32 127, ptr %296, align 4, !tbaa !25
  %297 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %298 = getelementptr inbounds [12 x i32], ptr %297, i64 0, i64 10
  store i32 3, ptr %298, align 8, !tbaa !25
  %299 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %300 = getelementptr inbounds [12 x i32], ptr %299, i64 0, i64 11
  store i32 129, ptr %300, align 4, !tbaa !25
  br label %383

301:                                              ; preds = %139
  %302 = load i32, ptr %18, align 4, !tbaa !25
  %303 = sub nsw i32 %302, 1
  %304 = mul nsw i32 %303, 4
  %305 = load i32, ptr %18, align 4, !tbaa !25
  %306 = sext i32 %305 to i64
  %307 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %306
  %308 = getelementptr inbounds [12 x i32], ptr %307, i64 0, i64 0
  store i32 %304, ptr %308, align 16, !tbaa !25
  %309 = load i32, ptr %18, align 4, !tbaa !25
  %310 = sext i32 %309 to i64
  %311 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %310
  %312 = getelementptr inbounds [12 x i32], ptr %311, i64 0, i64 1
  store i32 128, ptr %312, align 4, !tbaa !25
  %313 = load i32, ptr %18, align 4, !tbaa !25
  %314 = mul nsw i32 %313, 4
  %315 = load i32, ptr %18, align 4, !tbaa !25
  %316 = sext i32 %315 to i64
  %317 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %316
  %318 = getelementptr inbounds [12 x i32], ptr %317, i64 0, i64 2
  store i32 %314, ptr %318, align 8, !tbaa !25
  %319 = load i32, ptr %18, align 4, !tbaa !25
  %320 = sub nsw i32 %319, 1
  %321 = mul nsw i32 %320, 4
  %322 = add nsw i32 %321, 2
  %323 = load i32, ptr %18, align 4, !tbaa !25
  %324 = sext i32 %323 to i64
  %325 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %324
  %326 = getelementptr inbounds [12 x i32], ptr %325, i64 0, i64 3
  store i32 %322, ptr %326, align 4, !tbaa !25
  %327 = load i32, ptr %18, align 4, !tbaa !25
  %328 = sub nsw i32 %327, 1
  %329 = mul nsw i32 %328, 4
  %330 = add nsw i32 %329, 1
  %331 = load i32, ptr %18, align 4, !tbaa !25
  %332 = sext i32 %331 to i64
  %333 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %332
  %334 = getelementptr inbounds [12 x i32], ptr %333, i64 0, i64 4
  store i32 %330, ptr %334, align 16, !tbaa !25
  %335 = load i32, ptr %18, align 4, !tbaa !25
  %336 = mul nsw i32 %335, 4
  %337 = add nsw i32 %336, 1
  %338 = load i32, ptr %18, align 4, !tbaa !25
  %339 = sext i32 %338 to i64
  %340 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %339
  %341 = getelementptr inbounds [12 x i32], ptr %340, i64 0, i64 5
  store i32 %337, ptr %341, align 4, !tbaa !25
  %342 = load i32, ptr %18, align 4, !tbaa !25
  %343 = mul nsw i32 %342, 4
  %344 = add nsw i32 %343, 1
  %345 = load i32, ptr %18, align 4, !tbaa !25
  %346 = sext i32 %345 to i64
  %347 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %346
  %348 = getelementptr inbounds [12 x i32], ptr %347, i64 0, i64 6
  store i32 %344, ptr %348, align 8, !tbaa !25
  %349 = load i32, ptr %18, align 4, !tbaa !25
  %350 = mul nsw i32 %349, 4
  %351 = add nsw i32 %350, 2
  %352 = load i32, ptr %18, align 4, !tbaa !25
  %353 = sext i32 %352 to i64
  %354 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %353
  %355 = getelementptr inbounds [12 x i32], ptr %354, i64 0, i64 7
  store i32 %351, ptr %355, align 4, !tbaa !25
  %356 = load i32, ptr %18, align 4, !tbaa !25
  %357 = sub nsw i32 %356, 1
  %358 = mul nsw i32 %357, 4
  %359 = add nsw i32 %358, 2
  %360 = load i32, ptr %18, align 4, !tbaa !25
  %361 = sext i32 %360 to i64
  %362 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %361
  %363 = getelementptr inbounds [12 x i32], ptr %362, i64 0, i64 8
  store i32 %359, ptr %363, align 16, !tbaa !25
  %364 = load i32, ptr %18, align 4, !tbaa !25
  %365 = sub nsw i32 %364, 1
  %366 = mul nsw i32 %365, 4
  %367 = add nsw i32 %366, 3
  %368 = load i32, ptr %18, align 4, !tbaa !25
  %369 = sext i32 %368 to i64
  %370 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %369
  %371 = getelementptr inbounds [12 x i32], ptr %370, i64 0, i64 9
  store i32 %367, ptr %371, align 4, !tbaa !25
  %372 = load i32, ptr %18, align 4, !tbaa !25
  %373 = mul nsw i32 %372, 4
  %374 = add nsw i32 %373, 3
  %375 = load i32, ptr %18, align 4, !tbaa !25
  %376 = sext i32 %375 to i64
  %377 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %376
  %378 = getelementptr inbounds [12 x i32], ptr %377, i64 0, i64 10
  store i32 %374, ptr %378, align 8, !tbaa !25
  %379 = load i32, ptr %18, align 4, !tbaa !25
  %380 = sext i32 %379 to i64
  %381 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 %380
  %382 = getelementptr inbounds [12 x i32], ptr %381, i64 0, i64 11
  store i32 129, ptr %382, align 4, !tbaa !25
  br label %383

383:                                              ; preds = %301, %276
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #8
  br label %384

384:                                              ; preds = %383
  %385 = load i32, ptr %18, align 4, !tbaa !25
  %386 = add nsw i32 %385, 1
  store i32 %386, ptr %18, align 4, !tbaa !25
  br label %135, !llvm.loop !28

387:                                              ; preds = %138
  %388 = call noundef ptr @_ZNK3rmg8Object3D11getMaterialEv(ptr noundef nonnull align 8 dereferenceable(216) %41)
  %389 = icmp eq ptr %388, null
  br i1 %389, label %390, label %441

390:                                              ; preds = %387
  call void @llvm.lifetime.start.p0(i64 4, ptr %36) #8
  %391 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 1
  %392 = load float, ptr %391, align 8, !tbaa !9
  %393 = fpext float %392 to double
  %394 = fmul double 0x400921FB54442D18, %393
  %395 = fptrunc double %394 to float
  store float %395, ptr %36, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %37) #8
  %396 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 2
  %397 = load float, ptr %396, align 4, !tbaa !22
  %398 = getelementptr inbounds %"class.rmg::Cylinder3D", ptr %41, i32 0, i32 1
  %399 = load float, ptr %398, align 8, !tbaa !9
  %400 = call float @llvm.fmuladd.f32(float 2.000000e+00, float %399, float %397)
  store float %400, ptr %37, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %38) #8
  store i32 0, ptr %38, align 4, !tbaa !25
  br label %401

401:                                              ; preds = %437, %390
  %402 = load i32, ptr %38, align 4, !tbaa !25
  %403 = icmp slt i32 %402, 32
  br i1 %403, label %405, label %404

404:                                              ; preds = %401
  store i32 5, ptr %39, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %38) #8
  br label %440

405:                                              ; preds = %401
  call void @llvm.lifetime.start.p0(i64 4, ptr %40) #8
  store i32 0, ptr %40, align 4, !tbaa !25
  br label %406

406:                                              ; preds = %433, %405
  %407 = load i32, ptr %40, align 4, !tbaa !25
  %408 = icmp slt i32 %407, 4
  br i1 %408, label %410, label %409

409:                                              ; preds = %406
  store i32 8, ptr %39, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %40) #8
  br label %436

410:                                              ; preds = %406
  %411 = load float, ptr %36, align 4, !tbaa !21
  %412 = load i32, ptr %38, align 4, !tbaa !25
  %413 = sext i32 %412 to i64
  %414 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 %413
  %415 = load i32, ptr %40, align 4, !tbaa !25
  %416 = sext i32 %415 to i64
  %417 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %414, i64 0, i64 %416
  %418 = getelementptr inbounds %"struct.rmg::Vec2", ptr %417, i32 0, i32 0
  %419 = getelementptr inbounds %struct.anon.2, ptr %418, i32 0, i32 0
  %420 = load float, ptr %419, align 8, !tbaa !24
  %421 = fdiv float %420, %411
  store float %421, ptr %419, align 8, !tbaa !24
  %422 = load float, ptr %37, align 4, !tbaa !21
  %423 = load i32, ptr %38, align 4, !tbaa !25
  %424 = sext i32 %423 to i64
  %425 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 %424
  %426 = load i32, ptr %40, align 4, !tbaa !25
  %427 = sext i32 %426 to i64
  %428 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %425, i64 0, i64 %427
  %429 = getelementptr inbounds %"struct.rmg::Vec2", ptr %428, i32 0, i32 0
  %430 = getelementptr inbounds %struct.anon.2, ptr %429, i32 0, i32 1
  %431 = load float, ptr %430, align 4, !tbaa !24
  %432 = fdiv float %431, %422
  store float %432, ptr %430, align 4, !tbaa !24
  br label %433

433:                                              ; preds = %410
  %434 = load i32, ptr %40, align 4, !tbaa !25
  %435 = add nsw i32 %434, 1
  store i32 %435, ptr %40, align 4, !tbaa !25
  br label %406, !llvm.loop !30

436:                                              ; preds = %409
  br label %437

437:                                              ; preds = %436
  %438 = load i32, ptr %38, align 4, !tbaa !25
  %439 = add nsw i32 %438, 1
  store i32 %439, ptr %38, align 4, !tbaa !25
  br label %401, !llvm.loop !31

440:                                              ; preds = %404
  call void @llvm.lifetime.end.p0(i64 4, ptr %37) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %36) #8
  br label %441

441:                                              ; preds = %440, %387
  %442 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %5, i64 0, i64 0
  %443 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %442, i64 0, i64 0
  %444 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %6, i64 0, i64 0
  %445 = getelementptr inbounds [4 x %"struct.rmg::Vec3"], ptr %444, i64 0, i64 0
  %446 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %7, i64 0, i64 0
  %447 = getelementptr inbounds [4 x %"struct.rmg::Vec2"], ptr %446, i64 0, i64 0
  %448 = getelementptr inbounds [32 x [12 x i32]], ptr %8, i64 0, i64 0
  %449 = getelementptr inbounds [12 x i32], ptr %448, i64 0, i64 0
  call void @_ZN3rmg4MeshC1EPKNS_4Vec3ES3_PKNS_4Vec2EjPKjj(ptr noundef nonnull align 8 dereferenceable(52) %0, ptr noundef %443, ptr noundef %445, ptr noundef %447, i32 noundef 130, ptr noundef %449, i32 noundef 384)
  store i32 1, ptr %39, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 1536, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 1056, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 1584, ptr %6) #8
  call void @llvm.lifetime.end.p0(i64 1584, ptr %5) #8
  ret void
}

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #2 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8), float noundef, float noundef) unnamed_addr #2 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12), float noundef, float noundef, float noundef) unnamed_addr #2 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #4

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #3

; Function Attrs: nounwind
declare double @cos(double noundef) #5

; Function Attrs: nounwind
declare double @sin(double noundef) #5

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local <2 x float> @_ZNK3rmg4Vec2plERKS0_(ptr noundef nonnull align 4 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(8)) #6 align 2

declare noundef ptr @_ZNK3rmg8Object3D11getMaterialEv(ptr noundef nonnull align 8 dereferenceable(216)) #7

declare void @_ZN3rmg4MeshC1EPKNS_4Vec3ES3_PKNS_4Vec2EjPKjj(ptr noundef nonnull align 8 dereferenceable(52), ptr noundef, ptr noundef, ptr noundef, i32 noundef, ptr noundef, i32 noundef) unnamed_addr #7

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress uwtable "min-legal-vector-width"="64" "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 = { 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 #3 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { inlinehint mustprogress uwtable "min-legal-vector-width"="64" "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 #7 = { "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 #8 = { 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, !15, i64 216}
!10 = !{!"_ZTSN3rmg10Cylinder3DE", !11, i64 0, !15, i64 216, !15, i64 220}
!11 = !{!"_ZTSN3rmg8Object3DE", !12, i64 0, !18, i64 48, !19, i64 112, !6, i64 128, !15, i64 136, !15, i64 140, !15, i64 144, !6, i64 152, !6, i64 160, !20, i64 168, !6, i64 184, !6, i64 192, !20, i64 200}
!12 = !{!"_ZTSN3rmg6ObjectE", !13, i64 8, !6, i64 16, !14, i64 24, !16, i64 40, !17, i64 44}
!13 = !{!"long", !7, i64 0}
!14 = !{!"_ZTSN3rmg9ColorRGBAE", !15, i64 0, !15, i64 4, !15, i64 8, !15, i64 12}
!15 = !{!"float", !7, i64 0}
!16 = !{!"bool", !7, i64 0}
!17 = !{!"_ZTSN3rmg10ObjectTypeE", !7, i64 0}
!18 = !{!"_ZTSN3rmg4Mat4E", !7, i64 0}
!19 = !{!"_ZTSN3rmg4Vec3E", !7, i64 0}
!20 = !{!"_ZTSN3rmg8internal7PendingE", !6, i64 0, !6, i64 8}
!21 = !{!15, !15, i64 0}
!22 = !{!10, !15, i64 220}
!23 = !{i64 0, i64 12, !24}
!24 = !{!7, !7, i64 0}
!25 = !{!26, !26, i64 0}
!26 = !{!"int", !7, i64 0}
!27 = !{i64 0, i64 8, !24}
!28 = distinct !{!28, !29}
!29 = !{!"llvm.loop.mustprogress"}
!30 = distinct !{!30, !29}
!31 = distinct !{!31, !29}


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

%"class.rmg::Mesh" = type <{ ptr, ptr, ptr, ptr, i32, [4 x i8], ptr, i32, [4 x i8] }>
%"struct.rmg::Vec3" = type { %union.anon.0 }
%union.anon.0 = type { %struct.anon }
%struct.anon = type { float, float, float }
%"struct.rmg::Vec2" = type { %union.anon.1 }
%union.anon.1 = type { %struct.anon.2 }
%struct.anon.2 = type { float, float }

; 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 uwtable
define dso_local void @_ZN3rmg10Cylinder3D10createMeshEv(ptr dead_on_unwind noalias writable sret(%"class.rmg::Mesh") align 8 %0, ptr noundef nonnull align 8 dereferenceable(224) %1) local_unnamed_addr #1 align 2 {
  %3 = alloca [33 x [4 x %"struct.rmg::Vec3"]], align 16
  %4 = alloca [33 x [4 x %"struct.rmg::Vec3"]], align 16
  %5 = alloca [33 x [4 x %"struct.rmg::Vec2"]], align 16
  %6 = alloca [32 x [12 x i32]], align 16
  %7 = alloca %"struct.rmg::Vec2", align 8
  %8 = alloca %"struct.rmg::Vec2", align 8
  %9 = alloca %"struct.rmg::Vec3", align 4
  %10 = alloca %"struct.rmg::Vec3", align 4
  %11 = alloca %"struct.rmg::Vec3", align 4
  %12 = alloca %"struct.rmg::Vec3", align 4
  %13 = alloca %"struct.rmg::Vec3", align 4
  %14 = alloca %"struct.rmg::Vec3", align 4
  %15 = alloca %"struct.rmg::Vec3", align 4
  %16 = alloca %"struct.rmg::Vec3", align 4
  %17 = alloca %"struct.rmg::Vec3", align 4
  %18 = alloca %"struct.rmg::Vec3", align 4
  %19 = alloca %"struct.rmg::Vec3", align 4
  %20 = alloca %"struct.rmg::Vec3", align 4
  %21 = alloca %"struct.rmg::Vec2", align 4
  %22 = alloca %"struct.rmg::Vec2", align 8
  %23 = alloca %"struct.rmg::Vec2", align 8
  %24 = alloca %"struct.rmg::Vec2", align 4
  call void @llvm.lifetime.start.p0(i64 1584, ptr nonnull %3) #8
  br label %25

25:                                               ; preds = %25, %2
  %.idx = phi i64 [ 0, %2 ], [ %.add, %25 ]
  %.ptr = getelementptr inbounds i8, ptr %3, i64 %.idx
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %.ptr)
  %.add = add nuw nsw i64 %.idx, 12
  %26 = icmp eq i64 %.add, 1584
  br i1 %26, label %27, label %25

27:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 1584, ptr nonnull %4) #8
  br label %28

28:                                               ; preds = %28, %27
  %.idx94 = phi i64 [ 0, %27 ], [ %.add95, %28 ]
  %.ptr96 = getelementptr inbounds i8, ptr %4, i64 %.idx94
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %.ptr96)
  %.add95 = add nuw nsw i64 %.idx94, 12
  %29 = icmp eq i64 %.add95, 1584
  br i1 %29, label %30, label %28

30:                                               ; preds = %28
  call void @llvm.lifetime.start.p0(i64 1056, ptr nonnull %5) #8
  br label %31

31:                                               ; preds = %31, %30
  %.idx98 = phi i64 [ 0, %30 ], [ %.add99, %31 ]
  %.ptr100 = getelementptr inbounds i8, ptr %5, i64 %.idx98
  call void @_ZN3rmg4Vec2C2Ev(ptr noundef nonnull align 4 dereferenceable(8) %.ptr100)
  %.add99 = add nuw nsw i64 %.idx98, 8
  %32 = icmp eq i64 %.add99, 1056
  br i1 %32, label %33, label %31

33:                                               ; preds = %31
  call void @llvm.lifetime.start.p0(i64 1536, ptr nonnull %6) #8
  %34 = getelementptr inbounds i8, ptr %1, i64 216
  %35 = load float, ptr %34, align 8, !tbaa !5
  %36 = fmul float %35, 5.000000e-01
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #8
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %7, float noundef %36, float noundef %36)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #8
  %37 = load float, ptr %34, align 8, !tbaa !5
  %38 = getelementptr inbounds i8, ptr %1, i64 220
  %39 = load float, ptr %38, align 4, !tbaa !20
  %40 = fadd float %37, %39
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %8, float noundef %36, float noundef %40)
  %41 = load float, ptr %34, align 8, !tbaa !5
  %42 = fpext float %41 to double
  %43 = fmul double %42, 0x400921FB54442D18
  %44 = fptrunc double %43 to float
  %45 = load float, ptr %38, align 4, !tbaa !20
  %46 = call float @llvm.fmuladd.f32(float %41, float 2.000000e+00, float %45)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %9) #8
  %47 = fmul float %45, -5.000000e-01
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %9, float noundef %47, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %48 = getelementptr inbounds i8, ptr %3, i64 1536
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(12) %48, ptr noundef nonnull align 4 dereferenceable(12) %9, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %9) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %10) #8
  %49 = load float, ptr %38, align 4, !tbaa !20
  %50 = fmul float %49, 5.000000e-01
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %10, float noundef %50, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %51 = getelementptr inbounds i8, ptr %3, i64 1548
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %51, ptr noundef nonnull align 4 dereferenceable(12) %10, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %10) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %11) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %11, float noundef -1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %52 = getelementptr inbounds i8, ptr %4, i64 1536
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(12) %52, ptr noundef nonnull align 4 dereferenceable(12) %11, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %11) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %12) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %12, float noundef 1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %53 = getelementptr inbounds i8, ptr %4, i64 1548
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %53, ptr noundef nonnull align 4 dereferenceable(12) %12, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %12) #8
  %54 = getelementptr inbounds i8, ptr %5, i64 1024
  %55 = load <2 x float>, ptr %7, align 8, !tbaa !22
  %56 = load <2 x float>, ptr %8, align 8, !tbaa !22
  %57 = shufflevector <2 x float> %55, <2 x float> %56, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
  %58 = insertelement <4 x float> poison, float %44, i64 0
  %59 = insertelement <4 x float> %58, float %46, i64 1
  %60 = shufflevector <4 x float> %59, <4 x float> poison, <4 x i32> <i32 0, i32 1, i32 0, i32 1>
  %61 = fdiv <4 x float> %57, %60
  store <4 x float> %61, ptr %54, align 16, !tbaa !22
  %62 = getelementptr inbounds i8, ptr %6, i64 16
  %63 = getelementptr inbounds i8, ptr %6, i64 32
  %64 = getelementptr inbounds i8, ptr %6, i64 36
  %65 = getelementptr inbounds i8, ptr %6, i64 40
  %66 = getelementptr inbounds i8, ptr %6, i64 44
  br label %70

67:                                               ; preds = %127
  %68 = call noundef ptr @_ZNK3rmg8Object3D11getMaterialEv(ptr noundef nonnull align 8 dereferenceable(216) %1)
  %69 = icmp eq ptr %68, null
  br i1 %69, label %vector.ph, label %.loopexit

70:                                               ; preds = %33, %127
  %indvars.iv = phi i64 [ 0, %33 ], [ %indvars.iv.next, %127 ]
  %71 = trunc nuw nsw i64 %indvars.iv to i32
  %72 = uitofp nneg i32 %71 to float
  %73 = fmul float %72, 3.125000e-02
  %74 = fpext float %73 to double
  %75 = call double @llvm.fmuladd.f64(double %74, double 0x401921FB54442D18, double 0xC00490FDAA22168C)
  %76 = fptrunc double %75 to float
  %77 = fpext float %76 to double
  %78 = call double @cos(double noundef %77) #8
  %79 = fptrunc double %78 to float
  %80 = call double @sin(double noundef %77) #8
  %81 = fptrunc double %80 to float
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %13) #8
  %82 = load float, ptr %38, align 4, !tbaa !20
  %83 = fmul float %82, -5.000000e-01
  %84 = fmul float %36, %79
  %85 = fmul float %36, %81
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %13, float noundef %83, float noundef %84, float noundef %85)
  %86 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %3, i64 0, i64 %indvars.iv
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(12) %86, ptr noundef nonnull align 4 dereferenceable(12) %13, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %13) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %14) #8
  %87 = load float, ptr %38, align 4, !tbaa !20
  %88 = fmul float %87, -5.000000e-01
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %14, float noundef %88, float noundef %84, float noundef %85)
  %89 = getelementptr inbounds i8, ptr %86, i64 12
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %89, ptr noundef nonnull align 4 dereferenceable(12) %14, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %14) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %15) #8
  %90 = load float, ptr %38, align 4, !tbaa !20
  %91 = fmul float %90, 5.000000e-01
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %15, float noundef %91, float noundef %84, float noundef %85)
  %92 = getelementptr inbounds i8, ptr %86, i64 24
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(12) %92, ptr noundef nonnull align 4 dereferenceable(12) %15, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %15) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %16) #8
  %93 = load float, ptr %38, align 4, !tbaa !20
  %94 = fmul float %93, 5.000000e-01
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %16, float noundef %94, float noundef %84, float noundef %85)
  %95 = getelementptr inbounds i8, ptr %86, i64 36
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %95, ptr noundef nonnull align 4 dereferenceable(12) %16, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %16) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %17) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %17, float noundef -1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %96 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec3"]], ptr %4, i64 0, i64 %indvars.iv
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(12) %96, ptr noundef nonnull align 4 dereferenceable(12) %17, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %17) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %18) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %18, float noundef 0.000000e+00, float noundef %79, float noundef %81)
  %97 = getelementptr inbounds i8, ptr %96, i64 12
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %97, ptr noundef nonnull align 4 dereferenceable(12) %18, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %18) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %19) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %19, float noundef 0.000000e+00, float noundef %79, float noundef %81)
  %98 = getelementptr inbounds i8, ptr %96, i64 24
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(12) %98, ptr noundef nonnull align 4 dereferenceable(12) %19, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %19) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %20) #8
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %20, float noundef 1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  %99 = getelementptr inbounds i8, ptr %96, i64 36
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %99, ptr noundef nonnull align 4 dereferenceable(12) %20, i64 12, i1 false), !tbaa.struct !21
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %20) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %21) #8
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %21, float noundef %84, float noundef %85)
  %100 = call <2 x float> @_ZNK3rmg4Vec2plERKS0_(ptr noundef nonnull align 4 dereferenceable(8) %7, ptr noundef nonnull align 4 dereferenceable(8) %21)
  %101 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %indvars.iv
  store <2 x float> %100, ptr %101, align 16, !tbaa !22
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %21) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %22) #8
  %102 = fmul float %36, %76
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %22, float noundef %102, float noundef %36)
  %103 = getelementptr inbounds i8, ptr %101, i64 8
  %104 = load i64, ptr %22, align 8, !tbaa !22
  store i64 %104, ptr %103, align 8, !tbaa !22
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %22) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %23) #8
  %105 = load float, ptr %34, align 8, !tbaa !5
  %106 = load float, ptr %38, align 4, !tbaa !20
  %107 = fadd float %105, %106
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %23, float noundef %102, float noundef %107)
  %108 = load i64, ptr %23, align 8, !tbaa !22
  store i64 %108, ptr %103, align 8, !tbaa !22
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %23) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %24) #8
  call void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8) %24, float noundef %84, float noundef %85)
  %109 = call <2 x float> @_ZNK3rmg4Vec2plERKS0_(ptr noundef nonnull align 4 dereferenceable(8) %8, ptr noundef nonnull align 4 dereferenceable(8) %24)
  %110 = getelementptr inbounds i8, ptr %101, i64 24
  store <2 x float> %109, ptr %110, align 8, !tbaa !22
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %24) #8
  %111 = icmp eq i64 %indvars.iv, 0
  br i1 %111, label %112, label %113

112:                                              ; preds = %70
  store <4 x i32> <i32 124, i32 128, i32 0, i32 126>, ptr %6, align 16, !tbaa !23
  store <4 x i32> <i32 125, i32 1, i32 1, i32 2>, ptr %62, align 16, !tbaa !23
  store i32 126, ptr %63, align 16, !tbaa !23
  store i32 127, ptr %64, align 4, !tbaa !23
  store i32 3, ptr %65, align 8, !tbaa !23
  br label %127

113:                                              ; preds = %70
  %114 = shl nuw nsw i64 %indvars.iv, 2
  %115 = getelementptr inbounds [32 x [12 x i32]], ptr %6, i64 0, i64 %indvars.iv
  %116 = trunc i64 %114 to i32
  %117 = add i32 %116, -4
  store i32 %117, ptr %115, align 16, !tbaa !23
  %118 = getelementptr inbounds i8, ptr %115, i64 4
  store i32 128, ptr %118, align 4, !tbaa !23
  %119 = getelementptr inbounds i8, ptr %115, i64 8
  %120 = trunc nuw nsw i64 %114 to i32
  store i32 %120, ptr %119, align 8, !tbaa !23
  %121 = getelementptr inbounds i8, ptr %115, i64 12
  %122 = trunc i64 %114 to i32
  %123 = insertelement <8 x i32> poison, i32 %122, i64 0
  %124 = shufflevector <8 x i32> %123, <8 x i32> poison, <8 x i32> zeroinitializer
  %125 = add <8 x i32> %124, <i32 -2, i32 -3, i32 1, i32 1, i32 2, i32 -2, i32 -1, i32 3>
  store <8 x i32> %125, ptr %121, align 4, !tbaa !23
  %126 = getelementptr inbounds i8, ptr %115, i64 44
  br label %127

127:                                              ; preds = %113, %112
  %.sink = phi ptr [ %126, %113 ], [ %66, %112 ]
  store i32 129, ptr %.sink, align 4, !tbaa !23
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, 32
  br i1 %exitcond.not, label %67, label %70, !llvm.loop !25

vector.ph:                                        ; preds = %67
  %128 = load float, ptr %34, align 8, !tbaa !5
  %129 = load float, ptr %38, align 4, !tbaa !20
  %130 = call float @llvm.fmuladd.f32(float %128, float 2.000000e+00, float %129)
  %131 = fpext float %128 to double
  %132 = fmul double %131, 0x400921FB54442D18
  %133 = fptrunc double %132 to float
  %broadcast.splatinsert = insertelement <4 x float> poison, float %133, i64 0
  %broadcast.splat = shufflevector <4 x float> %broadcast.splatinsert, <4 x float> poison, <4 x i32> zeroinitializer
  %broadcast.splatinsert114 = insertelement <4 x float> poison, float %130, i64 0
  %broadcast.splat115 = shufflevector <4 x float> %broadcast.splatinsert114, <4 x float> poison, <4 x i32> zeroinitializer
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %134 = or disjoint i64 %index, 1
  %135 = or disjoint i64 %index, 2
  %136 = or disjoint i64 %index, 3
  %137 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %index, i64 0
  %138 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %134, i64 0
  %139 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %135, i64 0
  %140 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %136, i64 0
  %141 = load float, ptr %137, align 16, !tbaa !22
  %142 = load float, ptr %138, align 16, !tbaa !22
  %143 = load float, ptr %139, align 16, !tbaa !22
  %144 = load float, ptr %140, align 16, !tbaa !22
  %145 = insertelement <4 x float> poison, float %141, i64 0
  %146 = insertelement <4 x float> %145, float %142, i64 1
  %147 = insertelement <4 x float> %146, float %143, i64 2
  %148 = insertelement <4 x float> %147, float %144, i64 3
  %149 = fdiv <4 x float> %148, %broadcast.splat
  %150 = getelementptr inbounds i8, ptr %137, i64 4
  %151 = getelementptr inbounds i8, ptr %138, i64 4
  %152 = getelementptr inbounds i8, ptr %139, i64 4
  %153 = getelementptr inbounds i8, ptr %140, i64 4
  %154 = load float, ptr %150, align 4, !tbaa !22
  %155 = load float, ptr %151, align 4, !tbaa !22
  %156 = load float, ptr %152, align 4, !tbaa !22
  %157 = load float, ptr %153, align 4, !tbaa !22
  %158 = insertelement <4 x float> poison, float %154, i64 0
  %159 = insertelement <4 x float> %158, float %155, i64 1
  %160 = insertelement <4 x float> %159, float %156, i64 2
  %161 = insertelement <4 x float> %160, float %157, i64 3
  %162 = fdiv <4 x float> %161, %broadcast.splat115
  %163 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %index, i64 1
  %164 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %134, i64 1
  %165 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %135, i64 1
  %166 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %136, i64 1
  %167 = load float, ptr %163, align 8, !tbaa !22
  %168 = load float, ptr %164, align 8, !tbaa !22
  %169 = load float, ptr %165, align 8, !tbaa !22
  %170 = load float, ptr %166, align 8, !tbaa !22
  %171 = insertelement <4 x float> poison, float %167, i64 0
  %172 = insertelement <4 x float> %171, float %168, i64 1
  %173 = insertelement <4 x float> %172, float %169, i64 2
  %174 = insertelement <4 x float> %173, float %170, i64 3
  %175 = fdiv <4 x float> %174, %broadcast.splat
  %176 = getelementptr inbounds i8, ptr %163, i64 4
  %177 = getelementptr inbounds i8, ptr %164, i64 4
  %178 = getelementptr inbounds i8, ptr %165, i64 4
  %179 = getelementptr inbounds i8, ptr %166, i64 4
  %180 = load float, ptr %176, align 4, !tbaa !22
  %181 = load float, ptr %177, align 4, !tbaa !22
  %182 = load float, ptr %178, align 4, !tbaa !22
  %183 = load float, ptr %179, align 4, !tbaa !22
  %184 = insertelement <4 x float> poison, float %180, i64 0
  %185 = insertelement <4 x float> %184, float %181, i64 1
  %186 = insertelement <4 x float> %185, float %182, i64 2
  %187 = insertelement <4 x float> %186, float %183, i64 3
  %188 = fdiv <4 x float> %187, %broadcast.splat115
  %189 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %index, i64 2
  %190 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %134, i64 2
  %191 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %135, i64 2
  %192 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %136, i64 2
  %193 = load float, ptr %189, align 16, !tbaa !22
  %194 = load float, ptr %190, align 16, !tbaa !22
  %195 = load float, ptr %191, align 16, !tbaa !22
  %196 = load float, ptr %192, align 16, !tbaa !22
  %197 = insertelement <4 x float> poison, float %193, i64 0
  %198 = insertelement <4 x float> %197, float %194, i64 1
  %199 = insertelement <4 x float> %198, float %195, i64 2
  %200 = insertelement <4 x float> %199, float %196, i64 3
  %201 = fdiv <4 x float> %200, %broadcast.splat
  %202 = getelementptr inbounds i8, ptr %189, i64 4
  %203 = getelementptr inbounds i8, ptr %190, i64 4
  %204 = getelementptr inbounds i8, ptr %191, i64 4
  %205 = getelementptr inbounds i8, ptr %192, i64 4
  %206 = load float, ptr %202, align 4, !tbaa !22
  %207 = load float, ptr %203, align 4, !tbaa !22
  %208 = load float, ptr %204, align 4, !tbaa !22
  %209 = load float, ptr %205, align 4, !tbaa !22
  %210 = insertelement <4 x float> poison, float %206, i64 0
  %211 = insertelement <4 x float> %210, float %207, i64 1
  %212 = insertelement <4 x float> %211, float %208, i64 2
  %213 = insertelement <4 x float> %212, float %209, i64 3
  %214 = fdiv <4 x float> %213, %broadcast.splat115
  %215 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %index, i64 3
  %216 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %134, i64 3
  %217 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %135, i64 3
  %218 = getelementptr inbounds [33 x [4 x %"struct.rmg::Vec2"]], ptr %5, i64 0, i64 %136, i64 3
  %219 = load float, ptr %215, align 8, !tbaa !22
  %220 = load float, ptr %216, align 8, !tbaa !22
  %221 = load float, ptr %217, align 8, !tbaa !22
  %222 = load float, ptr %218, align 8, !tbaa !22
  %223 = insertelement <4 x float> poison, float %219, i64 0
  %224 = insertelement <4 x float> %223, float %220, i64 1
  %225 = insertelement <4 x float> %224, float %221, i64 2
  %226 = insertelement <4 x float> %225, float %222, i64 3
  %227 = fdiv <4 x float> %226, %broadcast.splat
  %228 = getelementptr inbounds i8, ptr %215, i64 4
  %229 = getelementptr inbounds i8, ptr %216, i64 4
  %230 = getelementptr inbounds i8, ptr %217, i64 4
  %231 = getelementptr inbounds i8, ptr %218, i64 4
  %232 = load float, ptr %228, align 4, !tbaa !22
  %233 = load float, ptr %229, align 4, !tbaa !22
  %234 = load float, ptr %230, align 4, !tbaa !22
  %235 = load float, ptr %231, align 4, !tbaa !22
  %236 = insertelement <4 x float> poison, float %232, i64 0
  %237 = insertelement <4 x float> %236, float %233, i64 1
  %238 = insertelement <4 x float> %237, float %234, i64 2
  %239 = insertelement <4 x float> %238, float %235, i64 3
  %240 = fdiv <4 x float> %239, %broadcast.splat115
  %241 = getelementptr inbounds i8, ptr %215, i64 -24
  %242 = shufflevector <4 x float> %149, <4 x float> %162, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7>
  %243 = shufflevector <4 x float> %175, <4 x float> %188, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7>
  %244 = shufflevector <4 x float> %201, <4 x float> %214, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7>
  %245 = shufflevector <4 x float> %227, <4 x float> %240, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7>
  %246 = shufflevector <8 x float> %242, <8 x float> %243, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15>
  %247 = shufflevector <8 x float> %244, <8 x float> %245, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15>
  %interleaved.vec = shufflevector <16 x float> %246, <16 x float> %247, <32 x i32> <i32 0, i32 4, i32 8, i32 12, i32 16, i32 20, i32 24, i32 28, i32 1, i32 5, i32 9, i32 13, i32 17, i32 21, i32 25, i32 29, i32 2, i32 6, i32 10, i32 14, i32 18, i32 22, i32 26, i32 30, i32 3, i32 7, i32 11, i32 15, i32 19, i32 23, i32 27, i32 31>
  store <32 x float> %interleaved.vec, ptr %241, align 16, !tbaa !22
  %index.next = add nuw i64 %index, 4
  %248 = icmp eq i64 %index.next, 32
  br i1 %248, label %.loopexit, label %vector.body, !llvm.loop !27

.loopexit:                                        ; preds = %vector.body, %67
  call void @_ZN3rmg4MeshC1EPKNS_4Vec3ES3_PKNS_4Vec2EjPKjj(ptr noundef nonnull align 8 dereferenceable(52) %0, ptr noundef nonnull %3, ptr noundef nonnull %4, ptr noundef nonnull %5, i32 noundef 130, ptr noundef nonnull %6, i32 noundef 384)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #8
  call void @llvm.lifetime.end.p0(i64 1536, ptr nonnull %6) #8
  call void @llvm.lifetime.end.p0(i64 1056, ptr nonnull %5) #8
  call void @llvm.lifetime.end.p0(i64 1584, ptr nonnull %4) #8
  call void @llvm.lifetime.end.p0(i64 1584, ptr nonnull %3) #8
  ret void
}

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #2 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3rmg4Vec2C2Eff(ptr noundef nonnull align 4 dereferenceable(8), float noundef, float noundef) unnamed_addr #2 align 2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12), float noundef, float noundef, float noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #4

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #3

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @cos(double noundef) local_unnamed_addr #5

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @sin(double noundef) local_unnamed_addr #5

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local <2 x float> @_ZNK3rmg4Vec2plERKS0_(ptr noundef nonnull align 4 dereferenceable(8), ptr noundef nonnull align 4 dereferenceable(8)) local_unnamed_addr #6 align 2

declare noundef ptr @_ZNK3rmg8Object3D11getMaterialEv(ptr noundef nonnull align 8 dereferenceable(216)) local_unnamed_addr #7

declare void @_ZN3rmg4MeshC1EPKNS_4Vec3ES3_PKNS_4Vec2EjPKjj(ptr noundef nonnull align 8 dereferenceable(52), ptr noundef, ptr noundef, ptr noundef, i32 noundef, ptr noundef, i32 noundef) unnamed_addr #7

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress uwtable "min-legal-vector-width"="64" "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 = { 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 #3 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { mustprogress nofree nounwind willreturn memory(write) "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 = { inlinehint mustprogress uwtable "min-legal-vector-width"="64" "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 #7 = { "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 #8 = { 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, !14, i64 216}
!6 = !{!"_ZTSN3rmg10Cylinder3DE", !7, i64 0, !14, i64 216, !14, i64 220}
!7 = !{!"_ZTSN3rmg8Object3DE", !8, i64 0, !17, i64 48, !18, i64 112, !12, i64 128, !14, i64 136, !14, i64 140, !14, i64 144, !12, i64 152, !12, i64 160, !19, i64 168, !12, i64 184, !12, i64 192, !19, i64 200}
!8 = !{!"_ZTSN3rmg6ObjectE", !9, i64 8, !12, i64 16, !13, i64 24, !15, i64 40, !16, i64 44}
!9 = !{!"long", !10, i64 0}
!10 = !{!"omnipotent char", !11, i64 0}
!11 = !{!"Simple C++ TBAA"}
!12 = !{!"any pointer", !10, i64 0}
!13 = !{!"_ZTSN3rmg9ColorRGBAE", !14, i64 0, !14, i64 4, !14, i64 8, !14, i64 12}
!14 = !{!"float", !10, i64 0}
!15 = !{!"bool", !10, i64 0}
!16 = !{!"_ZTSN3rmg10ObjectTypeE", !10, i64 0}
!17 = !{!"_ZTSN3rmg4Mat4E", !10, i64 0}
!18 = !{!"_ZTSN3rmg4Vec3E", !10, i64 0}
!19 = !{!"_ZTSN3rmg8internal7PendingE", !12, i64 0, !12, i64 8}
!20 = !{!6, !14, i64 220}
!21 = !{i64 0, i64 12, !22}
!22 = !{!10, !10, i64 0}
!23 = !{!24, !24, i64 0}
!24 = !{!"int", !10, i64 0}
!25 = distinct !{!25, !26}
!26 = !{!"llvm.loop.mustprogress"}
!27 = distinct !{!27, !26, !28, !29}
!28 = !{!"llvm.loop.isvectorized", i32 1}
!29 = !{!"llvm.loop.unroll.runtime.disable"}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,VectorCombinePass