Nikodemus Siivola | 3 Oct 2010 15:17
Gravatar

SBCL User Survey 2010

I've put up an SBCL User Survey.

  http://random-state.net/sbcl-survey-2010.html

This survey is unofficial, but run by me in my capacity as an SBCL
developer. Please take a moment to fill it out, and forward the survey
URL to people who might not otherwise see it.

Summary of results will be published on the survey page.

Thank you,

 -- Nikodemus Siivola

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
Nikodemus Siivola | 5 Oct 2010 10:22
Gravatar

Re: building sbcl with unicode disabled fails

On 24 September 2010 15:44, Alistair Gee <alistair.gee <at> gmail.com> wrote:
> I was curious if SBCL built w/o unicode would be better for
> performance and/or memory usage. However, when I modified my
> customize-target-features.lisp to disable :sb-unicode and compile, I
> get the error trace shown at the end of this message.
>
> This error happens with both sbcl-1.0.42.0 and with the latest sbcl
> from git. The platform is x86 Ubuntu 10.04. If I do not disable
> :sb-unicode, the build succeeds.

Fixed as of 1.0.43.16, thanks to Alastair Bridgewater.

Cheers,

 -- Nikodemus

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
Nikodemus Siivola | 7 Oct 2010 16:47
Gravatar

Re: [Sbcl-devel] Started getting memory fault in core dumps?

On 7 October 2010 14:29, Jeff Cunningham <jeffrey <at> jkcunningham.com> wrote:

(Moving to sbcl-help.)

> Yesterday, I did an "apt-get upgrade" to upgrade a number of libraries that
> were causing problems in some other applications. When I restarted the
> machine the webserver core didn't restart, giving this error message:
>
> Starting servers
> CORRUPTION WARNING in SBCL pid 1129(tid 140737353971456):
> Memory fault at ae03e000 (pc=0x1000b80955, sp=0x7ffff4c726a0)
> The integrity of this image is possibly compromised.
> Continuing with fingers crossed.
> Error: Problem running initialization hook #<FUNCTION
> WEBSERVER::START-THE-SERVERS>:
>   Unhandled memory fault at #x2AAAAE03E000.
>
> Thinking that one of the basic libraries must have been updated, I checked
> out the latest SBCL, rebuilt it, and rebuilt all my fasl's before building
> the webserver core again. But it made no difference.
>
> Now I don't know what to do. I can start emacs and slime, hand compile the
> webserver and it runs just fine. But when I attempt to dump the core then
> start it, I get exactly the same error message above each time.

Any number of things could be causing this.

* Finalizers from before the core is saved trying to release foreign
memory allocated in the previous session. :DONT-SAVE keyword argument
to FINALIZE is for preventing that from happening. Happily, this is
(Continue reading)

Jeff Cunningham | 7 Oct 2010 18:05
Gravatar

[Fwd: Re: [Sbcl-devel] Started getting memory fault in core dumps?]

Forgot to cc the list.


-----Original Message-----
From: Attila Lendvai <attila.lendvai <at> gmail.com>
To: Jeff Cunningham <jeffrey <at> jkcunningham.com>
Subject: Re: [Sbcl-devel] Started getting memory fault in core dumps?
Date: Thu, 7 Oct 2010 15:03:05 +0200

> Any ideas? if you start a swank server, then this might be related: https://bugs.launchpad.net/slime/+bug/444427 although not probable if it only happened after the some upgrades...
Maybe low probability but good hunch, Attila. After browsing through that bug report I tried unsetting the swank *log-output* and it seems to fix it: (defun start-the-servers()   (setf swank:*log-output* nil)   (handler-bind ((serious-condition (lambda (c)                                       (declare (ignore c))                                       (sb-debug:backtrace))))       (rest-of-code))) Now the question is why? Or maybe better, why now? Do I injure my code in any way from just leaving the swank:*log-output* set to NIL there? Regards, Jeff
------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
_______________________________________________
Sbcl-help mailing list
Sbcl-help <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sbcl-help
Jeff Cunningham | 7 Oct 2010 18:06
Gravatar

[Fwd: Re: [Sbcl-devel] Started getting memory fault in core dumps?]

Forgot to cc the list.

-------- Forwarded Message --------
From: Jeff Cunningham <jeffrey <at> jkcunningham.com>
To: Nikodemus Siivola <nikodemus <at> random-state.net>
Subject: Re: [Sbcl-devel] Started getting memory fault in core dumps?
Date: Thu, 07 Oct 2010 11:48:59 -0400

Thank you for the response. I didn't know about sbcl-help so I just subscribed. Comments interspersed below:
--Jeff

-----Original Message-----
From: Nikodemus Siivola <nikodemus <at> random-state.net>

On 7 October 2010 14:29, Jeff Cunningham wrote: (Moving to sbcl-help.) [lengthy explanation snipped...] Any number of things could be causing this.
* Finalizers from before the core is saved trying to release foreign memory allocated in the previous session. :DONT-SAVE keyword argument to FINALIZE is for preventing that from happening. Happily, this is easy to rule out: (setf sb-impl::**finalizer-store** nil) right at the start of START-THE-SERVERS. If it makes the error go away, then it's a stale finalizer and all you need to do is to identify where it comes from, and add :DONT-SAVE to it.
I tried this right away, of course, but it made no difference.
* Something, somewhere, may be eg. grabbing a VECTOR-SAP (the actual memory address of vector) and trying to reuse it for the second invocation. * Something, somewhere, could be allocating foreign memory before the core is saved, and blindly assuming that the foreign memory will remain valid. These two (and related ones) are a bit tricker to identify. The best way is probably to try to identify just when does the memory fault occur -- which is likely to make identifying the underlying problem a lot easier. First try to get a backtrace from the error: (defun start-the-servers () (handler-bind ((serious-condition (lambda (c) (declare (ignore c)) (sb-debug:backtrace)))) (stuff))) with luck, this will set you on the right track.
Here is the backtrace I get when I try to launch the core after building in the backtrace: starting servers CORRUPTION WARNING in SBCL pid 13997(tid 140737353971456): Memory fault at ae03e000 (pc=0x1000b7f955, sp=0x7ffff4c72670) The integrity of this image is possibly compromised. Continuing with fingers crossed. 0: (SB-DEBUG::MAP-BACKTRACE #<CLOSURE (LAMBDA #) {1004E1A009}>)[:EXTERNAL] 1: (BACKTRACE     1152921504606846975     #<SYNONYM-STREAM :SYMBOL *TERMINAL-IO* {10002DD531}>) 2: (SIGNAL #<SB-SYS:MEMORY-FAULT-ERROR {1004E19A81}>)[:EXTERNAL] 3: (ERROR SB-SYS:MEMORY-FAULT-ERROR)[:EXTERNAL] 4: (SB-SYS:MEMORY-FAULT-ERROR) 5: ("foreign function: call_into_lisp") 6: ("foreign function: post_signal_tramp") 7: (SB-IMPL::OUTPUT-BYTES/UTF-8     #<SB-SYS:FD-STREAM for "standard error" {1000349001}>     ";; Swank started at port: "     NIL     0     26) 8: ((LAMBDA (&REST REST))     #<SB-SYS:FD-STREAM for "standard error" {1000349001}>     ";; Swank started at port: "     NIL     0     26) 9: ((LAMBDA (&REST REST))     #<SB-SYS:FD-STREAM for "standard error" {1000349001}>     ";; Swank started at port: "     NIL     0     26)[:OPTIONAL] 10: (SB-IMPL::FD-SOUT      #<SB-SYS:FD-STREAM for "standard error" {1000349001}>      ";; Swank started at port: "      0      26) 11: (SB-IMPL::%WRITE-STRING      ";; Swank started at port: "      #<SB-SYS:FD-STREAM for "standard error" {1000349001}>      0      NIL) 12: ((LAMBDA          (STREAM           &OPTIONAL           (#:FORMAT-ARG1072            (ERROR ??? :COMPLAINT "required argument missing" :CONTROL-STRING                   "~&;; Swank started at port: ~D.~%" :OFFSET 29))           &REST SB-FORMAT::ARGS))      #<SB-SYS:FD-STREAM for "standard error" {1000349001}>      4005) 13: (FORMAT      #<SB-SYS:FD-STREAM for "standard error" {1000349001}>      #<FUNCTION (LAMBDA #) {100207E6A9}>)[:EXTERNAL] 14: (SWANK::SIMPLE-ANNOUNCE-FUNCTION 4005) 15: (SWANK::SETUP-SERVER      4005      #<FUNCTION SWANK::SIMPLE-ANNOUNCE-FUNCTION>      :SPAWN      T      "iso-latin-1-unix") 16: (WEBSERVER::START-THE-SERVERS) 17: (SB-INT:CALL-HOOKS      "initialization"      (#<FUNCTION WEBSERVER::START-THE-SERVERS>))[:EXTERNAL] 18: ((LABELS SB-IMPL::RESTART-LISP)) Error: Problem running initialization hook #<FUNCTION WEBSERVER::START-THE-SERVERS>:   Unhandled memory fault at #x2AAAAE03E000. It looks like it has something to do with a foreign function call. Unfortunately, there are a number of these to track down. Regards, Jeff
------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
_______________________________________________
Sbcl-help mailing list
Sbcl-help <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sbcl-help
Manfred Lotz | 7 Oct 2010 18:35
Picon
Favicon

How to suppress messages when sbcl as script?

Hi there,
I'm pretty new to Lisp and thus to sbcl.

I wrote a small script starting like follows:

<---------------------------------snip---------------->   
#! /usr/bin/sbcl --script

(require 'asdf)
(require 'local-time)
<---------------------------------snap---------------->                          

Implicitly local-time requires cl-fad which requires sb-grovel,
sb-posix etc.

The following messages show up:
;loading system
definition<---------------------------------snap---------------->
from /home/manfred/cl/cl-fad-0.6.3/cl-fad.asd into ; #<PACKAGE
"ASDF0"> ; registering #<SYSTEM #:CL-FAD> as CL-FAD ; loading system
definition from /usr/lib/sbcl/sb-posix/sb-posix.asd into ; #<PACKAGE
"ASDF0"> ; loading system definition
from /usr/lib/sbcl/sb-grovel/sb-grovel.asd into ; #<PACKAGE "ASDF1">
; registering #<SYSTEM SB-GROVEL> as SB-GROVEL
; registering #<SYSTEM SB-POSIX> as SB-POSIX
; registering #<SYSTEM SB-POSIX-TESTS> as SB-POSIX-TESTS

Is there a way to suppress those messages?

--

-- 
Thanks,
Manfred

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
Stas Boukarev | 7 Oct 2010 18:50
Picon

Re: How to suppress messages when sbcl as script?

Manfred Lotz <manfred.lotz <at> arcor.de> writes:

> Hi there,
> I'm pretty new to Lisp and thus to sbcl.
>
> I wrote a small script starting like follows:
>
> <---------------------------------snip---------------->   
> #! /usr/bin/sbcl --script
>
> (require 'asdf)
> (require 'local-time)
> <---------------------------------snap---------------->                          
>
> Implicitly local-time requires cl-fad which requires sb-grovel,
> sb-posix etc.
>
>
> The following messages show up:
> ;loading system
> definition<---------------------------------snap---------------->
> from /home/manfred/cl/cl-fad-0.6.3/cl-fad.asd into ; #<PACKAGE
> "ASDF0"> ; registering #<SYSTEM #:CL-FAD> as CL-FAD ; loading system
> definition from /usr/lib/sbcl/sb-posix/sb-posix.asd into ; #<PACKAGE
> "ASDF0"> ; loading system definition
> from /usr/lib/sbcl/sb-grovel/sb-grovel.asd into ; #<PACKAGE "ASDF1">
> ; registering #<SYSTEM SB-GROVEL> as SB-GROVEL
> ; registering #<SYSTEM SB-POSIX> as SB-POSIX
> ; registering #<SYSTEM SB-POSIX-TESTS> as SB-POSIX-TESTS
>
>
> Is there a way to suppress those messages?
Try this:

(require 'asdf)
(setf *load-verbose* nil
      *load-print* nil
      asdf:*asdf-verbose* nil)
(require 'local-time)

This will only prevent of messages during LOAD, not COMPILE-FILE. In the
latter case you can nullify *compile-print*  and *compile-verbose*, but
you'll have to muffle all the style-warnings and notes produced by the
compiler. The better thing might be to use a saved image.

--

-- 
With Best Regards, Stas.

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
Nikodemus Siivola | 7 Oct 2010 18:53
Gravatar

Re: How to suppress messages when sbcl as script?

On 7 October 2010 19:35, Manfred Lotz <manfred.lotz <at> arcor.de> wrote:

> <---------------------------------snip---------------->
> #! /usr/bin/sbcl --script
>
> (require 'asdf)
> (require 'local-time)
> <---------------------------------snap---------------->

> The following messages show up:
> ;loading system
> definition<---------------------------------snap---------------->
> from /home/manfred/cl/cl-fad-0.6.3/cl-fad.asd into ; #<PACKAGE
> "ASDF0"> ; registering #<SYSTEM #:CL-FAD> as CL-FAD ; loading system
> definition from /usr/lib/sbcl/sb-posix/sb-posix.asd into ; #<PACKAGE
> "ASDF0"> ; loading system definition
> from /usr/lib/sbcl/sb-grovel/sb-grovel.asd into ; #<PACKAGE "ASDF1">
> ; registering #<SYSTEM SB-GROVEL> as SB-GROVEL
> ; registering #<SYSTEM SB-POSIX> as SB-POSIX
> ; registering #<SYSTEM SB-POSIX-TESTS> as SB-POSIX-TESTS
>
> Is there a way to suppress those messages?

Here's a nice big general-purpose hammer:

(let* ((nada (make-broadcast-stream))
       (*standard-output* nada)
       (*error-output* nada))
   (require :asdf)
   (require :local-time))

Cheers,

 -- Nikodemus

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
Manfred Lotz | 7 Oct 2010 19:12
Picon
Favicon

Re: How to suppress messages when sbcl as script?

On Thu, 07 Oct 2010 20:50:12 +0400
Stas Boukarev <stassats <at> gmail.com> wrote:

> Manfred Lotz <manfred.lotz <at> arcor.de> writes:
> 

> > The following messages show up:
> > ;loading system
> > definition<---------------------------------snap---------------->
> > from /home/manfred/cl/cl-fad-0.6.3/cl-fad.asd into ; #<PACKAGE
> > "ASDF0"> ; registering #<SYSTEM #:CL-FAD> as CL-FAD ; loading system
> > definition from /usr/lib/sbcl/sb-posix/sb-posix.asd into ; #<PACKAGE
> > "ASDF0"> ; loading system definition
> > from /usr/lib/sbcl/sb-grovel/sb-grovel.asd into ; #<PACKAGE "ASDF1">
> > ; registering #<SYSTEM SB-GROVEL> as SB-GROVEL
> > ; registering #<SYSTEM SB-POSIX> as SB-POSIX
> > ; registering #<SYSTEM SB-POSIX-TESTS> as SB-POSIX-TESTS
> >
> >
> > Is there a way to suppress those messages?
> Try this:
> 
> (require 'asdf)
> (setf *load-verbose* nil
>       *load-print* nil
>       asdf:*asdf-verbose* nil)
> (require 'local-time)
> 
> This will only prevent of messages during LOAD, not COMPILE-FILE. In
> the latter case you can nullify *compile-print*  and
> *compile-verbose*, but you'll have to muffle all the style-warnings
> and notes produced by the compiler. The better thing might be to use
> a saved image.
> 

OK, but compile-file will be done only once normally. I can live with
it. Works fine.

Thanks a lot for your help. 

--

-- 
Manfred

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
Teemu Likonen | 7 Oct 2010 19:18
Picon
Picon
Favicon

Re: How to suppress messages when sbcl as script?

* 2010-10-07 19:53 (+0300), Nikodemus Siivola wrote:

> Here's a nice big general-purpose hammer:
>
> (let* ((nada (make-broadcast-stream))
>        (*standard-output* nada)
>        (*error-output* nada))
>    (require :asdf)
>    (require :local-time))

I wonder if the broadcast stream should be closed (?). Anyway, I once
wrote this:

    (defmacro with-silence (&body body)
      (let ((stream (gensym)))
        `(let* ((,stream (make-broadcast-stream))
                (*standard-output* ,stream)
                (*error-output* ,stream)
                (*trace-output* ,stream))
           (unwind-protect (progn , <at> body)
             (close ,stream)))))

------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb

Gmane