8 #include <rmm/detail/export.hpp>
9 #include <rmm/mr/detail/sam_headroom_memory_resource_impl.hpp>
11 #include <cuda/memory_resource>
15 namespace RMM_NAMESPACE {
36 :
public cuda::mr::shared_resource<detail::sam_headroom_memory_resource_impl> {
37 using shared_base = cuda::mr::shared_resource<detail::sam_headroom_memory_resource_impl>;
44 cuda::mr::device_accessible) noexcept
52 cuda::mr::host_accessible) noexcept
76 static_assert(cuda::mr::synchronous_resource<sam_headroom_memory_resource>);
77 static_assert(cuda::mr::resource<sam_headroom_memory_resource>);
79 cuda::mr::synchronous_resource_with<sam_headroom_memory_resource, cuda::mr::device_accessible>);
81 cuda::mr::synchronous_resource_with<sam_headroom_memory_resource, cuda::mr::host_accessible>);
82 static_assert(cuda::mr::resource_with<sam_headroom_memory_resource, cuda::mr::device_accessible>);
83 static_assert(cuda::mr::resource_with<sam_headroom_memory_resource, cuda::mr::host_accessible>);
Resource that uses system memory resource to allocate memory with a headroom.
Definition: sam_headroom_memory_resource.hpp:36
sam_headroom_memory_resource & operator=(sam_headroom_memory_resource &&)=default
Default move assignment operator.
sam_headroom_memory_resource(sam_headroom_memory_resource const &)=default
Default copy constructor.
friend void get_property(sam_headroom_memory_resource const &, cuda::mr::device_accessible) noexcept
Enables the cuda::mr::device_accessible property.
Definition: sam_headroom_memory_resource.hpp:43
sam_headroom_memory_resource & operator=(sam_headroom_memory_resource const &)=default
Default copy assignment operator.
sam_headroom_memory_resource(std::size_t headroom)
Construct a headroom memory resource.
sam_headroom_memory_resource(sam_headroom_memory_resource &&)=default
Default move constructor.
friend void get_property(sam_headroom_memory_resource const &, cuda::mr::host_accessible) noexcept
Enables the cuda::mr::host_accessible property.
Definition: sam_headroom_memory_resource.hpp:51