Couldn't Allocate Heap, win32 error ...

SGDK only sub forum

Moderator: Stef

Manveru
Very interested
Posts: 74
Joined: Wed Sep 05, 2012 3:30 pm

Re: Couldn't Allocate Heap, win32 error ...

Post by Manveru » Fri Dec 25, 2015 4:36 pm

I solved this bug first with a register fix program, but i forgot its name. After that, i solved this error instaling PC Tools Firewall (it is not a joke). Casually the errors disappeared and after some time i discovered it was because of the firewall. Just disabling this firewall causes the errors to return (using windows 7 x64)
The man who moves a mountain begins by carrying away small stones. Confucius, 551-479 BC

ronin68k
Interested
Posts: 28
Joined: Mon Nov 02, 2015 5:28 am
Location: Krasnodar, Russia

Re: Couldn't Allocate Heap, win32 error ...

Post by ronin68k » Fri Mar 25, 2016 11:09 am

Stef wrote: I think the version which produce best code for m68k is around 2.8.xx but that is definitely too old and some nice compiler features are missing.
I think version 3.4.6 is "good enough", 4.X or new (5.X) produces poorly optimized code and generally later versions are worst :-/ That is just due to GCC adapting the code generation structure to newer CPU architecture which basically broke optimization done for older architecture as the 68000.
i wonder if we could fork latest stable gcc and make it work like 2.8, so we get the best code, no compatibility problems and bunch of new features :D
nonsense? :oops:

Stef
Very interested
Posts: 2976
Joined: Thu Nov 30, 2006 9:46 pm
Location: France - Sevres
Contact:

Re: Couldn't Allocate Heap, win32 error ...

Post by Stef » Fri Mar 25, 2016 12:23 pm

I think that is just impossible, there is too much differences and i guess the code generation part is somehow linked to the compiler new features as well...

ronin68k
Interested
Posts: 28
Joined: Mon Nov 02, 2015 5:28 am
Location: Krasnodar, Russia

Re: Couldn't Allocate Heap, win32 error ...

Post by ronin68k » Thu Apr 14, 2016 10:54 am

djcc's instructions (set winXP compatibility to make.exe) helped me with sgdk lib compilation, thanks a lot! But this does not work to a game project for some reason.

When i try to build a game project with xp-compatible make.exe/admin, im getting following errors:
"in function _start_entry, undefined reference to main"
"in function _reset_entry, undefined reference to main"

And when i do it without admin permissions, it does nothing, just like this...
Image
If i disable "XP mode", couldn't allocate heap error comes back and appears in 99,9% cases.
This is the main reason, why i just can't use sgdk with windows.
There are cases, when i couldn't build my project for 10 times in a row. I give up. :cry:

Also, if somebody does have gcc 3.4.6 or 2.8 sources, can i have it too? =^•^=
Maybe i could accidentally fix heap issue :lol:
Thanks! <3

Stef
Very interested
Posts: 2976
Joined: Thu Nov 30, 2006 9:46 pm
Location: France - Sevres
Contact:

Re: Couldn't Allocate Heap, win32 error ...

Post by Stef » Thu Apr 14, 2016 12:47 pm

I don't have the sources anymore, but i still have a sitting GCC 4.X binary somewhere. I don't think they are affected by this annoying memory allcoation crash issues.

ronin68k
Interested
Posts: 28
Joined: Mon Nov 02, 2015 5:28 am
Location: Krasnodar, Russia

Re: Couldn't Allocate Heap, win32 error ...

Post by ronin68k » Sat Apr 23, 2016 4:34 am

I don't have the sources anymore
Could those help sgdk development or this is completely useless for now? Also, what features are we missing with 2.8?
Sad, we cannot also use clang.

Stef
Very interested
Posts: 2976
Joined: Thu Nov 30, 2006 9:46 pm
Location: France - Sevres
Contact:

Re: Couldn't Allocate Heap, win32 error ...

Post by Stef » Sat Apr 23, 2016 9:31 am

SGDK makefile uses some switchs which may not be supported by GCC 2.8, and even GCC 3.4.6 does not support inlining correctly, i guess it would be even worst with 2.8 but honestly i'm intrigued and will probably give a try as i know GCC 2.8 provides the best code for 68k target :)
Thanks for the link !

ronin68k
Interested
Posts: 28
Joined: Mon Nov 02, 2015 5:28 am
Location: Krasnodar, Russia

Re: Couldn't Allocate Heap, win32 error ...

Post by ronin68k » Sat Apr 23, 2016 4:40 pm

Glad to help you, Stef! Thank you for sgdk, you made my dreams of genesis coding come true.
Hope, you will get 2.8 working :)

Post Reply