Short_stack_frame, Title, Short_stack_frame title – Zilog ZUSBOPTS User Manual
Page 264

Directives
UM017105-0511
236
Zilog Developer Studio II – ZNEO™
User Manual
Example
SEGMENT code ; predefined segment
DEFINE data ; user-defined
.SHORT_STACK_FRAME
The ZNEO LD and LEA instructions permit a special encoding when an argument is an
offset from the frame pointer and the offset can be expressed as a signed 6-bit value (-32 to
+31). Normally, the ZNEO assembler chooses the smaller encoding whenever possible;
otherwise, the assembler chooses the more general 14-bit encoding.
Also, when the ZNEO assembler encounters a LINK instruction allocating more than 256
bytes of stack frame, it silently substitutes a sequence of LINK and LEA or SUB instruc-
tions to obtain the desired result.
For especially tight code, you might prefer to be alerted with an error message when an
offset from the frame pointer on an LD or LEA instruction cannot be encoded in a 6-bit
field or when the stack size requested in a LINK instruction cannot be encoded in the 8-bit
field allowed for a LINK instruction. The .SHORT_STACK_FRAME directive supports
such a preference.
Syntax
<shortfp_directive> =>
.SHORT_STACK_FRAME ON
|
OFF
Example
.SHORT_STACK_FRAME ON ; Turn short stack frames on
; Section of code that needs to be very tight
.SHORT_STACK_FRAME OFF ; Turn short stack frames off
TITLE
Causes a user-defined
TITLE
to be displayed in the listing file. The new title remains in
effect until the next
TITLE
directive. The operand must be a string constant.
Synonym
.title
Syntax
<title_directive> =>
TITLE
<string_const>
Example
TITLE "My Title"