Other considerations and restrictions
This topic lists AMODE 31 and AMODE 64 considerations and restrictions.
Performance
There is an extra overhead to transition between AMODE 31 and 64. Avoid crossing AMODE in performance sensitive areas and group programs that need to call each other frequently into the same AMODE.
In the CALL statement, use CALL ... BY REFERENCE
whenever possible. This
requires less processing when the parameters are accessed in the other AMODE. Instead of using the
RETURNING
phrase, return the data item as a BY REFERENCE
parameter. This avoids additional copying when the call is returned. CALL ...BY
VALUE
is not supported.
Multi-threading
THREAD
compiler option is not
supported for COBOL programs compiled with LP(64) (running in AMODE 64). This limitation is extended
to COBOL programs compiled with LP(32) (running in AMODE 31) when the mixed AMODE 31/64 feature is
used. This means that when the LE runtime environment contains both AMODE 31 and AMODE 64 programs
within any LE enclave, only one thread can contain COBOL programs.Condition handling
The condition handling support does not extend across AMODE 31/64 boundary. When processing a condition, Language Environment® does not traverses stack frames to find a condition handler until an AMODE 31 and AMODE 64 boundary is reached. If a handler is not found at this point, the condition is treated as unhandled. Applications that rely on condition handling might need to be modified.
Additional information
For more information about AMODE 31/64 inter operation, see Introduction to AMODE 31 and AMODE 64 programs interoperability on Language Environment Vendor Interface for AMODE 31 and AMODE 64 Interoperability.