; LLVM IR from ddemidov/amgcl :: lib (amgcl)

; 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::tuple" = type { %"struct.std::_Tuple_impl.base", [4 x i8] }
%"struct.std::_Tuple_impl.base" = type <{ %"struct.std::_Tuple_impl.1", %"struct.std::_Head_base.12" }>
%"struct.std::_Tuple_impl.1" = type { %"struct.std::_Tuple_impl.2", %"struct.std::_Head_base.11" }
%"struct.std::_Tuple_impl.2" = type { %"struct.std::_Tuple_impl.3", %"struct.std::_Head_base.6" }
%"struct.std::_Tuple_impl.3" = type { %"struct.std::_Head_base" }
%"struct.std::_Head_base" = type { %"class.boost::iterator_range" }
%"class.boost::iterator_range" = type { %"class.boost::iterator_range_detail::iterator_range_base" }
%"class.boost::iterator_range_detail::iterator_range_base" = type { %"class.boost::iterator_range_detail::iterator_range_base.4" }
%"class.boost::iterator_range_detail::iterator_range_base.4" = type { %"class.boost::iterator_range_detail::iterator_range_base.5" }
%"class.boost::iterator_range_detail::iterator_range_base.5" = type { ptr, ptr }
%"struct.std::_Head_base.6" = type { %"class.boost::iterator_range.7" }
%"class.boost::iterator_range.7" = type { %"class.boost::iterator_range_detail::iterator_range_base.8" }
%"class.boost::iterator_range_detail::iterator_range_base.8" = type { %"class.boost::iterator_range_detail::iterator_range_base.9" }
%"class.boost::iterator_range_detail::iterator_range_base.9" = type { %"class.boost::iterator_range_detail::iterator_range_base.10" }
%"class.boost::iterator_range_detail::iterator_range_base.10" = type { ptr, ptr }
%"struct.std::_Head_base.11" = type { %"class.boost::iterator_range.7" }
%"struct.std::_Head_base.12" = type { i32 }
%"struct.amgcl::amg<amgcl::backend::builtin<double>, amgcl::runtime::coarsening::wrapper, amgcl::runtime::relaxation::wrapper>::params" = type <{ %"class.boost::property_tree::basic_ptree", %"class.boost::property_tree::basic_ptree", i32, i8, [3 x i8], i32, i32, i32, i32, i32, i8, [3 x i8] }>
%"class.boost::property_tree::basic_ptree" = type { %"class.std::__cxx11::basic_string", ptr }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon.0 }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon.0 = type { i64, [8 x i8] }
%"struct.amgcl::detail::empty_params" = type { i8 }

declare i32 @__gxx_personality_v0(...)

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) #0

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) #1

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

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

; Function Attrs: mustprogress uwtable
define dso_local ptr @amgcl_precond_create(i32 noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4) #3 personality ptr @__gxx_personality_v0 {
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca %"class.std::tuple", align 8
  %13 = alloca %"class.boost::iterator_range.7", align 8
  %14 = alloca %"class.boost::iterator_range.7", align 8
  %15 = alloca %"class.boost::iterator_range", align 8
  %16 = alloca %"struct.amgcl::amg<amgcl::backend::builtin<double>, amgcl::runtime::coarsening::wrapper, amgcl::runtime::relaxation::wrapper>::params", align 8
  %17 = alloca ptr, align 8
  %18 = alloca i32, align 4
  %19 = alloca %"struct.amgcl::detail::empty_params", align 1
  %20 = alloca i1, align 1
  %21 = alloca i32, align 4
  %22 = alloca %"struct.amgcl::amg<amgcl::backend::builtin<double>, amgcl::runtime::coarsening::wrapper, amgcl::runtime::relaxation::wrapper>::params", align 8
  %23 = alloca %"struct.amgcl::detail::empty_params", align 1
  %24 = alloca i1, align 1
  store i32 %0, ptr %7, align 4, !tbaa !5
  store ptr %1, ptr %8, align 8, !tbaa !9
  store ptr %2, ptr %9, align 8, !tbaa !9
  store ptr %3, ptr %10, align 8, !tbaa !9
  store ptr %4, ptr %11, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 56, ptr %12) #7
  call void @llvm.lifetime.start.p0(i64 16, ptr %13) #7
  %25 = load ptr, ptr %8, align 8, !tbaa !9
  %26 = load ptr, ptr %8, align 8, !tbaa !9
  %27 = load i32, ptr %7, align 4, !tbaa !5
  %28 = sext i32 %27 to i64
  %29 = getelementptr inbounds i32, ptr %26, i64 %28
  %30 = getelementptr inbounds i32, ptr %29, i64 1
  %31 = call { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKiEENS_14iterator_rangeIT_EES4_S4_(ptr noundef %25, ptr noundef %30)
  %32 = getelementptr inbounds %"class.boost::iterator_range.7", ptr %13, i32 0, i32 0
  %33 = getelementptr inbounds %"class.boost::iterator_range_detail::iterator_range_base.8", ptr %32, i32 0, i32 0
  %34 = getelementptr inbounds %"class.boost::iterator_range_detail::iterator_range_base.9", ptr %33, i32 0, i32 0
  %35 = getelementptr inbounds { ptr, ptr }, ptr %34, i32 0, i32 0
  %36 = extractvalue { ptr, ptr } %31, 0
  store ptr %36, ptr %35, align 8
  %37 = getelementptr inbounds { ptr, ptr }, ptr %34, i32 0, i32 1
  %38 = extractvalue { ptr, ptr } %31, 1
  store ptr %38, ptr %37, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr %14) #7
  %39 = load ptr, ptr %9, align 8, !tbaa !9
  %40 = load ptr, ptr %9, align 8, !tbaa !9
  %41 = load ptr, ptr %8, align 8, !tbaa !9
  %42 = load i32, ptr %7, align 4, !tbaa !5
  %43 = sext i32 %42 to i64
  %44 = getelementptr inbounds i32, ptr %41, i64 %43
  %45 = load i32, ptr %44, align 4, !tbaa !5
  %46 = sext i32 %45 to i64
  %47 = getelementptr inbounds i32, ptr %40, i64 %46
  %48 = call { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKiEENS_14iterator_rangeIT_EES4_S4_(ptr noundef %39, ptr noundef %47)
  %49 = getelementptr inbounds %"class.boost::iterator_range.7", ptr %14, i32 0, i32 0
  %50 = getelementptr inbounds %"class.boost::iterator_range_detail::iterator_range_base.8", ptr %49, i32 0, i32 0
  %51 = getelementptr inbounds %"class.boost::iterator_range_detail::iterator_range_base.9", ptr %50, i32 0, i32 0
  %52 = getelementptr inbounds { ptr, ptr }, ptr %51, i32 0, i32 0
  %53 = extractvalue { ptr, ptr } %48, 0
  store ptr %53, ptr %52, align 8
  %54 = getelementptr inbounds { ptr, ptr }, ptr %51, i32 0, i32 1
  %55 = extractvalue { ptr, ptr } %48, 1
  store ptr %55, ptr %54, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr %15) #7
  %56 = load ptr, ptr %10, align 8, !tbaa !9
  %57 = load ptr, ptr %10, align 8, !tbaa !9
  %58 = load ptr, ptr %8, align 8, !tbaa !9
  %59 = load i32, ptr %7, align 4, !tbaa !5
  %60 = sext i32 %59 to i64
  %61 = getelementptr inbounds i32, ptr %58, i64 %60
  %62 = load i32, ptr %61, align 4, !tbaa !5
  %63 = sext i32 %62 to i64
  %64 = getelementptr inbounds double, ptr %57, i64 %63
  %65 = call { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKdEENS_14iterator_rangeIT_EES4_S4_(ptr noundef %56, ptr noundef %64)
  %66 = getelementptr inbounds %"class.boost::iterator_range", ptr %15, i32 0, i32 0
  %67 = getelementptr inbounds %"class.boost::iterator_range_detail::iterator_range_base", ptr %66, i32 0, i32 0
  %68 = getelementptr inbounds %"class.boost::iterator_range_detail::iterator_range_base.4", ptr %67, i32 0, i32 0
  %69 = getelementptr inbounds { ptr, ptr }, ptr %68, i32 0, i32 0
  %70 = extractvalue { ptr, ptr } %65, 0
  store ptr %70, ptr %69, align 8
  %71 = getelementptr inbounds { ptr, ptr }, ptr %68, i32 0, i32 1
  %72 = extractvalue { ptr, ptr } %65, 1
  store ptr %72, ptr %71, align 8
  call void @_ZSt10make_tupleIJRiN5boost14iterator_rangeIPKiEES5_NS2_IPKdEEEESt5tupleIJDpNSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeEEEDpOSC_(ptr dead_on_unwind writable sret(%"class.std::tuple") align 8 %12, ptr noundef nonnull align 4 dereferenceable(4) %7, ptr noundef nonnull align 8 dereferenceable(16) %13, ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull align 8 dereferenceable(16) %15)
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr %13) #7
  %73 = load ptr, ptr %11, align 8, !tbaa !9
  %74 = icmp ne ptr %73, null
  br i1 %74, label %75, label %93

75:                                               ; preds = %5
  %76 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 136) #8
  store i1 true, ptr %20, align 1
  call void @llvm.lifetime.start.p0(i64 112, ptr %16) #7
  %77 = load ptr, ptr %11, align 8, !tbaa !9
  invoke void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsC2ERKN5boost13property_tree11basic_ptreeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESJ_St4lessISJ_EEE(ptr noundef nonnull align 8 dereferenceable(109) %16, ptr noundef nonnull align 8 dereferenceable(40) %77)
          to label %78 unwind label %81

78:                                               ; preds = %75
  call void @llvm.lifetime.start.p0(i64 1, ptr %19) #7
  invoke void @_ZN5amgcl6detail12empty_paramsC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %19)
          to label %79 unwind label %85

79:                                               ; preds = %78
  invoke void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEEC2ISt5tupleIJiN5boost14iterator_rangeIPKiEESG_NSD_IPKdEEEEEERKT_RKNS9_6paramsERKNS_6detail12empty_paramsE(ptr noundef nonnull align 8 dereferenceable(136) %76, ptr noundef nonnull align 8 dereferenceable(52) %12, ptr noundef nonnull align 8 dereferenceable(109) %16, ptr noundef nonnull align 1 dereferenceable(1) %19)
          to label %80 unwind label %85

80:                                               ; preds = %79
  store i1 false, ptr %20, align 1
  store ptr %76, ptr %6, align 8
  call void @llvm.lifetime.end.p0(i64 1, ptr %19) #7
  call void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109) %16) #7
  call void @llvm.lifetime.end.p0(i64 112, ptr %16) #7
  store i32 1, ptr %21, align 4
  br label %110

81:                                               ; preds = %75
  %82 = landingpad { ptr, i32 }
          cleanup
  %83 = extractvalue { ptr, i32 } %82, 0
  store ptr %83, ptr %17, align 8
  %84 = extractvalue { ptr, i32 } %82, 1
  store i32 %84, ptr %18, align 4
  br label %89

85:                                               ; preds = %79, %78
  %86 = landingpad { ptr, i32 }
          cleanup
  %87 = extractvalue { ptr, i32 } %86, 0
  store ptr %87, ptr %17, align 8
  %88 = extractvalue { ptr, i32 } %86, 1
  store i32 %88, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %19) #7
  call void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109) %16) #7
  br label %89

89:                                               ; preds = %85, %81
  call void @llvm.lifetime.end.p0(i64 112, ptr %16) #7
  %90 = load i1, ptr %20, align 1
  br i1 %90, label %91, label %92

91:                                               ; preds = %89
  call void @_ZdlPvm(ptr noundef %76, i64 noundef 136) #9
  br label %92

92:                                               ; preds = %91, %89
  br label %112

93:                                               ; preds = %5
  %94 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 136) #8
  store i1 true, ptr %24, align 1
  call void @llvm.lifetime.start.p0(i64 112, ptr %22) #7
  invoke void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsC2Ev(ptr noundef nonnull align 8 dereferenceable(109) %22)
          to label %95 unwind label %98

95:                                               ; preds = %93
  call void @llvm.lifetime.start.p0(i64 1, ptr %23) #7
  invoke void @_ZN5amgcl6detail12empty_paramsC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %23)
          to label %96 unwind label %102

96:                                               ; preds = %95
  invoke void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEEC2ISt5tupleIJiN5boost14iterator_rangeIPKiEESG_NSD_IPKdEEEEEERKT_RKNS9_6paramsERKNS_6detail12empty_paramsE(ptr noundef nonnull align 8 dereferenceable(136) %94, ptr noundef nonnull align 8 dereferenceable(52) %12, ptr noundef nonnull align 8 dereferenceable(109) %22, ptr noundef nonnull align 1 dereferenceable(1) %23)
          to label %97 unwind label %102

97:                                               ; preds = %96
  store i1 false, ptr %24, align 1
  store ptr %94, ptr %6, align 8
  call void @llvm.lifetime.end.p0(i64 1, ptr %23) #7
  call void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109) %22) #7
  call void @llvm.lifetime.end.p0(i64 112, ptr %22) #7
  store i32 1, ptr %21, align 4
  br label %110

98:                                               ; preds = %93
  %99 = landingpad { ptr, i32 }
          cleanup
  %100 = extractvalue { ptr, i32 } %99, 0
  store ptr %100, ptr %17, align 8
  %101 = extractvalue { ptr, i32 } %99, 1
  store i32 %101, ptr %18, align 4
  br label %106

102:                                              ; preds = %96, %95
  %103 = landingpad { ptr, i32 }
          cleanup
  %104 = extractvalue { ptr, i32 } %103, 0
  store ptr %104, ptr %17, align 8
  %105 = extractvalue { ptr, i32 } %103, 1
  store i32 %105, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %23) #7
  call void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109) %22) #7
  br label %106

106:                                              ; preds = %102, %98
  call void @llvm.lifetime.end.p0(i64 112, ptr %22) #7
  %107 = load i1, ptr %24, align 1
  br i1 %107, label %108, label %109

108:                                              ; preds = %106
  call void @_ZdlPvm(ptr noundef %94, i64 noundef 136) #9
  br label %109

109:                                              ; preds = %108, %106
  br label %112

110:                                              ; preds = %97, %80
  call void @llvm.lifetime.end.p0(i64 56, ptr %12) #7
  %111 = load ptr, ptr %6, align 8
  ret ptr %111

112:                                              ; preds = %109, %92
  call void @llvm.lifetime.end.p0(i64 56, ptr %12) #7
  br label %113

113:                                              ; preds = %112
  %114 = load ptr, ptr %17, align 8
  %115 = load i32, ptr %18, align 4
  %116 = insertvalue { ptr, i32 } poison, ptr %114, 0
  %117 = insertvalue { ptr, i32 } %116, i32 %115, 1
  resume { ptr, i32 } %117
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZSt10make_tupleIJRiN5boost14iterator_rangeIPKiEES5_NS2_IPKdEEEESt5tupleIJDpNSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeEEEDpOSC_(ptr dead_on_unwind noalias writable sret(%"class.std::tuple") align 8, ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKiEENS_14iterator_rangeIT_EES4_S4_(ptr noundef, ptr noundef) #5

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKdEENS_14iterator_rangeIT_EES4_S4_(ptr noundef, ptr noundef) #5

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEEC2ISt5tupleIJiN5boost14iterator_rangeIPKiEESG_NSD_IPKdEEEEEERKT_RKNS9_6paramsERKNS_6detail12empty_paramsE(ptr noundef nonnull align 8 dereferenceable(136), ptr noundef nonnull align 8 dereferenceable(52), ptr noundef nonnull align 8 dereferenceable(109), ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109)) unnamed_addr #6 align 2

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

attributes #0 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nobuiltin allocsize(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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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 = { 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 #7 = { nounwind }
attributes #8 = { builtin allocsize(0) }
attributes #9 = { builtin 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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}


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

%"class.std::tuple" = type { %"struct.std::_Tuple_impl.base", [4 x i8] }
%"struct.std::_Tuple_impl.base" = type <{ %"struct.std::_Tuple_impl.1", %"struct.std::_Head_base.12" }>
%"struct.std::_Tuple_impl.1" = type { %"struct.std::_Tuple_impl.2", %"struct.std::_Head_base.11" }
%"struct.std::_Tuple_impl.2" = type { %"struct.std::_Tuple_impl.3", %"struct.std::_Head_base.6" }
%"struct.std::_Tuple_impl.3" = type { %"struct.std::_Head_base" }
%"struct.std::_Head_base" = type { %"class.boost::iterator_range" }
%"class.boost::iterator_range" = type { %"class.boost::iterator_range_detail::iterator_range_base" }
%"class.boost::iterator_range_detail::iterator_range_base" = type { %"class.boost::iterator_range_detail::iterator_range_base.4" }
%"class.boost::iterator_range_detail::iterator_range_base.4" = type { %"class.boost::iterator_range_detail::iterator_range_base.5" }
%"class.boost::iterator_range_detail::iterator_range_base.5" = type { ptr, ptr }
%"struct.std::_Head_base.6" = type { %"class.boost::iterator_range.7" }
%"class.boost::iterator_range.7" = type { %"class.boost::iterator_range_detail::iterator_range_base.8" }
%"class.boost::iterator_range_detail::iterator_range_base.8" = type { %"class.boost::iterator_range_detail::iterator_range_base.9" }
%"class.boost::iterator_range_detail::iterator_range_base.9" = type { %"class.boost::iterator_range_detail::iterator_range_base.10" }
%"class.boost::iterator_range_detail::iterator_range_base.10" = type { ptr, ptr }
%"struct.std::_Head_base.11" = type { %"class.boost::iterator_range.7" }
%"struct.std::_Head_base.12" = type { i32 }
%"struct.amgcl::amg<amgcl::backend::builtin<double>, amgcl::runtime::coarsening::wrapper, amgcl::runtime::relaxation::wrapper>::params" = type <{ %"class.boost::property_tree::basic_ptree", %"class.boost::property_tree::basic_ptree", i32, i8, [3 x i8], i32, i32, i32, i32, i32, i8, [3 x i8] }>
%"class.boost::property_tree::basic_ptree" = type { %"class.std::__cxx11::basic_string", ptr }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon.0 }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon.0 = type { i64, [8 x i8] }
%"struct.amgcl::detail::empty_params" = type { i8 }

declare i32 @__gxx_personality_v0(...)

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) local_unnamed_addr #0

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) local_unnamed_addr #1

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef nonnull ptr @amgcl_precond_create(i32 noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, ptr noundef %4) local_unnamed_addr #3 personality ptr @__gxx_personality_v0 {
  %6 = alloca i32, align 4
  %7 = alloca %"class.std::tuple", align 8
  %8 = alloca %"class.boost::iterator_range.7", align 8
  %9 = alloca %"class.boost::iterator_range.7", align 8
  %10 = alloca %"class.boost::iterator_range", align 8
  %11 = alloca %"struct.amgcl::amg<amgcl::backend::builtin<double>, amgcl::runtime::coarsening::wrapper, amgcl::runtime::relaxation::wrapper>::params", align 8
  %12 = alloca %"struct.amgcl::detail::empty_params", align 1
  %13 = alloca %"struct.amgcl::amg<amgcl::backend::builtin<double>, amgcl::runtime::coarsening::wrapper, amgcl::runtime::relaxation::wrapper>::params", align 8
  %14 = alloca %"struct.amgcl::detail::empty_params", align 1
  store i32 %0, ptr %6, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 56, ptr nonnull %7) #7
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %8) #7
  %15 = sext i32 %0 to i64
  %16 = getelementptr inbounds i32, ptr %1, i64 %15
  %17 = getelementptr inbounds i8, ptr %16, i64 4
  %18 = tail call { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKiEENS_14iterator_rangeIT_EES4_S4_(ptr noundef %1, ptr noundef nonnull %17)
  %19 = extractvalue { ptr, ptr } %18, 0
  store ptr %19, ptr %8, align 8
  %20 = getelementptr inbounds i8, ptr %8, i64 8
  %21 = extractvalue { ptr, ptr } %18, 1
  store ptr %21, ptr %20, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #7
  %22 = load i32, ptr %16, align 4, !tbaa !5
  %23 = sext i32 %22 to i64
  %24 = getelementptr inbounds i32, ptr %2, i64 %23
  %25 = tail call { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKiEENS_14iterator_rangeIT_EES4_S4_(ptr noundef %2, ptr noundef %24)
  %26 = extractvalue { ptr, ptr } %25, 0
  store ptr %26, ptr %9, align 8
  %27 = getelementptr inbounds i8, ptr %9, i64 8
  %28 = extractvalue { ptr, ptr } %25, 1
  store ptr %28, ptr %27, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %10) #7
  %29 = load i32, ptr %16, align 4, !tbaa !5
  %30 = sext i32 %29 to i64
  %31 = getelementptr inbounds double, ptr %3, i64 %30
  %32 = tail call { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKdEENS_14iterator_rangeIT_EES4_S4_(ptr noundef %3, ptr noundef %31)
  %33 = extractvalue { ptr, ptr } %32, 0
  store ptr %33, ptr %10, align 8
  %34 = getelementptr inbounds i8, ptr %10, i64 8
  %35 = extractvalue { ptr, ptr } %32, 1
  store ptr %35, ptr %34, align 8
  call void @_ZSt10make_tupleIJRiN5boost14iterator_rangeIPKiEES5_NS2_IPKdEEEESt5tupleIJDpNSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeEEEDpOSC_(ptr dead_on_unwind nonnull writable sret(%"class.std::tuple") align 8 %7, ptr noundef nonnull align 4 dereferenceable(4) %6, ptr noundef nonnull align 8 dereferenceable(16) %8, ptr noundef nonnull align 8 dereferenceable(16) %9, ptr noundef nonnull align 8 dereferenceable(16) %10)
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #7
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %8) #7
  %.not = icmp eq ptr %4, null
  %36 = call noalias noundef nonnull dereferenceable(136) ptr @_Znwm(i64 noundef 136) #8
  br i1 %.not, label %45, label %37

37:                                               ; preds = %5
  call void @llvm.lifetime.start.p0(i64 112, ptr nonnull %11) #7
  invoke void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsC2ERKN5boost13property_tree11basic_ptreeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESJ_St4lessISJ_EEE(ptr noundef nonnull align 8 dereferenceable(109) %11, ptr noundef nonnull align 8 dereferenceable(40) %4)
          to label %38 unwind label %40

38:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %12) #7
  call void @_ZN5amgcl6detail12empty_paramsC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12)
  invoke void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEEC2ISt5tupleIJiN5boost14iterator_rangeIPKiEESG_NSD_IPKdEEEEEERKT_RKNS9_6paramsERKNS_6detail12empty_paramsE(ptr noundef nonnull align 8 dereferenceable(136) %36, ptr noundef nonnull align 8 dereferenceable(52) %7, ptr noundef nonnull align 8 dereferenceable(109) %11, ptr noundef nonnull align 1 dereferenceable(1) %12)
          to label %39 unwind label %42

39:                                               ; preds = %38
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %12) #7
  call void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109) %11) #7
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %11) #7
  br label %53

40:                                               ; preds = %37
  %41 = landingpad { ptr, i32 }
          cleanup
  br label %44

42:                                               ; preds = %38
  %43 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %12) #7
  call void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109) %11) #7
  br label %44

44:                                               ; preds = %42, %40
  %.pn20 = phi { ptr, i32 } [ %43, %42 ], [ %41, %40 ]
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %11) #7
  br label %54

45:                                               ; preds = %5
  call void @llvm.lifetime.start.p0(i64 112, ptr nonnull %13) #7
  invoke void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsC2Ev(ptr noundef nonnull align 8 dereferenceable(109) %13)
          to label %46 unwind label %48

46:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %14) #7
  call void @_ZN5amgcl6detail12empty_paramsC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %14)
  invoke void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEEC2ISt5tupleIJiN5boost14iterator_rangeIPKiEESG_NSD_IPKdEEEEEERKT_RKNS9_6paramsERKNS_6detail12empty_paramsE(ptr noundef nonnull align 8 dereferenceable(136) %36, ptr noundef nonnull align 8 dereferenceable(52) %7, ptr noundef nonnull align 8 dereferenceable(109) %13, ptr noundef nonnull align 1 dereferenceable(1) %14)
          to label %47 unwind label %50

47:                                               ; preds = %46
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %14) #7
  call void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109) %13) #7
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %13) #7
  br label %53

48:                                               ; preds = %45
  %49 = landingpad { ptr, i32 }
          cleanup
  br label %52

50:                                               ; preds = %46
  %51 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %14) #7
  call void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109) %13) #7
  br label %52

52:                                               ; preds = %50, %48
  %.pn = phi { ptr, i32 } [ %51, %50 ], [ %49, %48 ]
  call void @llvm.lifetime.end.p0(i64 112, ptr nonnull %13) #7
  br label %54

53:                                               ; preds = %47, %39
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %7) #7
  ret ptr %36

54:                                               ; preds = %52, %44
  %.pn20.pn = phi { ptr, i32 } [ %.pn20, %44 ], [ %.pn, %52 ]
  call void @_ZdlPvm(ptr noundef nonnull %36, i64 noundef 136) #9
  call void @llvm.lifetime.end.p0(i64 56, ptr nonnull %7) #7
  resume { ptr, i32 } %.pn20.pn
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZSt10make_tupleIJRiN5boost14iterator_rangeIPKiEES5_NS2_IPKdEEEESt5tupleIJDpNSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeEEEDpOSC_(ptr dead_on_unwind noalias writable sret(%"class.std::tuple") align 8, ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKiEENS_14iterator_rangeIT_EES4_S4_(ptr noundef, ptr noundef) local_unnamed_addr #5

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local { ptr, ptr } @_ZN5boost19make_iterator_rangeIPKdEENS_14iterator_rangeIT_EES4_S4_(ptr noundef, ptr noundef) local_unnamed_addr #5

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEEC2ISt5tupleIJiN5boost14iterator_rangeIPKiEESG_NSD_IPKdEEEEEERKT_RKNS9_6paramsERKNS_6detail12empty_paramsE(ptr noundef nonnull align 8 dereferenceable(136), ptr noundef nonnull align 8 dereferenceable(52), ptr noundef nonnull align 8 dereferenceable(109), ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN5amgcl3amgINS_7backend7builtinIdllEENS_7runtime10coarsening7wrapperENS4_10relaxation7wrapperEE6paramsD2Ev(ptr noundef nonnull align 8 dereferenceable(109)) unnamed_addr #6 align 2

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

attributes #0 = { nobuiltin nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nobuiltin allocsize(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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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 = { 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 #7 = { nounwind }
attributes #8 = { builtin allocsize(0) }
attributes #9 = { builtin 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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}


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