c++ Builder xe5 Error detected (LME288)

∥☆過路亽.° 提交于 2019-12-05 04:45:09
Barry Andrews

I got some information on this from Embarcadero which may help.

The error is an "out of memory", error. The reason for "Out Of Memory" errors (which come in different guises) in the linker, is that the linker has to pre-allocate memory in contiguous heaps that it then uses as it links, in the past these heaps could not be adjusted, we had to do a best guess, so in the new 64-bit linker (and has also been added to the 32-bit linker) we allowed people to be able adjust the size of these heaps manually when they needed to. Now the reason why these heaps can be problem is that not all systems are the same, some people use different software that map DLLs into the linker's address space like Windows Hook DLLs, antivirus software all these DLLs allocate memory INSIDE the linker's (any application really) address space and hence has an impact on the size of the heaps the linker can allocate. So we added this ability to adjust the heaps manually, but we also allocated the initial heaps quite big .

The 32bit linker has a new switch -GH, see below this is similar to the ilink64 switch.

The syntax for the switch is:

-GH[heap name]=[number of bytes for the heap]"

This option -GH exists from XE3 Update 1 onwards but evidently is not documented?

To see which heap is out of memory you can try from command line.

MSBuild /p:Platform=Win32 /v:diag XXXX.cbproj

This provides additional information such as:

Overrun on linker heap: code

Linker Heaps


info 0x002d0000 0x0a000000

code 0x000d0000 0x00100000

data 0x00030000 0x08000000

bss 0x08000000 0x08000000

Fatal: Out of memory

The left side of the above output is number of bytes being used at the moment and on the right the number of bytes allocated for the specific named heap.

The default heap sizes the linker allocates at start up are:

"system", default size 0x08000000

"info", default size 0x0A000000

"code", default size 0x08000000

"rodata", default size 0x06000000 //readonly data

"data", default size 0x08000000

"bss", default size 0x08000000

"tds", default size 0x0FA00000

When you see the "unknown heap" this is normally the "tds" heap

Example to adjust tds heap to 0x0A000000 you would do -GHtds=0x0A000000

Hopefully this information helps you and others with the LME288 error.

I got it.

I had the same problem with Seattle 10 on Windows 7x64. I tried it all. Everything you can find on SO, EDN, and more. I finally broke down and used my Embarcadero support ticket because I simply couldn't link anything anymore. After what I can only describe as an arduous and valiant effort by one of Embarcadero's senior software engineers, we finally stumbled across this fix:

First, right-click on ilink32.exe, select Properties, then go to the Compatibility tab and tick the "Run this program in compatibility mode for" checkbox and select Windows XP SP3. On my system (64 bit Win7, running Seattle 10) the ilink32.exe file is located in "C:\Program Files (x86)\Embarcadero\Studio\17.0\bin."

Second, force admin rights (even if you're already an admin) by right-clicking the Builder launch icon and selecting "Run as administrator."

Now, open your projects and link to your heart's content! (Your results may vary.)

I found this page looking for the same problem, and the solution for me is a simple trick:

Instead of double click in the project to open it (for example double click in xxxx.cbproj), start the ide and then open the project.

Explication? no idea, but now link correctly.

Max Kielland

I had the same problem here C++ Builder XE7 LME288 Error

My solution was simple to clean up all temp files. It seems like the error is connected with corrupt temp files.

slimbofat

I just had this issue with XE4 on Windows 10. Fvel got me on the right track. The issue was being caused by the file being opened with BDSLauncher.exe instead of bds.exe . I set the default program for .groupproj to be bds.exe and the problem went away.

Disable your AntiVirus protection software for the ilink32.exe in the embarcadero bin folder, especially if you are using bitdefender.

The solutions given here did not work for me. My solution is to set the size of the windows swap file to a fixed value (e.g. min: 1000 MB and max: 10000). After restart I checked the Radio Button to "System managed size" and restart again. Now I can compile and link without any linker errors. But the LME-error comes up again after some days. Then I have to do the same steps with the swapfile to solve the problem.

Chris

For me, in Windows 10, the issue was because there wasn't enough Virtual Memory allocated. Steps to resolve the issue:

  • Go to System > Advanced System Settings > Advanced.
  • Under 'Performance', click 'Settings' > Advanced
  • Under Virtual Memory click 'Change'
  • Ensure the currently allocated memory is equal to or greater than the recommended memory. If not, select 'Custom size' and set the initial size to the recommended size, and the Maximum size to a larger value.

See also C++ Builder XE7 LME288 Error

For me the problem started when I switched on Auto increment build number in XE7. The project I had had worked for several months without problem. The project was created by an earlier version of Builder. The first problem that occurred was problem for compiler to find windows.h, and the same for rc compiler. The PATHs was updated to invalid versions by Builder (perhaps these were from earlier Builder). After adding the PATHs the LME288 occurred. After switching of the Auto increment build number and removed all temporary files it seems to work again.

I had the same linker issue LME288 on RAD Studio XE7 / Windows 10. Cleaning temporary files using CCleaner fixed it.

Edit: the problem keeps coming back but another run of cleaning fixes it.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!