public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Chris Lattner <sabre@nondot.org>
To: Andrew Haley <aph@redhat.com>
Cc: Zack Weinberg <zack@codesourcery.com>, <Richard.Earnshaw@arm.com>,
	Jim Wilson <wilson@specifixinc.com>, <gcc-patches@gcc.gnu.org>
Subject: Re: avoid unnecessary register saves for setjmp
Date: Thu, 27 Nov 2003 09:22:00 -0000	[thread overview]
Message-ID: <Pine.LNX.4.44.0311270312450.28662-100000@nondot.org> (raw)
In-Reply-To: <16325.49098.646932.196135@cuddles.cambridge.redhat.com>

On Thu, 27 Nov 2003, Andrew Haley wrote:

> Chris Lattner writes:
>  > Zack Weinberg said:
>  > > I'm going to take this opportunity to throw in a suggestion I've
>  > > made before, which is that setjmp/longjmp should - always, not
>  > > just when special variants are used - be converted by the front
>  > > end into invocations of the exception-unwinding facility, which
>  > > gives us tons more control.
>
> True.  But the obvious problem with this is that it places a burden on
> small applications (boot ROMs, say) that might only have a single
> setjmp/longjmp.  These would be forced to include the unwinder and all
> its baggage just for that.

Not at all.  For example, somewhat confusingly, the LLVM->C backend
actually turns "stack unwinding" operations into setjmp/longjmp calls.
This is basically equivalent to SJLJ exception handling, with all of it's
problems, but the point is that you don't _NEED_ to include an unwinder.

The entire point of LLVM is to make these implementation decisions as
orthogonal as possible so that the end user can decide how they want EH
implemented.  *shrug*  setjmp/longjmp is just the C form of exception
handling.  Why represent it any differently?

-Chris

-- 
http://llvm.cs.uiuc.edu/
http://www.nondot.org/~sabre/Projects/

  reply	other threads:[~2003-11-27  9:15 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-11-27  9:19 Chris Lattner
2003-11-27  9:21 ` Andrew Haley
2003-11-27  9:22   ` Chris Lattner [this message]
2003-11-27  9:39     ` Andrew Haley
2003-11-27  9:43       ` Chris Lattner
2003-11-27 10:14       ` Zack Weinberg
2003-11-27 10:15         ` Chris Lattner
2003-11-27 11:01           ` Zack Weinberg
2003-11-27 20:28             ` Chris Lattner
2003-11-27 20:51               ` Gabriel Dos Reis
2003-11-27 15:41           ` Jan Vroonhof
2003-11-27 16:23           ` Jan Vroonhof
2003-11-27 10:31         ` Andrew Haley
2003-11-27 10:53           ` Zack Weinberg
     [not found] <5cad8ef043da68f2a3332f00bd6a186a3fc6195b@mail.esmertec.com>
2003-11-27 20:44 ` Chris Lattner
  -- strict thread matches above, loose matches on Subject: below --
2003-11-22  4:13 Richard Kenner
2003-12-01  3:29 ` Jim Wilson
2003-11-21  5:54 Jim Wilson
2003-11-21 18:39 ` Daniel Jacobowitz
2003-11-22  0:22   ` Jim Wilson
2003-11-22  3:57     ` Daniel Jacobowitz
2003-11-22  9:06       ` Jim Wilson
2003-11-22 14:37         ` Richard Earnshaw
2003-11-22 16:33           ` Daniel Jacobowitz
2003-11-27  9:11             ` Zack Weinberg
2003-11-27 17:11               ` Andrew Pinski
2003-11-27 18:23                 ` Zack Weinberg
2003-11-28  5:15                   ` Geert Bosch
2003-11-28 11:14                   ` Richard Earnshaw
2003-11-28 14:02             ` Richard Earnshaw
2003-11-21 20:14 ` Geoff Keating
2003-11-22  0:20   ` Jim Wilson
2003-11-30  9:23   ` Jim Wilson

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

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

  git send-email \
    --in-reply-to=Pine.LNX.4.44.0311270312450.28662-100000@nondot.org \
    --to=sabre@nondot.org \
    --cc=Richard.Earnshaw@arm.com \
    --cc=aph@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=wilson@specifixinc.com \
    --cc=zack@codesourcery.com \
    /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).