Article View: comp.os.msdos.programmer
Article #2897Re: .com and .exe files
From: lsalomo
Date: Fri, 02 Nov 1990 13:26
Date: Fri, 02 Nov 1990 13:26
21 lines
1551 bytes
1551 bytes
From article <92.2730D05F@bohemia.UUCP>, by Greg.Smith@bohemia.UUCP (Greg Smith):
> The extensions of the files are mainly there for our referance. The way the
> computer differentiates (sp) between the files is the header at the
> beginning of the file. on EXE's an "MZ" will be the first two bytes in
> the file, while com files start out with actual code. Also, following the
> MZ is a Program Segment Prefix(PSP) which defines many other needs, and
> memory/stack useage terms.
Not meaning to start a big discussion, but following the .EXE id ('MZ' as
you pointed out) is a header (NOT THE PSP) which describes the size of the
code in pages, the entry point, etc. plus the relocation table which the
loader uses to do any segment fixups before jumping to the entry point.
Cheers,
Q - the "Q"uestor for knowledge (, a degree, etc.)
lsalomo@hubcap.clemson.edu
ibmman@clemson.clemson.edu
=============================================================================
"Gee Wally, I think there's something wrong with the Beaver."
=============================================================================
Technical Details
Message-ID:
<11349@hubcap.clemson.edu>Path:
arc1-ca.pugleaf.net!utzoo!attcan!uunet!midway!linac!uwm.edu!wuarchive!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!emory!hubcap!lsalomoReferences:
<92.2730D05F@bohemia.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!midway!linac!uwm.edu!wuarchive!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!emory!hubcap!lsalomo From: lsalomo@hubcap.clemson.edu (lsalomo) Newsgroups: comp.os.msdos.programmer Subject: Re: .com and .exe files Message-ID: <11349@hubcap.clemson.edu> Date: 2 Nov 90 13:26:38 GMT References: <92.2730D05F@bohemia.UUCP> Organization: Clemson University, Clemson, SC Lines: 21