unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Keith Owens <kaos@ocs.com.au>
Cc: linux-ia64@vger.kernel.org, guile-devel@gnu.org
Subject: Re: Problem with Guile on ia64 (possibly "getcontext" related)
Date: Sun, 16 Jul 2006 12:54:51 +1000	[thread overview]
Message-ID: <16307.1153018491@ocs3.ocs.com.au> (raw)
In-Reply-To: Your message of "Sat, 15 Jul 2006 15:24:31 MST." <87ac7ajylc.fsf@raven.defaultvalue.org>

Rob Browning (on Sat, 15 Jul 2006 15:24:31 -0700) wrote:
>
>Guile 1.6.8 is crashing on ia64 with an illegal instruction whenever
>it tries to execute call-with-current-continuation.  For those who
>don't know, call-with-current-continuation captures the current state
>of the computation; it's a language feature somewhat similar to
>setjmp.
>
>The crash seems to be right around an asm "getcontext" call, and after
>looking around, I found these two links:
>
>  http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/144939
>  http://lists.freebsd.org/pipermail/freebsd-sparc64/2006-January/003739.html
>
>They appear claim that adding a dummy (non-executed) setjmp just after
>the getcontext call will fix the problem because gcc recognizes
>setjmp, but not getcontext, and makes appropriate arrangements.
>
>So I tried adding a dummy setjmp just after the getcontext call, and
>that does fix the problem.
>
>However, even though this worked, I'd still prefer to have a better
>idea that this is the right fix before adopting it.  Is that likely?
>>
>The relevant function is scm_make_continuation which you can find
>here:
>
>  http://cvs.savannah.gnu.org/viewcvs/guile/guile-core/libguile/continuations.c?rev=1.38.2.7&root=guile&only_with_tag=branch_release-1-6&view=markup

Wild guess, based on no data.  Add '__attribute__ ((returns_twice))' to
the definition of ia64_getcontext.  That should remove the need to use
setjmp.

-
To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


  reply	other threads:[~2006-07-16  2:54 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-15 22:24 Problem with Guile on ia64 (possibly "getcontext" related) Rob Browning
2006-07-16  2:54 ` Keith Owens [this message]
2006-07-19  1:40   ` Rob Browning
2006-07-19  2:11     ` Keith Owens

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=16307.1153018491@ocs3.ocs.com.au \
    --to=kaos@ocs.com.au \
    --cc=guile-devel@gnu.org \
    --cc=linux-ia64@vger.kernel.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).