Board index » cppbuilder » LME 352

LME 352


2005-04-26 11:10:41 PM
cppbuilder64
I am trying to link a very large application, containing many libraries --
all with full debug. The resultant executable is around 52MB and the
associated TDS file is around 60MB. We have found that while we can compile
and debug this program from within the IDE, we must link it from the command
line. This application has grown a bit over time and now even command line
links are failing with the following message:
"Fatal: Error detected (LME352)
Warning: Cannot reserve virtual memory at addr 54030000 for -196608 bytes
(errcode 87)"
I am running Windows XP SP2 and BCB 6.0 Professional with Borland's latest
patches (I'm very disappointed there have been no updates in the past two
years!):
- bcb6_eng_pro_upd4.exe dated July 2003
- Linker updates to:
- ilink32.dll
- ilink32.exe
The command line script to make is:
SET libSwitch=
if %2==lib ( SET libSwitch=-t"\%BCBRoot%\bin\deflib.bmk" )
"\%BCBRoot%\bin\bpr2mak" %libSwitch% %1.bpr>build.log
MAKE -f%1.mak>>build.log
%1 is the bpr file name
%2 is either "exe" or "lib". The linker error I have occurs on the "exe"
link.
Any help will be greatly appreciated. Thanks.
XXXX@XXXXX.COM
 
 

Re:LME 352

My guess is that if you must have debug enabled for everything then
you have exceeded the capacity and need to move something out to a
DLL. However I have never seen an application of any size, including
much smaller than yours, in which no modules have been debugged so you
may be able to bypass the problem by recompiling the already debugged
portions with debug off.
. Ed
Quote
Kevin Huber wrote in message
news:426e5a0d$ XXXX@XXXXX.COM ...

I am trying to link a very large application, containing many
libraries -- all with full debug. The resultant executable is around
52MB and the associated TDS file is around 60MB. We have found that
while we can compile and debug this program from within the IDE, we
must link it from the command line. This application has grown a bit
over time and now even command line links are failing with the
following message:

"Fatal: Error detected (LME352)

Warning: Cannot reserve virtual memory at addr 54030000 for -
196608 bytes (errcode 87)"

I am running Windows XP SP2 and BCB 6.0 Professional with Borland's
latest patches (I'm very disappointed there have been no updates in
the past two years!):

- bcb6_eng_pro_upd4.exe dated July 2003

- Linker updates to:

- ilink32.dll

- ilink32.exe

The command line script to make is:

SET libSwitch=

if %2==lib ( SET libSwitch=-t"\%BCBRoot%\bin\deflib.bmk" )

"\%BCBRoot%\bin\bpr2mak" %libSwitch% %1.bpr>build.log

MAKE -f%1.mak>>build.log

%1 is the bpr file name

%2 is either "exe" or "lib". The linker error I have occurs on the
"exe" link.
 

Re:LME 352

Hi!
My experieces meanwhile let me guess, that most LMEs come from buggy symbol
management in the linker.
Here are my tips, which may (!) help you, may be only for a while...
1. Compare the project options of your application, your libraries and
your components.
Any strange differences at Compiler, C++, Linker, Pascal adjustments?
Watch your Include paths: are they really correct?
2. Before every Make or Build, delete the precompiled headers from
Borland's Lib folder.
3. You have your own big libraries?
Split them into smaller libs, so that lib size is <= about 8 MB
4. Vary the order of the modules in your project, so that the CPPs
are compiled and linked in another order as previously.
Also change the order of the libs.
5. Reduce Symbols in your application, mainly by reducing big classes
with may methods and/or members.
6. You have many classes with a high inheritence depth, I means classes
with many a ancestors? Perhaps it's possible for you, to decrease the number
of ancestors.
Good luck,
EH :-)
 

{smallsort}