Edit

__psmash

Microsoft Specific

Expands a 2-MB reverse map table (RMP) entry into a corresponding set of contiguous 4-KB RMP entries.

Syntax

unsigned int __psmash(
   unsigned __int64 system_pa
);

Parameters

system_pa
[in] The system physical address of the 2-MB page.

Return value

Returns a status code that indicates the result of the operation.

Value Description
0 The operation completed successfully.
1 An input parameter is invalid.
2 The current address space identifier (ASID) isn't zero.
3 Another processor is modifying the same RMP entry.
7 The page doesn't meet the requirements for expansion.

Remarks

The __psmash intrinsic corresponds to the AMD PSMASH machine instruction. It's available only as an intrinsic and can be used only in kernel mode.

For more information, see AMD64 Architecture Programmer's Manual, Volume 2: System Programming.

Requirements

Available starting with MSVC 19.52.3683

Intrinsic Architecture Header
__psmash AMD x86/x64 with SEV-SNP support <ammintrin.h>

END Microsoft Specific

See also

Compiler intrinsics
__pvalidate
__rmpadjust
__rmpquery
__rmpread
__rmpupdate