Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Marks the end of an epilogue unwind region. This directive doesn't emit a Windows unwind data (WOD) unwind code.
Syntax
.ENDEPILOG
Remarks
Important
This directive is experimental and is subject to change.
Enable Unwind Version 3 by using ml64.exe /unwindv3.
.ENDEPILOG is only valid in Unwind Version 3.
- It marks the end of an epilogue region started by .BEGINEPILOG.
- These directives generate unwind metadata (
.xdataand.pdatasections) but don't produce executable code. - Epilogues must contain at least one directive.
- Epilogue directives are mandatory for epilogue unwind code generation. No epilogue unwind codes are emitted without a
.BEGINEPILOG/.ENDEPILOGpair. - It's an error to use epilogue directives outside of the region between .BEGINEPILOG and .ENDEPILOG.
Note
In Unwind Version 1, the directive appears after the corresponding instruction. In Unwind Version 3, the directive appears before the instruction.
Example
; ml64 /unwindv3 ex1.asm /link /entry:Example1 /SUBSYSTEM:CONSOLE
_text SEGMENT
Example1 PROC FRAME
.allocstack 16
sub rsp, 16
.endprolog
; function body
.beginepilog
.freestack 16
add rsp, 16
.endepilog
ret
Example1 ENDP
_text ENDS
END
See also
x64 Unwind Version 3 (experimental)
Directives Reference
.BEGINEPILOG
.ENDPROLOG
MASM BNF Grammar