#ifndef _NTRTL_H
#if defined(_M_AMD64) || defined(_M_ARM64)
NTSYSAPI
VOID
NTAPI
RtlFillMemoryNonTemporal(
_Out_writes_bytes_all_(Length) VOID UNALIGNED *Destination,
_In_ SIZE_T Length,
_In_ CONST UCHAR Value
);
View code on GitHub#ifndef _NTRTL_H
#if defined(_M_AMD64) || defined(_M_ARM64)
// ...
#else
#define RtlFillMemoryNonTemporal RtlFillMemory
View code on GitHub// wdm.h
NTSYSAPI VOID RtlFillMemoryNonTemporal(
VOID *Destination,
SIZE_T Length,
const UCHAR Value
);
View the official Windows Driver Kit DDI referenceNo description available.
This function fills a block of memory with the specified fill value using non-temporal moves that do not pollute the cache.
DestinationA pointer to the destination memory block to copy the bytes to.
LengthThe number of bytes to copy from the source to the destination.
ValueThe value to fill the destination memory block with. This value is copied to every byte in the memory block that is defined by Destination and Length.
This function returns NTSYSAPI VOID.
RtlFillMemoryNonTemporal only performs a non-temporal fill for x64-based systems, and only when the Length parameter is 8 bytes or greater. Otherwise, this function is equivalent to RtlFillMemory.