When a translated library has been replaced by a native version of the library, you need to define accordingly any logical names that point to it---that is, you need to redefine image_TV to image.
TIE Statistics and Feedback
In addition to the TIE's run-time support function, TIE statistics and feedback can help to improve translated image performance:
DECmigrate for OpenVMS AXP Systems Translating Images describes these features in detail and explains how to
define the logical names that enable and disable their use.
9.3.1 Problems and Restrictions
This section describes known problems and restrictions with the TIE.
9.3.1.1 Condition Handler Restriction
There is a permanent restriction on the type of condition handler that
can be established for both native and translated images. A native
routine cannot establish a translated condition handler, nor can a
translated routine establish a native condition handler. If a native or
translated image violates this restriction, the run-time results are
unpredictable.
9.3.1.2 Exception Handler Restrictions
The following exception handler restrictions are permanent:
The following floating-point restrictions are permanent:
MOVD (SP),R2 MOVD R2,-(SP)
LDD F2,0(R14) ! Pick up D float CVTDG F2,F2 ! Convert to Canonical G Form with rounding CVTGD F2,F17 ! Convert back to D Form for storing STD F17,-8(R14) ! Store the result
Note the following interoperability restrictions:
The following translated VAX C program restrictions are permanent:
Translation support is provided to remove impediments for users moving to Alpha due to:
For languages whose VAX versions are undergoing active development, native Alpha versions are now available. The TIE is being maintained to support those language features that were available as of the release of OpenVMS VAX Version 5.5-2.
Similarly, translation is supported for images whose use of system services and run-time library entry points is restricted to those that existed on OpenVMS VAX Version 5.5-2.
In cases where more recent VAX layered products have been installed, it may be necessary to take minor additional steps if application needs require rebuilding an image suitable for translation. For instance, with DECwindows Motif Version 1.2 or Version 1.2--3 for OpenVMS VAX, images must be built with the OSF Motif Version 1.1.3 library or the DECwindows XUI library rather than with the OSF Motif Version 1.2.2 or Version 1.2.3 library in order to be suitable for translation.
Similarly, for those using recent versions of DEC Fortran for VAX, an additional qualifier is required to compile Fortran programs that are suitable for translation.
For further information, see the release notes for particular VAX products.
As a safety measure for situations where future rebuilding and retranslation of OpenVMS VAX images is likely, it may be preferable to save copies of the relevant OpenVMS VAX Version 5.5-2 shareable images in a separate VAX directory and link new versions of VAX applications against those images. Using that technique the resulting images will be compatible with newer OpenVMS VAX shareable images (picking up any OpenVMS enhancements of existing features), and will also be properly built for translation to OpenVMS Alpha (by not requiring newer versions of shareable images).
The following sections list the translated images, image information files, and other related files that are provided with OpenVMS Alpha.
OpenVMS Alpha contains no translated message images. All message images have been made native.
Translated Images in SYS$LIBRARY:
Translated Images in SYS$SYSTEM:
Translated RTL Images in IMAGELIB:
Note that most of the translated RTLs are provided in D56 format rather than D53 format; some are provided in both formats. Where both formats are provided, the default format is D53. See Section 9.5 for more information about the translated run-time libraries.
Image Information Files in SYS$LIBRARY:
System Logical Names Definitions
The following system logical names are defined to facilitate the translated environment:
As part of the OpenVMS Alpha kit, Digital provides a set of translated run-time libraries.
Some of the routines in the VAX run-time libraries use the VAX D_floating data type for double-precision arithmetic.
In the translated versions of these libraries, the Alpha D56 D_floating data type is used by default (where the VAX run-time library used D_floating). This provides the full precision of the 56-bit mantissa in VAX D_floating, yielding consistency of results at a cost in execution-time performance.
For a handful of performance-critical math-related libraries, Digital also supplies versions of the translated run-time libraries that use the Alpha D53 D_floating data type for double-precision operations. For these libraries, the D53 forms are the default. The D53 forms provide better performance by sacrificing the low-order three bits of precision in the mantissa.
The following translated libraries are provided in D56 form only:
The following translated libraries are provided in both D56 and D53 (the default) form:
Accessing the D56 Form of the Run-Time Libraries
When you use the run-time libraries, the following happens by default:
Some users might need the full precision of D56 floating point. However, using the D56 routines imposes a very significant performance penalty. To access the D56 routines, redefine the run-time library's logical name to the D56 form, as shown in Table 9-2. The logical name can be defined on a per-process or systemwide basis, as appropriate for your site.
Library | Logical Name | D56 Name |
---|---|---|
BASRTL2 | BASRTL2_TV | BASRTL2_D56_TV |
BLAS1RTL | BLAS1RTL_TV | BLAS1RTL_D56_TV |
MTHRTL | MTHRTL_TV | MTHRTL_D56_TV |
Translated callers to CRF$FREE_VM and CRF$GET_VM will not work properly. The translated callers are expecting VAX JSB semantics, but instead, Alpha JSB semantics are present in the native code (naturally).
To work around this problem, the translated callers need to use CALL
instead of JSB.
9.6 Translated VAX C Run-Time Library
The following sections contain release notes pertaining to the
translated VAX C run-time library.
9.6.1 Problems and Restrictions
This section describes known problems and restrictions with the
OpenVMS Alpha translated VAX C Run-Time Library (VAX C RTL).
9.6.1.1 Functional Restrictions
The translated VAX C RTL is a translated version of the OpenVMS VAX Version 5.4 VAX C RTL. All problems and restrictions present in that release of the VAX C RTL exist unchanged in the translated VAX C RTL. The following items are known restrictions in the functionality of the translated VAX C RTL:
The following restrictions apply when the translated VAX C RTL interoperates with the native DEC C RTL:
Programs that perform any of these restricted actions may receive
access violations or other exceptions. No testing is performed to
detect and prevent restricted operations from being performed.
9.7 Translated VAX COBOL Programs
The OpenVMS Alpha operating system supports the execution of translated
VAX COBOL programs compiled with the VAX COBOL Version 5.0 compiler (or
earlier compilers).
9.7.1 Problems and Restrictions
Programs compiled with the VAX COBOL Version 5.1 compiler are not supported by the OpenVMS Alpha operating system.
This chapter describes how to create native Alpha images that can make
calls to and be called by translated VAX images.
10.1 Overview
DECmigrate for OpenVMS AXP Systems Translating Images describes how to use the VAX Environment Software Translator (VEST) to convert a VAX executable or shareable image into a functionally equivalent Alpha image. (DECmigrate for OpenVMS Alpha is an optional layered product that supports the migration of a VAX application to an Alpha system. VEST is a component of the DECmigrate utility.)
Using VEST, you can translate all the components of an application, such as the main executable image and all the shareable images that it calls. However, you can also create an application that is a mix of translated and native components. For example, you may want to create a native version of a shareable image that is called by your application to take advantage of native performance. You may also choose to use a mixture of native and translated components to allow you to create a native version of your application in stages.
You can use translated VAX images as you would a native Alpha image.
However, to create native images that can interoperate with translated
images requires some additional considerations, described in the
following sections.
10.1.1 Compiling Native Images That Can Interoperate with Translated Images
To create a native image that can call or be called by a translated image, you must specify the /TIE qualifier when compiling the source files of the native Alpha image. Any source module that contains a procedure that is made available to external callers must be compiled with the /TIE qualifier. When you specify the /TIE qualifier, the compilers create procedure signature blocks (PSBs) that are needed by the Translated Image Environment (TIE) at execution time in order to properly jacket calls between translated and native images. The TIE is part of the operating system.
You must also specify the /TIE qualifier when compiling a source module that contains a procedure that performs a callback (or calls out to a specified procedure) that may be in a translated image. In this case, the /TIE qualifier causes the compilers to generate a call to a special run-time library routine, OTS$CALL_PROC, that ensures that the outbound call to a translated procedure is handled properly.
In addition to the /TIE qualifier, you may need to specify other compiler qualifiers to ensure correct interoperation between a translated image and a native shareable image. For example, if the translated callers of a native shareable image use the VAX D_floating format for double-precision floating-point operations (the default for VAX languages), you must specify the /FLOAT=D_FLOAT qualifier because the default format for double-precision data on Alpha systems is not VAX D_floating. Consult compiler documentation to determine the exact qualifier syntax to specify VAX D_floating format. Note that, because the VAX D_floating data type is not supported by the Alpha architecture, its use adversely affects performance.
Depending on application-specific semantics, you may also need to
specify other compiler qualifiers to force byte granularity, data
alignment, and AST atomicity.
10.1.2 Linking Native Images That Can Interoperate with Translated Images
To create a native Alpha image that can call a translated VAX image, you must explicitly link the native object modules with the /NONATIVE_ONLY qualifier. (Note that /NATIVE_ONLY is the default used by the linker for this qualifier.) This qualifier causes the linker to include in the image the PSB information created by the compilers.
Because the /NONATIVE_ONLY qualifier affects only outgoing calls from native images to translated images, you do not need to specify it when creating a native Alpha image that will be called by a translated VAX image. The linker's default behavior (/NATIVE_ONLY qualifier) can prevent native images from calling translated images but not from being called by translated images.
Note that the layout of the symbol vector in the native version of the
shareable image must match the layout of the symbol vector in the
translated shareable image it replaces. For more information about
replacing translated shareable images with native shareable images, see
Section 10.3.
10.2 Creating a Native Image That Can Call a Translated Image
To create a native Alpha image that can make calls to a translated VAX shareable image, perform the following steps:
To illustrate interoperability, consider the programs in Example 10-1 and Example 10-2. Example 10-1 calls the routine mysub that is defined in Example 10-2.
Example 10-1 Source Code for Main Program (MYMAIN.C)
#include <stdio.h> int mysub(); main() { int num1, num2, result; num1 = 5; num2 = 6; result = mysub( num1, num2 ); printf("Result is: %d\n", result); }
Example 10-2 Source Code for Shareable Image (MYMATH.C)
int myadd(value_1, value_2) int value_1; int value_2; { int result; result = value_1 + value_2; return( result ); } int mysub(value_1,value_2) int value_1; int value_2; { int result; result = value_1 - value_2; return( result ); } int mydiv( value_1, value_2 ) int value_1; int value_2; { int result; result = value_1 / value_2; return( result ); } int mymul( value_1, value_2 ) int value_1; int value_2; { int result; result = value_1 * value_2; return( result ); }
6459P010.HTM OSSG Documentation 22-NOV-1996 13:07:19.67
Copyright © Digital Equipment Corporation 1996. All Rights Reserved.