[Larceny-users] Larceny Panic: Can't allocate an object of size ...

Sven Hartrumpf hartrumpf at gmx.net
Fri Feb 12 06:29:21 EST 2016


Hello.

SH wrote 2016-02-06 16:55:
> Hello Will.
> 
> You wrote 2016-02-05 14:26:52-05:00:
>> Sven wrote:
>> 
>>> Is there a way to avoid the following compiler crash?
>> 
>> Sorry about that.
> 
> No problem. I know the status of larceny, its limitations and its
> strengths. So I can cope with both :-)
> 
>> In my experience, this error means Larceny's assembler tried
>> to create a single monolithic chunk of x86 machine code whose
>> size was the reported 17536520 bytes, which is larger than
>> the maximum object size Larceny currently supports.
>> 
>> The best workaround I know of is to force Larceny's compiler
>> to break that one huge chunk of x86 machine code into smaller
>> chunks.  You can probably do that using the lambda-optimization
>> compiler switch to disable lambda optimization, but that's a
>> rather blunt approach even if it works.
> 
> It didn't solve the problem.
>
> I will reduce the size of the program by using the flow analysis
> from some other Scheme implementation (to determine and eliminate
> unused functions given the entry function for the program).
> I think this will bring the size below 16 MB.

This approach worked fine so that larceny successfully compiles
my program.
For the record, the program that was too large had 160000 LOC,
while the one that worked had only 125000 LOC.

Sven



More information about the Larceny-users mailing list