Mail Archives: djgpp/1997/09/29/13:45:45
Thomas Demmer <demmer AT LSTM DOT Ruhr-UNI-Bochum DOT De> wrote:
> Eli Zaretskii wrote:
> >
> > On 28 Sep 1997, Paul Derbyshire wrote:
> >
> > > How about when the exe needs to read its own
> > > attached stuff back, or modify it? Same thing? Won't this cause errors in
> > > windows and other file sharing environments when the exe will be "in use"?
> >
> > Why would the .exe file of a running program be "in use", Windows or
> > no Windows? I don't think it should. For example, I have no problems
> > building Emacs (where eventually the old emacs.exe is entirely
> > overwritten) on Windows when the old emacs.exe is already running.
> Ther are cases when the exe file remains open,
Be sure of that, but not djgpp ones.
> and then you might get a
> problem. PMail, for example is such a beast.
My Clipper programs too.
> What I have not yet
> figured out is which programs show this behavior (Well, all TurboPascal
> files with the overlay appended to the exe).
I can bet these programs are compiled with overlays in the EXE. Borland can do
it. The overlay code is IN the EXE and not in separated .ovl files. In Clipper
there are a mechanism called "Dynamic Overlays", when you try to execute a
function that isn't in memory Clipper discards some code and loads 1Kb of your
function. Under such cases the file isn't closed during the execution.
> And if there is the
> slightest
> chance of porting the program to UNIX, writing back to the exe file
> is a big No-No.
I don't know about it.
> IMHO, puting the data into an object file is not that bad, it is
> portable (without write back, of course, but Shawn had reading in
> mind, I guess), and the unused stuff gets paged out if neccessary.
Yes but if you have 10Mb of data and you need to load just 100Kb at the same
time is possible to get "Out of virtual ...".
SET
------------------------------------ 0 --------------------------------
Visit my home page: http://www.geocities.com/SiliconValley/Vista/6552/
Salvador Eduardo Tropea (SET). (Electronics Engineer)
Alternative e-mail: set-sot AT usa DOT net - ICQ: 2951574
Address: Curapaligue 2124, Caseros, 3 de Febrero
Buenos Aires, (1678), ARGENTINA
TE: +(541) 759 0013
- Raw text -