; LLVM IR from yangfengzzz/Arche-webgpu :: vox.math/spherical_harmonics3.ll (ZN3vox19SphericalHarmonics3clERKNS_6VectorIfLm3EEE)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"struct.vox::Color" = type { float, float, float, float }
%"class.vox::SphericalHarmonics3" = type { %"struct.std::array" }
%"struct.std::array" = type { [27 x float] }
%"struct.vox::Vector" = type { float, float, float }

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local { <2 x float>, <2 x float> } @_ZN3vox19SphericalHarmonics3clERKNS_6VectorIfLm3EEE(ptr noundef nonnull align 4 dereferenceable(108) %0, ptr noundef nonnull align 4 dereferenceable(12) %1) #2 align 2 {
  %3 = alloca %"struct.vox::Color", align 4
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca float, align 4
  %8 = alloca float, align 4
  %9 = alloca float, align 4
  %10 = alloca float, align 4
  %11 = alloca float, align 4
  %12 = alloca float, align 4
  %13 = alloca float, align 4
  %14 = alloca float, align 4
  %15 = alloca float, align 4
  %16 = alloca float, align 4
  %17 = alloca float, align 4
  %18 = alloca float, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  %19 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #4
  %20 = getelementptr inbounds %"class.vox::SphericalHarmonics3", ptr %19, i32 0, i32 0
  store ptr %20, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #4
  store float 0x3FEC5BF8C0000000, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #4
  %21 = load ptr, ptr %5, align 8, !tbaa !5
  %22 = getelementptr inbounds %"struct.vox::Vector", ptr %21, i32 0, i32 1
  %23 = load float, ptr %22, align 4, !tbaa !11
  %24 = fmul float 0xBFF05F8C20000000, %23
  store float %24, ptr %8, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #4
  %25 = load ptr, ptr %5, align 8, !tbaa !5
  %26 = getelementptr inbounds %"struct.vox::Vector", ptr %25, i32 0, i32 2
  %27 = load float, ptr %26, align 4, !tbaa !13
  %28 = fmul float 0x3FF05F8C20000000, %27
  store float %28, ptr %9, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #4
  %29 = load ptr, ptr %5, align 8, !tbaa !5
  %30 = getelementptr inbounds %"struct.vox::Vector", ptr %29, i32 0, i32 0
  %31 = load float, ptr %30, align 4, !tbaa !14
  %32 = fmul float 0xBFF05F8C20000000, %31
  store float %32, ptr %10, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #4
  %33 = load ptr, ptr %5, align 8, !tbaa !5
  %34 = getelementptr inbounds %"struct.vox::Vector", ptr %33, i32 0, i32 1
  %35 = load float, ptr %34, align 4, !tbaa !11
  %36 = fmul float 0x3FEB7570C0000000, %35
  %37 = load ptr, ptr %5, align 8, !tbaa !5
  %38 = getelementptr inbounds %"struct.vox::Vector", ptr %37, i32 0, i32 0
  %39 = load float, ptr %38, align 4, !tbaa !14
  %40 = fmul float %36, %39
  store float %40, ptr %11, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  %41 = load ptr, ptr %5, align 8, !tbaa !5
  %42 = getelementptr inbounds %"struct.vox::Vector", ptr %41, i32 0, i32 1
  %43 = load float, ptr %42, align 4, !tbaa !11
  %44 = fmul float 0xBFEB7570C0000000, %43
  %45 = load ptr, ptr %5, align 8, !tbaa !5
  %46 = getelementptr inbounds %"struct.vox::Vector", ptr %45, i32 0, i32 2
  %47 = load float, ptr %46, align 4, !tbaa !13
  %48 = fmul float %44, %47
  store float %48, ptr %12, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  %49 = load ptr, ptr %5, align 8, !tbaa !5
  %50 = getelementptr inbounds %"struct.vox::Vector", ptr %49, i32 0, i32 2
  %51 = load float, ptr %50, align 4, !tbaa !13
  %52 = fmul float 3.000000e+00, %51
  %53 = load ptr, ptr %5, align 8, !tbaa !5
  %54 = getelementptr inbounds %"struct.vox::Vector", ptr %53, i32 0, i32 2
  %55 = load float, ptr %54, align 4, !tbaa !13
  %56 = call float @llvm.fmuladd.f32(float %52, float %55, float -1.000000e+00)
  %57 = fmul float 0x3FCFB4E540000000, %56
  store float %57, ptr %13, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #4
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  %59 = getelementptr inbounds %"struct.vox::Vector", ptr %58, i32 0, i32 2
  %60 = load float, ptr %59, align 4, !tbaa !13
  %61 = fmul float 0xBFEB7570C0000000, %60
  %62 = load ptr, ptr %5, align 8, !tbaa !5
  %63 = getelementptr inbounds %"struct.vox::Vector", ptr %62, i32 0, i32 0
  %64 = load float, ptr %63, align 4, !tbaa !14
  %65 = fmul float %61, %64
  store float %65, ptr %14, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #4
  %66 = load ptr, ptr %5, align 8, !tbaa !5
  %67 = getelementptr inbounds %"struct.vox::Vector", ptr %66, i32 0, i32 0
  %68 = load float, ptr %67, align 4, !tbaa !14
  %69 = load ptr, ptr %5, align 8, !tbaa !5
  %70 = getelementptr inbounds %"struct.vox::Vector", ptr %69, i32 0, i32 0
  %71 = load float, ptr %70, align 4, !tbaa !14
  %72 = load ptr, ptr %5, align 8, !tbaa !5
  %73 = getelementptr inbounds %"struct.vox::Vector", ptr %72, i32 0, i32 1
  %74 = load float, ptr %73, align 4, !tbaa !11
  %75 = load ptr, ptr %5, align 8, !tbaa !5
  %76 = getelementptr inbounds %"struct.vox::Vector", ptr %75, i32 0, i32 1
  %77 = load float, ptr %76, align 4, !tbaa !11
  %78 = fmul float %74, %77
  %79 = fneg float %78
  %80 = call float @llvm.fmuladd.f32(float %68, float %71, float %79)
  %81 = fmul float 0x3FDB756CA0000000, %80
  store float %81, ptr %15, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  %82 = load ptr, ptr %6, align 8, !tbaa !5
  %83 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %82, i64 noundef 0) #4
  %84 = load float, ptr %83, align 4, !tbaa !9
  %85 = fmul float %84, 0x3FEC5BF8C0000000
  store float %85, ptr %16, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #4
  %86 = load ptr, ptr %6, align 8, !tbaa !5
  %87 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %86, i64 noundef 1) #4
  %88 = load float, ptr %87, align 4, !tbaa !9
  %89 = fmul float %88, 0x3FEC5BF8C0000000
  store float %89, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #4
  %90 = load ptr, ptr %6, align 8, !tbaa !5
  %91 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %90, i64 noundef 2) #4
  %92 = load float, ptr %91, align 4, !tbaa !9
  %93 = fmul float %92, 0x3FEC5BF8C0000000
  store float %93, ptr %18, align 4, !tbaa !9
  %94 = load ptr, ptr %6, align 8, !tbaa !5
  %95 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %94, i64 noundef 3) #4
  %96 = load float, ptr %95, align 4, !tbaa !9
  %97 = load float, ptr %8, align 4, !tbaa !9
  %98 = load ptr, ptr %6, align 8, !tbaa !5
  %99 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %98, i64 noundef 6) #4
  %100 = load float, ptr %99, align 4, !tbaa !9
  %101 = load float, ptr %9, align 4, !tbaa !9
  %102 = fmul float %100, %101
  %103 = call float @llvm.fmuladd.f32(float %96, float %97, float %102)
  %104 = load ptr, ptr %6, align 8, !tbaa !5
  %105 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %104, i64 noundef 9) #4
  %106 = load float, ptr %105, align 4, !tbaa !9
  %107 = load float, ptr %10, align 4, !tbaa !9
  %108 = call float @llvm.fmuladd.f32(float %106, float %107, float %103)
  %109 = load float, ptr %16, align 4, !tbaa !9
  %110 = fadd float %109, %108
  store float %110, ptr %16, align 4, !tbaa !9
  %111 = load ptr, ptr %6, align 8, !tbaa !5
  %112 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %111, i64 noundef 4) #4
  %113 = load float, ptr %112, align 4, !tbaa !9
  %114 = load float, ptr %8, align 4, !tbaa !9
  %115 = load ptr, ptr %6, align 8, !tbaa !5
  %116 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %115, i64 noundef 7) #4
  %117 = load float, ptr %116, align 4, !tbaa !9
  %118 = load float, ptr %9, align 4, !tbaa !9
  %119 = fmul float %117, %118
  %120 = call float @llvm.fmuladd.f32(float %113, float %114, float %119)
  %121 = load ptr, ptr %6, align 8, !tbaa !5
  %122 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %121, i64 noundef 10) #4
  %123 = load float, ptr %122, align 4, !tbaa !9
  %124 = load float, ptr %10, align 4, !tbaa !9
  %125 = call float @llvm.fmuladd.f32(float %123, float %124, float %120)
  %126 = load float, ptr %17, align 4, !tbaa !9
  %127 = fadd float %126, %125
  store float %127, ptr %17, align 4, !tbaa !9
  %128 = load ptr, ptr %6, align 8, !tbaa !5
  %129 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %128, i64 noundef 5) #4
  %130 = load float, ptr %129, align 4, !tbaa !9
  %131 = load float, ptr %8, align 4, !tbaa !9
  %132 = load ptr, ptr %6, align 8, !tbaa !5
  %133 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %132, i64 noundef 8) #4
  %134 = load float, ptr %133, align 4, !tbaa !9
  %135 = load float, ptr %9, align 4, !tbaa !9
  %136 = fmul float %134, %135
  %137 = call float @llvm.fmuladd.f32(float %130, float %131, float %136)
  %138 = load ptr, ptr %6, align 8, !tbaa !5
  %139 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %138, i64 noundef 11) #4
  %140 = load float, ptr %139, align 4, !tbaa !9
  %141 = load float, ptr %10, align 4, !tbaa !9
  %142 = call float @llvm.fmuladd.f32(float %140, float %141, float %137)
  %143 = load float, ptr %18, align 4, !tbaa !9
  %144 = fadd float %143, %142
  store float %144, ptr %18, align 4, !tbaa !9
  %145 = load ptr, ptr %6, align 8, !tbaa !5
  %146 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %145, i64 noundef 12) #4
  %147 = load float, ptr %146, align 4, !tbaa !9
  %148 = load float, ptr %11, align 4, !tbaa !9
  %149 = load ptr, ptr %6, align 8, !tbaa !5
  %150 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %149, i64 noundef 15) #4
  %151 = load float, ptr %150, align 4, !tbaa !9
  %152 = load float, ptr %12, align 4, !tbaa !9
  %153 = fmul float %151, %152
  %154 = call float @llvm.fmuladd.f32(float %147, float %148, float %153)
  %155 = load ptr, ptr %6, align 8, !tbaa !5
  %156 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %155, i64 noundef 18) #4
  %157 = load float, ptr %156, align 4, !tbaa !9
  %158 = load float, ptr %13, align 4, !tbaa !9
  %159 = call float @llvm.fmuladd.f32(float %157, float %158, float %154)
  %160 = load ptr, ptr %6, align 8, !tbaa !5
  %161 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %160, i64 noundef 21) #4
  %162 = load float, ptr %161, align 4, !tbaa !9
  %163 = load float, ptr %14, align 4, !tbaa !9
  %164 = call float @llvm.fmuladd.f32(float %162, float %163, float %159)
  %165 = load ptr, ptr %6, align 8, !tbaa !5
  %166 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %165, i64 noundef 24) #4
  %167 = load float, ptr %166, align 4, !tbaa !9
  %168 = load float, ptr %15, align 4, !tbaa !9
  %169 = call float @llvm.fmuladd.f32(float %167, float %168, float %164)
  %170 = load float, ptr %16, align 4, !tbaa !9
  %171 = fadd float %170, %169
  store float %171, ptr %16, align 4, !tbaa !9
  %172 = load ptr, ptr %6, align 8, !tbaa !5
  %173 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %172, i64 noundef 13) #4
  %174 = load float, ptr %173, align 4, !tbaa !9
  %175 = load float, ptr %11, align 4, !tbaa !9
  %176 = load ptr, ptr %6, align 8, !tbaa !5
  %177 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %176, i64 noundef 16) #4
  %178 = load float, ptr %177, align 4, !tbaa !9
  %179 = load float, ptr %12, align 4, !tbaa !9
  %180 = fmul float %178, %179
  %181 = call float @llvm.fmuladd.f32(float %174, float %175, float %180)
  %182 = load ptr, ptr %6, align 8, !tbaa !5
  %183 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %182, i64 noundef 19) #4
  %184 = load float, ptr %183, align 4, !tbaa !9
  %185 = load float, ptr %13, align 4, !tbaa !9
  %186 = call float @llvm.fmuladd.f32(float %184, float %185, float %181)
  %187 = load ptr, ptr %6, align 8, !tbaa !5
  %188 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %187, i64 noundef 22) #4
  %189 = load float, ptr %188, align 4, !tbaa !9
  %190 = load float, ptr %14, align 4, !tbaa !9
  %191 = call float @llvm.fmuladd.f32(float %189, float %190, float %186)
  %192 = load ptr, ptr %6, align 8, !tbaa !5
  %193 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %192, i64 noundef 25) #4
  %194 = load float, ptr %193, align 4, !tbaa !9
  %195 = load float, ptr %15, align 4, !tbaa !9
  %196 = call float @llvm.fmuladd.f32(float %194, float %195, float %191)
  %197 = load float, ptr %17, align 4, !tbaa !9
  %198 = fadd float %197, %196
  store float %198, ptr %17, align 4, !tbaa !9
  %199 = load ptr, ptr %6, align 8, !tbaa !5
  %200 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %199, i64 noundef 14) #4
  %201 = load float, ptr %200, align 4, !tbaa !9
  %202 = load float, ptr %11, align 4, !tbaa !9
  %203 = load ptr, ptr %6, align 8, !tbaa !5
  %204 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %203, i64 noundef 17) #4
  %205 = load float, ptr %204, align 4, !tbaa !9
  %206 = load float, ptr %12, align 4, !tbaa !9
  %207 = fmul float %205, %206
  %208 = call float @llvm.fmuladd.f32(float %201, float %202, float %207)
  %209 = load ptr, ptr %6, align 8, !tbaa !5
  %210 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %209, i64 noundef 20) #4
  %211 = load float, ptr %210, align 4, !tbaa !9
  %212 = load float, ptr %13, align 4, !tbaa !9
  %213 = call float @llvm.fmuladd.f32(float %211, float %212, float %208)
  %214 = load ptr, ptr %6, align 8, !tbaa !5
  %215 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %214, i64 noundef 23) #4
  %216 = load float, ptr %215, align 4, !tbaa !9
  %217 = load float, ptr %14, align 4, !tbaa !9
  %218 = call float @llvm.fmuladd.f32(float %216, float %217, float %213)
  %219 = load ptr, ptr %6, align 8, !tbaa !5
  %220 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %219, i64 noundef 26) #4
  %221 = load float, ptr %220, align 4, !tbaa !9
  %222 = load float, ptr %15, align 4, !tbaa !9
  %223 = call float @llvm.fmuladd.f32(float %221, float %222, float %218)
  %224 = load float, ptr %18, align 4, !tbaa !9
  %225 = fadd float %224, %223
  store float %225, ptr %18, align 4, !tbaa !9
  %226 = load float, ptr %16, align 4, !tbaa !9
  %227 = load float, ptr %17, align 4, !tbaa !9
  %228 = load float, ptr %18, align 4, !tbaa !9
  call void @_ZN3vox5ColorC2Effff(ptr noundef nonnull align 4 dereferenceable(16) %3, float noundef %226, float noundef %227, float noundef %228, float noundef 1.000000e+00)
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #4
  %229 = load { <2 x float>, <2 x float> }, ptr %3, align 4
  ret { <2 x float>, <2 x float> } %229
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108), i64 noundef) #3 align 2

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"float", !7, i64 0}
!11 = !{!12, !10, i64 4}
!12 = !{!"_ZTSN3vox6VectorIfLm3EEE", !10, i64 0, !10, i64 4, !10, i64 8}
!13 = !{!12, !10, i64 8}
!14 = !{!12, !10, i64 0}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"struct.vox::Color" = type { float, float, float, float }

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

; Function Attrs: mustprogress nounwind uwtable
define dso_local { <2 x float>, <2 x float> } @_ZN3vox19SphericalHarmonics3clERKNS_6VectorIfLm3EEE(ptr noundef nonnull align 4 dereferenceable(108) %0, ptr nocapture noundef nonnull readonly align 4 dereferenceable(12) %1) local_unnamed_addr #1 align 2 {
  %3 = alloca %"struct.vox::Color", align 8
  %4 = getelementptr inbounds i8, ptr %1, i64 4
  %5 = load float, ptr %4, align 4, !tbaa !5
  %6 = fmul float %5, 0xBFF05F8C20000000
  %7 = getelementptr inbounds i8, ptr %1, i64 8
  %8 = load float, ptr %7, align 4, !tbaa !10
  %9 = fmul float %8, 0x3FF05F8C20000000
  %10 = load float, ptr %1, align 4, !tbaa !11
  %11 = fmul float %10, 0xBFF05F8C20000000
  %12 = fmul float %5, 0x3FEB7570C0000000
  %13 = fmul float %12, %10
  %14 = fmul float %5, 0xBFEB7570C0000000
  %15 = fmul float %14, %8
  %16 = fmul float %8, 3.000000e+00
  %17 = tail call float @llvm.fmuladd.f32(float %16, float %8, float -1.000000e+00)
  %18 = fmul float %17, 0x3FCFB4E540000000
  %19 = fmul float %8, 0xBFEB7570C0000000
  %20 = fmul float %19, %10
  %21 = fneg float %5
  %22 = fmul float %5, %21
  %23 = tail call float @llvm.fmuladd.f32(float %10, float %10, float %22)
  %24 = fmul float %23, 0x3FDB756CA0000000
  %25 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 0) #2
  %26 = load float, ptr %25, align 4, !tbaa !12
  %27 = fmul float %26, 0x3FEC5BF8C0000000
  %28 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 1) #2
  %29 = load float, ptr %28, align 4, !tbaa !12
  %30 = fmul float %29, 0x3FEC5BF8C0000000
  %31 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 2) #2
  %32 = load float, ptr %31, align 4, !tbaa !12
  %33 = fmul float %32, 0x3FEC5BF8C0000000
  %34 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 3) #2
  %35 = load float, ptr %34, align 4, !tbaa !12
  %36 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 6) #2
  %37 = load float, ptr %36, align 4, !tbaa !12
  %38 = fmul float %9, %37
  %39 = tail call float @llvm.fmuladd.f32(float %35, float %6, float %38)
  %40 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 9) #2
  %41 = load float, ptr %40, align 4, !tbaa !12
  %42 = tail call float @llvm.fmuladd.f32(float %41, float %11, float %39)
  %43 = fadd float %27, %42
  %44 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 4) #2
  %45 = load float, ptr %44, align 4, !tbaa !12
  %46 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 7) #2
  %47 = load float, ptr %46, align 4, !tbaa !12
  %48 = fmul float %9, %47
  %49 = tail call float @llvm.fmuladd.f32(float %45, float %6, float %48)
  %50 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 10) #2
  %51 = load float, ptr %50, align 4, !tbaa !12
  %52 = tail call float @llvm.fmuladd.f32(float %51, float %11, float %49)
  %53 = fadd float %30, %52
  %54 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 5) #2
  %55 = load float, ptr %54, align 4, !tbaa !12
  %56 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 8) #2
  %57 = load float, ptr %56, align 4, !tbaa !12
  %58 = fmul float %9, %57
  %59 = tail call float @llvm.fmuladd.f32(float %55, float %6, float %58)
  %60 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 11) #2
  %61 = load float, ptr %60, align 4, !tbaa !12
  %62 = tail call float @llvm.fmuladd.f32(float %61, float %11, float %59)
  %63 = fadd float %33, %62
  %64 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 12) #2
  %65 = load float, ptr %64, align 4, !tbaa !12
  %66 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 15) #2
  %67 = load float, ptr %66, align 4, !tbaa !12
  %68 = fmul float %15, %67
  %69 = tail call float @llvm.fmuladd.f32(float %65, float %13, float %68)
  %70 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 18) #2
  %71 = load float, ptr %70, align 4, !tbaa !12
  %72 = tail call float @llvm.fmuladd.f32(float %71, float %18, float %69)
  %73 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 21) #2
  %74 = load float, ptr %73, align 4, !tbaa !12
  %75 = tail call float @llvm.fmuladd.f32(float %74, float %20, float %72)
  %76 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 24) #2
  %77 = load float, ptr %76, align 4, !tbaa !12
  %78 = tail call float @llvm.fmuladd.f32(float %77, float %24, float %75)
  %79 = fadd float %43, %78
  %80 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 13) #2
  %81 = load float, ptr %80, align 4, !tbaa !12
  %82 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 16) #2
  %83 = load float, ptr %82, align 4, !tbaa !12
  %84 = fmul float %15, %83
  %85 = tail call float @llvm.fmuladd.f32(float %81, float %13, float %84)
  %86 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 19) #2
  %87 = load float, ptr %86, align 4, !tbaa !12
  %88 = tail call float @llvm.fmuladd.f32(float %87, float %18, float %85)
  %89 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 22) #2
  %90 = load float, ptr %89, align 4, !tbaa !12
  %91 = tail call float @llvm.fmuladd.f32(float %90, float %20, float %88)
  %92 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 25) #2
  %93 = load float, ptr %92, align 4, !tbaa !12
  %94 = tail call float @llvm.fmuladd.f32(float %93, float %24, float %91)
  %95 = fadd float %53, %94
  %96 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 14) #2
  %97 = load float, ptr %96, align 4, !tbaa !12
  %98 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 17) #2
  %99 = load float, ptr %98, align 4, !tbaa !12
  %100 = fmul float %15, %99
  %101 = tail call float @llvm.fmuladd.f32(float %97, float %13, float %100)
  %102 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 20) #2
  %103 = load float, ptr %102, align 4, !tbaa !12
  %104 = tail call float @llvm.fmuladd.f32(float %103, float %18, float %101)
  %105 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 23) #2
  %106 = load float, ptr %105, align 4, !tbaa !12
  %107 = tail call float @llvm.fmuladd.f32(float %106, float %20, float %104)
  %108 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108) %0, i64 noundef 26) #2
  %109 = load float, ptr %108, align 4, !tbaa !12
  %110 = tail call float @llvm.fmuladd.f32(float %109, float %24, float %107)
  %111 = fadd float %63, %110
  call void @_ZN3vox5ColorC2Effff(ptr noundef nonnull align 4 dereferenceable(16) %3, float noundef %79, float noundef %95, float noundef %111, float noundef 1.000000e+00)
  %.fca.0.load = load <2 x float>, ptr %3, align 8
  %.fca.0.insert = insertvalue { <2 x float>, <2 x float> } poison, <2 x float> %.fca.0.load, 0
  %.fca.1.gep = getelementptr inbounds i8, ptr %3, i64 8
  %.fca.1.load = load <2 x float>, ptr %.fca.1.gep, align 8
  %.fca.1.insert = insertvalue { <2 x float>, <2 x float> } %.fca.0.insert, <2 x float> %.fca.1.load, 1
  ret { <2 x float>, <2 x float> } %.fca.1.insert
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt5arrayIfLm27EEixEm(ptr noundef nonnull align 4 dereferenceable(108), i64 noundef) local_unnamed_addr #1 align 2

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #1 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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, !7, i64 4}
!6 = !{!"_ZTSN3vox6VectorIfLm3EEE", !7, i64 0, !7, i64 4, !7, i64 8}
!7 = !{!"float", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!6, !7, i64 8}
!11 = !{!6, !7, i64 0}
!12 = !{!7, !7, i64 0}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,TailCallElimPass