; LLVM IR from EricZinda/InductorHtn :: src/FXPlatform/Prolog (HtnTerm)

; 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::shared_ptr.6" = type { %"class.std::__shared_ptr.7" }
%"class.std::__shared_ptr.7" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }
%"class.std::vector.73" = type { %"struct.std::_Vector_base.74" }
%"struct.std::_Vector_base.74" = type { %"struct.std::_Vector_base<SubstituteStackFrame, std::allocator<SubstituteStackFrame>>::_Vector_impl" }
%"struct.std::_Vector_base<SubstituteStackFrame, std::allocator<SubstituteStackFrame>>::_Vector_impl" = type { %"struct.std::_Vector_base<SubstituteStackFrame, std::allocator<SubstituteStackFrame>>::_Vector_impl_data" }
%"struct.std::_Vector_base<SubstituteStackFrame, std::allocator<SubstituteStackFrame>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.SubstituteStackFrame = type { i32, %"class.std::vector", %"class.std::shared_ptr.6", ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::shared_ptr<HtnTerm>, std::allocator<std::shared_ptr<HtnTerm>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::shared_ptr<HtnTerm>, std::allocator<std::shared_ptr<HtnTerm>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::shared_ptr<HtnTerm>, std::allocator<std::shared_ptr<HtnTerm>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::shared_ptr<HtnTerm>, std::allocator<std::shared_ptr<HtnTerm>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.HtnTerm = type { %"class.std::enable_shared_from_this", ptr, %"class.std::vector", i8, i8, %"class.std::weak_ptr" }
%"class.std::enable_shared_from_this" = type { %"class.std::weak_ptr.0" }
%"class.std::weak_ptr.0" = type { %"class.std::__weak_ptr.1" }
%"class.std::__weak_ptr.1" = type { ptr, %"class.std::__weak_count" }
%"class.std::__weak_count" = type { ptr }
%"class.std::weak_ptr" = type { %"class.std::__weak_ptr" }
%"class.std::__weak_ptr" = type { ptr, %"class.std::__weak_count" }

; 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 void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt23enable_shared_from_thisI7HtnTermE16shared_from_thisEv(ptr dead_on_unwind noalias writable sret(%"class.std::shared_ptr.6") align 8, ptr noundef nonnull align 8 dereferenceable(16)) #2 align 2

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

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

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

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

declare void @_ZN14HtnTermFactory13CreateFunctorERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorISt10shared_ptrI7HtnTermESaISB_EE(ptr dead_on_unwind writable sret(%"class.std::shared_ptr.6") align 8, ptr noundef nonnull align 8 dereferenceable(33088), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) #3

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZStneI7HtnTermEbRKSt10shared_ptrIT_EDn(ptr noundef nonnull align 8 dereferenceable(16), ptr) #4

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7HtnTerm25SubstituteTermForVariableEP14HtnTermFactorySt10shared_ptrIS_ES3_(ptr dead_on_unwind noalias writable sret(%"class.std::shared_ptr.6") align 8 %0, ptr noundef nonnull align 8 dereferenceable(72) %1, ptr noundef %2, ptr noundef %3, ptr noundef %4) #2 align 2 personality ptr @__gxx_personality_v0 {
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca %"class.std::vector.73", align 8
  %12 = alloca %class.SubstituteStackFrame, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca %class.SubstituteStackFrame, align 8
  %16 = alloca ptr, align 8
  %17 = alloca %"class.std::shared_ptr.6", align 8
  %18 = alloca %"class.std::shared_ptr.6", align 8
  %19 = alloca %class.SubstituteStackFrame, align 8
  %20 = alloca %"class.std::shared_ptr.6", align 8
  %21 = alloca %"class.std::vector", align 8
  %22 = alloca %class.SubstituteStackFrame, align 8
  %23 = alloca %class.SubstituteStackFrame, align 8
  store ptr %0, ptr %6, align 8
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !5
  store ptr %4, ptr %10, align 8, !tbaa !5
  %24 = load ptr, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 24, ptr %11) #6
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  call void @llvm.lifetime.start.p0(i64 56, ptr %12) #6
  invoke void @_ZN20SubstituteStackFrameC2EP7HtnTerm(ptr noundef nonnull align 8 dereferenceable(56) %12, ptr noundef %24)
          to label %25 unwind label %52

25:                                               ; preds = %5
  invoke void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE9push_backEOS0_(ptr noundef nonnull align 8 dereferenceable(24) %11, ptr noundef nonnull align 8 dereferenceable(56) %12)
          to label %26 unwind label %56

26:                                               ; preds = %25
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %12) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr %12) #6
  call void @llvm.lifetime.start.p0(i64 56, ptr %15) #6
  invoke void @_ZN20SubstituteStackFrameC2Ev(ptr noundef nonnull align 8 dereferenceable(56) %15)
          to label %27 unwind label %61

27:                                               ; preds = %26
  br label %28

28:                                               ; preds = %224, %27
  %29 = call noundef i64 @_ZNKSt6vectorI20SubstituteStackFrameSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  %30 = icmp ugt i64 %29, 0
  br i1 %30, label %31, label %226

31:                                               ; preds = %28
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  %32 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  store ptr %32, ptr %16, align 8, !tbaa !5
  %33 = load ptr, ptr %16, align 8, !tbaa !5
  %34 = getelementptr inbounds %class.SubstituteStackFrame, ptr %33, i32 0, i32 3
  %35 = load ptr, ptr %34, align 8, !tbaa !9
  %36 = invoke noundef zeroext i1 @_ZNK7HtnTerm10isVariableEv(ptr noundef nonnull align 8 dereferenceable(72) %35)
          to label %37 unwind label %65

37:                                               ; preds = %31
  br i1 %36, label %38, label %85

38:                                               ; preds = %37
  %39 = load ptr, ptr %16, align 8, !tbaa !5
  %40 = getelementptr inbounds %class.SubstituteStackFrame, ptr %39, i32 0, i32 3
  %41 = load ptr, ptr %40, align 8, !tbaa !9
  %42 = call noundef nonnull align 8 dereferenceable(72) ptr @_ZNKSt19__shared_ptr_accessI7HtnTermLN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEdeEv(ptr noundef nonnull align 1 dereferenceable(1) %4) #6
  %43 = invoke noundef zeroext i1 @_ZNK7HtnTerm11nameEqualToERKS_(ptr noundef nonnull align 8 dereferenceable(72) %41, ptr noundef nonnull align 8 dereferenceable(72) %42)
          to label %44 unwind label %65

44:                                               ; preds = %38
  br i1 %43, label %45, label %69

45:                                               ; preds = %44
  %46 = load ptr, ptr %16, align 8, !tbaa !5
  %47 = getelementptr inbounds %class.SubstituteStackFrame, ptr %46, i32 0, i32 2
  %48 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt10shared_ptrI7HtnTermEaSERKS1_(ptr noundef nonnull align 8 dereferenceable(16) %47, ptr noundef nonnull align 8 dereferenceable(16) %3) #6
  %49 = load ptr, ptr %16, align 8, !tbaa !5
  %50 = invoke noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56) %15, ptr noundef nonnull align 8 dereferenceable(56) %49)
          to label %51 unwind label %65

51:                                               ; preds = %45
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  br label %84

52:                                               ; preds = %5
  %53 = landingpad { ptr, i32 }
          cleanup
  %54 = extractvalue { ptr, i32 } %53, 0
  store ptr %54, ptr %13, align 8
  %55 = extractvalue { ptr, i32 } %53, 1
  store i32 %55, ptr %14, align 4
  br label %60

56:                                               ; preds = %25
  %57 = landingpad { ptr, i32 }
          cleanup
  %58 = extractvalue { ptr, i32 } %57, 0
  store ptr %58, ptr %13, align 8
  %59 = extractvalue { ptr, i32 } %57, 1
  store i32 %59, ptr %14, align 4
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %12) #6
  br label %60

60:                                               ; preds = %56, %52
  call void @llvm.lifetime.end.p0(i64 56, ptr %12) #6
  br label %229

61:                                               ; preds = %26
  %62 = landingpad { ptr, i32 }
          cleanup
  %63 = extractvalue { ptr, i32 } %62, 0
  store ptr %63, ptr %13, align 8
  %64 = extractvalue { ptr, i32 } %62, 1
  store i32 %64, ptr %14, align 4
  br label %228

65:                                               ; preds = %185, %141, %114, %109, %95, %85, %73, %45, %38, %31
  %66 = landingpad { ptr, i32 }
          cleanup
  %67 = extractvalue { ptr, i32 } %66, 0
  store ptr %67, ptr %13, align 8
  %68 = extractvalue { ptr, i32 } %66, 1
  store i32 %68, ptr %14, align 4
  br label %225

69:                                               ; preds = %44
  call void @llvm.lifetime.start.p0(i64 16, ptr %17) #6
  %70 = load ptr, ptr %16, align 8, !tbaa !5
  %71 = getelementptr inbounds %class.SubstituteStackFrame, ptr %70, i32 0, i32 3
  %72 = load ptr, ptr %71, align 8, !tbaa !9
  invoke void @_ZNSt23enable_shared_from_thisI7HtnTermE16shared_from_thisEv(ptr dead_on_unwind writable sret(%"class.std::shared_ptr.6") align 8 %17, ptr noundef nonnull align 8 dereferenceable(16) %72)
          to label %73 unwind label %80

73:                                               ; preds = %69
  %74 = load ptr, ptr %16, align 8, !tbaa !5
  %75 = getelementptr inbounds %class.SubstituteStackFrame, ptr %74, i32 0, i32 2
  %76 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt10shared_ptrI7HtnTermEaSEOS1_(ptr noundef nonnull align 8 dereferenceable(16) %75, ptr noundef nonnull align 8 dereferenceable(16) %17) #6
  call void @_ZNSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %17) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %17) #6
  %77 = load ptr, ptr %16, align 8, !tbaa !5
  %78 = invoke noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56) %15, ptr noundef nonnull align 8 dereferenceable(56) %77)
          to label %79 unwind label %65

79:                                               ; preds = %73
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  br label %84

80:                                               ; preds = %69
  %81 = landingpad { ptr, i32 }
          cleanup
  %82 = extractvalue { ptr, i32 } %81, 0
  store ptr %82, ptr %13, align 8
  %83 = extractvalue { ptr, i32 } %81, 1
  store i32 %83, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %17) #6
  br label %225

84:                                               ; preds = %79, %51
  br label %224

85:                                               ; preds = %37
  %86 = load ptr, ptr %16, align 8, !tbaa !5
  %87 = getelementptr inbounds %class.SubstituteStackFrame, ptr %86, i32 0, i32 3
  %88 = load ptr, ptr %87, align 8, !tbaa !9
  %89 = invoke noundef zeroext i1 @_ZNK7HtnTerm10isConstantEv(ptr noundef nonnull align 8 dereferenceable(72) %88)
          to label %90 unwind label %65

90:                                               ; preds = %85
  br i1 %89, label %91, label %106

91:                                               ; preds = %90
  call void @llvm.lifetime.start.p0(i64 16, ptr %18) #6
  %92 = load ptr, ptr %16, align 8, !tbaa !5
  %93 = getelementptr inbounds %class.SubstituteStackFrame, ptr %92, i32 0, i32 3
  %94 = load ptr, ptr %93, align 8, !tbaa !9
  invoke void @_ZNSt23enable_shared_from_thisI7HtnTermE16shared_from_thisEv(ptr dead_on_unwind writable sret(%"class.std::shared_ptr.6") align 8 %18, ptr noundef nonnull align 8 dereferenceable(16) %94)
          to label %95 unwind label %102

95:                                               ; preds = %91
  %96 = load ptr, ptr %16, align 8, !tbaa !5
  %97 = getelementptr inbounds %class.SubstituteStackFrame, ptr %96, i32 0, i32 2
  %98 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt10shared_ptrI7HtnTermEaSEOS1_(ptr noundef nonnull align 8 dereferenceable(16) %97, ptr noundef nonnull align 8 dereferenceable(16) %18) #6
  call void @_ZNSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %18) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #6
  %99 = load ptr, ptr %16, align 8, !tbaa !5
  %100 = invoke noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56) %15, ptr noundef nonnull align 8 dereferenceable(56) %99)
          to label %101 unwind label %65

101:                                              ; preds = %95
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  br label %223

102:                                              ; preds = %91
  %103 = landingpad { ptr, i32 }
          cleanup
  %104 = extractvalue { ptr, i32 } %103, 0
  store ptr %104, ptr %13, align 8
  %105 = extractvalue { ptr, i32 } %103, 1
  store i32 %105, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %18) #6
  br label %225

106:                                              ; preds = %90
  %107 = getelementptr inbounds %class.SubstituteStackFrame, ptr %15, i32 0, i32 2
  %108 = call noundef zeroext i1 @_ZStneI7HtnTermEbRKSt10shared_ptrIT_EDn(ptr noundef nonnull align 8 dereferenceable(16) %107, ptr null) #6
  br i1 %108, label %109, label %185

109:                                              ; preds = %106
  %110 = load ptr, ptr %16, align 8, !tbaa !5
  %111 = getelementptr inbounds %class.SubstituteStackFrame, ptr %110, i32 0, i32 1
  %112 = getelementptr inbounds %class.SubstituteStackFrame, ptr %15, i32 0, i32 2
  invoke void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EE9push_backERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %111, ptr noundef nonnull align 8 dereferenceable(16) %112)
          to label %113 unwind label %65

113:                                              ; preds = %109
  call void @llvm.lifetime.start.p0(i64 56, ptr %19) #6
  invoke void @_ZN20SubstituteStackFrameC2Ev(ptr noundef nonnull align 8 dereferenceable(56) %19)
          to label %114 unwind label %148

114:                                              ; preds = %113
  %115 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSEOS_(ptr noundef nonnull align 8 dereferenceable(56) %15, ptr noundef nonnull align 8 dereferenceable(56) %19) #6
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %19) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr %19) #6
  %116 = load ptr, ptr %16, align 8, !tbaa !5
  %117 = getelementptr inbounds %class.SubstituteStackFrame, ptr %116, i32 0, i32 0
  %118 = load i32, ptr %117, align 8, !tbaa !19
  %119 = add nsw i32 %118, 1
  store i32 %119, ptr %117, align 8, !tbaa !19
  %120 = load ptr, ptr %16, align 8, !tbaa !5
  %121 = getelementptr inbounds %class.SubstituteStackFrame, ptr %120, i32 0, i32 0
  %122 = load i32, ptr %121, align 8, !tbaa !19
  %123 = sext i32 %122 to i64
  %124 = load ptr, ptr %16, align 8, !tbaa !5
  %125 = getelementptr inbounds %class.SubstituteStackFrame, ptr %124, i32 0, i32 3
  %126 = load ptr, ptr %125, align 8, !tbaa !9
  %127 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7HtnTerm9argumentsEv(ptr noundef nonnull align 8 dereferenceable(72) %126)
          to label %128 unwind label %65

128:                                              ; preds = %114
  %129 = call noundef i64 @_ZNKSt6vectorISt10shared_ptrI7HtnTermESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %127) #6
  %130 = icmp eq i64 %123, %129
  br i1 %130, label %131, label %161

131:                                              ; preds = %128
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #6
  %132 = load ptr, ptr %8, align 8, !tbaa !5
  %133 = load ptr, ptr %16, align 8, !tbaa !5
  %134 = getelementptr inbounds %class.SubstituteStackFrame, ptr %133, i32 0, i32 3
  %135 = load ptr, ptr %134, align 8, !tbaa !9
  %136 = getelementptr inbounds %class.HtnTerm, ptr %135, i32 0, i32 1
  %137 = load ptr, ptr %136, align 8, !tbaa !20
  %138 = load ptr, ptr %16, align 8, !tbaa !5
  %139 = getelementptr inbounds %class.SubstituteStackFrame, ptr %138, i32 0, i32 1
  invoke void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EEC2ERKS4_(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %139)
          to label %140 unwind label %152

140:                                              ; preds = %131
  invoke void @_ZN14HtnTermFactory13CreateFunctorERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorISt10shared_ptrI7HtnTermESaISB_EE(ptr dead_on_unwind writable sret(%"class.std::shared_ptr.6") align 8 %20, ptr noundef nonnull align 8 dereferenceable(33088) %132, ptr noundef nonnull align 8 dereferenceable(32) %137, ptr noundef %21)
          to label %141 unwind label %156

141:                                              ; preds = %140
  %142 = load ptr, ptr %16, align 8, !tbaa !5
  %143 = getelementptr inbounds %class.SubstituteStackFrame, ptr %142, i32 0, i32 2
  %144 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt10shared_ptrI7HtnTermEaSEOS1_(ptr noundef nonnull align 8 dereferenceable(16) %143, ptr noundef nonnull align 8 dereferenceable(16) %20) #6
  call void @_ZNSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %20) #6
  call void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #6
  %145 = load ptr, ptr %16, align 8, !tbaa !5
  %146 = invoke noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56) %15, ptr noundef nonnull align 8 dereferenceable(56) %145)
          to label %147 unwind label %65

147:                                              ; preds = %141
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  br label %184

148:                                              ; preds = %113
  %149 = landingpad { ptr, i32 }
          cleanup
  %150 = extractvalue { ptr, i32 } %149, 0
  store ptr %150, ptr %13, align 8
  %151 = extractvalue { ptr, i32 } %149, 1
  store i32 %151, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 56, ptr %19) #6
  br label %225

152:                                              ; preds = %131
  %153 = landingpad { ptr, i32 }
          cleanup
  %154 = extractvalue { ptr, i32 } %153, 0
  store ptr %154, ptr %13, align 8
  %155 = extractvalue { ptr, i32 } %153, 1
  store i32 %155, ptr %14, align 4
  br label %160

156:                                              ; preds = %140
  %157 = landingpad { ptr, i32 }
          cleanup
  %158 = extractvalue { ptr, i32 } %157, 0
  store ptr %158, ptr %13, align 8
  %159 = extractvalue { ptr, i32 } %157, 1
  store i32 %159, ptr %14, align 4
  call void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #6
  br label %160

160:                                              ; preds = %156, %152
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #6
  br label %225

161:                                              ; preds = %128
  call void @llvm.lifetime.start.p0(i64 56, ptr %22) #6
  %162 = load ptr, ptr %16, align 8, !tbaa !5
  %163 = getelementptr inbounds %class.SubstituteStackFrame, ptr %162, i32 0, i32 3
  %164 = load ptr, ptr %163, align 8, !tbaa !9
  %165 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7HtnTerm9argumentsEv(ptr noundef nonnull align 8 dereferenceable(72) %164)
          to label %166 unwind label %175

166:                                              ; preds = %161
  %167 = load ptr, ptr %16, align 8, !tbaa !5
  %168 = getelementptr inbounds %class.SubstituteStackFrame, ptr %167, i32 0, i32 0
  %169 = load i32, ptr %168, align 8, !tbaa !19
  %170 = sext i32 %169 to i64
  %171 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt6vectorISt10shared_ptrI7HtnTermESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %165, i64 noundef %170) #6
  %172 = call noundef ptr @_ZNKSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EE3getEv(ptr noundef nonnull align 8 dereferenceable(16) %171) #6
  invoke void @_ZN20SubstituteStackFrameC2EP7HtnTerm(ptr noundef nonnull align 8 dereferenceable(56) %22, ptr noundef %172)
          to label %173 unwind label %175

173:                                              ; preds = %166
  invoke void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE9push_backEOS0_(ptr noundef nonnull align 8 dereferenceable(24) %11, ptr noundef nonnull align 8 dereferenceable(56) %22)
          to label %174 unwind label %179

174:                                              ; preds = %173
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %22) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr %22) #6
  br label %184

175:                                              ; preds = %166, %161
  %176 = landingpad { ptr, i32 }
          cleanup
  %177 = extractvalue { ptr, i32 } %176, 0
  store ptr %177, ptr %13, align 8
  %178 = extractvalue { ptr, i32 } %176, 1
  store i32 %178, ptr %14, align 4
  br label %183

179:                                              ; preds = %173
  %180 = landingpad { ptr, i32 }
          cleanup
  %181 = extractvalue { ptr, i32 } %180, 0
  store ptr %181, ptr %13, align 8
  %182 = extractvalue { ptr, i32 } %180, 1
  store i32 %182, ptr %14, align 4
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %22) #6
  br label %183

183:                                              ; preds = %179, %175
  call void @llvm.lifetime.end.p0(i64 56, ptr %22) #6
  br label %225

184:                                              ; preds = %174, %147
  br label %222

185:                                              ; preds = %106
  %186 = load ptr, ptr %16, align 8, !tbaa !5
  %187 = getelementptr inbounds %class.SubstituteStackFrame, ptr %186, i32 0, i32 0
  %188 = load i32, ptr %187, align 8, !tbaa !19
  %189 = sext i32 %188 to i64
  %190 = load ptr, ptr %16, align 8, !tbaa !5
  %191 = getelementptr inbounds %class.SubstituteStackFrame, ptr %190, i32 0, i32 3
  %192 = load ptr, ptr %191, align 8, !tbaa !9
  %193 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7HtnTerm9argumentsEv(ptr noundef nonnull align 8 dereferenceable(72) %192)
          to label %194 unwind label %65

194:                                              ; preds = %185
  %195 = call noundef i64 @_ZNKSt6vectorISt10shared_ptrI7HtnTermESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %193) #6
  %196 = icmp ult i64 %189, %195
  br i1 %196, label %197, label %220

197:                                              ; preds = %194
  call void @llvm.lifetime.start.p0(i64 56, ptr %23) #6
  %198 = load ptr, ptr %16, align 8, !tbaa !5
  %199 = getelementptr inbounds %class.SubstituteStackFrame, ptr %198, i32 0, i32 3
  %200 = load ptr, ptr %199, align 8, !tbaa !9
  %201 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7HtnTerm9argumentsEv(ptr noundef nonnull align 8 dereferenceable(72) %200)
          to label %202 unwind label %211

202:                                              ; preds = %197
  %203 = load ptr, ptr %16, align 8, !tbaa !5
  %204 = getelementptr inbounds %class.SubstituteStackFrame, ptr %203, i32 0, i32 0
  %205 = load i32, ptr %204, align 8, !tbaa !19
  %206 = sext i32 %205 to i64
  %207 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt6vectorISt10shared_ptrI7HtnTermESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %201, i64 noundef %206) #6
  %208 = call noundef ptr @_ZNKSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EE3getEv(ptr noundef nonnull align 8 dereferenceable(16) %207) #6
  invoke void @_ZN20SubstituteStackFrameC2EP7HtnTerm(ptr noundef nonnull align 8 dereferenceable(56) %23, ptr noundef %208)
          to label %209 unwind label %211

209:                                              ; preds = %202
  invoke void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE9push_backEOS0_(ptr noundef nonnull align 8 dereferenceable(24) %11, ptr noundef nonnull align 8 dereferenceable(56) %23)
          to label %210 unwind label %215

210:                                              ; preds = %209
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %23) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr %23) #6
  br label %221

211:                                              ; preds = %202, %197
  %212 = landingpad { ptr, i32 }
          cleanup
  %213 = extractvalue { ptr, i32 } %212, 0
  store ptr %213, ptr %13, align 8
  %214 = extractvalue { ptr, i32 } %212, 1
  store i32 %214, ptr %14, align 4
  br label %219

215:                                              ; preds = %209
  %216 = landingpad { ptr, i32 }
          cleanup
  %217 = extractvalue { ptr, i32 } %216, 0
  store ptr %217, ptr %13, align 8
  %218 = extractvalue { ptr, i32 } %216, 1
  store i32 %218, ptr %14, align 4
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %23) #6
  br label %219

219:                                              ; preds = %215, %211
  call void @llvm.lifetime.end.p0(i64 56, ptr %23) #6
  br label %225

220:                                              ; preds = %194
  br label %221

221:                                              ; preds = %220, %210
  br label %222

222:                                              ; preds = %221, %184
  br label %223

223:                                              ; preds = %222, %101
  br label %224

224:                                              ; preds = %223, %84
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  br label %28, !llvm.loop !29

225:                                              ; preds = %219, %183, %160, %148, %102, %80, %65
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %15) #6
  br label %228

226:                                              ; preds = %28
  %227 = getelementptr inbounds %class.SubstituteStackFrame, ptr %15, i32 0, i32 2
  call void @_ZNSt10shared_ptrI7HtnTermEC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(16) %0, ptr noundef nonnull align 8 dereferenceable(16) %227) #6
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %15) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr %15) #6
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %11) #6
  ret void

228:                                              ; preds = %225, %61
  call void @llvm.lifetime.end.p0(i64 56, ptr %15) #6
  br label %229

229:                                              ; preds = %228, %60
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %11) #6
  br label %230

230:                                              ; preds = %229
  %231 = load ptr, ptr %13, align 8
  %232 = load i32, ptr %14, align 4
  %233 = insertvalue { ptr, i32 } poison, ptr %231, 0
  %234 = insertvalue { ptr, i32 } %233, i32 %232, 1
  resume { ptr, i32 } %234
}

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56)) unnamed_addr #4 align 2

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56), ptr noundef nonnull align 8 dereferenceable(56)) #5 align 2

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #1 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 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { "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 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !6, i64 48}
!10 = !{!"_ZTS20SubstituteStackFrame", !11, i64 0, !12, i64 8, !16, i64 32, !6, i64 48}
!11 = !{!"int", !7, i64 0}
!12 = !{!"_ZTSSt6vectorISt10shared_ptrI7HtnTermESaIS2_EE", !13, i64 0}
!13 = !{!"_ZTSSt12_Vector_baseISt10shared_ptrI7HtnTermESaIS2_EE", !14, i64 0}
!14 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrI7HtnTermESaIS2_EE12_Vector_implE", !15, i64 0}
!15 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrI7HtnTermESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!16 = !{!"_ZTSSt10shared_ptrI7HtnTermE", !17, i64 0}
!17 = !{!"_ZTSSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EE", !6, i64 0, !18, i64 8}
!18 = !{!"_ZTSSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EE", !6, i64 0}
!19 = !{!10, !11, i64 0}
!20 = !{!21, !6, i64 16}
!21 = !{!"_ZTS7HtnTerm", !22, i64 0, !6, i64 16, !12, i64 24, !26, i64 48, !26, i64 49, !27, i64 56}
!22 = !{!"_ZTSSt23enable_shared_from_thisI7HtnTermE", !23, i64 0}
!23 = !{!"_ZTSSt8weak_ptrI7HtnTermE", !24, i64 0}
!24 = !{!"_ZTSSt10__weak_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EE", !6, i64 0, !25, i64 8}
!25 = !{!"_ZTSSt12__weak_countILN9__gnu_cxx12_Lock_policyE2EE", !6, i64 0}
!26 = !{!"bool", !7, i64 0}
!27 = !{!"_ZTSSt8weak_ptrI14HtnTermFactoryE", !28, i64 0}
!28 = !{!"_ZTSSt10__weak_ptrI14HtnTermFactoryLN9__gnu_cxx12_Lock_policyE2EE", !6, i64 0, !25, i64 8}
!29 = distinct !{!29, !30}
!30 = !{!"llvm.loop.mustprogress"}


; 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::shared_ptr.6" = type { %"class.std::__shared_ptr.7" }
%"class.std::__shared_ptr.7" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }
%"class.std::vector.73" = type { %"struct.std::_Vector_base.74" }
%"struct.std::_Vector_base.74" = type { %"struct.std::_Vector_base<SubstituteStackFrame, std::allocator<SubstituteStackFrame>>::_Vector_impl" }
%"struct.std::_Vector_base<SubstituteStackFrame, std::allocator<SubstituteStackFrame>>::_Vector_impl" = type { %"struct.std::_Vector_base<SubstituteStackFrame, std::allocator<SubstituteStackFrame>>::_Vector_impl_data" }
%"struct.std::_Vector_base<SubstituteStackFrame, std::allocator<SubstituteStackFrame>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.SubstituteStackFrame = type { i32, %"class.std::vector", %"class.std::shared_ptr.6", ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::shared_ptr<HtnTerm>, std::allocator<std::shared_ptr<HtnTerm>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::shared_ptr<HtnTerm>, std::allocator<std::shared_ptr<HtnTerm>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::shared_ptr<HtnTerm>, std::allocator<std::shared_ptr<HtnTerm>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::shared_ptr<HtnTerm>, std::allocator<std::shared_ptr<HtnTerm>>>::_Vector_impl_data" = type { ptr, ptr, 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 void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #1 align 2

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt23enable_shared_from_thisI7HtnTermE16shared_from_thisEv(ptr dead_on_unwind noalias writable sret(%"class.std::shared_ptr.6") align 8, ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #2 align 2

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

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

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

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

declare void @_ZN14HtnTermFactory13CreateFunctorERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorISt10shared_ptrI7HtnTermESaISB_EE(ptr dead_on_unwind writable sret(%"class.std::shared_ptr.6") align 8, ptr noundef nonnull align 8 dereferenceable(33088), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef) local_unnamed_addr #3

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZStneI7HtnTermEbRKSt10shared_ptrIT_EDn(ptr noundef nonnull align 8 dereferenceable(16), ptr) local_unnamed_addr #4

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7HtnTerm25SubstituteTermForVariableEP14HtnTermFactorySt10shared_ptrIS_ES3_(ptr dead_on_unwind noalias writable sret(%"class.std::shared_ptr.6") align 8 %0, ptr noundef nonnull align 8 dereferenceable(72) %1, ptr noundef %2, ptr noundef %3, ptr noundef %4) local_unnamed_addr #2 align 2 personality ptr @__gxx_personality_v0 {
  %6 = alloca %"class.std::vector.73", align 8
  %7 = alloca %class.SubstituteStackFrame, align 8
  %8 = alloca %class.SubstituteStackFrame, align 8
  %9 = alloca %"class.std::shared_ptr.6", align 8
  %10 = alloca %"class.std::shared_ptr.6", align 8
  %11 = alloca %class.SubstituteStackFrame, align 8
  %12 = alloca %"class.std::shared_ptr.6", align 8
  %13 = alloca %"class.std::vector", align 8
  %14 = alloca %class.SubstituteStackFrame, align 8
  %15 = alloca %class.SubstituteStackFrame, align 8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #6
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  call void @llvm.lifetime.start.p0(i64 56, ptr nonnull %7) #6
  call void @_ZN20SubstituteStackFrameC2EP7HtnTerm(ptr noundef nonnull align 8 dereferenceable(56) %7, ptr noundef nonnull %1)
  invoke void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE9push_backEOS0_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(56) %7)
          to label %16 unwind label %33

16:                                               ; preds = %5
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %7) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %7) #6
  call void @llvm.lifetime.start.p0(i64 56, ptr nonnull %8) #6
  call void @_ZN20SubstituteStackFrameC2Ev(ptr noundef nonnull align 8 dereferenceable(56) %8)
  %17 = call noundef i64 @_ZNKSt6vectorI20SubstituteStackFrameSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %.not35 = icmp eq i64 %17, 0
  br i1 %.not35, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %16
  %18 = getelementptr inbounds i8, ptr %8, i64 32
  br label %19

19:                                               ; preds = %.lr.ph, %112
  %20 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %21 = getelementptr inbounds i8, ptr %20, i64 48
  %22 = load ptr, ptr %21, align 8, !tbaa !5
  %23 = call noundef zeroext i1 @_ZNK7HtnTerm10isVariableEv(ptr noundef nonnull align 8 dereferenceable(72) %22)
  %24 = load ptr, ptr %21, align 8, !tbaa !5
  br i1 %23, label %25, label %46

25:                                               ; preds = %19
  %26 = call noundef nonnull align 8 dereferenceable(72) ptr @_ZNKSt19__shared_ptr_accessI7HtnTermLN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEdeEv(ptr noundef nonnull align 1 dereferenceable(1) %4) #6
  %27 = call noundef zeroext i1 @_ZNK7HtnTerm11nameEqualToERKS_(ptr noundef nonnull align 8 dereferenceable(72) %24, ptr noundef nonnull align 8 dereferenceable(72) %26)
  br i1 %27, label %28, label %37

28:                                               ; preds = %25
  %29 = getelementptr inbounds i8, ptr %20, i64 32
  %30 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt10shared_ptrI7HtnTermEaSERKS1_(ptr noundef nonnull align 8 dereferenceable(16) %29, ptr noundef nonnull align 8 dereferenceable(16) %3) #6
  %31 = invoke noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56) %8, ptr noundef nonnull align 8 dereferenceable(56) %20)
          to label %32 unwind label %35

32:                                               ; preds = %28
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  br label %112

33:                                               ; preds = %5
  %34 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %7) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %7) #6
  br label %116

35:                                               ; preds = %75, %59, %50, %39, %28
  %36 = landingpad { ptr, i32 }
          cleanup
  br label %114

37:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #6
  %38 = load ptr, ptr %21, align 8, !tbaa !5
  invoke void @_ZNSt23enable_shared_from_thisI7HtnTermE16shared_from_thisEv(ptr dead_on_unwind nonnull writable sret(%"class.std::shared_ptr.6") align 8 %9, ptr noundef nonnull align 8 dereferenceable(16) %38)
          to label %39 unwind label %44

39:                                               ; preds = %37
  %40 = getelementptr inbounds i8, ptr %20, i64 32
  %41 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt10shared_ptrI7HtnTermEaSEOS1_(ptr noundef nonnull align 8 dereferenceable(16) %40, ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  call void @_ZNSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #6
  %42 = invoke noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56) %8, ptr noundef nonnull align 8 dereferenceable(56) %20)
          to label %43 unwind label %35

43:                                               ; preds = %39
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  br label %112

44:                                               ; preds = %37
  %45 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #6
  br label %114

46:                                               ; preds = %19
  %47 = call noundef zeroext i1 @_ZNK7HtnTerm10isConstantEv(ptr noundef nonnull align 8 dereferenceable(72) %24)
  br i1 %47, label %48, label %57

48:                                               ; preds = %46
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %10) #6
  %49 = load ptr, ptr %21, align 8, !tbaa !5
  invoke void @_ZNSt23enable_shared_from_thisI7HtnTermE16shared_from_thisEv(ptr dead_on_unwind nonnull writable sret(%"class.std::shared_ptr.6") align 8 %10, ptr noundef nonnull align 8 dereferenceable(16) %49)
          to label %50 unwind label %55

50:                                               ; preds = %48
  %51 = getelementptr inbounds i8, ptr %20, i64 32
  %52 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt10shared_ptrI7HtnTermEaSEOS1_(ptr noundef nonnull align 8 dereferenceable(16) %51, ptr noundef nonnull align 8 dereferenceable(16) %10) #6
  call void @_ZNSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %10) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #6
  %53 = invoke noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56) %8, ptr noundef nonnull align 8 dereferenceable(56) %20)
          to label %54 unwind label %35

54:                                               ; preds = %50
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  br label %112

55:                                               ; preds = %48
  %56 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #6
  br label %114

57:                                               ; preds = %46
  %58 = call noundef zeroext i1 @_ZStneI7HtnTermEbRKSt10shared_ptrIT_EDn(ptr noundef nonnull align 8 dereferenceable(16) %18, ptr null) #6
  br i1 %58, label %59, label %95

59:                                               ; preds = %57
  %60 = getelementptr inbounds i8, ptr %20, i64 8
  invoke void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EE9push_backERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %60, ptr noundef nonnull align 8 dereferenceable(16) %18)
          to label %61 unwind label %35

61:                                               ; preds = %59
  call void @llvm.lifetime.start.p0(i64 56, ptr nonnull %11) #6
  call void @_ZN20SubstituteStackFrameC2Ev(ptr noundef nonnull align 8 dereferenceable(56) %11)
  %62 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSEOS_(ptr noundef nonnull align 8 dereferenceable(56) %8, ptr noundef nonnull align 8 dereferenceable(56) %11) #6
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %11) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %11) #6
  %63 = load i32, ptr %20, align 8, !tbaa !18
  %64 = add nsw i32 %63, 1
  store i32 %64, ptr %20, align 8, !tbaa !18
  %65 = sext i32 %64 to i64
  %66 = load ptr, ptr %21, align 8, !tbaa !5
  %67 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7HtnTerm9argumentsEv(ptr noundef nonnull align 8 dereferenceable(72) %66)
  %68 = call noundef i64 @_ZNKSt6vectorISt10shared_ptrI7HtnTermESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %67) #6
  %69 = icmp eq i64 %68, %65
  br i1 %69, label %70, label %85

70:                                               ; preds = %61
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %12) #6
  %71 = load ptr, ptr %21, align 8, !tbaa !5
  %72 = getelementptr inbounds i8, ptr %71, i64 16
  %73 = load ptr, ptr %72, align 8, !tbaa !19
  invoke void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EEC2ERKS4_(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef nonnull align 8 dereferenceable(24) %60)
          to label %74 unwind label %80

74:                                               ; preds = %70
  invoke void @_ZN14HtnTermFactory13CreateFunctorERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorISt10shared_ptrI7HtnTermESaISB_EE(ptr dead_on_unwind nonnull writable sret(%"class.std::shared_ptr.6") align 8 %12, ptr noundef nonnull align 8 dereferenceable(33088) %2, ptr noundef nonnull align 8 dereferenceable(32) %73, ptr noundef nonnull %13)
          to label %75 unwind label %82

75:                                               ; preds = %74
  %76 = getelementptr inbounds i8, ptr %20, i64 32
  %77 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt10shared_ptrI7HtnTermEaSEOS1_(ptr noundef nonnull align 8 dereferenceable(16) %76, ptr noundef nonnull align 8 dereferenceable(16) %12) #6
  call void @_ZNSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #6
  call void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %12) #6
  %78 = invoke noundef nonnull align 8 dereferenceable(56) ptr @_ZN20SubstituteStackFrameaSERKS_(ptr noundef nonnull align 8 dereferenceable(56) %8, ptr noundef nonnull align 8 dereferenceable(56) %20)
          to label %79 unwind label %35

79:                                               ; preds = %75
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE8pop_backEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  br label %112

80:                                               ; preds = %70
  %81 = landingpad { ptr, i32 }
          cleanup
  br label %84

82:                                               ; preds = %74
  %83 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt6vectorISt10shared_ptrI7HtnTermESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #6
  br label %84

84:                                               ; preds = %82, %80
  %.pn = phi { ptr, i32 } [ %83, %82 ], [ %81, %80 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %12) #6
  br label %114

85:                                               ; preds = %61
  call void @llvm.lifetime.start.p0(i64 56, ptr nonnull %14) #6
  %86 = load ptr, ptr %21, align 8, !tbaa !5
  %87 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7HtnTerm9argumentsEv(ptr noundef nonnull align 8 dereferenceable(72) %86)
  %88 = load i32, ptr %20, align 8, !tbaa !18
  %89 = sext i32 %88 to i64
  %90 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt6vectorISt10shared_ptrI7HtnTermESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %87, i64 noundef %89) #6
  %91 = call noundef ptr @_ZNKSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EE3getEv(ptr noundef nonnull align 8 dereferenceable(16) %90) #6
  call void @_ZN20SubstituteStackFrameC2EP7HtnTerm(ptr noundef nonnull align 8 dereferenceable(56) %14, ptr noundef %91)
  invoke void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE9push_backEOS0_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(56) %14)
          to label %92 unwind label %93

92:                                               ; preds = %85
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %14) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %14) #6
  br label %112

93:                                               ; preds = %85
  %94 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %14) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %14) #6
  br label %114

95:                                               ; preds = %57
  %96 = load i32, ptr %20, align 8, !tbaa !18
  %97 = sext i32 %96 to i64
  %98 = load ptr, ptr %21, align 8, !tbaa !5
  %99 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7HtnTerm9argumentsEv(ptr noundef nonnull align 8 dereferenceable(72) %98)
  %100 = call noundef i64 @_ZNKSt6vectorISt10shared_ptrI7HtnTermESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %99) #6
  %101 = icmp ugt i64 %100, %97
  br i1 %101, label %102, label %112

102:                                              ; preds = %95
  call void @llvm.lifetime.start.p0(i64 56, ptr nonnull %15) #6
  %103 = load ptr, ptr %21, align 8, !tbaa !5
  %104 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7HtnTerm9argumentsEv(ptr noundef nonnull align 8 dereferenceable(72) %103)
  %105 = load i32, ptr %20, align 8, !tbaa !18
  %106 = sext i32 %105 to i64
  %107 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt6vectorISt10shared_ptrI7HtnTermESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %104, i64 noundef %106) #6
  %108 = call noundef ptr @_ZNKSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EE3getEv(ptr noundef nonnull align 8 dereferenceable(16) %107) #6
  call void @_ZN20SubstituteStackFrameC2EP7HtnTerm(ptr noundef nonnull align 8 dereferenceable(56) %15, ptr noundef %108)
  invoke void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EE9push_backEOS0_(ptr noundef nonnull align 8 dereferenceable(24) %6, ptr noundef nonnull align 8 dereferenceable(56) %15)
          to label %109 unwind label %110

109:                                              ; preds = %102
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %15) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %15) #6
  br label %112

110:                                              ; preds = %102
  %111 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %15) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %15) #6
  br label %114

112:                                              ; preds = %54, %109, %95, %79, %92, %32, %43
  %113 = call noundef i64 @_ZNKSt6vectorI20SubstituteStackFrameSaIS0_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  %.not = icmp eq i64 %113, 0
  br i1 %.not, label %._crit_edge, label %19, !llvm.loop !28

114:                                              ; preds = %110, %93, %84, %55, %44, %35
  %.pn32 = phi { ptr, i32 } [ %36, %35 ], [ %45, %44 ], [ %56, %55 ], [ %.pn, %84 ], [ %94, %93 ], [ %111, %110 ]
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %8) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %8) #6
  br label %116

._crit_edge:                                      ; preds = %112, %16
  %115 = getelementptr inbounds i8, ptr %8, i64 32
  call void @_ZNSt10shared_ptrI7HtnTermEC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(16) %0, ptr noundef nonnull align 8 dereferenceable(16) %115) #6
  call void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56) %8) #6
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %8) #6
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #6
  ret void

116:                                              ; preds = %114, %33
  %.pn32.pn = phi { ptr, i32 } [ %.pn32, %114 ], [ %34, %33 ]
  call void @_ZNSt6vectorI20SubstituteStackFrameSaIS0_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %6) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #6
  resume { ptr, i32 } %.pn32.pn
}

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN20SubstituteStackFrameD2Ev(ptr noundef nonnull align 8 dereferenceable(56)) unnamed_addr #4 align 2

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

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

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

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

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

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #1 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 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { "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 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !14, i64 48}
!6 = !{!"_ZTS20SubstituteStackFrame", !7, i64 0, !10, i64 8, !15, i64 32, !14, i64 48}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTSSt6vectorISt10shared_ptrI7HtnTermESaIS2_EE", !11, i64 0}
!11 = !{!"_ZTSSt12_Vector_baseISt10shared_ptrI7HtnTermESaIS2_EE", !12, i64 0}
!12 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrI7HtnTermESaIS2_EE12_Vector_implE", !13, i64 0}
!13 = !{!"_ZTSNSt12_Vector_baseISt10shared_ptrI7HtnTermESaIS2_EE17_Vector_impl_dataE", !14, i64 0, !14, i64 8, !14, i64 16}
!14 = !{!"any pointer", !8, i64 0}
!15 = !{!"_ZTSSt10shared_ptrI7HtnTermE", !16, i64 0}
!16 = !{!"_ZTSSt12__shared_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EE", !14, i64 0, !17, i64 8}
!17 = !{!"_ZTSSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EE", !14, i64 0}
!18 = !{!6, !7, i64 0}
!19 = !{!20, !14, i64 16}
!20 = !{!"_ZTS7HtnTerm", !21, i64 0, !14, i64 16, !10, i64 24, !25, i64 48, !25, i64 49, !26, i64 56}
!21 = !{!"_ZTSSt23enable_shared_from_thisI7HtnTermE", !22, i64 0}
!22 = !{!"_ZTSSt8weak_ptrI7HtnTermE", !23, i64 0}
!23 = !{!"_ZTSSt10__weak_ptrI7HtnTermLN9__gnu_cxx12_Lock_policyE2EE", !14, i64 0, !24, i64 8}
!24 = !{!"_ZTSSt12__weak_countILN9__gnu_cxx12_Lock_policyE2EE", !14, i64 0}
!25 = !{!"bool", !8, i64 0}
!26 = !{!"_ZTSSt8weak_ptrI14HtnTermFactoryE", !27, i64 0}
!27 = !{!"_ZTSSt10__weak_ptrI14HtnTermFactoryLN9__gnu_cxx12_Lock_policyE2EE", !14, i64 0, !24, i64 8}
!28 = distinct !{!28, !29}
!29 = !{!"llvm.loop.mustprogress"}


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