Re: Eigenvalues of a difficult matrix (storage for CONS is exhausted)
Subject: Re: Eigenvalues of a difficult matrix (storage for CONS is exhausted)
From: Francesco Poli
Date: Sat, 11 May 2002 11:58:48 +0200
On 2002.05.11 00:05 +0400 Vadim V. Zhytnikov wrote:
> Maximal amount of memory GCL can allocate is determined at compile
> time. By default it is 32*1024 pages (page size may be different on
> different systems)
What's the page size on a GNU/Linux system (IA32 architecture, actually
AMD Athlon CPU)?
> which amounts to 128Mb of RAM with 4K page. If you really want more
> RAM
> for your computations you should rebuild GCL with
> ./configure --enable-maxpage=64*1024
> or even more.
I compiled with --enable-maxpage=256*1024
Not enough? :-o
Central memory is 2 Gibyte wide...
So perhaps I can push it to --enable-maxpage=512*1024
512*1024*4096 byte = 2 Gibyte
Supposing page size is 4 Kibyte...
However there are many other processes running: I cannot assume that
all the core is available to Maxima and GCL...
> I also recommend to preallocate memory when Maxima or GCL starts.
> This dramatically improves speed especially for large computations.
> Create the file init.lsp and put it in your working directory.
I tried to look at the output with
(setq si::*notify-gbc* t)
I saw CONS, RELOCATABLE-BLOCKS and FIXNUM garbace collection messages.
I thought I should increase preallocation for this page types above the
values I see in messages (right?).
After some test, I exagerated:
(progn
(si::allocate-relocatable-pages 20000 t)
(si::allocate 'cons 200000 t)
(si::allocate 'fixnum 10000 t)
#-gmp (si::allocate 'cfun 200 t)
#+gmp (si::allocate 'cfun 1000 t)
(si::allocate 'symbol 100 t)
#+gmp (si::set-gmp-allocate-relocatable t)
(setq si::*notify-gbc* t)
)
Thus I got the following error just at Maxima startup:
GCL (GNU Common Lisp) Version(2.4.0) Mon May 6 15:54:33 CEST 2002
Licensed under GNU Library General Public License
Contains Enhancements by W. Schelter
Loading init.lsp
Unrecoverable error: Can't allocate. Good-bye!.
Aborted
I tried with mid-values:
(progn
(si::allocate-relocatable-pages 10000 t)
(si::allocate 'cons 100000 t)
(si::allocate 'fixnum 5000 t)
#-gmp (si::allocate 'cfun 200 t)
#+gmp (si::allocate 'cfun 1000 t)
(si::allocate 'symbol 100 t)
#+gmp (si::set-gmp-allocate-relocatable t)
(setq si::*notify-gbc* t)
)
I got Maxima running and launched a part of my difficult eigenvalue
calculation...
I'm getting much fewer garbage collection messages than before...
What does all this mean?
Now what can I do?
TNX 1E+06 for your reply! :-)
--
Francesco Poli <frx@firenze.linux.it>
===================================================
"May the Source be with you!" -- Eric S. Raymond