ddl.omf.OMFBinary
Support for loading of OMF Binary data.
Authors:
Eric Anderton
License:
BSD Derivative (see source for details)
- struct IMPDEF;
- (COMENT subrecord)
This record describes the imported names for a module.
- struct WKEXT;
- (COMENT subrecord)
This record marks a set of external names as "weak," and for every weak extern,
the record associates another external name to use as the default resolution.
- struct EXTDEF;
- The EXTDEF record contains a list of symbolic external references that is, references
to symbols defined in other object modules. The linker resolves external references by
matching the symbols declared in EXTDEF records with symbols declared in PUBDEF records.
- struct PUBDEF;
- The PUBDEF record contains a list of public names. It makes items defined in this object
module available to satisfy external references in other modules with which it is bound
or linked. The symbols are also available for export if so indicated in an EXPDEF
comment record.
- struct LINNUM;
- The LINNUM record relates line numbers in source code to addresses in object code.
- struct SEGDEF;
- The SEGDEF record describes a logical segment in an object module.
It defines the segment's name, length, and alignment, and the way the segment can be
combined with other logical segments at bind, link, or load time.
Object records that follow a SEGDEF record can refer to it to identify a particular
segment. The SEGDEF records are ordered by occurrence, and are referenced by segment
indexes (starting from 1) in subsequent records.
- struct GRPDEF;
- This record causes the program segments identified by SEGDEF records to be collected
together (grouped). For OS/2, the segments are combined into a logical segment that
is to be addressed through a single selector. For MS-DOS, the segments are combined
within the same 64K frame in the run-time memory map.
- struct FIXUPP;
- The FIXUPP record contains information that allows the linker to resolve (fix up)
and eventually relocate references between object modules. FIXUPP records describe
the LOCATION of each address value to be fixed up, the TARGET address to which the
fixup refers, and the FRAME relative to which the address computation is performed.
- struct FixupThread;
- Temporary record used to store FIXUPP TARGET and FRAME information
- struct FixupData;
- Temporary record usd to store LIDATA, LEDATA and COMDAT address information for
subsequent use by FIXUPP records
TODO:
fashion a "Fixup Source" that optionally references COMDAT symbol by name
so
- void parse(inout ExpContainer fixups, inout FixupData fixupData, OMFReader reader);
- FixupSet parse routine.
- struct LIDATA;
- This record provides contiguous binary data-executable code or program data that is
part of a program segment. The data is eventually copied into the program's executable
binary image by the linker.
The data bytes may be subject to relocation or fixing up as determined by the presence
of a subsequent FIXUPP record, but otherwise they require no expansion when mapped to
memory at run time.
- struct LEDATA;
- Like the LEDATA record, the LIDATA record contains binary data-executable code or
program data. The data in an LIDATA record, however, is specified as a repeating
pattern (iterated), rather than by explicit enumeration.
The data in an LIDATA record can be modified by the linker if the LIDATA record is
followed by a FIXUPP record, although this is not recommended.
- struct COMDEF;
- The COMDEF record is an extension to the basic set of 8086 object record types.
It declares a list of one or more communal variables (uninitialized static data
or data that may match initialized static data in another compilation unit).
The size of such a variable is the maximum size defined in any module naming the
variable as communal or public. The placement of communal variables is determined
by the data type using established conventions (noted below).
- struct CEXTDEF;
- This record serves the same purpose as the EXTDEF record described earlier. However,
the symbol named is referred to through a Logical Name Index field. Such a Logical
Name Index field is defined through an LNAMES or LLNAMES record.
- struct COMDAT;
- The purpose of the COMDAT record is to combine logical blocks of code and data that
may be duplicated across a number of compiled modules.
- struct LINSYM;
- This record will be used to output line numbers for functions specified through COMDAT
records. Each LINSYM record is associated with a preceding COMDAT record.
- struct OMFRecord;
- Abstraction of an OMFRecord. Provides support for record checksums and determining
word and byte width.