unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Miroslav Lichvar <mlichvar@redhat.com>
To: guile-devel@gnu.org
Subject: Re: `scm_c_read ()' and `swap_buffer' trick harmful
Date: Sat, 20 Dec 2008 00:32:57 +0100	[thread overview]
Message-ID: <20081219233256.GA32465@localhost> (raw)
In-Reply-To: <87myerdia0.fsf@gnu.org>

On Fri, Dec 19, 2008 at 09:25:27PM +0100, Ludovic Courtès wrote:
> > It seems that the optimizations broke lilypond, it's now failing with
> > this message:
> >
> > ports.c:978: scm_fill_input: Assertion `pt->read_pos == pt->read_end' failed.
> 
> Ouch!
> 
> > A bug report is here:
> > https://bugzilla.redhat.com/show_bug.cgi?id=477007
> 
> Can you get a full C backtrace?

Here it is, let me know if you need anything else.

(gdb) bt
#0  0x00007f6b232b6f05 in raise () from /lib64/libc.so.6
#1  0x00007f6b232b8a73 in abort () from /lib64/libc.so.6
#2  0x00007f6b232afef9 in __assert_fail () from /lib64/libc.so.6
#3  0x0000000000d52b92 in scm_fill_input (port=0x7f6b1d4b7420) at ports.c:978
#4  0x0000000000638b66 in internal_ly_parse_scm (ps=0x7fff2b827bc0) at parse-scm.cc:43
#5  0x0000000000638d38 in ly_parse_scm (
    s=0x1fe907c "(if (and #t (defined? 'set-debug-cell-accesses!))\n  (set-debug-cell-accesses! 5000))\n\n\\version \"2.10.0\"\n\n\\include \"declarations-init.ly\"\n\n\n#(ly:set-option 'old-relative #f)\n#(define toplevel-scores (l"..., n=0x7fff2b827dcc, i=
      {start_ = 0x1fe907c "(if (and #t (defined? 'set-debug-cell-accesses!))\n  (set-debug-cell-accesses! 5000))\n\n\\version \"2.10.0\"\n\n\\include \"declarations-init.ly\"\n\n\n#(ly:set-option 'old-relative #f)\n#(define toplevel-scores (l"..., end_ = 0x1fe907c "(if (and #t (defined? 'set-debug-cell-accesses!))\n  (set-debug-cell-accesses! 5000))\n\n\\version \"2.10.0\"\n\n\\include \"declarations-init.ly\"\n\n\n#(ly:set-option 'old-relative #f)\n#(define toplevel-scores (l"..., source_file_ = 0x208cdd0}, safe=false, parser=0x2083ee0)
    at parse-scm.cc:131
#6  0x0000000000751c0b in Lily_lexer::yylex (this=0x1fc2d40) at lexer.ll:340
#7  0x000000000075506e in yylex (s=0x7fff2b82a4a0, loc=0x7fff2b82a480, v=0x2083ee0) at parser.yy:2696
#8  0x000000000075680f in yyparse (my_lily_parser=0x2083ee0) at out/parser.cc:2612
#9  0x0000000000762d31 in Lily_parser::do_yyparse (this=0x2083ee0) at parser.yy:2476
#10 0x00000000005a3278 in Lily_parser::parse_file (this=0x2083ee0, init=
        {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<__gnu_cxx::new_allocator<char>> = {<No data fields>}, <No data fields>}, _M_p = 0x2000f38 "init.ly"}}, name=
        {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<__gnu_cxx::new_allocator<char>> = {<No data fields>}, <No data fields>}, _M_p = 0x2083a18 "/tmp/lilypond-2.11.65/ly/generate-documentation.ly"}}, out_name=
        {static npos = 18446744073709551615, _M_dataplus = {<std::allocator<char>> = {<__gnu_cxx::new_allocator<char>> = {<No data fields>}, <No data fields>}, _M_p = 0x2040a18 "generate-documentation"}})
    at lily-parser.cc:114
#11 0x00000000005a1118 in ly_parse_file (name=0x7f6b21d1b260) at lily-parser-scheme.cc:124
#12 0x0000000000d1d2b4 in deval (x=0x404, env=0x7f6b1d4b57b0) at eval.c:4232
#13 0x0000000000d1f512 in scm_dapply (proc=0x7f6b1d4b58c0, arg1=0x404, args=0x7f6b1d4b57b0) at eval.c:5012
#14 0x0000000000d13e73 in scm_apply (proc=0x7f6b1d4b58a0, arg1=0x404, args=0x404) at eval.c:4811
#15 0x0000000000d13bb8 in scm_call_0 (proc=0x7f6b1d4b58a0) at eval.c:4666
#16 0x0000000000d826b1 in scm_body_thunk (body_data=0x7fff2b82d100) at throw.c:355
#17 0x0000000000d821c9 in scm_c_catch (tag=0x7f6b21d66860, body=0xd82690 <scm_body_thunk>, 
    body_data=0x7fff2b82d100, handler=0xd826b3 <scm_handle_by_proc>, handler_data=0x7fff2b82d0e8, 
    pre_unwind_handler=0, pre_unwind_handler_data=0x7fff2b82d0e0) at throw.c:203
#18 0x0000000000d82b72 in scm_catch_with_pre_unwind_handler (key=0x7f6b21d66860, thunk=0x7f6b1d4b58a0, 
    handler=0x7f6b1d4b5830, pre_unwind_handler=0x204) at throw.c:587
#19 0x0000000000d3438c in scm_gsubr_apply (args=0x404) at gsubr.c:223
#20 0x0000000000d1efcc in scm_dapply (proc=0x7f6b21fb84f0, arg1=0x7f6b229ab8e0, args=0x7f6b1d4b5800)
    at eval.c:4930
#21 0x0000000000d1dda2 in deval (x=0x7f6b20320f90, env=0x7f6b1d4b5950) at eval.c:4378
#22 0x0000000000d17c02 in deval (x=0x7f6b20324010, env=0x7f6b1d4b5a60) at eval.c:3397
#23 0x0000000000d1f512 in scm_dapply (proc=0x7f6b1d4b3db0, arg1=0x404, args=0x7f6b1d4b3d20) at eval.c:5012
#24 0x0000000000d13e73 in scm_apply (proc=0x7f6b1d4b3d90, arg1=0x7f6b21d1b260, args=0x7f6b229aa700)
    at eval.c:4811
#25 0x0000000000d13be2 in scm_call_1 (proc=0x7f6b1d4b3d90, arg1=0x7f6b21d1b260) at eval.c:4672
#26 0x00007f6b20ad295b in scm_srfi1_for_each (proc=0x7f6b1d4b3d90, arg1=0x7f6b20283060, args=0x404)
    at srfi-1.c:1516
#27 0x0000000000d1dca3 in deval (x=0x404, env=0x7f6b20282930) at eval.c:4367
#28 0x0000000000d17c02 in deval (x=0x7f6b20323790, env=0x7f6b20282930) at eval.c:3397
#29 0x0000000000d19c96 in deval (x=0x7f6b20282b60, env=0x7f6b20282fa0) at eval.c:3648
#30 0x0000000000d1f512 in scm_dapply (proc=0x7f6b203290f0, arg1=0x404, args=0x7f6b20282fa0) at eval.c:5012
#31 0x0000000000d13e73 in scm_apply (proc=0x7f6b20328f40, arg1=0x7f6b20283060, args=0x7f6b229aa700)
    at eval.c:4811
#32 0x0000000000d13be2 in scm_call_1 (proc=0x7f6b20328f40, arg1=0x7f6b20283060) at eval.c:4672
#33 0x00000000005bb2a1 in main_with_guile () at main.cc:426
#34 0x0000000000d38aee in invoke_main_func (body_data=0x7fff2b830890) at init.c:367
#35 0x0000000000cfc9ea in c_body (d=0x7fff2b8307d0) at continuations.c:349
#36 0x0000000000d821c9 in scm_c_catch (tag=0x104, body=0xcfc9c5 <c_body>, body_data=0x7fff2b8307d0, 
    handler=0xcfc9fc <c_handler>, handler_data=0x7fff2b8307d0, 
    pre_unwind_handler=0xd82a02 <scm_handle_by_message_noexit>, pre_unwind_handler_data=0x0) at throw.c:203
#37 0x0000000000cfc98e in scm_i_with_continuation_barrier (body=0xcfc9c5 <c_body>, 
    body_data=0x7fff2b8307d0, handler=0xcfc9fc <c_handler>, handler_data=0x7fff2b8307d0, 
    pre_unwind_handler=0xd82a02 <scm_handle_by_message_noexit>, pre_unwind_handler_data=0x0)
    at continuations.c:325
#38 0x0000000000cfca72 in scm_c_with_continuation_barrier (func=0xd38aa1 <invoke_main_func>, 
    data=0x7fff2b830890) at continuations.c:367
#39 0x0000000000d8035d in scm_i_with_guile_and_parent (func=0xd38aa1 <invoke_main_func>, 
    data=0x7fff2b830890, parent=0x0) at threads.c:726
#40 0x0000000000d8032a in scm_with_guile (func=0xd38aa1 <invoke_main_func>, data=0x7fff2b830890)
    at threads.c:714
#41 0x0000000000d38a82 in scm_boot_guile (argc=3, argv=0x7fff2b830a08, 
    main_func=0x5bad7a <main_with_guile>, closure=0x0) at init.c:350
#42 0x00000000005bad6c in main (argc=3, argv=0x7fff2b830a08, envp=0x7fff2b830a28) at main.cc:622


-- 
Miroslav Lichvar




  reply	other threads:[~2008-12-19 23:32 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-15 20:04 `scm_c_read ()' and `swap_buffer' trick harmful Ludovic Courtès
2008-11-20 13:22 ` Neil Jerram
2008-11-20 13:48   ` Ludovic Courtès
2008-11-20 22:25     ` Neil Jerram
2008-11-21 17:05       ` Ludovic Courtès
2008-11-22 15:02         ` Ludovic Courtès
2008-11-23 23:08           ` Neil Jerram
2008-11-23 22:30         ` Neil Jerram
2008-12-19 14:44           ` Miroslav Lichvar
2008-12-19 20:25             ` Ludovic Courtès
2008-12-19 23:32               ` Miroslav Lichvar [this message]
2008-12-20 17:10                 ` Ludovic Courtès
2008-12-20 19:11                   ` Miroslav Lichvar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20081219233256.GA32465@localhost \
    --to=mlichvar@redhat.com \
    --cc=guile-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).