Module pmem::ptr [] [src]

The functions in this section provide optimized copying to persistent memory

The copy, copy_nonoverlapping, and write_bytes, provide the same memory copying as memmove(3), memcpy(3), and memset(3), and ensure that the result has been flushed to persistence before returning.

Warning: Using these functions where is_pmem(1) returns false may not do anything useful. Use the normal libc functions in that case.

Structs

PmemConstPtr

Direct *const T pointer to a pmem location

PmemConstVirtualPtr

Persistent memory virtual pointer

PmemMutPtr

Direct *mut T pointer to a pmem location

PmemMutVirtualPtr

Persistent memory virtual mutable pointer

Functions

copy

Copies count * size_of<T> bytes from src to pmemdest. The source and destination may overlap.

copy_nonoverlapping

Copies count * size_of<T> bytes from src to pmemdest. The source and destination may not overlap.

msync
null
null_mut
write

Overwrites a memory location with the given value without reading or dropping the old value.

write_bytes

Invokes memset on the specified pointer, setting count * size_of::<T>() bytes of memory starting at pmemdest to val.