bug-gnu-music
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: segfault in grob.cc


From: Jan Nieuwenhuizen
Subject: Re: segfault in grob.cc
Date: 02 Jun 2001 12:11:48 +0200
User-agent: Gnus/5.090003 (Oort Gnus v0.03) Emacs/20.7

John Galbraith <address@hidden> writes:

> This is weird: I only get the crash when lilypond is called from ly2dvi.
> If I call lilypond directly (even if I cut and paste the lilypond command 
> and arguments from a ly2dvi --verbose run) I don't see the crash.  This would
> seem to violate some physical law, unless it was an environmental
> issue.

Hmm.  I've notice something similarly weird before, using python.  I
wrote a proc-time utility in python, and it ran ok, but would make big
commands (typically lilypond on the coriolan) segfault:

See http://appel.lilypond.org/fred/software/

    proc-time.py:
        Prototype in Python. It exhibits mysterious Python SIGSEGV
        problems with larger COMMANDs, python-1.5.2, python-1.6a2, on ppc
        as well as on intel hardware.

Noone I asked could help me with this, so I rewrote it in C, and all
was fine.  I asked about this on the python developers list, but I was
ignored.  It was reproducible too, so there are/were possibly no
violations of physical laws :-)

> Because I can't figure out how to actually run lilypond in the debugger
> and trigger the crash, I have to load a core dump after the fact.
> 
> Unlike my previous post, I now seem to be getting stuck in an infinite
> recursion in Grob::handle_broken_smobs (src=1100160656, criterion=9588)
> at grob.cc:413 that is at least 10,000 levels deep - maybe a lot deeper.

So, you probably hit the ulimit of your stack; which causes the
segfault.  Is it the same under python as directly under bash?

> I am suspicious that a recursion this deep is not normal...

No, it isn't.  So running from python makes LilyPond behave
differently.  What happens if you change ly2dvi so that instead of
LilyPond, it invokes bash:

    os.system ('bash')

At that prompt, you run lilypond, or even gdb lilypond.  Hmm, maybe
python invokes /bin/sh, which might be another shell?

> OK, things are getting pretty strange.  I will post a version of my input.
> But first, I am going to try to trim it down as small as I can get it 
> while still hitting the bug.  I will post when it is ready.

That's ok, but don't put too much effort into trimming the input; you
do it only for yourself, it won't help the debugging anyway.

Jan.

-- 
Jan Nieuwenhuizen <address@hidden> | GNU LilyPond - The music typesetter
http://www.xs4all.nl/~jantien       | http://www.lilypond.org




reply via email to

[Prev in Thread] Current Thread [Next in Thread]