lamppp
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
lmp::tensor::detail::DataPtr Struct Reference

Smart pointer wrapper for tensor data with custom deleter support. More...

#include <data_ptr.hpp>

Public Member Functions

 DataPtr (void *data_ptr, std::function< void(void *)> dealloc)
 
void * data () const
 

Public Attributes

std::shared_ptr< void > ptr
 

Detailed Description

Smart pointer wrapper for tensor data with custom deleter support.

DataPtr wraps raw pointers with automatic memory management and custom deallocators for different allocation strategies (CPU, CUDA, etc.).

Note
that DataPtr does not actually define any of the allocation strategies. they are defined in empty_stub()
See also
empty_stub

The documentation for this struct was generated from the following file: