Vault 7: Projects
This publication series is about specific projects related to the Vault 7 main publication.
© 2005-2011 Microchip Technology Inc. DS70157F-page 435
Section 5. Instruction Descriptions
Instruction
Descriptions
5
ULNK
De-allocate Stack Frame
Implemented in: PIC24F PIC24H PIC24E dsPIC30F dsPIC33F dsPIC33E
X X X X
Syntax: {label:} ULNK
Operands: None
Operation: W14 → W15
(W15) – 2 → W15
(TOS) → W14
Status Affected: None
Encoding:
1111 1010 1000 0000 0000 0000
Description: This instruction de-allocates a Stack Frame for a subroutine calling
sequence. The Stack Frame is de-allocated by setting the Stack Pointer
(W15) equal to the Frame Pointer (W14), and then POPping the stack
to reset the Frame Pointer (W14).
Words: 1
Cycles: 1
Example 1:
ULNK ; Unlink the stack frame
Before
Instruction
After
Instruction
W14 2002 W14 2000
W15 20A2 W15 2000
Data 2000 2000 Data 2000 2000
SR 0000 SR 0000
Example 2:
ULNK ; Unlink the stack frame
Before
Instruction
After
Instruction
W14 0802 W14 0800
W15 0812 W15 0800
Data 0800 0800 Data 0800 0800
SR 0000 SR 0000
Protego_Release_01_05-Related-OEM-Documentation-PIC24FJ64GA004-Programmers_Reference_Manual.pdf