; LLVM IR from hbatagelo/abcg :: abcg/external/glslang/glslang/MachineIndependent (iomapper)

; 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.std::_Rb_tree_iterator" = type { ptr }
%"struct.glslang::TVarEntryInfo" = type { i64, ptr, i8, i32, i32, i32, i32, i32, i32 }
%"struct.glslang::TDefaultIoResolverBase" = type { %"class.glslang::TIoMapResolver", %"class.std::unordered_map", i8, ptr, i32, i32, i32, [15 x i8], [14 x ptr] }
%"class.glslang::TIoMapResolver" = type { ptr }
%"class.std::unordered_map" = type { %"class.std::_Hashtable" }
%"class.std::_Hashtable" = 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 }
%"struct.glslang::SpvVersion" = type <{ i32, i32, i32, i32, i8, [3 x i8] }>
%"class.glslang::TQualifier" = type <{ ptr, i64, i8, [3 x i8], i32, i32, i64, i64, i8, i8, i8, i8, i8, [3 x i8], i32, i8, [3 x i8], i32, ptr }>
%"struct.glslang::TDefaultGlslIoResolver" = type { %"struct.glslang::TDefaultIoResolverBase", i32, i32, %"class.std::map.110", %"class.std::map.110" }
%"class.std::map.110" = type { %"class.std::_Rb_tree.111" }
%"class.std::_Rb_tree.111" = type { %"struct.std::_Rb_tree<int, std::pair<const int, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, glslang::pool_allocator<char>>, int>>, std::_Select1st<std::pair<const int, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, glslang::pool_allocator<char>>, int>>>, std::less<int>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<int, std::pair<const int, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, glslang::pool_allocator<char>>, int>>, std::_Select1st<std::pair<const int, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, glslang::pool_allocator<char>>, int>>>, std::less<int>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.std::pair" = type <{ %"class.std::__cxx11::basic_string.105", i32, [4 x i8] }>
%"class.std::__cxx11::basic_string.105" = type { %"struct.std::__cxx11::basic_string<char, std::char_traits<char>, glslang::pool_allocator<char>>::_Alloc_hider", i64, %union.anon.106 }
%"struct.std::__cxx11::basic_string<char, std::char_traits<char>, glslang::pool_allocator<char>>::_Alloc_hider" = type { %"class.glslang::pool_allocator", ptr }
%"class.glslang::pool_allocator" = type { ptr }
%union.anon.106 = type { i64, [8 x i8] }

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZNK7glslang22TDefaultIoResolverBase14getBaseBindingE11EShLanguageNS_13TResourceTypeEj(ptr noundef nonnull align 8 dereferenceable(224), i32 noundef, i32 noundef, i32 noundef) #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK7glslang22TDefaultIoResolverBase20doAutoBindingMappingEv(ptr noundef nonnull align 8 dereferenceable(224)) #0 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZN7glslang22TDefaultIoResolverBase11reserveSlotEiii(ptr noundef nonnull align 8 dereferenceable(224), i32 noundef, i32 noundef, i32 noundef) #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZN7glslang22TDefaultIoResolverBase11getFreeSlotEiii(ptr noundef nonnull align 8 dereferenceable(224), i32 noundef, i32 noundef, i32 noundef) #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(17) ptr @_ZNK7glslang13TIntermediate6getSpvEv(ptr noundef nonnull align 8 dereferenceable(1784)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE4findERSB_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(40)) #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiEESD_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48)) #2 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEEixERSB_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(40)) #0 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN7glslang22TDefaultGlslIoResolver14resolveBindingE11EShLanguageRNS_13TVarEntryInfoE(ptr noundef nonnull align 8 dereferenceable(328) %0, i32 noundef %1, ptr noundef nonnull align 8 dereferenceable(48) %2) unnamed_addr #0 align 2 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %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 i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i8, align 1
  %17 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %18 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %19 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i32 %1, ptr %6, align 4, !tbaa !9
  store ptr %2, ptr %7, align 8, !tbaa !5
  %20 = load ptr, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #3
  %21 = load ptr, ptr %7, align 8, !tbaa !5
  %22 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %21, i32 0, i32 1
  %23 = load ptr, ptr %22, align 8, !tbaa !11
  %24 = load ptr, ptr %23, align 8, !tbaa !16
  %25 = getelementptr inbounds ptr, ptr %24, i64 30
  %26 = load ptr, ptr %25, align 8
  %27 = call noundef nonnull align 8 dereferenceable(144) ptr %26(ptr noundef nonnull align 8 dereferenceable(176) %23)
  store ptr %27, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #3
  %28 = load ptr, ptr %7, align 8, !tbaa !5
  %29 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %28, i32 0, i32 1
  %30 = load ptr, ptr %29, align 8, !tbaa !11
  %31 = load ptr, ptr %30, align 8, !tbaa !16
  %32 = getelementptr inbounds ptr, ptr %31, i64 51
  %33 = load ptr, ptr %32, align 8
  %34 = call noundef nonnull align 8 dereferenceable(40) ptr %33(ptr noundef nonnull align 8 dereferenceable(256) %30)
  store ptr %34, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #3
  %35 = getelementptr inbounds %"struct.glslang::TDefaultIoResolverBase", ptr %20, i32 0, i32 3
  %36 = load ptr, ptr %35, align 8, !tbaa !18
  %37 = call noundef nonnull align 4 dereferenceable(17) ptr @_ZNK7glslang13TIntermediate6getSpvEv(ptr noundef nonnull align 8 dereferenceable(1784) %36)
  %38 = getelementptr inbounds %"struct.glslang::SpvVersion", ptr %37, i32 0, i32 3
  %39 = load i32, ptr %38, align 4, !tbaa !27
  %40 = icmp ne i32 %39, 0
  br i1 %40, label %41, label %53

41:                                               ; preds = %3
  %42 = load ptr, ptr %8, align 8, !tbaa !5
  %43 = load ptr, ptr %42, align 8, !tbaa !16
  %44 = getelementptr inbounds ptr, ptr %43, i64 30
  %45 = load ptr, ptr %44, align 8
  %46 = call noundef zeroext i1 %45(ptr noundef nonnull align 8 dereferenceable(144) %42)
  br i1 %46, label %47, label %53

47:                                               ; preds = %41
  %48 = load ptr, ptr %8, align 8, !tbaa !5
  %49 = load ptr, ptr %48, align 8, !tbaa !16
  %50 = getelementptr inbounds ptr, ptr %49, i64 17
  %51 = load ptr, ptr %50, align 8
  %52 = call noundef i32 %51(ptr noundef nonnull align 8 dereferenceable(144) %48)
  br label %54

53:                                               ; preds = %41, %3
  br label %54

54:                                               ; preds = %53, %47
  %55 = phi i32 [ %52, %47 ], [ 1, %53 ]
  store i32 %55, ptr %10, align 4, !tbaa !29
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #3
  %56 = load ptr, ptr %8, align 8, !tbaa !5
  %57 = load ptr, ptr %20, align 8, !tbaa !16
  %58 = getelementptr inbounds ptr, ptr %57, i64 21
  %59 = load ptr, ptr %58, align 8
  %60 = call noundef i32 %59(ptr noundef nonnull align 8 dereferenceable(328) %20, ptr noundef nonnull align 8 dereferenceable(144) %56)
  store i32 %60, ptr %11, align 4, !tbaa !30
  %61 = load i32, ptr %11, align 4, !tbaa !30
  %62 = icmp eq i32 %61, 3
  br i1 %62, label %63, label %73

63:                                               ; preds = %54
  %64 = load ptr, ptr %8, align 8, !tbaa !5
  %65 = load ptr, ptr %64, align 8, !tbaa !16
  %66 = getelementptr inbounds ptr, ptr %65, i64 7
  %67 = load ptr, ptr %66, align 8
  %68 = call noundef i32 %67(ptr noundef nonnull align 8 dereferenceable(144) %64)
  %69 = icmp ne i32 %68, 16
  br i1 %69, label %70, label %73

70:                                               ; preds = %63
  %71 = load ptr, ptr %7, align 8, !tbaa !5
  %72 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %71, i32 0, i32 3
  store i32 -1, ptr %72, align 4, !tbaa !32
  store i32 -1, ptr %4, align 4
  store i32 1, ptr %12, align 4
  br label %178

73:                                               ; preds = %63, %54
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  %74 = getelementptr inbounds %"struct.glslang::TDefaultIoResolverBase", ptr %20, i32 0, i32 3
  %75 = load ptr, ptr %74, align 8, !tbaa !18
  %76 = call noundef nonnull align 4 dereferenceable(17) ptr @_ZNK7glslang13TIntermediate6getSpvEv(ptr noundef nonnull align 8 dereferenceable(1784) %75)
  %77 = getelementptr inbounds %"struct.glslang::SpvVersion", ptr %76, i32 0, i32 3
  %78 = load i32, ptr %77, align 4, !tbaa !27
  %79 = icmp ne i32 %78, 0
  br i1 %79, label %80, label %82

80:                                               ; preds = %73
  %81 = load i32, ptr %11, align 4, !tbaa !30
  br label %86

82:                                               ; preds = %73
  %83 = load ptr, ptr %7, align 8, !tbaa !5
  %84 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %83, i32 0, i32 4
  %85 = load i32, ptr %84, align 8, !tbaa !33
  br label %86

86:                                               ; preds = %82, %80
  %87 = phi i32 [ %81, %80 ], [ %85, %82 ]
  store i32 %87, ptr %13, align 4, !tbaa !29
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #3
  %88 = load i32, ptr %13, align 4, !tbaa !29
  store i32 %88, ptr %14, align 4, !tbaa !29
  %89 = load i32, ptr %11, align 4, !tbaa !30
  %90 = icmp slt i32 %89, 6
  br i1 %90, label %91, label %174

91:                                               ; preds = %86
  %92 = load ptr, ptr %8, align 8, !tbaa !5
  %93 = load ptr, ptr %92, align 8, !tbaa !16
  %94 = getelementptr inbounds ptr, ptr %93, i64 11
  %95 = load ptr, ptr %94, align 8
  %96 = call noundef nonnull align 8 dereferenceable(72) ptr %95(ptr noundef nonnull align 8 dereferenceable(144) %92)
  %97 = call noundef zeroext i1 @_ZNK7glslang10TQualifier10hasBindingEv(ptr noundef nonnull align 8 dereferenceable(72) %96)
  br i1 %97, label %98, label %120

98:                                               ; preds = %91
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #3
  %99 = load i32, ptr %14, align 4, !tbaa !29
  %100 = load i32, ptr %6, align 4, !tbaa !9
  %101 = load i32, ptr %11, align 4, !tbaa !30
  %102 = load i32, ptr %13, align 4, !tbaa !29
  %103 = call noundef i32 @_ZNK7glslang22TDefaultIoResolverBase14getBaseBindingE11EShLanguageNS_13TResourceTypeEj(ptr noundef nonnull align 8 dereferenceable(224) %20, i32 noundef %100, i32 noundef %101, i32 noundef %102)
  %104 = load ptr, ptr %8, align 8, !tbaa !5
  %105 = load ptr, ptr %104, align 8, !tbaa !16
  %106 = getelementptr inbounds ptr, ptr %105, i64 11
  %107 = load ptr, ptr %106, align 8
  %108 = call noundef nonnull align 8 dereferenceable(72) ptr %107(ptr noundef nonnull align 8 dereferenceable(144) %104)
  %109 = getelementptr inbounds %"class.glslang::TQualifier", ptr %108, i32 0, i32 6
  %110 = load i64, ptr %109, align 4
  %111 = lshr i64 %110, 32
  %112 = and i64 %111, 65535
  %113 = trunc i64 %112 to i32
  %114 = add nsw i32 %103, %113
  %115 = load i32, ptr %10, align 4, !tbaa !29
  %116 = call noundef i32 @_ZN7glslang22TDefaultIoResolverBase11reserveSlotEiii(ptr noundef nonnull align 8 dereferenceable(224) %20, i32 noundef %99, i32 noundef %114, i32 noundef %115)
  store i32 %116, ptr %15, align 4, !tbaa !29
  %117 = load i32, ptr %15, align 4, !tbaa !29
  %118 = load ptr, ptr %7, align 8, !tbaa !5
  %119 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %118, i32 0, i32 3
  store i32 %117, ptr %119, align 4, !tbaa !32
  store i32 %117, ptr %4, align 4
  store i32 1, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #3
  br label %177

120:                                              ; preds = %91
  call void @llvm.lifetime.start.p0(i64 1, ptr %16) #3
  store i8 0, ptr %16, align 1, !tbaa !34
  %121 = load ptr, ptr %7, align 8, !tbaa !5
  %122 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %121, i32 0, i32 3
  store i32 -1, ptr %122, align 4, !tbaa !32
  %123 = getelementptr inbounds %"struct.glslang::TDefaultGlslIoResolver", ptr %20, i32 0, i32 3
  %124 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48) %123, ptr noundef nonnull align 4 dereferenceable(4) %14)
  %125 = call noundef zeroext i1 @_ZNKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48) %124) #3
  br i1 %125, label %144, label %126

126:                                              ; preds = %120
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #3
  %127 = getelementptr inbounds %"struct.glslang::TDefaultGlslIoResolver", ptr %20, i32 0, i32 3
  %128 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48) %127, ptr noundef nonnull align 4 dereferenceable(4) %14)
  %129 = load ptr, ptr %9, align 8, !tbaa !5
  %130 = call ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE4findERSB_(ptr noundef nonnull align 8 dereferenceable(48) %128, ptr noundef nonnull align 8 dereferenceable(40) %129)
  %131 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %17, i32 0, i32 0
  store ptr %130, ptr %131, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #3
  %132 = getelementptr inbounds %"struct.glslang::TDefaultGlslIoResolver", ptr %20, i32 0, i32 3
  %133 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48) %132, ptr noundef nonnull align 4 dereferenceable(4) %14)
  %134 = call ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %133) #3
  %135 = getelementptr inbounds %"struct.std::_Rb_tree_iterator", ptr %18, i32 0, i32 0
  store ptr %134, ptr %135, align 8
  %136 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiEESD_(ptr noundef nonnull align 8 dereferenceable(8) %17, ptr noundef nonnull align 8 dereferenceable(8) %18) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #3
  br i1 %136, label %137, label %143

137:                                              ; preds = %126
  store i8 1, ptr %16, align 1, !tbaa !34
  %138 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %17) #3
  %139 = getelementptr inbounds %"struct.std::pair", ptr %138, i32 0, i32 1
  %140 = load i32, ptr %139, align 8, !tbaa !35
  %141 = load ptr, ptr %7, align 8, !tbaa !5
  %142 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %141, i32 0, i32 3
  store i32 %140, ptr %142, align 4, !tbaa !32
  br label %143

143:                                              ; preds = %137, %126
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #3
  br label %144

144:                                              ; preds = %143, %120
  %145 = load i8, ptr %16, align 1, !tbaa !34, !range !40, !noundef !41
  %146 = trunc i8 %145 to i1
  br i1 %146, label %170, label %147

147:                                              ; preds = %144
  %148 = load ptr, ptr %7, align 8, !tbaa !5
  %149 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %148, i32 0, i32 2
  %150 = load i8, ptr %149, align 8, !tbaa !42, !range !40, !noundef !41
  %151 = trunc i8 %150 to i1
  br i1 %151, label %152, label %170

152:                                              ; preds = %147
  %153 = call noundef zeroext i1 @_ZNK7glslang22TDefaultIoResolverBase20doAutoBindingMappingEv(ptr noundef nonnull align 8 dereferenceable(224) %20)
  br i1 %153, label %154, label %170

154:                                              ; preds = %152
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #3
  %155 = load i32, ptr %14, align 4, !tbaa !29
  %156 = load i32, ptr %6, align 4, !tbaa !9
  %157 = load i32, ptr %11, align 4, !tbaa !30
  %158 = load i32, ptr %13, align 4, !tbaa !29
  %159 = call noundef i32 @_ZNK7glslang22TDefaultIoResolverBase14getBaseBindingE11EShLanguageNS_13TResourceTypeEj(ptr noundef nonnull align 8 dereferenceable(224) %20, i32 noundef %156, i32 noundef %157, i32 noundef %158)
  %160 = load i32, ptr %10, align 4, !tbaa !29
  %161 = call noundef i32 @_ZN7glslang22TDefaultIoResolverBase11getFreeSlotEiii(ptr noundef nonnull align 8 dereferenceable(224) %20, i32 noundef %155, i32 noundef %159, i32 noundef %160)
  store i32 %161, ptr %19, align 4, !tbaa !29
  %162 = load i32, ptr %19, align 4, !tbaa !29
  %163 = getelementptr inbounds %"struct.glslang::TDefaultGlslIoResolver", ptr %20, i32 0, i32 3
  %164 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48) %163, ptr noundef nonnull align 4 dereferenceable(4) %14)
  %165 = load ptr, ptr %9, align 8, !tbaa !5
  %166 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEEixERSB_(ptr noundef nonnull align 8 dereferenceable(48) %164, ptr noundef nonnull align 8 dereferenceable(40) %165)
  store i32 %162, ptr %166, align 4, !tbaa !29
  %167 = load i32, ptr %19, align 4, !tbaa !29
  %168 = load ptr, ptr %7, align 8, !tbaa !5
  %169 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %168, i32 0, i32 3
  store i32 %167, ptr %169, align 4, !tbaa !32
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #3
  br label %170

170:                                              ; preds = %154, %152, %147, %144
  %171 = load ptr, ptr %7, align 8, !tbaa !5
  %172 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %171, i32 0, i32 3
  %173 = load i32, ptr %172, align 4, !tbaa !32
  store i32 %173, ptr %4, align 4
  store i32 1, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %16) #3
  br label %177

174:                                              ; preds = %86
  %175 = load ptr, ptr %7, align 8, !tbaa !5
  %176 = getelementptr inbounds %"struct.glslang::TVarEntryInfo", ptr %175, i32 0, i32 3
  store i32 -1, ptr %176, align 4, !tbaa !32
  store i32 -1, ptr %4, align 4
  store i32 1, ptr %12, align 4
  br label %177

177:                                              ; preds = %174, %170, %98
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  br label %178

178:                                              ; preds = %177, %70
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #3
  %179 = load i32, ptr %4, align 4
  ret i32 %179
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK7glslang10TQualifier10hasBindingEv(ptr noundef nonnull align 8 dereferenceable(72)) #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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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 = !{!"_ZTS11EShLanguage", !7, i64 0}
!11 = !{!12, !6, i64 8}
!12 = !{!"_ZTSN7glslang13TVarEntryInfoE", !13, i64 0, !6, i64 8, !14, i64 16, !15, i64 20, !15, i64 24, !15, i64 28, !15, i64 32, !15, i64 36, !10, i64 40}
!13 = !{!"long long", !7, i64 0}
!14 = !{!"bool", !7, i64 0}
!15 = !{!"int", !7, i64 0}
!16 = !{!17, !17, i64 0}
!17 = !{!"vtable pointer", !8, i64 0}
!18 = !{!19, !6, i64 72}
!19 = !{!"_ZTSN7glslang22TDefaultIoResolverBaseE", !20, i64 0, !21, i64 8, !14, i64 64, !6, i64 72, !15, i64 80, !15, i64 84, !15, i64 88, !7, i64 92, !7, i64 112}
!20 = !{!"_ZTSN7glslang14TIoMapResolverE"}
!21 = !{!"_ZTSSt13unordered_mapIiSt6vectorIiSaIiEESt4hashIiESt8equal_toIiESaISt4pairIKiS2_EEE", !22, i64 0}
!22 = !{!"_ZTSSt10_HashtableIiSt4pairIKiSt6vectorIiSaIiEEESaIS5_ENSt8__detail10_Select1stESt8equal_toIiESt4hashIiENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb0ELb0ELb1EEEE", !6, i64 0, !23, i64 8, !24, i64 16, !23, i64 24, !25, i64 32, !6, i64 48}
!23 = !{!"long", !7, i64 0}
!24 = !{!"_ZTSNSt8__detail15_Hash_node_baseE", !6, i64 0}
!25 = !{!"_ZTSNSt8__detail20_Prime_rehash_policyE", !26, i64 0, !23, i64 8}
!26 = !{!"float", !7, i64 0}
!27 = !{!28, !15, i64 12}
!28 = !{!"_ZTSN7glslang10SpvVersionE", !15, i64 0, !15, i64 4, !15, i64 8, !15, i64 12, !14, i64 16}
!29 = !{!15, !15, i64 0}
!30 = !{!31, !31, i64 0}
!31 = !{!"_ZTSN7glslang13TResourceTypeE", !7, i64 0}
!32 = !{!12, !15, i64 20}
!33 = !{!12, !15, i64 24}
!34 = !{!14, !14, i64 0}
!35 = !{!36, !15, i64 40}
!36 = !{!"_ZTSSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiE", !37, i64 0, !15, i64 40}
!37 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEE", !38, i64 0, !23, i64 16, !7, i64 24}
!38 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEE12_Alloc_hiderE", !39, i64 0, !6, i64 8}
!39 = !{!"_ZTSN7glslang14pool_allocatorIcEE", !6, i64 0}
!40 = !{i8 0, i8 2}
!41 = !{}
!42 = !{!12, !14, i64 16}


; 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.std::_Rb_tree_iterator" = type { ptr }

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK7glslang22TDefaultIoResolverBase20doAutoBindingMappingEv(ptr noundef nonnull align 8 dereferenceable(224)) local_unnamed_addr #0 align 2

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(17) ptr @_ZNK7glslang13TIntermediate6getSpvEv(ptr noundef nonnull align 8 dereferenceable(1784)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE4findERSB_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #0 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEEixERSB_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN7glslang22TDefaultGlslIoResolver14resolveBindingE11EShLanguageRNS_13TVarEntryInfoE(ptr noundef nonnull align 8 dereferenceable(328) %0, i32 noundef %1, ptr nocapture noundef nonnull align 8 dereferenceable(48) %2) unnamed_addr #0 align 2 {
  %4 = alloca i32, align 4
  %5 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %6 = alloca %"struct.std::_Rb_tree_iterator", align 8
  %7 = getelementptr inbounds i8, ptr %2, i64 8
  %8 = load ptr, ptr %7, align 8, !tbaa !5
  %9 = load ptr, ptr %8, align 8, !tbaa !14
  %10 = getelementptr inbounds i8, ptr %9, i64 240
  %11 = load ptr, ptr %10, align 8
  %12 = tail call noundef nonnull align 8 dereferenceable(144) ptr %11(ptr noundef nonnull align 8 dereferenceable(176) %8)
  %13 = load ptr, ptr %7, align 8, !tbaa !5
  %14 = load ptr, ptr %13, align 8, !tbaa !14
  %15 = getelementptr inbounds i8, ptr %14, i64 408
  %16 = load ptr, ptr %15, align 8
  %17 = tail call noundef nonnull align 8 dereferenceable(40) ptr %16(ptr noundef nonnull align 8 dereferenceable(256) %13)
  %18 = getelementptr inbounds i8, ptr %0, i64 72
  %19 = load ptr, ptr %18, align 8, !tbaa !16
  %20 = tail call noundef nonnull align 4 dereferenceable(17) ptr @_ZNK7glslang13TIntermediate6getSpvEv(ptr noundef nonnull align 8 dereferenceable(1784) %19)
  %21 = getelementptr inbounds i8, ptr %20, i64 12
  %22 = load i32, ptr %21, align 4, !tbaa !25
  %.not = icmp eq i32 %22, 0
  br i1 %.not, label %33, label %23

23:                                               ; preds = %3
  %24 = load ptr, ptr %12, align 8, !tbaa !14
  %25 = getelementptr inbounds i8, ptr %24, i64 240
  %26 = load ptr, ptr %25, align 8
  %27 = tail call noundef zeroext i1 %26(ptr noundef nonnull align 8 dereferenceable(144) %12)
  br i1 %27, label %28, label %33

28:                                               ; preds = %23
  %29 = load ptr, ptr %12, align 8, !tbaa !14
  %30 = getelementptr inbounds i8, ptr %29, i64 136
  %31 = load ptr, ptr %30, align 8
  %32 = tail call noundef i32 %31(ptr noundef nonnull align 8 dereferenceable(144) %12)
  br label %33

33:                                               ; preds = %3, %23, %28
  %34 = phi i32 [ %32, %28 ], [ 1, %23 ], [ 1, %3 ]
  %35 = load ptr, ptr %0, align 8, !tbaa !14
  %36 = getelementptr inbounds i8, ptr %35, i64 168
  %37 = load ptr, ptr %36, align 8
  %38 = tail call noundef i32 %37(ptr noundef nonnull align 8 dereferenceable(328) %0, ptr noundef nonnull align 8 dereferenceable(144) %12)
  %39 = icmp eq i32 %38, 3
  br i1 %39, label %40, label %47

40:                                               ; preds = %33
  %41 = load ptr, ptr %12, align 8, !tbaa !14
  %42 = getelementptr inbounds i8, ptr %41, i64 56
  %43 = load ptr, ptr %42, align 8
  %44 = tail call noundef i32 %43(ptr noundef nonnull align 8 dereferenceable(144) %12)
  %.not39 = icmp eq i32 %44, 16
  br i1 %.not39, label %47, label %45

45:                                               ; preds = %40
  %46 = getelementptr inbounds i8, ptr %2, i64 20
  store i32 -1, ptr %46, align 4, !tbaa !27
  br label %107

47:                                               ; preds = %40, %33
  %48 = load ptr, ptr %18, align 8, !tbaa !16
  %49 = tail call noundef nonnull align 4 dereferenceable(17) ptr @_ZNK7glslang13TIntermediate6getSpvEv(ptr noundef nonnull align 8 dereferenceable(1784) %48)
  %50 = getelementptr inbounds i8, ptr %49, i64 12
  %51 = load i32, ptr %50, align 4, !tbaa !25
  %.not40 = icmp eq i32 %51, 0
  %52 = getelementptr inbounds i8, ptr %2, i64 24
  %53 = load i32, ptr %52, align 8
  %54 = select i1 %.not40, i32 %53, i32 %38
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #3
  store i32 %54, ptr %4, align 4, !tbaa !28
  %55 = icmp slt i32 %38, 6
  br i1 %55, label %56, label %104

56:                                               ; preds = %47
  %57 = load ptr, ptr %12, align 8, !tbaa !14
  %58 = getelementptr inbounds i8, ptr %57, i64 88
  %59 = load ptr, ptr %58, align 8
  %60 = tail call noundef nonnull align 8 dereferenceable(72) ptr %59(ptr noundef nonnull align 8 dereferenceable(144) %12)
  %61 = tail call noundef zeroext i1 @_ZNK7glslang10TQualifier10hasBindingEv(ptr noundef nonnull align 8 dereferenceable(72) %60)
  br i1 %61, label %62, label %76

62:                                               ; preds = %56
  %63 = tail call noundef i32 @_ZNK7glslang22TDefaultIoResolverBase14getBaseBindingE11EShLanguageNS_13TResourceTypeEj(ptr noundef nonnull align 8 dereferenceable(224) %0, i32 noundef %1, i32 noundef %38, i32 noundef %54)
  %64 = load ptr, ptr %12, align 8, !tbaa !14
  %65 = getelementptr inbounds i8, ptr %64, i64 88
  %66 = load ptr, ptr %65, align 8
  %67 = tail call noundef nonnull align 8 dereferenceable(72) ptr %66(ptr noundef nonnull align 8 dereferenceable(144) %12)
  %68 = getelementptr inbounds i8, ptr %67, i64 28
  %69 = load i64, ptr %68, align 4
  %70 = lshr i64 %69, 32
  %71 = trunc nuw i64 %70 to i32
  %72 = and i32 %71, 65535
  %73 = add nsw i32 %72, %63
  %74 = tail call noundef i32 @_ZN7glslang22TDefaultIoResolverBase11reserveSlotEiii(ptr noundef nonnull align 8 dereferenceable(224) %0, i32 noundef %54, i32 noundef %73, i32 noundef %34)
  %75 = getelementptr inbounds i8, ptr %2, i64 20
  store i32 %74, ptr %75, align 4, !tbaa !27
  br label %106

76:                                               ; preds = %56
  %77 = getelementptr inbounds i8, ptr %2, i64 20
  store i32 -1, ptr %77, align 4, !tbaa !27
  %78 = getelementptr inbounds i8, ptr %0, i64 232
  %79 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48) %78, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %80 = call noundef zeroext i1 @_ZNKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48) %79) #3
  br i1 %80, label %.critedge, label %81

81:                                               ; preds = %76
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #3
  %82 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48) %78, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %83 = call ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE4findERSB_(ptr noundef nonnull align 8 dereferenceable(48) %82, ptr noundef nonnull align 8 dereferenceable(40) %17)
  store ptr %83, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #3
  %84 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48) %78, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %85 = call ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %84) #3
  store ptr %85, ptr %6, align 8
  %86 = call noundef zeroext i1 @_ZStneRKSt17_Rb_tree_iteratorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiEESD_(ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(8) %6) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #3
  br i1 %86, label %87, label %.critedge42

87:                                               ; preds = %81
  %88 = call noundef ptr @_ZNKSt17_Rb_tree_iteratorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiEEptEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #3
  %89 = getelementptr inbounds i8, ptr %88, i64 40
  %90 = load i32, ptr %89, align 8, !tbaa !29
  store i32 %90, ptr %77, align 4, !tbaa !27
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #3
  br label %102

.critedge42:                                      ; preds = %81
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #3
  br label %.critedge

.critedge:                                        ; preds = %76, %.critedge42
  %91 = getelementptr inbounds i8, ptr %2, i64 16
  %92 = load i8, ptr %91, align 8, !tbaa !34, !range !35, !noundef !36
  %93 = trunc nuw i8 %92 to i1
  br i1 %93, label %94, label %102

94:                                               ; preds = %.critedge
  %95 = call noundef zeroext i1 @_ZNK7glslang22TDefaultIoResolverBase20doAutoBindingMappingEv(ptr noundef nonnull align 8 dereferenceable(224) %0)
  br i1 %95, label %96, label %102

96:                                               ; preds = %94
  %97 = load i32, ptr %4, align 4, !tbaa !28
  %98 = call noundef i32 @_ZNK7glslang22TDefaultIoResolverBase14getBaseBindingE11EShLanguageNS_13TResourceTypeEj(ptr noundef nonnull align 8 dereferenceable(224) %0, i32 noundef %1, i32 noundef %38, i32 noundef %54)
  %99 = call noundef i32 @_ZN7glslang22TDefaultIoResolverBase11getFreeSlotEiii(ptr noundef nonnull align 8 dereferenceable(224) %0, i32 noundef %97, i32 noundef %98, i32 noundef %34)
  %100 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3mapIiS_INSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEES8_IiESaISA_IKiSE_EEEixERSG_(ptr noundef nonnull align 8 dereferenceable(48) %78, ptr noundef nonnull align 4 dereferenceable(4) %4)
  %101 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiSt4lessIS7_ESaISt4pairIKS7_iEEEixERSB_(ptr noundef nonnull align 8 dereferenceable(48) %100, ptr noundef nonnull align 8 dereferenceable(40) %17)
  store i32 %99, ptr %101, align 4, !tbaa !28
  store i32 %99, ptr %77, align 4, !tbaa !27
  br label %102

102:                                              ; preds = %87, %96, %94, %.critedge
  %103 = load i32, ptr %77, align 4, !tbaa !27
  br label %106

104:                                              ; preds = %47
  %105 = getelementptr inbounds i8, ptr %2, i64 20
  store i32 -1, ptr %105, align 4, !tbaa !27
  br label %106

106:                                              ; preds = %104, %102, %62
  %.0 = phi i32 [ %74, %62 ], [ %103, %102 ], [ -1, %104 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #3
  br label %107

107:                                              ; preds = %106, %45
  %.1 = phi i32 [ -1, %45 ], [ %.0, %106 ]
  ret i32 %.1
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK7glslang10TQualifier10hasBindingEv(ptr noundef nonnull align 8 dereferenceable(72)) 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 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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, !10, i64 8}
!6 = !{!"_ZTSN7glslang13TVarEntryInfoE", !7, i64 0, !10, i64 8, !11, i64 16, !12, i64 20, !12, i64 24, !12, i64 28, !12, i64 32, !12, i64 36, !13, i64 40}
!7 = !{!"long long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"bool", !8, i64 0}
!12 = !{!"int", !8, i64 0}
!13 = !{!"_ZTS11EShLanguage", !8, i64 0}
!14 = !{!15, !15, i64 0}
!15 = !{!"vtable pointer", !9, i64 0}
!16 = !{!17, !10, i64 72}
!17 = !{!"_ZTSN7glslang22TDefaultIoResolverBaseE", !18, i64 0, !19, i64 8, !11, i64 64, !10, i64 72, !12, i64 80, !12, i64 84, !12, i64 88, !8, i64 92, !8, i64 112}
!18 = !{!"_ZTSN7glslang14TIoMapResolverE"}
!19 = !{!"_ZTSSt13unordered_mapIiSt6vectorIiSaIiEESt4hashIiESt8equal_toIiESaISt4pairIKiS2_EEE", !20, i64 0}
!20 = !{!"_ZTSSt10_HashtableIiSt4pairIKiSt6vectorIiSaIiEEESaIS5_ENSt8__detail10_Select1stESt8equal_toIiESt4hashIiENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb0ELb0ELb1EEEE", !10, i64 0, !21, i64 8, !22, i64 16, !21, i64 24, !23, i64 32, !10, i64 48}
!21 = !{!"long", !8, i64 0}
!22 = !{!"_ZTSNSt8__detail15_Hash_node_baseE", !10, i64 0}
!23 = !{!"_ZTSNSt8__detail20_Prime_rehash_policyE", !24, i64 0, !21, i64 8}
!24 = !{!"float", !8, i64 0}
!25 = !{!26, !12, i64 12}
!26 = !{!"_ZTSN7glslang10SpvVersionE", !12, i64 0, !12, i64 4, !12, i64 8, !12, i64 12, !11, i64 16}
!27 = !{!6, !12, i64 20}
!28 = !{!12, !12, i64 0}
!29 = !{!30, !12, i64 40}
!30 = !{!"_ZTSSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEEiE", !31, i64 0, !12, i64 40}
!31 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEEE", !32, i64 0, !21, i64 16, !8, i64 24}
!32 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcEN7glslang14pool_allocatorIcEEE12_Alloc_hiderE", !33, i64 0, !10, i64 8}
!33 = !{!"_ZTSN7glslang14pool_allocatorIcEE", !10, i64 0}
!34 = !{!6, !11, i64 16}
!35 = !{i8 0, i8 2}
!36 = !{}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass