Related articles |
---|
Free x86 C compiler wanted js.stoezel@gmail.com (Jean-Sebastien Stoezel) (2007-04-06) |
Re: Free x86 C compiler wanted ArarghMail704@Arargh.com (2007-04-06) |
Re: Free x86 C compiler wanted DrDiettrich1@aol.com (Hans-Peter Diettrich) (2007-04-06) |
Re: Free x86 C compiler wanted cmeerw@cmeerw.org (Christof Meerwald) (2007-04-06) |
Re: Free x86 C compiler wanted cr88192@hotmail.com (cr88192) (2007-04-06) |
Re: Free x86 C compiler wanted gneuner2@comcast.net (George Neuner) (2007-04-06) |
Re: Free x86 C compiler wanted DrDiettrich1@aol.com (Hans-Peter Diettrich) (2007-04-08) |
Re: Free x86 C compiler wanted gneuner2@comcast.net (George Neuner) (2007-04-08) |
Re: Free x86 C compiler wanted nmh@t3x.org (Nils M Holm) (2007-04-08) |
Re: Free x86 C compiler wanted ang.usenet@gmail.com (Aaron Gray) (2007-04-11) |
Re: Free x86 C compiler wanted gah@ugcs.caltech.edu (glen herrmannsfeldt) (2007-04-11) |
Re: Free x86 C compiler wanted lpsantil@gmail.com (lpsantil@gmail.com) (2007-04-13) |
Re: Free x86 C compiler wanted kenney@cix.compulink.co.uk (2007-04-13) |
From: | Hans-Peter Diettrich <DrDiettrich1@aol.com> |
Newsgroups: | comp.compilers |
Date: | 8 Apr 2007 09:51:35 -0400 |
Organization: | Compilers Central |
References: | 07-04-015 07-04-019 07-04-024 |
Keywords: | MSDOS |
Posted-Date: | 08 Apr 2007 09:51:34 EDT |
George Neuner wrote:
> Additionally, COM files are non-relocatable and based at address
> 0x100. If you load them anywhere else they don't work.
>
> George
> [COM files can load anywhere in memory, since DOS sets the CS register
> to point at where they're loaded. If they're more than 64K, they do have
> to do their own segment register management. -John]
Right, John. AFAIR COM programs are restricted to the small memory
model, where everything resides in a single 64K segment. The segment
registers usually are left unchanged during execution, just as in the 32
bit flat model.
The 0x100 offset IMO is related to the PSP, so that the PSP resides at
CS:0000, and the code (loaded file) at CS:0100. The loader must follow
this convention, in order to make the program work properly.
DoDi
Return to the
comp.compilers page.
Search the
comp.compilers archives again.