graham | 15 Jul 2006 12:15

Disabling STYLE-WARNING when redefining a function?

I have a feeling this is a FAQ but the usual Google searches didn't
turn anything up.

Is there any way to stop SBCL warning me when I redefine a function?
To me it is just unwanted noise cluttering up the REPL.

I already know I'm redefining functions.  One of my reasons for using
Lisp in the first place is that I can do this without having to relink
and restart my entire executable.

If the warnings are SBCL's way of telling me that I'm preventing it
from performing some optimization or other, I want to tell it that I
don't care unless I'm compiling with (optimize (speed 3)).

Graham

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
Benjamin Lambert | 18 Jul 2006 22:30
Picon
Favicon

SB-SPROF report documentation??

Is there any documentation available that describes what the report  
from sb-sprof means?  The main thing I'm confused about is what are  
the differences among "self", "cumul", and "total".  But also I  
wonder exactly what the profiler samples.  Does it just sample the  
function that is currently executing or does it sample the entire  
call stack?

Thanks,
Ben

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Peter Hertmuller | 18 Jul 2006 23:09
Picon

Argh! gc_find_free_space failed

I'm having problems running sbcl. I'll try to be as concise as possible:

I start SBCL (via SLIME in a terminal), start my program, and after sometime, SBCL crashes, with a message like this:

Argh! gc_find_free_space failed (first_page), nbytes=8.
Gen Boxed Unboxed LB LUB !move Alloc Waste Trig WP GCs Mem-age
0: 128844 1 27 0 13 527686944 172768 2050840 0 1 0.0000
1: 291 6 0 0 269 1044752 171760 2059000 22 1 10.4453
2: 1217 565 71 49 239 7655936 134656 9492648 1037 1 1.9623
3: 0 0 0 0 0 0 0 2000000 0 0 0.0000
4: 0 0 0 0 0 0 0 2000000 0 0 0.0000
5: 0 0 0 0 0 0 0 2000000 0 0 0.0000
6: 0 0 0 0 0 0 0 0 0 0 0.0000
Total bytes allocatedS6387632

Googling for an answer didn't work at all. I'm using the latest CVS SBCL version, under Debian (kernel 2.6) in a Xeon Machine with 2GB RAM.
Do you know what's the reason of this error? Any solutions?
Thanks in advance for your help
Peter
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Sbcl-help mailing list
Sbcl-help <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sbcl-help
Juho Snellman | 19 Jul 2006 01:23
Picon
Picon
Favicon

Re: SB-SPROF report documentation??


Benjamin Lambert <benlambert <at> cmu.edu> writes:
> Is there any documentation available that describes what the report  
> from sb-sprof means? The main thing I'm confused about is what are  
> the differences among "self", "cumul", and "total".

No, it's not documented. One reason is that I keep wondering whether
"cumul" and "total" should be switched around, which we really
shouldn't do once they've been formally documented.

"self" is time spent executing the function itself. "cumul" is the
time spent in the function or functions called from it. "total" is the
sum of the "self"s of this function, and all functions above it in the
list.

Or maybe "cumul" and "total" were the other way around. I
forget... ;-) It should be obvious from the report which is which.

> But also I wonder exactly what the profiler samples.  Does it just
> sample the function that is currently executing or does it sample
> the entire call stack?

Neither. By default it samples eight levels of the call stack on x86
and x86-64, and two levels on other platforms.

--

-- 
Juho Snellman

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Juho Snellman | 19 Jul 2006 01:30
Picon
Picon
Favicon

Re: Argh! gc_find_free_space failed

"Peter Hertmuller" <phertmuller <at> gmail.com> writes:

> I'm having problems running sbcl. I'll try to be as concise as possible:
> 
> I start SBCL (via SLIME in a terminal), start my program, and after
> sometime, SBCL crashes, with a message like this:
> 
> Argh! gc_find_free_space failed (first_page), nbytes=8.

This means that you've run out of memory (a maximum of 512MB can be
allocated on Linux/x86 for and sbcl compiled with the default
settings).

>     Gen Boxed Unboxed LB   LUB  !move  Alloc  Waste   Trig    WP  GCs Mem-age
>    0: 128844     1    27     0    13 527686944 172768  2050840    0   1  0.0000

And this says that practically all of the memory was used by newly
allocated small objects. Which really shouldn't be happening: while
these objects are being allocated, garbage collections should be
triggered, which move some of them from the 0th generation to older
ones.

Is your application maybe disabling the GC or alternately disabling
interrupts?

--

-- 
Juho Snellman

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Peter Hertmuller | 19 Jul 2006 10:26
Picon

Re: Argh! gc_find_free_space failed


>     Gen Boxed Unboxed LB   LUB  !move  Alloc  Waste   Trig    WP  GCs Mem-age
>    0: 128844     1    27     0    13 527686944 172768  2050840    0   1  0.0000

And this says that practically all of the memory was used by newly
allocated small objects. Which really shouldn't be happening: while
these objects are being allocated, garbage collections should be
triggered, which move some of them from the 0th generation to older
ones.

 

Is your application maybe disabling the GC or alternately disabling
interrupts?

No, the application does not disable the GC or interrupts. I've been trying to force the call to the gc by means of (sb-ext:gc). It didn't work.

I've downloaded the source code from CVS, and I've tried to increase the dynamic memory space changing the parms.lisp file under /src/compiler/x86/ folder (I've followed the recomedations made in an email sometime ago for an X86-64 machine). My machine has 2GB of RAM, so I've increased the memory figures up to 1GB (changing the dynamic-space-end from 512MB (x29000000) up to 1GB (x49000000), considering that the dynamic-space-starts at x09000000. This didn't work as well. I've got an error when the compiler fires the make-target-2.sh. Appears the error:

&lt;!-- <at> page { size: 21cm 29.7cm; margin: 2cm } P { margin-bottom: 0.21cm } --&gt;

//doing warm init

mmap: wanted 1073741824 bytes at 0x9000000, actually mapped at 0x40182000

ensure_space: failed to validate 1073741824 bytes at 0x09000000

(hint: Try "ulimit -a"; maybe you should increase memory limits.)


Typing "ulimit -a" appears the following information (in a Xeon machine with 2GB RAM)
&lt;!-- <at> page { size: 21cm 29.7cm; margin: 2cm } P { margin-bottom: 0.21cm } --&gt;

core file size (blocks, -c) 0
data seg size (kbytes, -d) unlimited
file size (blocks, -f) unlimited
max locked memory (kbytes, -l) unlimited
max memory size (kbytes, -m) unlimited
open files (-n) 1024
pipe size (512 bytes, -p) 8
stack size (kbytes, -s) 8192
cpu time (seconds, -t) unlimited
max user processes (-u) unlimited
virtual memory (kbytes, -v) unlimited

The parms.lisp file is not enough documented and I'm not able to get a successful compilation.

Do you have any ideas about what I have to do to increase the dynamic space?

Peter




--
Juho Snellman


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Sbcl-help mailing list
Sbcl-help <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sbcl-help
Peter Hertmuller | 19 Jul 2006 13:00
Picon

Re: Argh! gc_find_free_space failed (re-formulated)

I don't think that my previous email was enough clear. My question is: What I have to do to get more dynamic space available?  Is it just needed to edit the parms.lisp file, changing the dynamic-space-end up to a higher value? Has anybody already tried that (increase the dynamic space up to 1GB, changing the defaults options) with a successful compilation results?
Cheers

On 7/19/06, Peter Hertmuller <phertmuller <at> gmail.com> wrote:

>     Gen Boxed Unboxed LB   LUB  !move  Alloc  Waste   Trig    WP  GCs Mem-age
>    0: 128844     1    27     0    13 527686944 172768  2050840    0   1  0.0000

And this says that practically all of the memory was used by newly
allocated small objects. Which really shouldn't be happening: while
these objects are being allocated, garbage collections should be
triggered, which move some of them from the 0th generation to older
ones.

 

Is your application maybe disabling the GC or alternately disabling
interrupts?

No, the application does not disable the GC or interrupts. I've been trying to force the call to the gc by means of (sb-ext:gc). It didn't work.

I've downloaded the source code from CVS, and I've tried to increase the dynamic memory space changing the parms.lisp file under /src/compiler/x86/ folder (I've followed the recomedations made in an email sometime ago for an X86-64 machine). My machine has 2GB of RAM, so I've increased the memory figures up to 1GB (changing the dynamic-space-end from 512MB (x29000000) up to 1GB (x49000000), considering that the dynamic-space-starts at x09000000. This didn't work as well. I've got an error when the compiler fires the make-target-2.sh. Appears the error:

//doing warm init

mmap: wanted 1073741824 bytes at 0x9000000, actually mapped at 0x40182000

ensure_space: failed to validate 1073741824 bytes at 0x09000000

(hint: Try "ulimit -a"; maybe you should increase memory limits.)


Typing "ulimit -a" appears the following information (in a Xeon machine with 2GB RAM)

core file size (blocks, -c) 0
data seg size (kbytes, -d) unlimited
file size (blocks, -f) unlimited
max locked memory (kbytes, -l) unlimited
max memory size (kbytes, -m) unlimited
open files (-n) 1024
pipe size (512 bytes, -p) 8
stack size (kbytes, -s) 8192
cpu time (seconds, -t) unlimited
max user processes (-u) unlimited
virtual memory (kbytes, -v) unlimited

The parms.lisp file is not enough documented and I'm not able to get a successful compilation.

Do you have any ideas about what I have to do to increase the dynamic space?

Peter




--
Juho Snellman



-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Sbcl-help mailing list
Sbcl-help <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sbcl-help
Juho Snellman | 19 Jul 2006 23:52
Picon
Picon
Favicon

Re: Argh! gc_find_free_space failed

"Peter Hertmuller" <phertmuller <at> gmail.com> writes:

> > >     Gen Boxed Unboxed LB   LUB  !move  Alloc  Waste   Trig    WP  GCs
> > Mem-age
> > >    0: 128844     1    27     0    13 527686944 172768  2050840    0
> > 1  0.0000

Ok, we got another similar report with a test-case. This was
apparently a regression on x86 since 0.9.14, and should be fixed as of
0.9.14.27. Can you check that this version also fixes your program?

> I've downloaded the source code from CVS, and I've tried to increase the
> dynamic memory space changing the parms.lisp file under /src/compiler/x86/
> folder (I've followed the recomedations made in an email sometime ago for an
> X86-64 machine). My machine has 2GB of RAM,

The amount of physical memory you have in your computer doesn't matter,
the issue is the available address space.

> so I've increased the memory
> figures up to 1GB (changing the dynamic-space-end from 512MB (x29000000) up
> to 1GB (x49000000), considering that the dynamic-space-starts at x09000000.
> This didn't work as well. I've got an error when the compiler fires the
> make-target-2.sh. Appears the error:
> 
>  //doing warm init
> 
> mmap: wanted 1073741824 bytes at 0x9000000, actually mapped at 0x40182000
> 
> ensure_space: failed to validate 1073741824 bytes at 0x09000000

There wasn't a gigabyte of free address space available starting at
0x900000. If that happens, you need to move the start of the dynamic
space elsewhere. You might find src/runtime/trymap.c to be useful for
determining where the reserved memory areas are on your system.

--

-- 
Juho Snellman

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Ben Lambert | 20 Jul 2006 20:55
Picon

Re: SB-SPROF report documentation??


On Jul 18, 2006, at 7:23 PM, Juho Snellman wrote:

But also I wonder exactly what the profiler samples.  Does it just

sample the function that is currently executing or does it sample

the entire call stack?


Neither. By default it samples eight levels of the call stack on x86

and x86-64, and two levels on other platforms.


Thanks Juho.  Just one more question, if 8 and 2 are the defaults for this, is it possible to increase them?  Or are there hard limitations on how far back in the stack it's possible to look when sampling?

Ben
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Sbcl-help mailing list
Sbcl-help <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sbcl-help
Juho Snellman | 20 Jul 2006 21:22
Picon
Picon
Favicon

Re: SB-SPROF report documentation??

Ben Lambert <belambert <at> mac.com> writes:

> On Jul 18, 2006, at 7:23 PM, Juho Snellman wrote:
> 
> >> But also I wonder exactly what the profiler samples.  Does it just
> >> sample the function that is currently executing or does it sample
> >> the entire call stack?
> >
> > Neither. By default it samples eight levels of the call stack on x86
> > and x86-64, and two levels on other platforms.
> 
> Thanks Juho.  Just one more question, if 8 and 2 are the defaults for
> this, is it possible to increase them?  Or are there hard limitations
> on how far back in the stack it's possible to look when sampling?

You can increase it on x86* by increasing the value of +sample-size+
and recompiling sb-sprof. There's no hard limit, but profiling will
cause bigger slowdowns with higher depths. For non-x86oid platforms
going beyond 2 levels would require some coding.

--

-- 
Juho Snellman

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

Gmane