Hi ! I'm not quite sure if this is the right place to go for help with Hugs, but I'll give it try... Situation is this: I was running some scripts in WinHugs, and everything was running happily. I then attempted to add ( using ":a" ) a new script, and received the following error message: "Program code storage space exhausted". Well, I thought to myself ( fool that I evidently was ! ) that there must be a parameter somewhere in Hugs that I can set to increase the program storage space, so I set out to find it. Unfortunately, having tweaked a couple of numbers ( heap size was one, I think, and the other was something similar-looking ), and restarted Hugs, I now have the following error as I start WinHugs: "Cannot allocate heap storage". Immediately after this error message within the WinHugs interface, a pop-up box appears, containing the message: "Fatal Error: unable to load prelude". At that point, WinHugs disappears. I've tried uninstalling Hugs, and completely re-installing it, but that doesn't appear to do any good. So, I've clearly f*cked up somewhere, but I'm not sure where. Any comments or advice would be greatly appreciated. I understand that this might not count as a bug in its own right, as the software is presumably behaving in a perfectly sensible way; rather, the bug is in me, the over-adventurous user. However, though I've read all the documentation, I'm stuck, and would appreciate any help or assistance you can give me. If you want to flame me for gross stupidity, that would be fine, too ! Thanks for your ( hoped for ) help. Sincerely, Iain McNaughton. -- Iain McNaughton
Hi Iain, I'm working with UNIX only but likely my change will solve your problem too. Iain> I was running some scripts in WinHugs, and everything was Iain> running happily. I then attempted to add ( using ":a" ) a new Iain> script, and received the following error message: "Program Iain> code storage space exhausted". In the "src" directory, there are some parameters defined in "prelude.h". Our settings are (we use LARGE_HUGS): #define NUM_ADDRS Pick(28000, 60000, 1280000) #define NUM_STACK Pick(1800, 12000, 64000) NUM_ADDRS is for the program code storage space and NUM_STACK for the stacksize. Recompile, maybe it'll work. Cheers -- Christoph Herrmann Postdoctoral Research Associate University of Passau, Germany E-mail: herrmann@fmi.uni-passau.de WWW: http://brahms.fmi.uni-passau.de/cl/staff/herrmann.html
Hi Iain, Iain McNaughton wrote:
Well, I thought to myself ( fool that I evidently was ! ) that there must be a parameter somewhere in Hugs that I can set to increase the program storage space, so I set out to find it. Unfortunately, having tweaked a couple of numbers ( heap size was one, I think, and the other was something similar-looking ), and restarted Hugs, I now have the following error as I start WinHugs: "Cannot allocate heap storage". Immediately after this error message within the WinHugs interface, a pop-up box appears, containing the message: "Fatal Error: unable to load prelude". At that point, WinHugs disappears.
I've tried uninstalling Hugs, and completely re-installing it, but that doesn't appear to do any good. So, I've clearly f*cked up somewhere, but I'm not sure where. Any comments or advice would be greatly appreciated.
Actually, I think you have stepped on a known design problem concerning how hugs stores its state to the registry under Windows. Unfortunately, every time you do a ":set" in hugs, the changes you make to the options settings are stored in the registry. This is great if you set the right option in exactly the right way, but is brutally unforgiving of mistakes (as you have discovered). Your best bet (be VERY careful doing this) is to run "regedit" (by selecting "Run..." from the Windows "Start" menu and typing "regedit"), and navigate to the key: "HKEY_CURRENT_USER\Software\Haskell\Hugs" select the subkey folder for your hugs version (i.e. "February 2000"). The "Options" key contains the options settings you entered. You can try and edit this by hand to get rid of the options settings that accidentally caused your problem. I *think* you can also just delete this key altogether and hugs will revert to its default configuration. All of this is done at your own risk.
I understand that this might not count as a bug in its own right, as the software is presumably behaving in a perfectly sensible way; rather, the bug is in me, the over-adventurous user. However, though I've read all the documentation, I'm stuck, and would appreciate any help or assistance you can give me. If you want to flame me for gross stupidity, that would be fine, too !
Whether this is a bug or a "design flaw" is a matter of opinion. But hopefully we all agree that an "adventurous user" should not be punished with an unusable hugs installation for all time! We are working on improving this situation. Good luck, -antony -- Antony Courtney Grad. Student, Dept. of Computer Science, Yale University antony@apocalypse.org http://www.apocalypse.org/pub/u/antony
Dear Antony,
This is just to thank you for your helpful advice in solving my problem
with WinHugs. I followed your instructions, and they seem to have worked
perfectly. Thank you for your help with this.
Yours sincerely,
Iain McNaughton.
In message <3AFFDDB1.69112D35@apocalypse.org>, Antony Courtney
Your best bet (be VERY careful doing this) is to run "regedit" (by selecting "Run..." from the Windows "Start" menu and typing "regedit"), and navigate to the key:
"HKEY_CURRENT_USER\Software\Haskell\Hugs"
select the subkey folder for your hugs version (i.e. "February 2000").
The "Options" key contains the options settings you entered. You can try and edit this by hand to get rid of the options settings that accidentally caused your problem.
.... -- Iain McNaughton
participants (3)
-
Antony Courtney -
Ch. A. Herrmann -
Iain McNaughton