OpenVMS Alpha Porting and Migration

Porting code invoking LIB$TPARSE with action
routines to OpenVMS Alpha and LIB$TABLE_PARSE

This page contains links to the source for a VAX LIB$TPARSE action routine which demonstrates a method for porting it to an OpenVMS Alpha platform with minimal code changes.

The LIB$T{ABLE_}PARSE run-time library is simple facility to implement state-driven parsing. On the VAX, the routine is called LIB$TPARSE; on the Alpha, it is LIB$TABLE_PARSE. The arguments to these routines are similar and the construction of the state-table is the same. LIB$TPARSE and LIB$TABLE_PARSE differ in the way they pass arguments to action routines. Thus, simply changing name of the routine is not sufficient to port the application using the finite state parser to the Alpha.

TMESIS Software has implemented a macro set which can be found on this page (and others) to allow the modification of the argument pointer (VAX AP) register. There is no argument pointer on the Alpha and its use in macro programs is merely a compiler manifestation. Typically, any code with writes to AP will cause the Alpha amacro-32 compiler to generate code which accesses the Alpha register R12. Using a technique similar to that employed in the the OpenVMS supplied ${UN}LOCK_PAGE macro set, TMESIS Software can allow modifications to the AP register to exist in code ported to the Alpha.

Here is a demonstation of using this macro set to port a LIB$TPARSE action routine from the VAX to Alpha without actually changing the code employed in the original VAX version. ACTION_RTN.MAR

The source for the .START_AP_JACKET, .END_AP_JACKET and the two architecture selector macros: .ON_AXP and .ON_VAX can be found here. MACROS.MAC





This page has been accessed 16 times.

Copyright © 1998
TMESIS SOFTWARE
All Rights Reserved.

This document was last modified Wednesday, April 07, 1999 03:13:04 PM




page design, graphics and layout by  
TMESIS Software