Out of memory during compilation

Matt Gamble gamblemj at gmail.com
Wed May 2 15:13:58 UTC 2018

On Wednesday, 2 May 2018 at 14:30:19 UTC, Joakim wrote:
> On Wednesday, 2 May 2018 at 14:25:35 UTC, Matt Gamble wrote:
>> I have a large program (for me) with several thousand lines of 
>> code. Recently when I've tried to compile under debug (-g 
>> -unittest)  with VS2017, dmd2.076.1, windows 10, 8Gb ram), 
>> I've had the following output:
>> Compiling SKaTERoptimizerD.d...
>> Fatal Error: Out of memory
>> Building x64\Debug\SKaTERoptimizerD.exe failed!
>> When compiled under release (-O -release -inline 
>> -boundscheck=off) mode it works fine.
>> Any advice on how to combat this? Do I need to start compiling 
>> DLLs? Does that change how the linking would be done? Would 
>> that affect the debugger?
>> Any help is appreciated,
>> Matt
> My guess would be Optlink, the old OMF linker. Are you using 
> that or the VS linker? Try adding the -v flag to check log 
> output for where it fails.

I believe I'm using the vs linker (link.exe). This is what is 
automatically set for VisualD under x64 mode. I tried the -v flag 
and got compiler output messages that are 13,758 lines long. The 
"Fatal Error: Out of memory" happens at line 13,639. How do I use 
this information?

More information about the Digitalmars-d-learn mailing list