Defines the name for the procedure. Follows the naming convention of langtype.
prologuearg
Arguments to pass to the prologue procedure. With the default PROLOGUE and EPILOGUE, the FORCEFRAME argument generates a stack segment, even if one is not necessary. LOADDS causes the DS register to be saved in the PROLOGUE and restored in the EPILOGUE. Parameters must be separated by commas. Angle brackets are required but not passed.
distance
Can be NEAR, FAR, NEAR16, NEAR32, FAR16, or FAR32. Indicates the call distance of this procedure. If you choose NEAR or FAR, the assembler will select 16- or 32-bit NEAR or FAR depending on the current segment size. If you do not specify this option, the assembler determines the distance from the memory model and processor type. NEAR is the default if you do not use the .MODEL directive.
langtype
Any valid language type. Determines naming style and calling convention.
visibility
Can be PRIVATE, PUBLIC, or EXPORT. Determines how the procedure is made available to other modules. PUBLIC is the standard default, but the default can be reset with the OPTION PROC directive. EXPORT implies PUBLIC and FAR and informs the linker that the procedure should be placed in the export entry table.
reglist
List of registers that the prologue preserves on the stack and the epilogue restores on exit. Separate multiple registers with spaces.
parameter
Procedure parameter. The assembler translates argument references into a direct reference to the stack location. Separate multiple arguments with commas.
tag
Either a qualified type or VARARG. VARARG allows a variable number of arguments to be passed as a comma separated list to <argument>. If VARARG is used, it must be applied to the last parameter of the PROC directive. VARARG is only allowed with the C, SYSCALL, and STDCALL language types. If tag is omitted, the assembler defaults to WORD in a 16-bit segment or DWORD in a 32-bit segment.
[FRAME [:ehandler-address] ] is only valid with ml64.exe, and causes MASM to generate a function table entry in .pdata and unwind information in .xdata for a function's structured exception handling unwind behavior.
When the FRAME attribute is used, it must be followed by an .ENDPROLOG directive.