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

; 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::Sphere3D" = type <{ %"class.rmg::Object3D", float, [4 x i8] }>
%"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 @_ZN3rmg8Sphere3D10createMeshEv(ptr dead_on_unwind noalias writable sret(%"class.rmg::Mesh") align 8 %0, ptr noundef nonnull align 8 dereferenceable(220) %1) #1 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca [6 x [9 x [9 x %"struct.rmg::Vec3"]]], align 16
  %6 = alloca [6 x [9 x [9 x %"struct.rmg::Vec3"]]], align 16
  %7 = alloca [6 x [9 x [9 x %"struct.rmg::Vec2"]]], align 16
  %8 = alloca [6 x [8 x [8 x [6 x i32]]]], align 16
  %9 = alloca float, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, 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::Vec3", 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::Vec3", align 4
  %31 = alloca %"struct.rmg::Vec3", align 4
  %32 = alloca %"struct.rmg::Vec3", align 4
  %33 = alloca i32, align 4
  %34 = alloca i32, align 4
  %35 = alloca %"struct.rmg::Vec3", align 4
  %36 = alloca { <2 x float>, float }, align 8
  %37 = alloca %"struct.rmg::Vec3", align 4
  %38 = alloca { <2 x float>, float }, align 8
  %39 = alloca %"struct.rmg::Vec3", align 4
  %40 = alloca %"struct.rmg::Vec3", align 4
  %41 = alloca { <2 x float>, float }, align 8
  %42 = alloca { <2 x float>, float }, align 8
  %43 = alloca %"struct.rmg::Vec3", align 4
  %44 = alloca { <2 x float>, float }, align 8
  %45 = alloca %"struct.rmg::Vec3", align 4
  %46 = alloca { <2 x float>, float }, align 8
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  %47 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 5832, ptr %5) #6
  %48 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %5, i32 0, i32 0, i32 0, i32 0
  %49 = getelementptr inbounds %"struct.rmg::Vec3", ptr %48, i64 486
  br label %50

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

54:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 5832, ptr %6) #6
  %55 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %6, i32 0, i32 0, i32 0, i32 0
  %56 = getelementptr inbounds %"struct.rmg::Vec3", ptr %55, i64 486
  br label %57

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

61:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 3888, ptr %7) #6
  %62 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec2"]]], ptr %7, i32 0, i32 0, i32 0, i32 0
  %63 = getelementptr inbounds %"struct.rmg::Vec2", ptr %62, i64 486
  br label %64

64:                                               ; preds = %64, %61
  %65 = phi ptr [ %62, %61 ], [ %66, %64 ]
  call void @_ZN3rmg4Vec2C2Ev(ptr noundef nonnull align 4 dereferenceable(8) %65)
  %66 = getelementptr inbounds %"struct.rmg::Vec2", ptr %65, i64 1
  %67 = icmp eq ptr %66, %63
  br i1 %67, label %68, label %64

68:                                               ; preds = %64
  call void @llvm.lifetime.start.p0(i64 9216, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #6
  %69 = getelementptr inbounds %"class.rmg::Sphere3D", ptr %47, i32 0, i32 1
  %70 = load float, ptr %69, align 8, !tbaa !9
  %71 = fdiv float %70, 2.000000e+00
  store float %71, ptr %9, align 4, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  store i32 0, ptr %10, align 4, !tbaa !22
  br label %72

72:                                               ; preds = %290, %68
  %73 = load i32, ptr %10, align 4, !tbaa !22
  %74 = icmp slt i32 %73, 6
  br i1 %74, label %76, label %75

75:                                               ; preds = %72
  store i32 2, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  br label %293

76:                                               ; preds = %72
  call void @llvm.lifetime.start.p0(i64 12, ptr %12) #6
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %12)
  call void @llvm.lifetime.start.p0(i64 12, ptr %13) #6
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %13)
  call void @llvm.lifetime.start.p0(i64 12, ptr %14) #6
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %14)
  %77 = load i32, ptr %10, align 4, !tbaa !22
  %78 = icmp eq i32 %77, 0
  br i1 %78, label %79, label %80

79:                                               ; preds = %76
  call void @llvm.lifetime.start.p0(i64 12, ptr %15) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %15, float noundef -1.000000e+00, float noundef 1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %12, ptr align 4 %15, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %15) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %16) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %16, float noundef 0.000000e+00, float noundef -1.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %13, ptr align 4 %16, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %16) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %17) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %17, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %17, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %17) #6
  br label %105

80:                                               ; preds = %76
  %81 = load i32, ptr %10, align 4, !tbaa !22
  %82 = icmp eq i32 %81, 1
  br i1 %82, label %83, label %84

83:                                               ; preds = %80
  call void @llvm.lifetime.start.p0(i64 12, ptr %18) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %18, float noundef 1.000000e+00, float noundef -1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %12, ptr align 4 %18, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %18) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %19) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %19, float noundef 0.000000e+00, float noundef 1.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %13, ptr align 4 %19, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %19) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %20) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %20, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %20, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %20) #6
  br label %104

84:                                               ; preds = %80
  %85 = load i32, ptr %10, align 4, !tbaa !22
  %86 = icmp eq i32 %85, 2
  br i1 %86, label %87, label %88

87:                                               ; preds = %84
  call void @llvm.lifetime.start.p0(i64 12, ptr %21) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %21, float noundef -1.000000e+00, float noundef -1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %12, ptr align 4 %21, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %21) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %22) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %22, float noundef 1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %13, ptr align 4 %22, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %22) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %23) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %23, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %23, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %23) #6
  br label %103

88:                                               ; preds = %84
  %89 = load i32, ptr %10, align 4, !tbaa !22
  %90 = icmp eq i32 %89, 3
  br i1 %90, label %91, label %92

91:                                               ; preds = %88
  call void @llvm.lifetime.start.p0(i64 12, ptr %24) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %24, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %12, ptr align 4 %24, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %24) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %25) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %25, float noundef -1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %13, ptr align 4 %25, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %25) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %26) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %26, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %26, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %26) #6
  br label %102

92:                                               ; preds = %88
  %93 = load i32, ptr %10, align 4, !tbaa !22
  %94 = icmp eq i32 %93, 4
  br i1 %94, label %95, label %96

95:                                               ; preds = %92
  call void @llvm.lifetime.start.p0(i64 12, ptr %27) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %27, float noundef -1.000000e+00, float noundef 1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %12, ptr align 4 %27, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %27) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %28) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %28, float noundef 1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %13, ptr align 4 %28, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %28) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %29) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %29, float noundef 0.000000e+00, float noundef -1.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %29, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %29) #6
  br label %101

96:                                               ; preds = %92
  %97 = load i32, ptr %10, align 4, !tbaa !22
  %98 = icmp eq i32 %97, 5
  br i1 %98, label %99, label %100

99:                                               ; preds = %96
  call void @llvm.lifetime.start.p0(i64 12, ptr %30) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %30, float noundef -1.000000e+00, float noundef -1.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %12, ptr align 4 %30, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %30) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %31) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %31, float noundef 1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %13, ptr align 4 %31, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %31) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %32) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %32, float noundef 0.000000e+00, float noundef 1.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %32, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %32) #6
  br label %100

100:                                              ; preds = %99, %96
  br label %101

101:                                              ; preds = %100, %95
  br label %102

102:                                              ; preds = %101, %91
  br label %103

103:                                              ; preds = %102, %87
  br label %104

104:                                              ; preds = %103, %83
  br label %105

105:                                              ; preds = %104, %79
  call void @llvm.lifetime.start.p0(i64 4, ptr %33) #6
  store i32 0, ptr %33, align 4, !tbaa !22
  br label %106

106:                                              ; preds = %286, %105
  %107 = load i32, ptr %33, align 4, !tbaa !22
  %108 = icmp slt i32 %107, 9
  br i1 %108, label %110, label %109

109:                                              ; preds = %106
  store i32 5, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %33) #6
  br label %289

110:                                              ; preds = %106
  call void @llvm.lifetime.start.p0(i64 4, ptr %34) #6
  store i32 0, ptr %34, align 4, !tbaa !22
  br label %111

111:                                              ; preds = %282, %110
  %112 = load i32, ptr %34, align 4, !tbaa !22
  %113 = icmp slt i32 %112, 9
  br i1 %113, label %115, label %114

114:                                              ; preds = %111
  store i32 8, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %34) #6
  br label %285

115:                                              ; preds = %111
  call void @llvm.lifetime.start.p0(i64 12, ptr %35) #6
  %116 = load i32, ptr %34, align 4, !tbaa !22
  %117 = sitofp i32 %116 to float
  %118 = fdiv float %117, 8.000000e+00
  %119 = fmul float 2.000000e+00, %118
  %120 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %119, ptr noundef nonnull align 4 dereferenceable(12) %13)
  %121 = getelementptr inbounds %"struct.rmg::Vec3", ptr %35, i32 0, i32 0
  %122 = getelementptr inbounds %union.anon.0, ptr %121, i32 0, i32 0
  store { <2 x float>, float } %120, ptr %36, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %122, ptr align 8 %36, i64 12, i1 false)
  call void @llvm.lifetime.start.p0(i64 12, ptr %37) #6
  %123 = load i32, ptr %33, align 4, !tbaa !22
  %124 = sitofp i32 %123 to float
  %125 = fdiv float %124, 8.000000e+00
  %126 = fmul float 2.000000e+00, %125
  %127 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %126, ptr noundef nonnull align 4 dereferenceable(12) %14)
  %128 = getelementptr inbounds %"struct.rmg::Vec3", ptr %37, i32 0, i32 0
  %129 = getelementptr inbounds %union.anon.0, ptr %128, i32 0, i32 0
  store { <2 x float>, float } %127, ptr %38, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %129, ptr align 8 %38, i64 12, i1 false)
  call void @llvm.lifetime.start.p0(i64 12, ptr %39) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %40) #6
  %130 = call { <2 x float>, float } @_ZNK3rmg4Vec3plERKS0_(ptr noundef nonnull align 4 dereferenceable(12) %12, ptr noundef nonnull align 4 dereferenceable(12) %35)
  %131 = getelementptr inbounds %"struct.rmg::Vec3", ptr %40, i32 0, i32 0
  %132 = getelementptr inbounds %union.anon.0, ptr %131, i32 0, i32 0
  store { <2 x float>, float } %130, ptr %41, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %132, ptr align 8 %41, i64 12, i1 false)
  %133 = call { <2 x float>, float } @_ZNK3rmg4Vec3plERKS0_(ptr noundef nonnull align 4 dereferenceable(12) %40, ptr noundef nonnull align 4 dereferenceable(12) %37)
  %134 = getelementptr inbounds %"struct.rmg::Vec3", ptr %39, i32 0, i32 0
  %135 = getelementptr inbounds %union.anon.0, ptr %134, i32 0, i32 0
  store { <2 x float>, float } %133, ptr %42, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %135, ptr align 8 %42, i64 12, i1 false)
  call void @llvm.lifetime.end.p0(i64 12, ptr %40) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %43) #6
  %136 = call { <2 x float>, float } @_ZNK3rmg4Vec39normalizeEv(ptr noundef nonnull align 4 dereferenceable(12) %39)
  %137 = getelementptr inbounds %"struct.rmg::Vec3", ptr %43, i32 0, i32 0
  %138 = getelementptr inbounds %union.anon.0, ptr %137, i32 0, i32 0
  store { <2 x float>, float } %136, ptr %44, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %138, ptr align 8 %44, i64 12, i1 false)
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %39, ptr align 4 %43, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %43) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr %45) #6
  %139 = load float, ptr %9, align 4, !tbaa !21
  %140 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %139, ptr noundef nonnull align 4 dereferenceable(12) %39)
  %141 = getelementptr inbounds %"struct.rmg::Vec3", ptr %45, i32 0, i32 0
  %142 = getelementptr inbounds %union.anon.0, ptr %141, i32 0, i32 0
  store { <2 x float>, float } %140, ptr %46, align 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %142, ptr align 8 %46, i64 12, i1 false)
  %143 = load i32, ptr %10, align 4, !tbaa !22
  %144 = sext i32 %143 to i64
  %145 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %5, i64 0, i64 %144
  %146 = load i32, ptr %33, align 4, !tbaa !22
  %147 = sext i32 %146 to i64
  %148 = getelementptr inbounds [9 x [9 x %"struct.rmg::Vec3"]], ptr %145, i64 0, i64 %147
  %149 = load i32, ptr %34, align 4, !tbaa !22
  %150 = sext i32 %149 to i64
  %151 = getelementptr inbounds [9 x %"struct.rmg::Vec3"], ptr %148, i64 0, i64 %150
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %151, ptr align 4 %45, i64 12, i1 false), !tbaa.struct !24
  call void @llvm.lifetime.end.p0(i64 12, ptr %45) #6
  %152 = load i32, ptr %10, align 4, !tbaa !22
  %153 = sext i32 %152 to i64
  %154 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %6, i64 0, i64 %153
  %155 = load i32, ptr %33, align 4, !tbaa !22
  %156 = sext i32 %155 to i64
  %157 = getelementptr inbounds [9 x [9 x %"struct.rmg::Vec3"]], ptr %154, i64 0, i64 %156
  %158 = load i32, ptr %34, align 4, !tbaa !22
  %159 = sext i32 %158 to i64
  %160 = getelementptr inbounds [9 x %"struct.rmg::Vec3"], ptr %157, i64 0, i64 %159
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %160, ptr align 4 %39, i64 12, i1 false), !tbaa.struct !24
  %161 = load i32, ptr %33, align 4, !tbaa !22
  %162 = icmp slt i32 %161, 8
  br i1 %162, label %163, label %281

163:                                              ; preds = %115
  %164 = load i32, ptr %34, align 4, !tbaa !22
  %165 = icmp slt i32 %164, 8
  br i1 %165, label %166, label %281

166:                                              ; preds = %163
  %167 = load i32, ptr %10, align 4, !tbaa !22
  %168 = mul nsw i32 %167, 9
  %169 = mul nsw i32 %168, 9
  %170 = load i32, ptr %33, align 4, !tbaa !22
  %171 = mul nsw i32 %170, 9
  %172 = add nsw i32 %169, %171
  %173 = load i32, ptr %34, align 4, !tbaa !22
  %174 = add nsw i32 %172, %173
  %175 = load i32, ptr %10, align 4, !tbaa !22
  %176 = sext i32 %175 to i64
  %177 = getelementptr inbounds [6 x [8 x [8 x [6 x i32]]]], ptr %8, i64 0, i64 %176
  %178 = load i32, ptr %33, align 4, !tbaa !22
  %179 = sext i32 %178 to i64
  %180 = getelementptr inbounds [8 x [8 x [6 x i32]]], ptr %177, i64 0, i64 %179
  %181 = load i32, ptr %34, align 4, !tbaa !22
  %182 = sext i32 %181 to i64
  %183 = getelementptr inbounds [8 x [6 x i32]], ptr %180, i64 0, i64 %182
  %184 = getelementptr inbounds [6 x i32], ptr %183, i64 0, i64 0
  store i32 %174, ptr %184, align 8, !tbaa !22
  %185 = load i32, ptr %10, align 4, !tbaa !22
  %186 = mul nsw i32 %185, 9
  %187 = mul nsw i32 %186, 9
  %188 = load i32, ptr %33, align 4, !tbaa !22
  %189 = mul nsw i32 %188, 9
  %190 = add nsw i32 %187, %189
  %191 = load i32, ptr %34, align 4, !tbaa !22
  %192 = add nsw i32 %190, %191
  %193 = add nsw i32 %192, 1
  %194 = load i32, ptr %10, align 4, !tbaa !22
  %195 = sext i32 %194 to i64
  %196 = getelementptr inbounds [6 x [8 x [8 x [6 x i32]]]], ptr %8, i64 0, i64 %195
  %197 = load i32, ptr %33, align 4, !tbaa !22
  %198 = sext i32 %197 to i64
  %199 = getelementptr inbounds [8 x [8 x [6 x i32]]], ptr %196, i64 0, i64 %198
  %200 = load i32, ptr %34, align 4, !tbaa !22
  %201 = sext i32 %200 to i64
  %202 = getelementptr inbounds [8 x [6 x i32]], ptr %199, i64 0, i64 %201
  %203 = getelementptr inbounds [6 x i32], ptr %202, i64 0, i64 1
  store i32 %193, ptr %203, align 4, !tbaa !22
  %204 = load i32, ptr %10, align 4, !tbaa !22
  %205 = mul nsw i32 %204, 9
  %206 = mul nsw i32 %205, 9
  %207 = load i32, ptr %33, align 4, !tbaa !22
  %208 = add nsw i32 %207, 1
  %209 = mul nsw i32 %208, 9
  %210 = add nsw i32 %206, %209
  %211 = load i32, ptr %34, align 4, !tbaa !22
  %212 = add nsw i32 %210, %211
  %213 = add nsw i32 %212, 1
  %214 = load i32, ptr %10, align 4, !tbaa !22
  %215 = sext i32 %214 to i64
  %216 = getelementptr inbounds [6 x [8 x [8 x [6 x i32]]]], ptr %8, i64 0, i64 %215
  %217 = load i32, ptr %33, align 4, !tbaa !22
  %218 = sext i32 %217 to i64
  %219 = getelementptr inbounds [8 x [8 x [6 x i32]]], ptr %216, i64 0, i64 %218
  %220 = load i32, ptr %34, align 4, !tbaa !22
  %221 = sext i32 %220 to i64
  %222 = getelementptr inbounds [8 x [6 x i32]], ptr %219, i64 0, i64 %221
  %223 = getelementptr inbounds [6 x i32], ptr %222, i64 0, i64 2
  store i32 %213, ptr %223, align 8, !tbaa !22
  %224 = load i32, ptr %10, align 4, !tbaa !22
  %225 = mul nsw i32 %224, 9
  %226 = mul nsw i32 %225, 9
  %227 = load i32, ptr %33, align 4, !tbaa !22
  %228 = add nsw i32 %227, 1
  %229 = mul nsw i32 %228, 9
  %230 = add nsw i32 %226, %229
  %231 = load i32, ptr %34, align 4, !tbaa !22
  %232 = add nsw i32 %230, %231
  %233 = add nsw i32 %232, 1
  %234 = load i32, ptr %10, align 4, !tbaa !22
  %235 = sext i32 %234 to i64
  %236 = getelementptr inbounds [6 x [8 x [8 x [6 x i32]]]], ptr %8, i64 0, i64 %235
  %237 = load i32, ptr %33, align 4, !tbaa !22
  %238 = sext i32 %237 to i64
  %239 = getelementptr inbounds [8 x [8 x [6 x i32]]], ptr %236, i64 0, i64 %238
  %240 = load i32, ptr %34, align 4, !tbaa !22
  %241 = sext i32 %240 to i64
  %242 = getelementptr inbounds [8 x [6 x i32]], ptr %239, i64 0, i64 %241
  %243 = getelementptr inbounds [6 x i32], ptr %242, i64 0, i64 3
  store i32 %233, ptr %243, align 4, !tbaa !22
  %244 = load i32, ptr %10, align 4, !tbaa !22
  %245 = mul nsw i32 %244, 9
  %246 = mul nsw i32 %245, 9
  %247 = load i32, ptr %33, align 4, !tbaa !22
  %248 = add nsw i32 %247, 1
  %249 = mul nsw i32 %248, 9
  %250 = add nsw i32 %246, %249
  %251 = load i32, ptr %34, align 4, !tbaa !22
  %252 = add nsw i32 %250, %251
  %253 = load i32, ptr %10, align 4, !tbaa !22
  %254 = sext i32 %253 to i64
  %255 = getelementptr inbounds [6 x [8 x [8 x [6 x i32]]]], ptr %8, i64 0, i64 %254
  %256 = load i32, ptr %33, align 4, !tbaa !22
  %257 = sext i32 %256 to i64
  %258 = getelementptr inbounds [8 x [8 x [6 x i32]]], ptr %255, i64 0, i64 %257
  %259 = load i32, ptr %34, align 4, !tbaa !22
  %260 = sext i32 %259 to i64
  %261 = getelementptr inbounds [8 x [6 x i32]], ptr %258, i64 0, i64 %260
  %262 = getelementptr inbounds [6 x i32], ptr %261, i64 0, i64 4
  store i32 %252, ptr %262, align 8, !tbaa !22
  %263 = load i32, ptr %10, align 4, !tbaa !22
  %264 = mul nsw i32 %263, 9
  %265 = mul nsw i32 %264, 9
  %266 = load i32, ptr %33, align 4, !tbaa !22
  %267 = mul nsw i32 %266, 9
  %268 = add nsw i32 %265, %267
  %269 = load i32, ptr %34, align 4, !tbaa !22
  %270 = add nsw i32 %268, %269
  %271 = load i32, ptr %10, align 4, !tbaa !22
  %272 = sext i32 %271 to i64
  %273 = getelementptr inbounds [6 x [8 x [8 x [6 x i32]]]], ptr %8, i64 0, i64 %272
  %274 = load i32, ptr %33, align 4, !tbaa !22
  %275 = sext i32 %274 to i64
  %276 = getelementptr inbounds [8 x [8 x [6 x i32]]], ptr %273, i64 0, i64 %275
  %277 = load i32, ptr %34, align 4, !tbaa !22
  %278 = sext i32 %277 to i64
  %279 = getelementptr inbounds [8 x [6 x i32]], ptr %276, i64 0, i64 %278
  %280 = getelementptr inbounds [6 x i32], ptr %279, i64 0, i64 5
  store i32 %270, ptr %280, align 4, !tbaa !22
  br label %281

281:                                              ; preds = %166, %163, %115
  call void @llvm.lifetime.end.p0(i64 12, ptr %39) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %37) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %35) #6
  br label %282

282:                                              ; preds = %281
  %283 = load i32, ptr %34, align 4, !tbaa !22
  %284 = add nsw i32 %283, 1
  store i32 %284, ptr %34, align 4, !tbaa !22
  br label %111, !llvm.loop !26

285:                                              ; preds = %114
  br label %286

286:                                              ; preds = %285
  %287 = load i32, ptr %33, align 4, !tbaa !22
  %288 = add nsw i32 %287, 1
  store i32 %288, ptr %33, align 4, !tbaa !22
  br label %106, !llvm.loop !28

289:                                              ; preds = %109
  call void @llvm.lifetime.end.p0(i64 12, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr %12) #6
  br label %290

290:                                              ; preds = %289
  %291 = load i32, ptr %10, align 4, !tbaa !22
  %292 = add nsw i32 %291, 1
  store i32 %292, ptr %10, align 4, !tbaa !22
  br label %72, !llvm.loop !29

293:                                              ; preds = %75
  %294 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %5, i64 0, i64 0
  %295 = getelementptr inbounds [9 x [9 x %"struct.rmg::Vec3"]], ptr %294, i64 0, i64 0
  %296 = getelementptr inbounds [9 x %"struct.rmg::Vec3"], ptr %295, i64 0, i64 0
  %297 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %6, i64 0, i64 0
  %298 = getelementptr inbounds [9 x [9 x %"struct.rmg::Vec3"]], ptr %297, i64 0, i64 0
  %299 = getelementptr inbounds [9 x %"struct.rmg::Vec3"], ptr %298, i64 0, i64 0
  %300 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec2"]]], ptr %7, i64 0, i64 0
  %301 = getelementptr inbounds [9 x [9 x %"struct.rmg::Vec2"]], ptr %300, i64 0, i64 0
  %302 = getelementptr inbounds [9 x %"struct.rmg::Vec2"], ptr %301, i64 0, i64 0
  %303 = getelementptr inbounds [6 x [8 x [8 x [6 x i32]]]], ptr %8, i64 0, i64 0
  %304 = getelementptr inbounds [8 x [8 x [6 x i32]]], ptr %303, i64 0, i64 0
  %305 = getelementptr inbounds [8 x [6 x i32]], ptr %304, i64 0, i64 0
  %306 = getelementptr inbounds [6 x i32], ptr %305, i64 0, i64 0
  call void @_ZN3rmg4MeshC1EPKNS_4Vec3ES3_PKNS_4Vec2EjPKjj(ptr noundef nonnull align 8 dereferenceable(52) %0, ptr noundef %296, ptr noundef %299, ptr noundef %302, i32 noundef 486, ptr noundef %306, i32 noundef 2304)
  store i32 1, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 9216, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 3888, ptr %7) #6
  call void @llvm.lifetime.end.p0(i64 5832, ptr %6) #6
  call void @llvm.lifetime.end.p0(i64 5832, ptr %5) #6
  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 @_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) #3

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef, ptr noundef nonnull align 4 dereferenceable(12)) #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { <2 x float>, float } @_ZNK3rmg4Vec3plERKS0_(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) #4 align 2

declare { <2 x float>, float } @_ZNK3rmg4Vec39normalizeEv(ptr noundef nonnull align 4 dereferenceable(12)) #5

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 #5

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 nounwind willreturn memory(argmem: readwrite) }
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 = { "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, !15, i64 216}
!10 = !{!"_ZTSN3rmg8Sphere3DE", !11, i64 0, !15, i64 216}
!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 = !{!23, !23, i64 0}
!23 = !{!"int", !7, i64 0}
!24 = !{i64 0, i64 12, !25}
!25 = !{!7, !7, i64 0}
!26 = distinct !{!26, !27}
!27 = !{!"llvm.loop.mustprogress"}
!28 = distinct !{!28, !27}
!29 = distinct !{!29, !27}


; 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 @_ZN3rmg8Sphere3D10createMeshEv(ptr dead_on_unwind noalias writable sret(%"class.rmg::Mesh") align 8 %0, ptr nocapture noundef nonnull readonly align 8 dereferenceable(220) %1) local_unnamed_addr #1 align 2 {
  %3 = alloca [6 x [9 x [9 x %"struct.rmg::Vec3"]]], align 16
  %4 = alloca [6 x [9 x [9 x %"struct.rmg::Vec3"]]], align 16
  %5 = alloca [6 x [9 x [9 x %"struct.rmg::Vec2"]]], align 16
  %6 = alloca [6 x [8 x [8 x [6 x i32]]]], align 16
  %7 = alloca %"struct.rmg::Vec3", align 4
  %8 = alloca %"struct.rmg::Vec3", align 4
  %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::Vec3", 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 8
  %29 = alloca %"struct.rmg::Vec3", align 8
  %30 = alloca %"struct.rmg::Vec3", align 8
  %31 = alloca %"struct.rmg::Vec3", align 8
  call void @llvm.lifetime.start.p0(i64 5832, ptr nonnull %3) #6
  br label %32

32:                                               ; preds = %32, %2
  %.idx = phi i64 [ 0, %2 ], [ %.add, %32 ]
  %.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
  %33 = icmp eq i64 %.add, 5832
  br i1 %33, label %34, label %32

34:                                               ; preds = %32
  call void @llvm.lifetime.start.p0(i64 5832, ptr nonnull %4) #6
  br label %35

35:                                               ; preds = %35, %34
  %.idx86 = phi i64 [ 0, %34 ], [ %.add87, %35 ]
  %.ptr88 = getelementptr inbounds i8, ptr %4, i64 %.idx86
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %.ptr88)
  %.add87 = add nuw nsw i64 %.idx86, 12
  %36 = icmp eq i64 %.add87, 5832
  br i1 %36, label %37, label %35

37:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 3888, ptr nonnull %5) #6
  br label %38

38:                                               ; preds = %38, %37
  %.idx90 = phi i64 [ 0, %37 ], [ %.add91, %38 ]
  %.ptr92 = getelementptr inbounds i8, ptr %5, i64 %.idx90
  call void @_ZN3rmg4Vec2C2Ev(ptr noundef nonnull align 4 dereferenceable(8) %.ptr92)
  %.add91 = add nuw nsw i64 %.idx90, 8
  %39 = icmp eq i64 %.add91, 3888
  br i1 %39, label %40, label %38

40:                                               ; preds = %38
  call void @llvm.lifetime.start.p0(i64 9216, ptr nonnull %6) #6
  %41 = getelementptr inbounds i8, ptr %1, i64 216
  %42 = load float, ptr %41, align 8, !tbaa !5
  %43 = fmul float %42, 5.000000e-01
  %.sroa.224.0..sroa_idx = getelementptr inbounds i8, ptr %28, i64 8
  %.sroa.220.0..sroa_idx = getelementptr inbounds i8, ptr %29, i64 8
  %.sroa.216.0..sroa_idx = getelementptr inbounds i8, ptr %31, i64 8
  %.sroa.212.0..sroa_idx = getelementptr inbounds i8, ptr %30, i64 8
  br label %45

44:                                               ; preds = %74
  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 486, ptr noundef nonnull %6, i32 noundef 2304)
  call void @llvm.lifetime.end.p0(i64 9216, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 3888, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 5832, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 5832, ptr nonnull %3) #6
  ret void

45:                                               ; preds = %40, %74
  %indvars.iv108 = phi i64 [ 0, %40 ], [ %indvars.iv.next109, %74 ]
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %7) #6
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %7)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %8) #6
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %8)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %9) #6
  call void @_ZN3rmg4Vec3C2Ev(ptr noundef nonnull align 4 dereferenceable(12) %9)
  %46 = trunc nuw nsw i64 %indvars.iv108 to i32
  switch i32 %46, label %default.unreachable [
    i32 0, label %47
    i32 1, label %48
    i32 2, label %49
    i32 3, label %50
    i32 4, label %51
    i32 5, label %52
  ]

47:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %10) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %10, float noundef -1.000000e+00, float noundef 1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %10, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %10) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %11) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %11, float noundef 0.000000e+00, float noundef -1.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(12) %11, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %11) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %12) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %12, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %9, ptr noundef nonnull align 4 dereferenceable(12) %12, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %12) #6
  br label %53

48:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %13) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %13, float noundef 1.000000e+00, float noundef -1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %13, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %13) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %14) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %14, float noundef 0.000000e+00, float noundef 1.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(12) %14, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %14) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %15) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %15, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %9, ptr noundef nonnull align 4 dereferenceable(12) %15, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %15) #6
  br label %53

49:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %16) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %16, float noundef -1.000000e+00, float noundef -1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %16, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %16) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %17) #6
  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)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(12) %17, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %17) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %18) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %18, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %9, ptr noundef nonnull align 4 dereferenceable(12) %18, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %18) #6
  br label %53

50:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %19) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %19, float noundef 1.000000e+00, float noundef 1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %19, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %19) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %20) #6
  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)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(12) %20, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %20) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %21) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %21, float noundef 0.000000e+00, float noundef 0.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %9, ptr noundef nonnull align 4 dereferenceable(12) %21, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %21) #6
  br label %53

51:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %22) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %22, float noundef -1.000000e+00, float noundef 1.000000e+00, float noundef -1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %22, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %22) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %23) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %23, float noundef 1.000000e+00, float noundef 0.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(12) %23, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %23) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %24) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %24, float noundef 0.000000e+00, float noundef -1.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %9, ptr noundef nonnull align 4 dereferenceable(12) %24, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %24) #6
  br label %53

52:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %25) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %25, float noundef -1.000000e+00, float noundef -1.000000e+00, float noundef 1.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %25, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %25) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %26) #6
  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)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %8, ptr noundef nonnull align 4 dereferenceable(12) %26, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %26) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %27) #6
  call void @_ZN3rmg4Vec3C2Efff(ptr noundef nonnull align 4 dereferenceable(12) %27, float noundef 0.000000e+00, float noundef 1.000000e+00, float noundef 0.000000e+00)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %9, ptr noundef nonnull align 4 dereferenceable(12) %27, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %27) #6
  br label %53

default.unreachable:                              ; preds = %45
  unreachable

53:                                               ; preds = %48, %50, %52, %51, %49, %47
  %54 = mul nuw nsw i64 %indvars.iv108, 81
  br label %.preheader

.preheader:                                       ; preds = %53, %.split.us
  %indvars.iv104 = phi i64 [ 0, %53 ], [ %indvars.iv.next105, %.split.us ]
  %55 = trunc nuw nsw i64 %indvars.iv104 to i32
  %56 = uitofp nneg i32 %55 to float
  %57 = fmul float %56, 1.250000e-01
  %58 = fmul float %57, 2.000000e+00
  %.not = icmp eq i64 %indvars.iv104, 8
  %59 = mul nuw nsw i64 %indvars.iv104, 9
  %60 = add nuw nsw i64 %59, %54
  %61 = add nuw nsw i64 %60, 9
  br i1 %.not, label %.preheader.split.us, label %.preheader.split

.preheader.split.us:                              ; preds = %.preheader, %.preheader.split.us
  %indvars.iv100 = phi i64 [ %indvars.iv.next101, %.preheader.split.us ], [ 0, %.preheader ]
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %28) #6
  %62 = trunc nuw nsw i64 %indvars.iv100 to i32
  %63 = uitofp nneg i32 %62 to float
  %64 = fmul float %63, 1.250000e-01
  %65 = fmul float %64, 2.000000e+00
  %66 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %65, ptr noundef nonnull align 4 dereferenceable(12) %8)
  %.fca.0.extract21.us = extractvalue { <2 x float>, float } %66, 0
  %.fca.1.extract22.us = extractvalue { <2 x float>, float } %66, 1
  store <2 x float> %.fca.0.extract21.us, ptr %28, align 8
  store float %.fca.1.extract22.us, ptr %.sroa.224.0..sroa_idx, align 8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %29) #6
  %67 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %58, ptr noundef nonnull align 4 dereferenceable(12) %9)
  %.fca.0.extract17.us = extractvalue { <2 x float>, float } %67, 0
  %.fca.1.extract18.us = extractvalue { <2 x float>, float } %67, 1
  store <2 x float> %.fca.0.extract17.us, ptr %29, align 8
  store float %.fca.1.extract18.us, ptr %.sroa.220.0..sroa_idx, align 8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %30) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %31) #6
  %68 = call { <2 x float>, float } @_ZNK3rmg4Vec3plERKS0_(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %28)
  %.fca.0.extract13.us = extractvalue { <2 x float>, float } %68, 0
  %.fca.1.extract14.us = extractvalue { <2 x float>, float } %68, 1
  store <2 x float> %.fca.0.extract13.us, ptr %31, align 8
  store float %.fca.1.extract14.us, ptr %.sroa.216.0..sroa_idx, align 8
  %69 = call { <2 x float>, float } @_ZNK3rmg4Vec3plERKS0_(ptr noundef nonnull align 4 dereferenceable(12) %31, ptr noundef nonnull align 4 dereferenceable(12) %29)
  %.fca.0.extract9.us = extractvalue { <2 x float>, float } %69, 0
  %.fca.1.extract10.us = extractvalue { <2 x float>, float } %69, 1
  store <2 x float> %.fca.0.extract9.us, ptr %30, align 8
  store float %.fca.1.extract10.us, ptr %.sroa.212.0..sroa_idx, align 8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %31) #6
  %70 = call { <2 x float>, float } @_ZNK3rmg4Vec39normalizeEv(ptr noundef nonnull align 4 dereferenceable(12) %30)
  %.fca.0.extract3.us = extractvalue { <2 x float>, float } %70, 0
  %.fca.1.extract4.us = extractvalue { <2 x float>, float } %70, 1
  store <2 x float> %.fca.0.extract3.us, ptr %30, align 8
  store float %.fca.1.extract4.us, ptr %.sroa.212.0..sroa_idx, align 8, !tbaa !21
  %71 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %43, ptr noundef nonnull align 4 dereferenceable(12) %30)
  %.fca.0.extract.us = extractvalue { <2 x float>, float } %71, 0
  %.fca.1.extract.us = extractvalue { <2 x float>, float } %71, 1
  %72 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %3, i64 0, i64 %indvars.iv108, i64 8, i64 %indvars.iv100
  store <2 x float> %.fca.0.extract.us, ptr %72, align 4
  %.sroa.4.0..sroa_idx.us = getelementptr inbounds i8, ptr %72, i64 8
  store float %.fca.1.extract.us, ptr %.sroa.4.0..sroa_idx.us, align 4, !tbaa !21
  %73 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %4, i64 0, i64 %indvars.iv108, i64 8, i64 %indvars.iv100
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %73, ptr noundef nonnull align 8 dereferenceable(12) %30, i64 12, i1 false), !tbaa.struct !20
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %30) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %29) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %28) #6
  %indvars.iv.next101 = add nuw nsw i64 %indvars.iv100, 1
  %exitcond103.not = icmp eq i64 %indvars.iv.next101, 9
  br i1 %exitcond103.not, label %.split.us, label %.preheader.split.us, !llvm.loop !22

74:                                               ; preds = %.split.us
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %9) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %8) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #6
  %indvars.iv.next109 = add nuw nsw i64 %indvars.iv108, 1
  %exitcond111.not = icmp eq i64 %indvars.iv.next109, 6
  br i1 %exitcond111.not, label %44, label %45, !llvm.loop !24

.split.us:                                        ; preds = %.preheader.split.us, %.thread
  %indvars.iv.next105 = add nuw nsw i64 %indvars.iv104, 1
  %exitcond107.not = icmp eq i64 %indvars.iv.next105, 9
  br i1 %exitcond107.not, label %74, label %.preheader, !llvm.loop !25

.preheader.split:                                 ; preds = %.preheader, %87
  %indvars.iv = phi i64 [ %indvars.iv.next, %87 ], [ 0, %.preheader ]
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %28) #6
  %75 = trunc nuw nsw i64 %indvars.iv to i32
  %76 = uitofp nneg i32 %75 to float
  %77 = fmul float %76, 1.250000e-01
  %78 = fmul float %77, 2.000000e+00
  %79 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %78, ptr noundef nonnull align 4 dereferenceable(12) %8)
  %.fca.0.extract21 = extractvalue { <2 x float>, float } %79, 0
  %.fca.1.extract22 = extractvalue { <2 x float>, float } %79, 1
  store <2 x float> %.fca.0.extract21, ptr %28, align 8
  store float %.fca.1.extract22, ptr %.sroa.224.0..sroa_idx, align 8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %29) #6
  %80 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %58, ptr noundef nonnull align 4 dereferenceable(12) %9)
  %.fca.0.extract17 = extractvalue { <2 x float>, float } %80, 0
  %.fca.1.extract18 = extractvalue { <2 x float>, float } %80, 1
  store <2 x float> %.fca.0.extract17, ptr %29, align 8
  store float %.fca.1.extract18, ptr %.sroa.220.0..sroa_idx, align 8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %30) #6
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %31) #6
  %81 = call { <2 x float>, float } @_ZNK3rmg4Vec3plERKS0_(ptr noundef nonnull align 4 dereferenceable(12) %7, ptr noundef nonnull align 4 dereferenceable(12) %28)
  %.fca.0.extract13 = extractvalue { <2 x float>, float } %81, 0
  %.fca.1.extract14 = extractvalue { <2 x float>, float } %81, 1
  store <2 x float> %.fca.0.extract13, ptr %31, align 8
  store float %.fca.1.extract14, ptr %.sroa.216.0..sroa_idx, align 8
  %82 = call { <2 x float>, float } @_ZNK3rmg4Vec3plERKS0_(ptr noundef nonnull align 4 dereferenceable(12) %31, ptr noundef nonnull align 4 dereferenceable(12) %29)
  %.fca.0.extract9 = extractvalue { <2 x float>, float } %82, 0
  %.fca.1.extract10 = extractvalue { <2 x float>, float } %82, 1
  store <2 x float> %.fca.0.extract9, ptr %30, align 8
  store float %.fca.1.extract10, ptr %.sroa.212.0..sroa_idx, align 8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %31) #6
  %83 = call { <2 x float>, float } @_ZNK3rmg4Vec39normalizeEv(ptr noundef nonnull align 4 dereferenceable(12) %30)
  %.fca.0.extract3 = extractvalue { <2 x float>, float } %83, 0
  %.fca.1.extract4 = extractvalue { <2 x float>, float } %83, 1
  store <2 x float> %.fca.0.extract3, ptr %30, align 8
  store float %.fca.1.extract4, ptr %.sroa.212.0..sroa_idx, align 8, !tbaa !21
  %84 = call { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef %43, ptr noundef nonnull align 4 dereferenceable(12) %30)
  %.fca.0.extract = extractvalue { <2 x float>, float } %84, 0
  %.fca.1.extract = extractvalue { <2 x float>, float } %84, 1
  %85 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %3, i64 0, i64 %indvars.iv108, i64 %indvars.iv104, i64 %indvars.iv
  store <2 x float> %.fca.0.extract, ptr %85, align 4
  %.sroa.4.0..sroa_idx = getelementptr inbounds i8, ptr %85, i64 8
  store float %.fca.1.extract, ptr %.sroa.4.0..sroa_idx, align 4, !tbaa !21
  %86 = getelementptr inbounds [6 x [9 x [9 x %"struct.rmg::Vec3"]]], ptr %4, i64 0, i64 %indvars.iv108, i64 %indvars.iv104, i64 %indvars.iv
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %86, ptr noundef nonnull align 8 dereferenceable(12) %30, i64 12, i1 false), !tbaa.struct !20
  %.not97 = icmp eq i64 %indvars.iv, 8
  br i1 %.not97, label %.thread, label %87

.thread:                                          ; preds = %.preheader.split
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %30) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %29) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %28) #6
  br label %.split.us

87:                                               ; preds = %.preheader.split
  %88 = add nuw nsw i64 %60, %indvars.iv
  %89 = getelementptr inbounds [6 x [8 x [8 x [6 x i32]]]], ptr %6, i64 0, i64 %indvars.iv108, i64 %indvars.iv104, i64 %indvars.iv
  %90 = trunc nuw nsw i64 %88 to i32
  store i32 %90, ptr %89, align 8, !tbaa !26
  %91 = getelementptr inbounds i8, ptr %89, i64 4
  %92 = trunc i64 %88 to i32
  %93 = add i32 %92, 1
  store i32 %93, ptr %91, align 4, !tbaa !26
  %94 = add nuw nsw i64 %61, %indvars.iv
  %95 = getelementptr inbounds i8, ptr %89, i64 8
  %96 = trunc i64 %94 to i32
  %97 = add i32 %96, 1
  store i32 %97, ptr %95, align 8, !tbaa !26
  %98 = getelementptr inbounds i8, ptr %89, i64 12
  store i32 %97, ptr %98, align 4, !tbaa !26
  %99 = getelementptr inbounds i8, ptr %89, i64 16
  %100 = trunc nuw nsw i64 %94 to i32
  store i32 %100, ptr %99, align 8, !tbaa !26
  %101 = getelementptr inbounds i8, ptr %89, i64 20
  store i32 %90, ptr %101, align 4, !tbaa !26
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %30) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %29) #6
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %28) #6
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  br label %.preheader.split
}

; 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 @_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) #3

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { <2 x float>, float } @_ZN3rmgmlEfRKNS_4Vec3E(float noundef, ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { <2 x float>, float } @_ZNK3rmg4Vec3plERKS0_(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #4 align 2

declare { <2 x float>, float } @_ZNK3rmg4Vec39normalizeEv(ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #5

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 #5

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 nounwind willreturn memory(argmem: readwrite) }
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 = { "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, !14, i64 216}
!6 = !{!"_ZTSN3rmg8Sphere3DE", !7, i64 0, !14, i64 216}
!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 = !{i64 0, i64 12, !21}
!21 = !{!10, !10, i64 0}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}
!24 = distinct !{!24, !23}
!25 = distinct !{!25, !23}
!26 = !{!27, !27, i64 0}
!27 = !{!"int", !10, i64 0}


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