Home
last modified time | relevance | path

Searched refs:util (Results 1 – 25 of 59) sorted by relevance

123

/petsc/include/petsc/private/cpp/
H A Dtype_traits.hpp11 namespace util namespace
150 static_assert(!::Petsc::util::detail::is_derived_petsc_object_impl<_p_PetscObject>::value, "");
152 static_assert(!::Petsc::util::detail::is_derived_petsc_object_impl<int>::value, "");
153 static_assert(!::Petsc::util::detail::is_derived_petsc_object_impl<Empty>::value, "");
154 static_assert(!::Petsc::util::detail::is_derived_petsc_object_impl<IntHdr>::value, "");
157 static_assert(::Petsc::util::detail::is_derived_petsc_object_impl<CPetscObject>::value, "");
158 static_assert(::Petsc::util::detail::is_derived_petsc_object_impl<CxxPetscObject>::value, "");
159 static_assert(::Petsc::util::detail::is_derived_petsc_object_impl<CxxDerivedPetscObject>::value, ""…
191 PETSC_NODISCARD inline constexpr Petsc::util::remove_const_t<T> &PetscRemoveConstCast(T &object) no… in PetscRemoveConstCast()
193 return const_cast<Petsc::util::remove_const_t<T> &>(object); in PetscRemoveConstCast()
[all …]
H A Dfunctional.hpp13 namespace util namespace
38 using type = util::tuple_element_t<ix, std::tuple<Args...>>;
49 using type = util::tuple_element_t<ix, std::tuple<Args...>>;
59 using type = util::tuple_element_t<ix, std::tuple<Args...>>;
134 …static inline auto gobblefn(TupleT &&tuple, Petsc::util::index_sequence<idx...>) PETSC_DECLTYPE_NO…
136 …YPE_NOEXCEPT_AUTO_RETURNS(gobblefn(std::forward_as_tuple(args...), Petsc::util::make_index_sequenc…
H A Dmemory.hpp15 namespace util namespace
51 return std::unique_ptr<T>(new util::remove_extent_t<T>[n]());
H A Dcrtp.hpp6 namespace util namespace
H A Dregister_finalize.hpp42 class RegisterFinalizeable : public util::crtp<RegisterFinalizeable, Derived> {
99 using decayed_type = util::decay_t<Self>; in do_register_finalize_()
H A Dtuple.hpp11 namespace util namespace
H A Dobject_pool.hpp286 PetscCallCXX(util::construct_at(ptr, std::forward<Args>(args)...)); in construct_()
295 PetscCallCXX(util::destroy_at(ptr)); in destroy_()
357 util::compressed_pair<constructor_type, allocator_type> pair_{};
H A Dunordered_map.hpp55 class KHashTable : util::compressed_pair<Hash, Eq> {
280 using conditional_const = util::conditional_t<is_const_it, util::add_const_t<U>, U>;
308 …template <bool other_is_const_it, util::enable_if_t<is_const_it && !other_is_const_it> * = nullptr>
313 …template <bool other_is_const_it, util::enable_if_t<is_const_it && !other_is_const_it> * = nullptr>
771 …e(other.flags_)), count_(util::exchange(other.count_, 0)), n_occupied_(util::exchange(other.n_occu… in KHashTable()
782 count_ = util::exchange(other.count_, 0); in operator =()
783 n_occupied_ = util::exchange(other.n_occupied_, 0); in operator =()
784 upper_bound_ = util::exchange(other.upper_bound_, 0); in operator =()
H A Darray.hpp12 namespace util namespace
/petsc/lib/petsc/bin/maint/petsclinter/petsclinter/
H A D__init__.py32 import importlib.util
34 spec = importlib.util.find_spec(name, package=package)
36 spec.loader = importlib.util.LazyLoader(loader)
37 module = importlib.util.module_from_spec(spec)
45 from . import util
H A D_typing.py130 from .util._clang import CXTranslationUnit, ClangFunction
131 from .util._color import Color
132 from .util._utility import PrecompiledHeader
H A Dqueue_main.py17 from .util._timeout import timeout
18 from .util._utility import traceback_format_exception
177 pl.util.initialize_libclang(clang_lib=clang_lib, compat_check=clang_compat_check)
H A Dmain.py96 return pl.util.build_compiler_flags(
195 …pl.util.initialize_libclang(clang_dir=clang_dir, clang_lib=clang_lib, compat_check=clang_compat_ch…
210 with pl.util.PrecompiledHeader.from_flags(
256 output = pl.util.subprocess_capture_output(
355 clang_dir = pl.util.try_to_find_libclang_dir()
H A Dtest_main.py16 from .util._utility import traceback_format_exception
162 pl.util.subprocess_capture_output(
/petsc/src/sys/objects/device/impls/
H A Dimpldevicebase.hpp23 class DeviceBase : public util::crtp<DeviceBase, Derived> {
64 template <typename... T, util::enable_if_t<sizeof...(T) >= 3, int> = 0>
68 template <typename... T, util::enable_if_t<sizeof...(T) >= 3, int> = 0>
72 template <typename... T, util::enable_if_t<sizeof...(T) >= 3, int> = 0>
151 template <typename... T, util::enable_if_t<sizeof...(T) >= 3, int>>
162 auto type = static_cast<PetscInt>(util::to_underlying(*inittype)); in PetscOptionDeviceInitialize()
171 template <typename... T, util::enable_if_t<sizeof...(T) >= 3, int>>
188 template <typename... T, util::enable_if_t<sizeof...(T) >= 3, int>>
H A Dsegmentedmempool.hpp165 …t_)), open_(util::exchange(other.open_, false)), stream_id_(util::exchange(other.stream_id_, devic… in MemoryChunk()
175 open_ = util::exchange(other.open_, false); in operator =()
176 stream_id_ = util::exchange(other.stream_id_, device::DefaultStream::INVALID_ID); in operator =()
177 size_ = util::exchange(other.size_, 0); in operator =()
385 …MemoryBlock &&other) noexcept : mem_(util::exchange(other.mem_, nullptr)), allocator_(other.alloca… in MemoryBlock()
397 mem_ = util::exchange(other.mem_, nullptr); in operator =()
399 size_ = util::exchange(other.size_, 0); in operator =()
/petsc/src/sys/objects/cxx/memory/
H A Dobject_pool.cxx106 return AllocationHeader::header_size() + size + util::to_underlying(align) - 1; in total_size_()
128 if (const auto ptr = util::exchange(*in_ptr, nullptr)) { in delete_ptr_()
219 constexpr auto max_align = util::to_underlying(AllocationHeader::max_alignment()); in valid_alignment_()
220 const auto align = util::to_underlying(in_align); in valid_alignment_()
330 …PetscCallCXX(base_ptr = reinterpret_cast<unsigned char *>(util::construct_at(reinterpret_cast<Allo… in allocate_ptr_()
334 *ret_ptr = std::align(util::to_underlying(align), size, aligned_ptr, usable_size); in allocate_ptr_()
336 …failed to align pointer %p (size %zu, alignment %zu)", aligned_ptr, size, util::to_underlying(alig… in allocate_ptr_()
338 constexpr auto max_align = util::to_underlying(AllocationHeader::max_alignment()); in allocate_ptr_()
504 if (auto ptr = util::exchange(*in_ptr, nullptr)) { in deallocate()
/petsc/src/sys/objects/device/util/
H A Ddevicereg.c74 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_INIT_NONE) == 0, "");
75 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_INIT_LAZY) == 1, "");
76 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_INIT_EAGER) == 2, "");
/petsc/include/petsc/private/
H A Dcupminterface.hpp109 static_assert(util::to_underlying(DeviceType::CUDA) == 0, ""); in cupmName()
110 static_assert(util::to_underlying(DeviceType::HIP) == 1, ""); in cupmName()
111 return std::get<util::to_underlying(T)>(DeviceTypes); in cupmName()
150 …using cupmComplex_t = util::conditional_t<PetscDefined(USE_REAL_SINGLE), cuComplex, cuDo…
279 …return cudaLaunchKernel<util::remove_reference_t<FunctionT>>(std::addressof(func), std::move(gridD… in PETSC_CUPM_ALIAS_FUNCTION()
296 …using cupmComplex_t = util::conditional_t<PetscDefined(USE_REAL_SINGLE), hipComplex, hip…
541 using cupmReal_t = util::conditional_t<PetscDefined(USE_REAL_SINGLE), float, double>;
542 using cupmScalar_t = util::conditional_t<PetscDefined(USE_COMPLEX), cupmComplex_t, cupmReal_t>;
674 …static PetscErrorCode PetscCUPMMemcpyAsync(D *dest, const util::type_identity_t<D> *src, std::size… in PetscCUPMMemcpyAsync()
709 …static PetscErrorCode PetscCUPMMemcpy(D *dest, const util::type_identity_t<D> *src, std::size_t n,… in PetscCUPMMemcpy()
[all …]
/petsc/src/sys/objects/device/interface/
H A Dmemory.cxx25 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_COPY_HTOH) == 0, "");
26 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_COPY_DTOH) == 1, "");
27 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_COPY_HTOD) == 2, "");
28 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_COPY_DTOD) == 3, "");
29 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_COPY_AUTO) == 4, "");
H A Ddevice.cxx521 …e], defaultDeviceId, PetscBools[defaultView], PetscDeviceInitTypes[Petsc::util::to_underlying(*def… in PetscDeviceInitializeTypeFromOptions_Private()
659 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_HOST) == 0, ""); in PetscDeviceInitializeFromOptions_Internal()
660 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_CUDA) == 1, ""); in PetscDeviceInitializeFromOptions_Internal()
661 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_HIP) == 2, ""); in PetscDeviceInitializeFromOptions_Internal()
662 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_SYCL) == 3, ""); in PetscDeviceInitializeFromOptions_Internal()
663 static_assert(Petsc::util::to_underlying(PETSC_DEVICE_MAX) == 4, ""); in PetscDeviceInitializeFromOptions_Internal()
/petsc/config/BuildSystem/config/
H A D__init__.py3 from config.util import *
/petsc/config/BuildSystem/config/utilities/
H A D__init__.py3 from config.util import *
/petsc/src/sys/objects/device/impls/cupm/
H A Dcupmevent.hpp135 …PMEvent(CUPMEvent &&other) noexcept : pool_type(std::move(other)), event_(util::exchange(other.eve… in CUPMEvent()
147 event_ = util::exchange(other.event_, cupmEvent_t{}); in operator =()
/petsc/src/binding/petsc4py/src/petsc4py/lib/
H A D__init__.py61 import importlib.util
77 module = importlib.util.module_from_spec(spec)

123