Dynamic link libraries (DLLs)
A DLL is a program object that can be accessed from other separate program objects.
A DLL differs from a traditional program object in
that it exports definitions of programs, functions, or
variables to DLLs, DLL applications, or non-DLLs. Therefore, you do
not need to link the target routines into the same program
object as the referencing routine. When an application references
a separate DLL for the first time, the system automatically loads
the DLL into memory. In other words, calling a program in a DLL is
similar to calling a program object with a dynamic CALL
.
A DLL application is an application that references imported definitions of programs, functions, or variables.
Although some functions of z/OS® DLLs
overlap the functions provided by COBOL dynamic CALL
statements,
DLLs have several advantages over regular z/OS program objects and
dynamic calls:
- DLLs are common across COBOL and C/C++, thus providing better interoperation for applications that use multiple programming languages. Reentrant COBOL and C/C++ DLLs can also interoperate smoothly.
- You can make calls to programs in separate DLL modules that have
long program-names. (Dynamic call resolution truncates program-names
to eight characters.) Using the COBOL option
PGMNAME(LONGUPPER)
orPGMNAME(LONGMIXED)
and the COBOL DLL support, you can make calls between program objects with names of up to 160 characters.
DLLs are supported by IBM® z/OS Language Environment®, based on function provided by the z/OS program management binder. DLL support is available for applications running under z/OS in batch or in TSO, CICS®, z/OS UNIX, or IMS environments.
PGMNAME
MVS™ Program Management: User's Guide and Reference (Binder support for DLLs)