pTAL Conversion Guide

pTAL Built-In Routines
pTAL Conversion Guide527302-002
18-44
$SGWADDR_TO_SGBADDR
$SGWADDR_TO_SGBADDR
$SGWADDR_TO_SGBADDR converts an SGWADDR or SGXWADDR address to an
SGBADDR address.
expression
is an expression whose value is an SGWADDR or SGXWADDR address.
If expression is not an address in the lower half of the 64K-word segment, the
address returned by $SGWADDR_TO_SGBADDR is undefined.
$STACK_ALLOCATE
$STACK_ALLOCATE allocates a block of memory and returns the address of the
block.
pTAL privileged procedure No
Can be executed only by privileged procedures No
Sets condition code No
Sets $CARRY No
Sets $OVERFLOW No
Example 18-33. Call to $SGWADDR_TO_SGBADDR Routine
STRING .SG s;
INT .SG i;
@s := $SGWADDR_TO_SGBADDR(@i); ! OK if i is in the lower half
! of system globals
Note. The pTAL and EpTAL compilers behave differently.
expression( )
VST690.vsd
$SGWADDR_TO_SGBADDR
( size )
VST032.vsd
$STACK_ALLOCATE