; LLVM IR from buresjan/optim_lbm :: nomad/src/Algos (Subproblem)

; 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.std::set.19" = type { %"class.std::_Rb_tree.20" }
%"class.std::_Rb_tree.20" = type { %"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_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 <{ %"struct.std::_Rb_tree_const_iterator", i8, [7 x i8] }>
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%"class.std::__cxx11::list" = type { %"class.std::__cxx11::_List_base" }
%"class.std::__cxx11::_List_base" = type { %"struct.std::__cxx11::_List_base<std::set<unsigned long>, std::allocator<std::set<unsigned long>>>::_List_impl" }
%"struct.std::__cxx11::_List_base<std::set<unsigned long>, std::allocator<std::set<unsigned long>>>::_List_impl" = type { %"struct.std::__detail::_List_node_header" }
%"struct.std::__detail::_List_node_header" = type { %"struct.std::__detail::_List_node_base", i64 }
%"struct.std::__detail::_List_node_base" = type { ptr, ptr }
%"struct.std::_List_iterator" = type { ptr }

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

declare i32 @__gxx_personality_v0(...)

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

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

declare noundef nonnull align 8 dereferenceable(17) ptr @_ZNK9NOMAD_4_313ArrayOfDoubleixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK9NOMAD_4_310Subproblem40resetVariableGroupsAgainstFixedVariablesERNSt7__cxx114listISt3setImSt4lessImESaImEESaIS7_EEERKNS_5PointE(ptr noundef nonnull align 8 dereferenceable(72) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(24) %2) #3 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca %"class.std::set.19", align 8
  %9 = alloca i64, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca %"struct.std::pair", align 8
  %13 = alloca %"class.std::__cxx11::list", align 8
  %14 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %15 = alloca ptr, align 8
  %16 = alloca %"struct.std::_List_iterator", align 8
  %17 = alloca %"struct.std::_List_iterator", align 8
  %18 = alloca i32, align 4
  %19 = alloca %"class.std::set.19", align 8
  %20 = alloca %"class.std::set.19", align 8
  %21 = alloca ptr, align 8
  %22 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %23 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %24 = alloca i64, align 8
  %25 = alloca i64, align 8
  %26 = alloca %"struct.std::pair", align 8
  %27 = alloca %"struct.std::pair", align 8
  %28 = alloca %"class.std::set.19", align 8
  %29 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %30 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %31 = alloca i64, align 8
  %32 = alloca %"struct.std::pair", align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  %33 = load ptr, ptr %4, align 8
  %34 = load ptr, ptr %5, align 8, !tbaa !5
  %35 = call noundef zeroext i1 @_ZNKSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %34) #5
  br i1 %35, label %42, label %36

36:                                               ; preds = %3
  %37 = load ptr, ptr %6, align 8, !tbaa !5
  %38 = load ptr, ptr %37, align 8, !tbaa !9
  %39 = getelementptr inbounds ptr, ptr %38, i64 2
  %40 = load ptr, ptr %39, align 8
  %41 = call noundef zeroext i1 %40(ptr noundef nonnull align 8 dereferenceable(24) %37)
  br i1 %41, label %43, label %42

42:                                               ; preds = %36, %3
  br label %196

43:                                               ; preds = %36
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %44 = load ptr, ptr %6, align 8, !tbaa !5
  %45 = call noundef i64 @_ZNK9NOMAD_4_313ArrayOfDouble4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %44)
  store i64 %45, ptr %7, align 8, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 48, ptr %8) #5
  call void @_ZNSt3setImSt4lessImESaImEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  store i64 0, ptr %9, align 8, !tbaa !11
  br label %46

46:                                               ; preds = %70, %43
  %47 = load i64, ptr %9, align 8, !tbaa !11
  %48 = load i64, ptr %7, align 8, !tbaa !11
  %49 = icmp ult i64 %47, %48
  br i1 %49, label %51, label %50

50:                                               ; preds = %46
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %73

51:                                               ; preds = %46
  %52 = load ptr, ptr %6, align 8, !tbaa !5
  %53 = load i64, ptr %9, align 8, !tbaa !11
  %54 = invoke noundef nonnull align 8 dereferenceable(17) ptr @_ZNK9NOMAD_4_313ArrayOfDoubleixEm(ptr noundef nonnull align 8 dereferenceable(24) %52, i64 noundef %53)
          to label %55 unwind label %65

55:                                               ; preds = %51
  %56 = invoke noundef zeroext i1 @_ZNK9NOMAD_4_36Double9isDefinedEv(ptr noundef nonnull align 8 dereferenceable(17) %54)
          to label %57 unwind label %65

57:                                               ; preds = %55
  br i1 %56, label %58, label %69

58:                                               ; preds = %57
  %59 = invoke { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48) %8, ptr noundef nonnull align 8 dereferenceable(8) %9)
          to label %60 unwind label %65

60:                                               ; preds = %58
  %61 = getelementptr inbounds { ptr, i8 }, ptr %12, i32 0, i32 0
  %62 = extractvalue { ptr, i8 } %59, 0
  store ptr %62, ptr %61, align 8
  %63 = getelementptr inbounds { ptr, i8 }, ptr %12, i32 0, i32 1
  %64 = extractvalue { ptr, i8 } %59, 1
  store i8 %64, ptr %63, align 8
  br label %69

65:                                               ; preds = %58, %55, %51
  %66 = landingpad { ptr, i32 }
          cleanup
  %67 = extractvalue { ptr, i32 } %66, 0
  store ptr %67, ptr %10, align 8
  %68 = extractvalue { ptr, i32 } %66, 1
  store i32 %68, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %197

69:                                               ; preds = %60, %57
  br label %70

70:                                               ; preds = %69
  %71 = load i64, ptr %9, align 8, !tbaa !11
  %72 = add i64 %71, 1
  store i64 %72, ptr %9, align 8, !tbaa !11
  br label %46, !llvm.loop !13

73:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 24, ptr %13) #5
  call void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  br label %74

74:                                               ; preds = %188, %73
  %75 = call noundef zeroext i1 @_ZNKSt3setImSt4lessImESaImEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  %76 = xor i1 %75, true
  br i1 %76, label %77, label %195

77:                                               ; preds = %74
  call void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  %78 = call ptr @_ZNKSt3setImSt4lessImESaImEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  %79 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %14, i32 0, i32 0
  store ptr %78, ptr %79, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  %80 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %80, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  %81 = load ptr, ptr %15, align 8, !tbaa !5
  %82 = call ptr @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %81) #5
  %83 = getelementptr inbounds %"struct.std::_List_iterator", ptr %16, i32 0, i32 0
  store ptr %82, ptr %83, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  %84 = load ptr, ptr %15, align 8, !tbaa !5
  %85 = call ptr @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %84) #5
  %86 = getelementptr inbounds %"struct.std::_List_iterator", ptr %17, i32 0, i32 0
  store ptr %85, ptr %86, align 8
  br label %87

87:                                               ; preds = %156, %77
  %88 = call noundef zeroext i1 @_ZStneRKSt14_List_iteratorISt3setImSt4lessImESaImEEES7_(ptr noundef nonnull align 8 dereferenceable(8) %16, ptr noundef nonnull align 8 dereferenceable(8) %17) #5
  br i1 %88, label %90, label %89

89:                                               ; preds = %87
  store i32 7, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  br label %160

90:                                               ; preds = %87
  call void @llvm.lifetime.start.p0(i64 48, ptr %19) #5
  %91 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNKSt14_List_iteratorISt3setImSt4lessImESaImEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %16) #5
  invoke void @_ZNSt3setImSt4lessImESaImEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(48) %19, ptr noundef nonnull align 8 dereferenceable(48) %91)
          to label %92 unwind label %102

92:                                               ; preds = %90
  call void @llvm.lifetime.start.p0(i64 48, ptr %20) #5
  call void @_ZNSt3setImSt4lessImESaImEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %20) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #5
  store ptr %19, ptr %21, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #5
  %93 = load ptr, ptr %21, align 8, !tbaa !5
  %94 = call ptr @_ZNKSt3setImSt4lessImESaImEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %93) #5
  %95 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %22, i32 0, i32 0
  store ptr %94, ptr %95, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #5
  %96 = load ptr, ptr %21, align 8, !tbaa !5
  %97 = call ptr @_ZNKSt3setImSt4lessImESaImEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %96) #5
  %98 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %23, i32 0, i32 0
  store ptr %97, ptr %98, align 8
  br label %99

99:                                               ; preds = %144, %92
  %100 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorImES2_(ptr noundef nonnull align 8 dereferenceable(8) %22, ptr noundef nonnull align 8 dereferenceable(8) %23) #5
  br i1 %100, label %106, label %101

101:                                              ; preds = %99
  store i32 9, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  br label %147

102:                                              ; preds = %90
  %103 = landingpad { ptr, i32 }
          cleanup
  %104 = extractvalue { ptr, i32 } %103, 0
  store ptr %104, ptr %10, align 8
  %105 = extractvalue { ptr, i32 } %103, 1
  store i32 %105, ptr %11, align 4
  br label %159

106:                                              ; preds = %99
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #5
  %107 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt23_Rb_tree_const_iteratorImEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %22) #5
  %108 = load i64, ptr %107, align 8, !tbaa !11
  store i64 %108, ptr %24, align 8, !tbaa !11
  %109 = load i64, ptr %24, align 8, !tbaa !11
  %110 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt23_Rb_tree_const_iteratorImEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #5
  %111 = load i64, ptr %110, align 8, !tbaa !11
  %112 = icmp ugt i64 %109, %111
  br i1 %112, label %113, label %126

113:                                              ; preds = %106
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #5
  %114 = load i64, ptr %24, align 8, !tbaa !11
  %115 = sub i64 %114, 1
  store i64 %115, ptr %25, align 8, !tbaa !11
  %116 = invoke { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertEOm(ptr noundef nonnull align 8 dereferenceable(48) %20, ptr noundef nonnull align 8 dereferenceable(8) %25)
          to label %117 unwind label %122

117:                                              ; preds = %113
  %118 = getelementptr inbounds { ptr, i8 }, ptr %26, i32 0, i32 0
  %119 = extractvalue { ptr, i8 } %116, 0
  store ptr %119, ptr %118, align 8
  %120 = getelementptr inbounds { ptr, i8 }, ptr %26, i32 0, i32 1
  %121 = extractvalue { ptr, i8 } %116, 1
  store i8 %121, ptr %120, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  br label %143

122:                                              ; preds = %113
  %123 = landingpad { ptr, i32 }
          cleanup
  %124 = extractvalue { ptr, i32 } %123, 0
  store ptr %124, ptr %10, align 8
  %125 = extractvalue { ptr, i32 } %123, 1
  store i32 %125, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #5
  br label %146

126:                                              ; preds = %106
  %127 = load i64, ptr %24, align 8, !tbaa !11
  %128 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt23_Rb_tree_const_iteratorImEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #5
  %129 = load i64, ptr %128, align 8, !tbaa !11
  %130 = icmp ult i64 %127, %129
  br i1 %130, label %131, label %142

131:                                              ; preds = %126
  %132 = invoke { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48) %20, ptr noundef nonnull align 8 dereferenceable(8) %24)
          to label %133 unwind label %138

133:                                              ; preds = %131
  %134 = getelementptr inbounds { ptr, i8 }, ptr %27, i32 0, i32 0
  %135 = extractvalue { ptr, i8 } %132, 0
  store ptr %135, ptr %134, align 8
  %136 = getelementptr inbounds { ptr, i8 }, ptr %27, i32 0, i32 1
  %137 = extractvalue { ptr, i8 } %132, 1
  store i8 %137, ptr %136, align 8
  br label %142

138:                                              ; preds = %131
  %139 = landingpad { ptr, i32 }
          cleanup
  %140 = extractvalue { ptr, i32 } %139, 0
  store ptr %140, ptr %10, align 8
  %141 = extractvalue { ptr, i32 } %139, 1
  store i32 %141, ptr %11, align 4
  br label %146

142:                                              ; preds = %133, %126
  br label %143

143:                                              ; preds = %142, %117
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #5
  br label %144

144:                                              ; preds = %143
  %145 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorImEppEv(ptr noundef nonnull align 8 dereferenceable(8) %22) #5
  br label %99

146:                                              ; preds = %138, %122
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #5
  br label %158

147:                                              ; preds = %101
  %148 = call noundef zeroext i1 @_ZNKSt3setImSt4lessImESaImEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48) %20) #5
  br i1 %148, label %155, label %149

149:                                              ; preds = %147
  invoke void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE9push_backERKS5_(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef nonnull align 8 dereferenceable(48) %20)
          to label %150 unwind label %151

150:                                              ; preds = %149
  br label %155

151:                                              ; preds = %149
  %152 = landingpad { ptr, i32 }
          cleanup
  %153 = extractvalue { ptr, i32 } %152, 0
  store ptr %153, ptr %10, align 8
  %154 = extractvalue { ptr, i32 } %152, 1
  store i32 %154, ptr %11, align 4
  br label %158

155:                                              ; preds = %150, %147
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %20) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %20) #5
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #5
  br label %156

156:                                              ; preds = %155
  %157 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt14_List_iteratorISt3setImSt4lessImESaImEEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %16) #5
  br label %87

158:                                              ; preds = %151, %146
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %20) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %20) #5
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %19) #5
  br label %159

159:                                              ; preds = %158, %102
  call void @llvm.lifetime.end.p0(i64 48, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  br label %194

160:                                              ; preds = %89
  call void @llvm.lifetime.start.p0(i64 48, ptr %28) #5
  call void @_ZNSt3setImSt4lessImESaImEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %28) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #5
  %161 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorImEppEv(ptr noundef nonnull align 8 dereferenceable(8) %14) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %29, ptr align 8 %161, i64 8, i1 false), !tbaa.struct !15
  br label %162

162:                                              ; preds = %177, %160
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #5
  %163 = call ptr @_ZNKSt3setImSt4lessImESaImEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  %164 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %30, i32 0, i32 0
  store ptr %163, ptr %164, align 8
  %165 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorImES2_(ptr noundef nonnull align 8 dereferenceable(8) %29, ptr noundef nonnull align 8 dereferenceable(8) %30) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #5
  br i1 %165, label %167, label %166

166:                                              ; preds = %162
  store i32 11, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #5
  br label %183

167:                                              ; preds = %162
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #5
  %168 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt23_Rb_tree_const_iteratorImEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %29) #5
  %169 = load i64, ptr %168, align 8, !tbaa !11
  %170 = sub i64 %169, 1
  store i64 %170, ptr %31, align 8, !tbaa !11
  %171 = invoke { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertEOm(ptr noundef nonnull align 8 dereferenceable(48) %28, ptr noundef nonnull align 8 dereferenceable(8) %31)
          to label %172 unwind label %179

172:                                              ; preds = %167
  %173 = getelementptr inbounds { ptr, i8 }, ptr %32, i32 0, i32 0
  %174 = extractvalue { ptr, i8 } %171, 0
  store ptr %174, ptr %173, align 8
  %175 = getelementptr inbounds { ptr, i8 }, ptr %32, i32 0, i32 1
  %176 = extractvalue { ptr, i8 } %171, 1
  store i8 %176, ptr %175, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #5
  br label %177

177:                                              ; preds = %172
  %178 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorImEppEv(ptr noundef nonnull align 8 dereferenceable(8) %29) #5
  br label %162, !llvm.loop !16

179:                                              ; preds = %167
  %180 = landingpad { ptr, i32 }
          cleanup
  %181 = extractvalue { ptr, i32 } %180, 0
  store ptr %181, ptr %10, align 8
  %182 = extractvalue { ptr, i32 } %180, 1
  store i32 %182, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #5
  br label %193

183:                                              ; preds = %166
  %184 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3setImSt4lessImESaImEEaSERKS3_(ptr noundef nonnull align 8 dereferenceable(48) %8, ptr noundef nonnull align 8 dereferenceable(48) %28)
          to label %185 unwind label %189

185:                                              ; preds = %183
  %186 = load ptr, ptr %5, align 8, !tbaa !5
  %187 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EEaSERKS7_(ptr noundef nonnull align 8 dereferenceable(24) %186, ptr noundef nonnull align 8 dereferenceable(24) %13)
          to label %188 unwind label %189

188:                                              ; preds = %185
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %28) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %28) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  br label %74, !llvm.loop !17

189:                                              ; preds = %185, %183
  %190 = landingpad { ptr, i32 }
          cleanup
  %191 = extractvalue { ptr, i32 } %190, 0
  store ptr %191, ptr %10, align 8
  %192 = extractvalue { ptr, i32 } %190, 1
  store i32 %192, ptr %11, align 4
  br label %193

193:                                              ; preds = %189, %179
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %28) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %28) #5
  br label %194

194:                                              ; preds = %193, %159
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  call void @_ZNSt7__cxx1110_List_baseISt3setImSt4lessImESaImEESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #5
  br label %197

195:                                              ; preds = %74
  call void @_ZNSt7__cxx1110_List_baseISt3setImSt4lessImESaImEESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #5
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  br label %196

196:                                              ; preds = %195, %42
  ret void

197:                                              ; preds = %194, %65
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  br label %198

198:                                              ; preds = %197
  %199 = load ptr, ptr %10, align 8
  %200 = load i32, ptr %11, align 4
  %201 = insertvalue { ptr, i32 } poison, ptr %199, 0
  %202 = insertvalue { ptr, i32 } %201, i32 %200, 1
  resume { ptr, i32 } %202
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt7__cxx1110_List_baseISt3setImSt4lessImESaImEESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt3setImSt4lessImESaImEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #3 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertEOm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE9push_backERKS5_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(48)) #3 align 2

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

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

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

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

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { "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 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 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #5 = { 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 = !{!"vtable pointer", !8, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{i64 0, i64 8, !5}
!16 = distinct !{!16, !14}
!17 = distinct !{!17, !14}


; 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.std::set.19" = type { %"class.std::_Rb_tree.20" }
%"class.std::_Rb_tree.20" = type { %"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned long, unsigned long, std::_Identity<unsigned long>, std::less<unsigned long>>::_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 }
%"class.std::__cxx11::list" = type { %"class.std::__cxx11::_List_base" }
%"class.std::__cxx11::_List_base" = type { %"struct.std::__cxx11::_List_base<std::set<unsigned long>, std::allocator<std::set<unsigned long>>>::_List_impl" }
%"struct.std::__cxx11::_List_base<std::set<unsigned long>, std::allocator<std::set<unsigned long>>>::_List_impl" = type { %"struct.std::__detail::_List_node_header" }
%"struct.std::__detail::_List_node_header" = type { %"struct.std::__detail::_List_node_base", i64 }
%"struct.std::__detail::_List_node_base" = type { ptr, ptr }
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%"struct.std::_List_iterator" = type { ptr }

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

declare i32 @__gxx_personality_v0(...)

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

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

declare noundef nonnull align 8 dereferenceable(17) ptr @_ZNK9NOMAD_4_313ArrayOfDoubleixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK9NOMAD_4_310Subproblem40resetVariableGroupsAgainstFixedVariablesERNSt7__cxx114listISt3setImSt4lessImESaImEESaIS7_EEERKNS_5PointE(ptr nocapture noundef nonnull readnone align 8 dereferenceable(72) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(24) %2) local_unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.std::set.19", align 8
  %5 = alloca i64, align 8
  %6 = alloca %"class.std::__cxx11::list", align 8
  %7 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %8 = alloca %"struct.std::_List_iterator", align 8
  %9 = alloca %"struct.std::_List_iterator", align 8
  %10 = alloca %"class.std::set.19", align 8
  %11 = alloca %"class.std::set.19", align 8
  %12 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %13 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca %"class.std::set.19", align 8
  %17 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %18 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %19 = alloca i64, align 8
  %20 = tail call noundef zeroext i1 @_ZNKSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #4
  br i1 %20, label %108, label %21

21:                                               ; preds = %3
  %22 = load ptr, ptr %2, align 8, !tbaa !5
  %23 = getelementptr inbounds i8, ptr %22, i64 16
  %24 = load ptr, ptr %23, align 8
  %25 = tail call noundef zeroext i1 %24(ptr noundef nonnull align 8 dereferenceable(24) %2)
  br i1 %25, label %26, label %108

26:                                               ; preds = %21
  %27 = tail call noundef i64 @_ZNK9NOMAD_4_313ArrayOfDouble4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %2)
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %4) #4
  call void @_ZNSt3setImSt4lessImESaImEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #4
  store i64 0, ptr %5, align 8, !tbaa !8
  %.not = icmp eq i64 %27, 0
  br i1 %.not, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %36, %26
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #4
  call void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #4
  %28 = call noundef zeroext i1 @_ZNKSt3setImSt4lessImESaImEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  br i1 %28, label %._crit_edge46, label %.lr.ph45

.lr.ph:                                           ; preds = %26, %36
  %storemerge34 = phi i64 [ %38, %36 ], [ 0, %26 ]
  %29 = invoke noundef nonnull align 8 dereferenceable(17) ptr @_ZNK9NOMAD_4_313ArrayOfDoubleixEm(ptr noundef nonnull align 8 dereferenceable(24) %2, i64 noundef %storemerge34)
          to label %30 unwind label %34

30:                                               ; preds = %.lr.ph
  %31 = call noundef zeroext i1 @_ZNK9NOMAD_4_36Double9isDefinedEv(ptr noundef nonnull align 8 dereferenceable(17) %29)
  br i1 %31, label %32, label %36

32:                                               ; preds = %30
  %33 = invoke { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 8 dereferenceable(8) %5)
          to label %36 unwind label %34

34:                                               ; preds = %32, %.lr.ph
  %35 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #4
  br label %109

36:                                               ; preds = %32, %30
  %37 = load i64, ptr %5, align 8, !tbaa !8
  %38 = add i64 %37, 1
  store i64 %38, ptr %5, align 8, !tbaa !8
  %39 = icmp ult i64 %38, %27
  br i1 %39, label %.lr.ph, label %._crit_edge, !llvm.loop !11

.lr.ph45:                                         ; preds = %._crit_edge, %102
  call void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #4
  %40 = call ptr @_ZNKSt3setImSt4lessImESaImEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  store ptr %40, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #4
  %41 = call ptr @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #4
  store ptr %41, ptr %8, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #4
  %42 = call ptr @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #4
  store ptr %42, ptr %9, align 8
  %43 = call noundef zeroext i1 @_ZStneRKSt14_List_iteratorISt3setImSt4lessImESaImEEES7_(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(8) %9) #4
  br i1 %43, label %.lr.ph39, label %._crit_edge40

._crit_edge40:                                    ; preds = %84, %.lr.ph45
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #4
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %16) #4
  call void @_ZNSt3setImSt4lessImESaImEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %16) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %17) #4
  %44 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorImEppEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #4
  %45 = load i64, ptr %44, align 8, !tbaa !13
  store i64 %45, ptr %17, align 8, !tbaa !13
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #4
  %46 = call ptr @_ZNKSt3setImSt4lessImESaImEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  store ptr %46, ptr %18, align 8
  %47 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorImES2_(ptr noundef nonnull align 8 dereferenceable(8) %17, ptr noundef nonnull align 8 dereferenceable(8) %18) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #4
  br i1 %47, label %.lr.ph42, label %._crit_edge43

.lr.ph39:                                         ; preds = %.lr.ph45, %84
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %10) #4
  %48 = call noundef nonnull align 8 dereferenceable(48) ptr @_ZNKSt14_List_iteratorISt3setImSt4lessImESaImEEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #4
  invoke void @_ZNSt3setImSt4lessImESaImEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(48) %10, ptr noundef nonnull align 8 dereferenceable(48) %48)
          to label %49 unwind label %54

49:                                               ; preds = %.lr.ph39
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %11) #4
  call void @_ZNSt3setImSt4lessImESaImEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %11) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #4
  %50 = call ptr @_ZNKSt3setImSt4lessImESaImEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %10) #4
  store ptr %50, ptr %12, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #4
  %51 = call ptr @_ZNKSt3setImSt4lessImESaImEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %10) #4
  store ptr %51, ptr %13, align 8
  %52 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorImES2_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %13) #4
  br i1 %52, label %.lr.ph36, label %._crit_edge37

._crit_edge37:                                    ; preds = %77, %49
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #4
  %53 = call noundef zeroext i1 @_ZNKSt3setImSt4lessImESaImEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48) %11) #4
  br i1 %53, label %84, label %81

54:                                               ; preds = %.lr.ph39
  %55 = landingpad { ptr, i32 }
          cleanup
  br label %88

.lr.ph36:                                         ; preds = %49, %77
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %14) #4
  %56 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt23_Rb_tree_const_iteratorImEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #4
  %57 = load i64, ptr %56, align 8, !tbaa !8
  store i64 %57, ptr %14, align 8, !tbaa !8
  %58 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt23_Rb_tree_const_iteratorImEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #4
  %59 = load i64, ptr %58, align 8, !tbaa !8
  %60 = icmp ugt i64 %57, %59
  br i1 %60, label %61, label %68

61:                                               ; preds = %.lr.ph36
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #4
  %62 = load i64, ptr %14, align 8, !tbaa !8
  %63 = add i64 %62, -1
  store i64 %63, ptr %15, align 8, !tbaa !8
  %64 = invoke { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertEOm(ptr noundef nonnull align 8 dereferenceable(48) %11, ptr noundef nonnull align 8 dereferenceable(8) %15)
          to label %65 unwind label %66

65:                                               ; preds = %61
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #4
  br label %77

66:                                               ; preds = %61
  %67 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #4
  br label %80

68:                                               ; preds = %.lr.ph36
  %69 = load i64, ptr %14, align 8, !tbaa !8
  %70 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt23_Rb_tree_const_iteratorImEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #4
  %71 = load i64, ptr %70, align 8, !tbaa !8
  %72 = icmp ult i64 %69, %71
  br i1 %72, label %73, label %77

73:                                               ; preds = %68
  %74 = invoke { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48) %11, ptr noundef nonnull align 8 dereferenceable(8) %14)
          to label %77 unwind label %75

75:                                               ; preds = %73
  %76 = landingpad { ptr, i32 }
          cleanup
  br label %80

77:                                               ; preds = %73, %68, %65
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #4
  %78 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorImEppEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #4
  %79 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorImES2_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %13) #4
  br i1 %79, label %.lr.ph36, label %._crit_edge37

80:                                               ; preds = %75, %66
  %.pn27 = phi { ptr, i32 } [ %67, %66 ], [ %76, %75 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %14) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #4
  br label %87

81:                                               ; preds = %._crit_edge37
  invoke void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE9push_backERKS5_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(48) %11)
          to label %84 unwind label %82

82:                                               ; preds = %81
  %83 = landingpad { ptr, i32 }
          cleanup
  br label %87

84:                                               ; preds = %81, %._crit_edge37
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %11) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %11) #4
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %10) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %10) #4
  %85 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt14_List_iteratorISt3setImSt4lessImESaImEEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #4
  %86 = call noundef zeroext i1 @_ZStneRKSt14_List_iteratorISt3setImSt4lessImESaImEEES7_(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(8) %9) #4
  br i1 %86, label %.lr.ph39, label %._crit_edge40

87:                                               ; preds = %82, %80
  %.pn27.pn = phi { ptr, i32 } [ %.pn27, %80 ], [ %83, %82 ]
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %11) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %11) #4
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %10) #4
  br label %88

88:                                               ; preds = %87, %54
  %.pn27.pn.pn = phi { ptr, i32 } [ %.pn27.pn, %87 ], [ %55, %54 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %10) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #4
  br label %107

._crit_edge43:                                    ; preds = %94, %._crit_edge40
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #4
  %89 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNSt3setImSt4lessImESaImEEaSERKS3_(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 8 dereferenceable(48) %16)
          to label %100 unwind label %104

.lr.ph42:                                         ; preds = %._crit_edge40, %94
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %19) #4
  %90 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt23_Rb_tree_const_iteratorImEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %17) #4
  %91 = load i64, ptr %90, align 8, !tbaa !8
  %92 = add i64 %91, -1
  store i64 %92, ptr %19, align 8, !tbaa !8
  %93 = invoke { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertEOm(ptr noundef nonnull align 8 dereferenceable(48) %16, ptr noundef nonnull align 8 dereferenceable(8) %19)
          to label %94 unwind label %98

94:                                               ; preds = %.lr.ph42
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %19) #4
  %95 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorImEppEv(ptr noundef nonnull align 8 dereferenceable(8) %17) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #4
  %96 = call ptr @_ZNKSt3setImSt4lessImESaImEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  store ptr %96, ptr %18, align 8
  %97 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorImES2_(ptr noundef nonnull align 8 dereferenceable(8) %17, ptr noundef nonnull align 8 dereferenceable(8) %18) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #4
  br i1 %97, label %.lr.ph42, label %._crit_edge43, !llvm.loop !15

98:                                               ; preds = %.lr.ph42
  %99 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %19) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %17) #4
  br label %106

100:                                              ; preds = %._crit_edge43
  %101 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EEaSERKS7_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(24) %6)
          to label %102 unwind label %104

102:                                              ; preds = %100
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %16) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  %103 = call noundef zeroext i1 @_ZNKSt3setImSt4lessImESaImEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  br i1 %103, label %._crit_edge46, label %.lr.ph45, !llvm.loop !16

104:                                              ; preds = %100, %._crit_edge43
  %105 = landingpad { ptr, i32 }
          cleanup
  br label %106

106:                                              ; preds = %104, %98
  %.pn = phi { ptr, i32 } [ %99, %98 ], [ %105, %104 ]
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %16) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %16) #4
  br label %107

107:                                              ; preds = %106, %88
  %.pn27.pn.pn.pn = phi { ptr, i32 } [ %.pn27.pn.pn, %88 ], [ %.pn, %106 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  call void @_ZNSt7__cxx1110_List_baseISt3setImSt4lessImESaImEESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #4
  br label %109

._crit_edge46:                                    ; preds = %102, %._crit_edge
  call void @_ZNSt7__cxx1110_List_baseISt3setImSt4lessImESaImEESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #4
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4) #4
  br label %108

108:                                              ; preds = %3, %21, %._crit_edge46
  ret void

109:                                              ; preds = %107, %34
  %.pn32 = phi { ptr, i32 } [ %35, %34 ], [ %.pn27.pn.pn.pn, %107 ]
  call void @_ZNSt3setImSt4lessImESaImEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4) #4
  resume { ptr, i32 } %.pn32
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt7__cxx1110_List_baseISt3setImSt4lessImESaImEESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertERKm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt3setImSt4lessImESaImEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #3 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setImSt4lessImESaImEE6insertEOm(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EE9push_backERKS5_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #3 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt7__cxx114listISt3setImSt4lessImESaImEESaIS5_EEaSERKS7_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #3 align 2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { "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 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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"long", !10, i64 0}
!10 = !{!"omnipotent char", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !14, i64 0}
!14 = !{!"any pointer", !10, i64 0}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !12}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass