Skip to main content

Mapping Struct

Declaration

struct simaai::neat::Mapping { ... }

Included Headers

#include <TensorCore.h>

Public Constructors Index

Mapping ()=default
Mapping (const Mapping &)=delete
Mapping (Mapping &&other) noexcept

Public Destructor Index

~Mapping ()

Public Operators Index

Mapping &operator= (const Mapping &)=delete
Mapping &operator= (Mapping &&other) noexcept

Public Member Attributes Index

void *data = nullptr
std::size_tsize_bytes = 0
std::function< void()>unmap
std::shared_ptr< void >keepalive

Definition at line 122 of file TensorCore.h.

Public Constructors

Mapping()

simaai::neat::Mapping::Mapping ()
default

Definition at line 128 of file TensorCore.h.

Mapping()

simaai::neat::Mapping::Mapping (const Mapping &)
delete

Definition at line 129 of file TensorCore.h.

Mapping()

simaai::neat::Mapping::Mapping (Mapping && other)
inline noexcept

Definition at line 131 of file TensorCore.h.

131 Mapping(Mapping&& other) noexcept {
132 *this = std::move(other);
133 }

Public Destructor

~Mapping()

simaai::neat::Mapping::~Mapping ()
inline

Definition at line 149 of file TensorCore.h.

150 if (unmap)
151 unmap();
152 }

Public Operators

operator=()

Mapping& simaai::neat::Mapping::operator= (const Mapping &)
delete

Definition at line 130 of file TensorCore.h.

operator=()

Mapping& simaai::neat::Mapping::operator= (Mapping && other)
inline noexcept

Definition at line 134 of file TensorCore.h.

134 Mapping& operator=(Mapping&& other) noexcept {
135 if (this != &other) {
136 if (unmap)
137 unmap();
138 data = other.data;
139 size_bytes = other.size_bytes;
140 unmap = std::move(other.unmap);
141 keepalive = std::move(other.keepalive);
142 other.data = nullptr;
143 other.size_bytes = 0;
144 other.unmap = nullptr;
145 other.keepalive.reset();
146 }
147 return *this;
148 }

Public Member Attributes

data

void* simaai::neat::Mapping::data = nullptr

Definition at line 123 of file TensorCore.h.

123 void* data = nullptr;

keepalive

std::shared_ptr<void> simaai::neat::Mapping::keepalive

Definition at line 126 of file TensorCore.h.

126 std::shared_ptr<void> keepalive;

size_bytes

std::size_t simaai::neat::Mapping::size_bytes = 0

Definition at line 124 of file TensorCore.h.

124 std::size_t size_bytes = 0;

unmap

std::function<void()> simaai::neat::Mapping::unmap

Definition at line 125 of file TensorCore.h.

125 std::function<void()> unmap;

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


Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.9.1.