Add_8_16f (add fast, 8 bit to 16 bit), Adds_8_16 (add signed, 8 bit to 16 bit), Alloc (allocate stack space) – Echelon Neuron User Manual
Page 172
![background image](/manuals/735710/172/background.png)
_add_8_16f (Add Fast, 8 Bit to 16 Bit)
This function adds an 8-bit value to a 16-bit value. The “f” stands for “fast” in
that if there is no carry, only an 8-bit add is done.
Stack Transformation: (offset, value(2) -- value(2)+offset)
Location: Near
Registers Affected: None
Example:
This example adds 50 to 300.
pushd #d’300 ; (d’44, 1)
push #d’50 ; (d’50, d’44, 1)
call _add_8_16f ; (d’94, 1)
_adds_8_16 (Add Signed, 8 Bit to 16 Bit)
This function adds an 8-bit signed value to a 16-bit value.
Stack Transformation: (a, b(2) -- a + b(2))
Location: Near
Registers Affected: None
Example:
This example adds -50 to 300.
pushd #d’300 ; (d’44, 1)
push #@lb(-d’50) ; (-d’50, d’44, 1)
call _adds_8_16 ; (d’250, 0)
_alloc (Allocate Stack Space)
This function allocates space on the data stack by pushing count bytes of zeros on
the data stack. It can be used to allocate space on the data stack for local
variables. For fewer than nine bytes, consider using the ALLOC instruction,
even though it does not initialize the allocated area to zero.
See also _dealloc (Deallocate Stack Space and Return).
Stack Transformation: (count -- 0, …, 0)
Location: Near
Registers Affected: None
Example:
162
System-Provided Functions