; LLVM IR from Try/Tempest :: Engine/thirdparty/spirv_cross (spirv_glsl)

; 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.spirv_cross::TypedID.281" = type { i32 }
%"struct.spirv_cross::SPIRConstant" = type { %"struct.spirv_cross::IVariant.base", %"class.spirv_cross::TypedID.281", %"struct.spirv_cross::SPIRConstant::ConstantMatrix", i8, i8, i8, %"class.spirv_cross::SmallVector.310", %"class.std::__cxx11::basic_string" }
%"struct.spirv_cross::IVariant.base" = type <{ ptr, %"class.spirv_cross::TypedID.280" }>
%"class.spirv_cross::TypedID.280" = type { i32 }
%"struct.spirv_cross::SPIRConstant::ConstantMatrix" = type { [4 x %"struct.spirv_cross::SPIRConstant::ConstantVector"], [4 x %"class.spirv_cross::TypedID.280"], i32, [4 x i8] }
%"struct.spirv_cross::SPIRConstant::ConstantVector" = type <{ [4 x %"union.spirv_cross::SPIRConstant::Constant"], [4 x %"class.spirv_cross::TypedID.280"], i32, [4 x i8] }>
%"union.spirv_cross::SPIRConstant::Constant" = type { i64 }
%"class.spirv_cross::SmallVector.310" = type { %"class.spirv_cross::VectorView.311", i64, %"class.spirv_cross::AlignedBuffer.312" }
%"class.spirv_cross::VectorView.311" = type { ptr, i64 }
%"class.spirv_cross::AlignedBuffer.312" = type { [32 x i8] }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"struct.spirv_cross::SPIRType" = type { %"struct.spirv_cross::IVariant.base", i32, i32, i32, i32, i32, %"class.spirv_cross::SmallVector.92", %"class.spirv_cross::SmallVector.284", i32, i8, i8, i32, %"class.spirv_cross::SmallVector.227", %"class.spirv_cross::SmallVector.92", %"struct.spirv_cross::SPIRType::ImageType", %"class.spirv_cross::TypedID.281", %"class.spirv_cross::TypedID.281", %"class.std::unordered_set.165" }
%"class.spirv_cross::SmallVector.284" = type { %"class.spirv_cross::VectorView.285", i64, %"class.spirv_cross::AlignedBuffer.286" }
%"class.spirv_cross::VectorView.285" = type { ptr, i64 }
%"class.spirv_cross::AlignedBuffer.286" = type { [8 x i8] }
%"class.spirv_cross::SmallVector.227" = type { %"class.spirv_cross::VectorView.228", i64, %"class.spirv_cross::AlignedBuffer.229" }
%"class.spirv_cross::VectorView.228" = type { ptr, i64 }
%"class.spirv_cross::AlignedBuffer.229" = type { [32 x i8] }
%"class.spirv_cross::SmallVector.92" = type { %"class.spirv_cross::VectorView.93", i64, %"class.spirv_cross::AlignedBuffer.94" }
%"class.spirv_cross::VectorView.93" = type { ptr, i64 }
%"class.spirv_cross::AlignedBuffer.94" = type { [32 x i8] }
%"struct.spirv_cross::SPIRType::ImageType" = type { %"class.spirv_cross::TypedID.281", i32, i8, i8, i8, i32, i32, i32 }
%"class.std::unordered_set.165" = type { %"class.std::_Hashtable.166" }
%"class.std::_Hashtable.166" = type { ptr, i64, %"struct.std::__detail::_Hash_node_base", i64, %"struct.std::__detail::_Prime_rehash_policy", ptr }
%"struct.std::__detail::_Hash_node_base" = type { ptr }
%"struct.std::__detail::_Prime_rehash_policy" = type { float, i64 }

@_ZTIN11spirv_cross13CompilerErrorE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.952 = external hidden unnamed_addr constant [53 x i8], align 1

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

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

declare ptr @__cxa_allocate_exception(i64)

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

declare i32 @__gxx_personality_v0(...)

declare void @__cxa_free_exception(ptr)

; Function Attrs: nounwind
declare void @_ZNSt13runtime_errorD2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2

declare void @__cxa_throw(ptr, ptr, ptr)

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(336) ptr @_ZN11spirv_cross8Compiler3getINS_8SPIRTypeEEERT_j(ptr noundef nonnull align 8 dereferenceable(3176), i32 noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK11spirv_cross7TypedIDILNS_5TypesE1EEcvjEv(ptr noundef nonnull align 4 dereferenceable(4)) #3 align 2

declare noundef zeroext i1 @_ZNK11spirv_cross8Compiler8is_arrayERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176), ptr noundef nonnull align 8 dereferenceable(336)) #4

declare noundef zeroext i1 @_ZNK11spirv_cross8Compiler9is_matrixERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176), ptr noundef nonnull align 8 dereferenceable(336)) #4

declare noundef zeroext i1 @_ZNK11spirv_cross8Compiler9is_vectorERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176), ptr noundef nonnull align 8 dereferenceable(336)) #4

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11spirv_cross12CompilerGLSL23fill_composite_constantERNS_12SPIRConstantENS_7TypedIDILNS_5TypesE1EEERKNS_11SmallVectorINS3_ILS4_3EEELm8EEE(ptr noundef nonnull align 8 dereferenceable(9848) %0, ptr noundef nonnull align 8 dereferenceable(360) %1, i32 %2, ptr noundef nonnull align 8 dereferenceable(56) %3) #1 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca %"class.spirv_cross::TypedID.281", align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  %13 = alloca i32, align 4
  %14 = getelementptr inbounds %"class.spirv_cross::TypedID.281", ptr %5, i32 0, i32 0
  store i32 %2, ptr %14, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %3, ptr %8, align 8, !tbaa !5
  %15 = load ptr, ptr %6, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %16 = call noundef i32 @_ZNK11spirv_cross7TypedIDILNS_5TypesE1EEcvjEv(ptr noundef nonnull align 4 dereferenceable(4) %5)
  %17 = call noundef nonnull align 8 dereferenceable(336) ptr @_ZN11spirv_cross8Compiler3getINS_8SPIRTypeEEERT_j(ptr noundef nonnull align 8 dereferenceable(3176) %15, i32 noundef %16)
  store ptr %17, ptr %9, align 8, !tbaa !5
  %18 = load ptr, ptr %7, align 8, !tbaa !5
  %19 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant", ptr %18, i32 0, i32 3
  store i8 1, ptr %19, align 8, !tbaa !9
  %20 = load ptr, ptr %9, align 8, !tbaa !5
  %21 = call noundef zeroext i1 @_ZNK11spirv_cross8Compiler8is_arrayERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176) %15, ptr noundef nonnull align 8 dereferenceable(336) %20)
  br i1 %21, label %27, label %22

22:                                               ; preds = %4
  %23 = load ptr, ptr %9, align 8, !tbaa !5
  %24 = getelementptr inbounds %"struct.spirv_cross::SPIRType", ptr %23, i32 0, i32 2
  %25 = load i32, ptr %24, align 8, !tbaa !23
  %26 = icmp eq i32 %25, 15
  br i1 %26, label %27, label %32

27:                                               ; preds = %22, %4
  %28 = load ptr, ptr %8, align 8, !tbaa !5
  %29 = load ptr, ptr %7, align 8, !tbaa !5
  %30 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant", ptr %29, i32 0, i32 6
  %31 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZN11spirv_cross11SmallVectorINS_7TypedIDILNS_5TypesE3EEELm8EEaSERKS4_(ptr noundef nonnull align 8 dereferenceable(56) %30, ptr noundef nonnull align 8 dereferenceable(56) %28) #5
  br label %121

32:                                               ; preds = %22
  %33 = load ptr, ptr %9, align 8, !tbaa !5
  %34 = call noundef zeroext i1 @_ZNK11spirv_cross8Compiler9is_matrixERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176) %15, ptr noundef nonnull align 8 dereferenceable(336) %33)
  br i1 %34, label %35, label %75

35:                                               ; preds = %32
  %36 = load ptr, ptr %9, align 8, !tbaa !5
  %37 = getelementptr inbounds %"struct.spirv_cross::SPIRType", ptr %36, i32 0, i32 5
  %38 = load i32, ptr %37, align 4, !tbaa !46
  %39 = load ptr, ptr %7, align 8, !tbaa !5
  %40 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant", ptr %39, i32 0, i32 2
  %41 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant::ConstantMatrix", ptr %40, i32 0, i32 2
  store i32 %38, ptr %41, align 8, !tbaa !47
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  store i32 0, ptr %10, align 4, !tbaa !48
  br label %42

42:                                               ; preds = %71, %35
  %43 = load i32, ptr %10, align 4, !tbaa !48
  %44 = load ptr, ptr %9, align 8, !tbaa !5
  %45 = getelementptr inbounds %"struct.spirv_cross::SPIRType", ptr %44, i32 0, i32 5
  %46 = load i32, ptr %45, align 4, !tbaa !46
  %47 = icmp ult i32 %43, %46
  br i1 %47, label %49, label %48

48:                                               ; preds = %42
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  br label %74

49:                                               ; preds = %42
  %50 = load ptr, ptr %8, align 8, !tbaa !5
  %51 = load i32, ptr %10, align 4, !tbaa !48
  %52 = zext i32 %51 to i64
  %53 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE3EEEEixEm(ptr noundef nonnull align 8 dereferenceable(16) %50, i64 noundef %52) #5
  %54 = load ptr, ptr %7, align 8, !tbaa !5
  %55 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant", ptr %54, i32 0, i32 2
  %56 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant::ConstantMatrix", ptr %55, i32 0, i32 1
  %57 = load i32, ptr %10, align 4, !tbaa !48
  %58 = zext i32 %57 to i64
  %59 = getelementptr inbounds [4 x %"class.spirv_cross::TypedID.280"], ptr %56, i64 0, i64 %58
  %60 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN11spirv_cross7TypedIDILNS_5TypesE0EEaSILS1_3EEERS2_RKNS0_IXT_EEE(ptr noundef nonnull align 4 dereferenceable(4) %59, ptr noundef nonnull align 4 dereferenceable(4) %53)
  %61 = load ptr, ptr %9, align 8, !tbaa !5
  %62 = getelementptr inbounds %"struct.spirv_cross::SPIRType", ptr %61, i32 0, i32 4
  %63 = load i32, ptr %62, align 8, !tbaa !49
  %64 = load ptr, ptr %7, align 8, !tbaa !5
  %65 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant", ptr %64, i32 0, i32 2
  %66 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant::ConstantMatrix", ptr %65, i32 0, i32 0
  %67 = load i32, ptr %10, align 4, !tbaa !48
  %68 = zext i32 %67 to i64
  %69 = getelementptr inbounds [4 x %"struct.spirv_cross::SPIRConstant::ConstantVector"], ptr %66, i64 0, i64 %68
  %70 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant::ConstantVector", ptr %69, i32 0, i32 2
  store i32 %63, ptr %70, align 8, !tbaa !50
  br label %71

71:                                               ; preds = %49
  %72 = load i32, ptr %10, align 4, !tbaa !48
  %73 = add i32 %72, 1
  store i32 %73, ptr %10, align 4, !tbaa !48
  br label %42, !llvm.loop !52

74:                                               ; preds = %48
  br label %120

75:                                               ; preds = %32
  %76 = load ptr, ptr %9, align 8, !tbaa !5
  %77 = call noundef zeroext i1 @_ZNK11spirv_cross8Compiler9is_vectorERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176) %15, ptr noundef nonnull align 8 dereferenceable(336) %76)
  br i1 %77, label %78, label %112

78:                                               ; preds = %75
  %79 = load ptr, ptr %9, align 8, !tbaa !5
  %80 = getelementptr inbounds %"struct.spirv_cross::SPIRType", ptr %79, i32 0, i32 4
  %81 = load i32, ptr %80, align 8, !tbaa !49
  %82 = load ptr, ptr %7, align 8, !tbaa !5
  %83 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant", ptr %82, i32 0, i32 2
  %84 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant::ConstantMatrix", ptr %83, i32 0, i32 0
  %85 = getelementptr inbounds [4 x %"struct.spirv_cross::SPIRConstant::ConstantVector"], ptr %84, i64 0, i64 0
  %86 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant::ConstantVector", ptr %85, i32 0, i32 2
  store i32 %81, ptr %86, align 8, !tbaa !50
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  store i32 0, ptr %11, align 4, !tbaa !48
  br label %87

87:                                               ; preds = %108, %78
  %88 = load i32, ptr %11, align 4, !tbaa !48
  %89 = load ptr, ptr %9, align 8, !tbaa !5
  %90 = getelementptr inbounds %"struct.spirv_cross::SPIRType", ptr %89, i32 0, i32 4
  %91 = load i32, ptr %90, align 8, !tbaa !49
  %92 = icmp ult i32 %88, %91
  br i1 %92, label %94, label %93

93:                                               ; preds = %87
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  br label %111

94:                                               ; preds = %87
  %95 = load ptr, ptr %8, align 8, !tbaa !5
  %96 = load i32, ptr %11, align 4, !tbaa !48
  %97 = zext i32 %96 to i64
  %98 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE3EEEEixEm(ptr noundef nonnull align 8 dereferenceable(16) %95, i64 noundef %97) #5
  %99 = load ptr, ptr %7, align 8, !tbaa !5
  %100 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant", ptr %99, i32 0, i32 2
  %101 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant::ConstantMatrix", ptr %100, i32 0, i32 0
  %102 = getelementptr inbounds [4 x %"struct.spirv_cross::SPIRConstant::ConstantVector"], ptr %101, i64 0, i64 0
  %103 = getelementptr inbounds %"struct.spirv_cross::SPIRConstant::ConstantVector", ptr %102, i32 0, i32 1
  %104 = load i32, ptr %11, align 4, !tbaa !48
  %105 = zext i32 %104 to i64
  %106 = getelementptr inbounds [4 x %"class.spirv_cross::TypedID.280"], ptr %103, i64 0, i64 %105
  %107 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN11spirv_cross7TypedIDILNS_5TypesE0EEaSILS1_3EEERS2_RKNS0_IXT_EEE(ptr noundef nonnull align 4 dereferenceable(4) %106, ptr noundef nonnull align 4 dereferenceable(4) %98)
  br label %108

108:                                              ; preds = %94
  %109 = load i32, ptr %11, align 4, !tbaa !48
  %110 = add i32 %109, 1
  store i32 %110, ptr %11, align 4, !tbaa !48
  br label %87, !llvm.loop !54

111:                                              ; preds = %93
  br label %119

112:                                              ; preds = %75
  %113 = call ptr @__cxa_allocate_exception(i64 16) #5
  invoke void @_ZN11spirv_cross13CompilerErrorC2EPKc(ptr noundef nonnull align 8 dereferenceable(16) %113, ptr noundef @.str.952)
          to label %114 unwind label %115

114:                                              ; preds = %112
  call void @__cxa_throw(ptr %113, ptr @_ZTIN11spirv_cross13CompilerErrorE, ptr @_ZNSt13runtime_errorD2Ev) #6
  unreachable

115:                                              ; preds = %112
  %116 = landingpad { ptr, i32 }
          cleanup
  %117 = extractvalue { ptr, i32 } %116, 0
  store ptr %117, ptr %12, align 8
  %118 = extractvalue { ptr, i32 } %116, 1
  store i32 %118, ptr %13, align 4
  call void @__cxa_free_exception(ptr %113) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %122

119:                                              ; preds = %111
  br label %120

120:                                              ; preds = %119, %74
  br label %121

121:                                              ; preds = %120, %27
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  ret void

122:                                              ; preds = %115
  %123 = load ptr, ptr %12, align 8
  %124 = load i32, ptr %13, align 4
  %125 = insertvalue { ptr, i32 } poison, ptr %123, 0
  %126 = insertvalue { ptr, i32 } %125, i32 %124, 1
  resume { ptr, i32 } %126
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(56) ptr @_ZN11spirv_cross11SmallVectorINS_7TypedIDILNS_5TypesE3EEELm8EEaSERKS4_(ptr noundef nonnull align 8 dereferenceable(56), ptr noundef nonnull align 8 dereferenceable(56)) #3 align 2

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

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

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

!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, !16, i64 264}
!10 = !{!"_ZTSN11spirv_cross12SPIRConstantE", !11, i64 0, !14, i64 12, !15, i64 16, !16, i64 264, !16, i64 265, !16, i64 266, !17, i64 272, !21, i64 328}
!11 = !{!"_ZTSN11spirv_cross8IVariantE", !12, i64 8}
!12 = !{!"_ZTSN11spirv_cross7TypedIDILNS_5TypesE0EEE", !13, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{!"_ZTSN11spirv_cross7TypedIDILNS_5TypesE1EEE", !13, i64 0}
!15 = !{!"_ZTSN11spirv_cross12SPIRConstant14ConstantMatrixE", !7, i64 0, !7, i64 224, !13, i64 240}
!16 = !{!"bool", !7, i64 0}
!17 = !{!"_ZTSN11spirv_cross11SmallVectorINS_7TypedIDILNS_5TypesE3EEELm8EEE", !18, i64 0, !19, i64 16, !20, i64 24}
!18 = !{!"_ZTSN11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE3EEEEE", !6, i64 0, !19, i64 8}
!19 = !{!"long", !7, i64 0}
!20 = !{!"_ZTSN11spirv_cross13AlignedBufferINS_7TypedIDILNS_5TypesE3EEELm8EEE", !7, i64 0}
!21 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !22, i64 0, !19, i64 8, !7, i64 16}
!22 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!23 = !{!24, !26, i64 16}
!24 = !{!"_ZTSN11spirv_cross8SPIRTypeE", !11, i64 0, !25, i64 12, !26, i64 16, !13, i64 20, !13, i64 24, !13, i64 28, !27, i64 32, !30, i64 88, !13, i64 120, !16, i64 124, !16, i64 125, !33, i64 128, !34, i64 136, !27, i64 192, !37, i64 248, !14, i64 272, !14, i64 276, !41, i64 280}
!25 = !{!"_ZTSN3spv2OpE", !7, i64 0}
!26 = !{!"_ZTSN11spirv_cross8SPIRType8BaseTypeE", !7, i64 0}
!27 = !{!"_ZTSN11spirv_cross11SmallVectorIjLm8EEE", !28, i64 0, !19, i64 16, !29, i64 24}
!28 = !{!"_ZTSN11spirv_cross10VectorViewIjEE", !6, i64 0, !19, i64 8}
!29 = !{!"_ZTSN11spirv_cross13AlignedBufferIjLm8EEE", !7, i64 0}
!30 = !{!"_ZTSN11spirv_cross11SmallVectorIbLm8EEE", !31, i64 0, !19, i64 16, !32, i64 24}
!31 = !{!"_ZTSN11spirv_cross10VectorViewIbEE", !6, i64 0, !19, i64 8}
!32 = !{!"_ZTSN11spirv_cross13AlignedBufferIbLm8EEE", !7, i64 0}
!33 = !{!"_ZTSN3spv12StorageClassE", !7, i64 0}
!34 = !{!"_ZTSN11spirv_cross11SmallVectorINS_7TypedIDILNS_5TypesE1EEELm8EEE", !35, i64 0, !19, i64 16, !36, i64 24}
!35 = !{!"_ZTSN11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE1EEEEE", !6, i64 0, !19, i64 8}
!36 = !{!"_ZTSN11spirv_cross13AlignedBufferINS_7TypedIDILNS_5TypesE1EEELm8EEE", !7, i64 0}
!37 = !{!"_ZTSN11spirv_cross8SPIRType9ImageTypeE", !14, i64 0, !38, i64 4, !16, i64 8, !16, i64 9, !16, i64 10, !13, i64 12, !39, i64 16, !40, i64 20}
!38 = !{!"_ZTSN3spv3DimE", !7, i64 0}
!39 = !{!"_ZTSN3spv11ImageFormatE", !7, i64 0}
!40 = !{!"_ZTSN3spv15AccessQualifierE", !7, i64 0}
!41 = !{!"_ZTSSt13unordered_setINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4hashIS5_ESt8equal_toIS5_ESaIS5_EE", !42, i64 0}
!42 = !{!"_ZTSSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_SaIS5_ENSt8__detail9_IdentityESt8equal_toIS5_ESt4hashIS5_ENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb1ELb1ELb1EEEE", !6, i64 0, !19, i64 8, !43, i64 16, !19, i64 24, !44, i64 32, !6, i64 48}
!43 = !{!"_ZTSNSt8__detail15_Hash_node_baseE", !6, i64 0}
!44 = !{!"_ZTSNSt8__detail20_Prime_rehash_policyE", !45, i64 0, !19, i64 8}
!45 = !{!"float", !7, i64 0}
!46 = !{!24, !13, i64 28}
!47 = !{!10, !13, i64 256}
!48 = !{!13, !13, i64 0}
!49 = !{!24, !13, i64 24}
!50 = !{!51, !13, i64 48}
!51 = !{!"_ZTSN11spirv_cross12SPIRConstant14ConstantVectorE", !7, i64 0, !7, i64 32, !13, i64 48}
!52 = distinct !{!52, !53}
!53 = !{!"llvm.loop.mustprogress"}
!54 = distinct !{!54, !53}


; 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.spirv_cross::TypedID.281" = type { i32 }
%"class.spirv_cross::TypedID.280" = type { i32 }
%"struct.spirv_cross::SPIRConstant::ConstantVector" = type <{ [4 x %"union.spirv_cross::SPIRConstant::Constant"], [4 x %"class.spirv_cross::TypedID.280"], i32, [4 x i8] }>
%"union.spirv_cross::SPIRConstant::Constant" = type { i64 }

@_ZTIN11spirv_cross13CompilerErrorE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.952 = external hidden unnamed_addr constant [53 x i8], align 1

declare ptr @__cxa_allocate_exception(i64) local_unnamed_addr

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

declare i32 @__gxx_personality_v0(...)

declare void @__cxa_free_exception(ptr) local_unnamed_addr

; Function Attrs: nounwind
declare void @_ZNSt13runtime_errorD2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #1

declare void @__cxa_throw(ptr, ptr, ptr) local_unnamed_addr

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(336) ptr @_ZN11spirv_cross8Compiler3getINS_8SPIRTypeEEERT_j(ptr noundef nonnull align 8 dereferenceable(3176), i32 noundef) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK11spirv_cross7TypedIDILNS_5TypesE1EEcvjEv(ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #2 align 2

declare noundef zeroext i1 @_ZNK11spirv_cross8Compiler8is_arrayERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176), ptr noundef nonnull align 8 dereferenceable(336)) local_unnamed_addr #3

declare noundef zeroext i1 @_ZNK11spirv_cross8Compiler9is_matrixERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176), ptr noundef nonnull align 8 dereferenceable(336)) local_unnamed_addr #3

declare noundef zeroext i1 @_ZNK11spirv_cross8Compiler9is_vectorERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176), ptr noundef nonnull align 8 dereferenceable(336)) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN11spirv_cross12CompilerGLSL23fill_composite_constantERNS_12SPIRConstantENS_7TypedIDILNS_5TypesE1EEERKNS_11SmallVectorINS3_ILS4_3EEELm8EEE(ptr noundef nonnull align 8 dereferenceable(9848) %0, ptr noundef nonnull align 8 dereferenceable(360) %1, i32 %2, ptr noundef nonnull align 8 dereferenceable(56) %3) local_unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca %"class.spirv_cross::TypedID.281", align 4
  store i32 %2, ptr %5, align 4
  %6 = call noundef i32 @_ZNK11spirv_cross7TypedIDILNS_5TypesE1EEcvjEv(ptr noundef nonnull align 4 dereferenceable(4) %5)
  %7 = call noundef nonnull align 8 dereferenceable(336) ptr @_ZN11spirv_cross8Compiler3getINS_8SPIRTypeEEERT_j(ptr noundef nonnull align 8 dereferenceable(3176) %0, i32 noundef %6)
  %8 = getelementptr inbounds i8, ptr %1, i64 264
  store i8 1, ptr %8, align 8, !tbaa !5
  %9 = call noundef zeroext i1 @_ZNK11spirv_cross8Compiler8is_arrayERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176) %0, ptr noundef nonnull align 8 dereferenceable(336) %7)
  %10 = getelementptr inbounds i8, ptr %7, i64 16
  %11 = load i32, ptr %10, align 8
  %12 = icmp eq i32 %11, 15
  %or.cond = select i1 %9, i1 true, i1 %12
  br i1 %or.cond, label %13, label %16

13:                                               ; preds = %4
  %14 = getelementptr inbounds i8, ptr %1, i64 272
  %15 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZN11spirv_cross11SmallVectorINS_7TypedIDILNS_5TypesE3EEELm8EEaSERKS4_(ptr noundef nonnull align 8 dereferenceable(56) %14, ptr noundef nonnull align 8 dereferenceable(56) %3) #4
  br label %.loopexit

16:                                               ; preds = %4
  %17 = call noundef zeroext i1 @_ZNK11spirv_cross8Compiler9is_matrixERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176) %0, ptr noundef nonnull align 8 dereferenceable(336) %7)
  br i1 %17, label %18, label %34

18:                                               ; preds = %16
  %19 = getelementptr inbounds i8, ptr %7, i64 28
  %20 = load i32, ptr %19, align 4, !tbaa !22
  %21 = getelementptr inbounds i8, ptr %1, i64 16
  %22 = getelementptr inbounds i8, ptr %1, i64 256
  store i32 %20, ptr %22, align 8, !tbaa !45
  %.not37 = icmp eq i32 %20, 0
  br i1 %.not37, label %.loopexit, label %.lr.ph36

.lr.ph36:                                         ; preds = %18
  %23 = getelementptr inbounds i8, ptr %1, i64 240
  %24 = getelementptr inbounds i8, ptr %7, i64 24
  br label %25

25:                                               ; preds = %.lr.ph36, %25
  %indvars.iv40 = phi i64 [ 0, %.lr.ph36 ], [ %indvars.iv.next41, %25 ]
  %26 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE3EEEEixEm(ptr noundef nonnull align 8 dereferenceable(16) %3, i64 noundef %indvars.iv40) #4
  %27 = getelementptr inbounds [4 x %"class.spirv_cross::TypedID.280"], ptr %23, i64 0, i64 %indvars.iv40
  %28 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN11spirv_cross7TypedIDILNS_5TypesE0EEaSILS1_3EEERS2_RKNS0_IXT_EEE(ptr noundef nonnull align 4 dereferenceable(4) %27, ptr noundef nonnull align 4 dereferenceable(4) %26)
  %29 = load i32, ptr %24, align 8, !tbaa !46
  %30 = getelementptr inbounds [4 x %"struct.spirv_cross::SPIRConstant::ConstantVector"], ptr %21, i64 0, i64 %indvars.iv40, i32 2
  store i32 %29, ptr %30, align 8, !tbaa !47
  %indvars.iv.next41 = add nuw nsw i64 %indvars.iv40, 1
  %31 = load i32, ptr %19, align 4, !tbaa !22
  %32 = zext i32 %31 to i64
  %33 = icmp ult i64 %indvars.iv.next41, %32
  br i1 %33, label %25, label %.loopexit, !llvm.loop !49

34:                                               ; preds = %16
  %35 = call noundef zeroext i1 @_ZNK11spirv_cross8Compiler9is_vectorERKNS_8SPIRTypeE(ptr noundef nonnull align 8 dereferenceable(3176) %0, ptr noundef nonnull align 8 dereferenceable(336) %7)
  br i1 %35, label %36, label %48

36:                                               ; preds = %34
  %37 = getelementptr inbounds i8, ptr %7, i64 24
  %38 = load i32, ptr %37, align 8, !tbaa !46
  %39 = getelementptr inbounds i8, ptr %1, i64 64
  store i32 %38, ptr %39, align 8, !tbaa !47
  %.not = icmp eq i32 %38, 0
  br i1 %.not, label %.loopexit, label %.lr.ph

.lr.ph:                                           ; preds = %36
  %40 = getelementptr inbounds i8, ptr %1, i64 48
  br label %41

41:                                               ; preds = %.lr.ph, %41
  %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %41 ]
  %42 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE3EEEEixEm(ptr noundef nonnull align 8 dereferenceable(16) %3, i64 noundef %indvars.iv) #4
  %43 = getelementptr inbounds [4 x %"class.spirv_cross::TypedID.280"], ptr %40, i64 0, i64 %indvars.iv
  %44 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZN11spirv_cross7TypedIDILNS_5TypesE0EEaSILS1_3EEERS2_RKNS0_IXT_EEE(ptr noundef nonnull align 4 dereferenceable(4) %43, ptr noundef nonnull align 4 dereferenceable(4) %42)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %45 = load i32, ptr %37, align 8, !tbaa !46
  %46 = zext i32 %45 to i64
  %47 = icmp ult i64 %indvars.iv.next, %46
  br i1 %47, label %41, label %.loopexit, !llvm.loop !51

48:                                               ; preds = %34
  %49 = call ptr @__cxa_allocate_exception(i64 16) #4
  invoke void @_ZN11spirv_cross13CompilerErrorC2EPKc(ptr noundef nonnull align 8 dereferenceable(16) %49, ptr noundef nonnull @.str.952)
          to label %50 unwind label %51

50:                                               ; preds = %48
  call void @__cxa_throw(ptr nonnull %49, ptr nonnull @_ZTIN11spirv_cross13CompilerErrorE, ptr nonnull @_ZNSt13runtime_errorD2Ev) #5
  unreachable

51:                                               ; preds = %48
  %52 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %49) #4
  resume { ptr, i32 } %52

.loopexit:                                        ; preds = %41, %25, %36, %18, %13
  ret void
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(56) ptr @_ZN11spirv_cross11SmallVectorINS_7TypedIDILNS_5TypesE3EEELm8EEaSERKS4_(ptr noundef nonnull align 8 dereferenceable(56), ptr noundef nonnull align 8 dereferenceable(56)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNK11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE3EEEEixEm(ptr noundef nonnull align 8 dereferenceable(16), i64 noundef) local_unnamed_addr #2 align 2

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

attributes #0 = { 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 #1 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 = { "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 }
attributes #5 = { noreturn }

!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 264}
!6 = !{!"_ZTSN11spirv_cross12SPIRConstantE", !7, i64 0, !12, i64 12, !13, i64 16, !14, i64 264, !14, i64 265, !14, i64 266, !15, i64 272, !20, i64 328}
!7 = !{!"_ZTSN11spirv_cross8IVariantE", !8, i64 8}
!8 = !{!"_ZTSN11spirv_cross7TypedIDILNS_5TypesE0EEE", !9, i64 0}
!9 = !{!"int", !10, i64 0}
!10 = !{!"omnipotent char", !11, i64 0}
!11 = !{!"Simple C++ TBAA"}
!12 = !{!"_ZTSN11spirv_cross7TypedIDILNS_5TypesE1EEE", !9, i64 0}
!13 = !{!"_ZTSN11spirv_cross12SPIRConstant14ConstantMatrixE", !10, i64 0, !10, i64 224, !9, i64 240}
!14 = !{!"bool", !10, i64 0}
!15 = !{!"_ZTSN11spirv_cross11SmallVectorINS_7TypedIDILNS_5TypesE3EEELm8EEE", !16, i64 0, !18, i64 16, !19, i64 24}
!16 = !{!"_ZTSN11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE3EEEEE", !17, i64 0, !18, i64 8}
!17 = !{!"any pointer", !10, i64 0}
!18 = !{!"long", !10, i64 0}
!19 = !{!"_ZTSN11spirv_cross13AlignedBufferINS_7TypedIDILNS_5TypesE3EEELm8EEE", !10, i64 0}
!20 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !21, i64 0, !18, i64 8, !10, i64 16}
!21 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !17, i64 0}
!22 = !{!23, !9, i64 28}
!23 = !{!"_ZTSN11spirv_cross8SPIRTypeE", !7, i64 0, !24, i64 12, !25, i64 16, !9, i64 20, !9, i64 24, !9, i64 28, !26, i64 32, !29, i64 88, !9, i64 120, !14, i64 124, !14, i64 125, !32, i64 128, !33, i64 136, !26, i64 192, !36, i64 248, !12, i64 272, !12, i64 276, !40, i64 280}
!24 = !{!"_ZTSN3spv2OpE", !10, i64 0}
!25 = !{!"_ZTSN11spirv_cross8SPIRType8BaseTypeE", !10, i64 0}
!26 = !{!"_ZTSN11spirv_cross11SmallVectorIjLm8EEE", !27, i64 0, !18, i64 16, !28, i64 24}
!27 = !{!"_ZTSN11spirv_cross10VectorViewIjEE", !17, i64 0, !18, i64 8}
!28 = !{!"_ZTSN11spirv_cross13AlignedBufferIjLm8EEE", !10, i64 0}
!29 = !{!"_ZTSN11spirv_cross11SmallVectorIbLm8EEE", !30, i64 0, !18, i64 16, !31, i64 24}
!30 = !{!"_ZTSN11spirv_cross10VectorViewIbEE", !17, i64 0, !18, i64 8}
!31 = !{!"_ZTSN11spirv_cross13AlignedBufferIbLm8EEE", !10, i64 0}
!32 = !{!"_ZTSN3spv12StorageClassE", !10, i64 0}
!33 = !{!"_ZTSN11spirv_cross11SmallVectorINS_7TypedIDILNS_5TypesE1EEELm8EEE", !34, i64 0, !18, i64 16, !35, i64 24}
!34 = !{!"_ZTSN11spirv_cross10VectorViewINS_7TypedIDILNS_5TypesE1EEEEE", !17, i64 0, !18, i64 8}
!35 = !{!"_ZTSN11spirv_cross13AlignedBufferINS_7TypedIDILNS_5TypesE1EEELm8EEE", !10, i64 0}
!36 = !{!"_ZTSN11spirv_cross8SPIRType9ImageTypeE", !12, i64 0, !37, i64 4, !14, i64 8, !14, i64 9, !14, i64 10, !9, i64 12, !38, i64 16, !39, i64 20}
!37 = !{!"_ZTSN3spv3DimE", !10, i64 0}
!38 = !{!"_ZTSN3spv11ImageFormatE", !10, i64 0}
!39 = !{!"_ZTSN3spv15AccessQualifierE", !10, i64 0}
!40 = !{!"_ZTSSt13unordered_setINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4hashIS5_ESt8equal_toIS5_ESaIS5_EE", !41, i64 0}
!41 = !{!"_ZTSSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_SaIS5_ENSt8__detail9_IdentityESt8equal_toIS5_ESt4hashIS5_ENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb1ELb1ELb1EEEE", !17, i64 0, !18, i64 8, !42, i64 16, !18, i64 24, !43, i64 32, !17, i64 48}
!42 = !{!"_ZTSNSt8__detail15_Hash_node_baseE", !17, i64 0}
!43 = !{!"_ZTSNSt8__detail20_Prime_rehash_policyE", !44, i64 0, !18, i64 8}
!44 = !{!"float", !10, i64 0}
!45 = !{!6, !9, i64 256}
!46 = !{!23, !9, i64 24}
!47 = !{!48, !9, i64 48}
!48 = !{!"_ZTSN11spirv_cross12SPIRConstant14ConstantVectorE", !10, i64 0, !10, i64 32, !9, i64 48}
!49 = distinct !{!49, !50}
!50 = !{!"llvm.loop.mustprogress"}
!51 = distinct !{!51, !50}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass