pTAL Conversion Guide

pTAL Built-In Routines
pTAL Conversion Guide527302-002
18-3
TNS Instruction Codes Supported by pTAL Built-In
Routines
TNS Instruction Codes Supported by pTAL
Built-In Routines
Many of the pTAL built-in routines provide the functionality of TNS instructions that
otherwise would be unavailable in pTAL.
Tables:
Table 18-1, pTAL Built-In Routines That TAL Supports, on page 18-3
Table 18-2, pTAL Built-In Routines That TAL Does Not Support, on page 18-4
Table 18-1. pTAL Built-In Routines That TAL Supports
Routine Description
$BADDR_TO_EXTADDR
Converts a BADDR address to an EXTADDR address
$BADDR_TO_WADDR
Converts a BADDR address to a WADDR address
$EXTADDR_TO_BADDR
Converts an EXTADDR address to a BADDR address
$EXTADDR_TO_WADDR
Converts an EXTADDR address to a WADDR address
$FILL8, $FILL16 and $FILL32
Fill an array or structure with repetitions of an 8-bit, 16-bit,
and 32-bit value, respectively
$INT_OV
Same as $INT, but sets overflow indicator in some cases
$PROCADDR
Converts an INT(32) expression to a PROCADDR address
$SGBADDR_TO_EXTADDR
Converts an SGBADDR or SGXBADDR address to an
EXTADDR address
$SGBADDR_TO_SGWADDR
Converts an SGBADDR or SGXBADDR address to an
SGWADDR address
$SGWADDR_TO_EXTADDR
Converts an SGWADDR or SGXWADDR address to an
EXTADDR address
$SGWADDR_TO_SGBADDR
Converts an SGWADDR or SGXWADDR address to an
SGBADDR address
$STACK_ALLOCATE
Allocates space above the stack area of the current
procedure
$WADDR_TO_BADDR
Converts a WADDR address to a BADDR address
$WADDR_TO_EXTADDR
Converts a WADDR address to an EXTADDR address