HP 3000 Manuals

Step One: Remove Hardware Dependencies [ SPL to HP C/XL Migration Guide ] MPE/iX 5.0 Documentation


SPL to HP C/XL Migration Guide

Step One:  Remove Hardware Dependencies 

Many SPL constructs are highly hardware-dependent, such as ASSEMBLE
statements and references to hardware registers.  In most cases, these
constructs were used by SPL programmers for reasons of efficiency, not
for lack of higher level alternatives.  Rewriting these portions and
testing the program again should be a first step.  Normally, this is a
matter of determining exactly what the old statements are intended to do,
and implementing the same function in SPL statements that do not depend
on specific hardware instructions or registers.

The direct use of the stack, via PUSH, DEL, and TOS operators is done for
one of two reasons:  either to avoid declaring temporary variables, or to
retrieve information left on the stack after an operation such as SCAN.
In the first case, simply declaring extra variables will allow the stack
references to be eliminated.  In the case of operations such as SCAN, see
the relevant areas of this guide for SPL procedures that isolate these
operations and may later be replaced by equivalent HP C/XL functions.



MPE/iX 5.0 Documentation