Charms.Pointer (charms v0.1.4)
Intrinsic module to work with pointers.
Charms.Pointer should be the "smart pointer" not just comes with lifetime management, but also SIMD and Tensor support.
Summary
Functions
Allocates a single element of the given elem_type
, returning a pointer to it.
Allocates an array of size
elements of the given elem_type
, returning a pointer to it.
Gets the element pointer of elem_type
for the given base pointer ptr
and index n
.
Loads a value of type
from the given pointer ptr
.
Stores a value val
at the given pointer ptr
.
Return the pointer type
Functions
Allocates a single element of the given elem_type
, returning a pointer to it.
Allocates an array of size
elements of the given elem_type
, returning a pointer to it.
Gets the element pointer of elem_type
for the given base pointer ptr
and index n
.
Loads a value of type
from the given pointer ptr
.
Stores a value val
at the given pointer ptr
.
Return the pointer type