public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Kai Tietz <ktietz70@googlemail.com>
To: xunxun <xunxun1982@gmail.com>
Cc: jojelino <jojelino@gmail.com>, gcc@gcc.gnu.org, qemu-devel@nongnu.org
Subject: Re: gcc auto-omit-frame-pointer vs msvc longjmp
Date: Sat, 22 Oct 2011 14:21:00 -0000	[thread overview]
Message-ID: <CAEwic4ZrFOHq8yn5vM+cNeGet4QpvhumTEydg+BznjT5FMzzdg@mail.gmail.com> (raw)
In-Reply-To: <4EA252C9.9060900@gmail.com>

2011/10/22 xunxun <xunxun1982@gmail.com>:
> 于 2011/10/22 13:13, xunxun 写道:
>>
>> Hi, all
>>
>>    It seems that gcc's auto-omit-frame-pointer has other problems.
>>
>>    The example is from mingw bug tracker:
>> http://sourceforge.net/tracker/?func=detail&aid=3426555&group_id=2435&atid=102435
>>
>>    g++ -O3 main.cpp       running will crash.
>>    g++ -O2 main.cpp       running no crash.
>>    g++ -O3 -fno-omit-frame-pointer    running no crash.
>>
>>    I don't know in the end which optimize option defaultly contains this
>> switch "-fomit-frame-pointer" on i686-pc-mingw32 or x86_64-w64-mingw32?
>>
> It crashes on Win7.

Well, this issue isn't related to this thread.  It is more related to
dw2 and SjLj used.  For toolchains using dw2 exception mechanism, you
will see this crash.  By using SjLj you won't (thanks for checking
this).
This shows indeed my strong concerns about dw2 exception mechanism for
32-bit Windows targets.  The implementation depends too much on
code-patterns and is therefore a bit inconsitant.  Secondly it causes
harm if you try to throw exceptions over VC generated code.  So I
would strongly recomment to use the slower, but more reliable SjLj
throwing mechanism on Windows 32-bit.

Regards,
Kai

  reply	other threads:[~2011-10-22 11:20 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <4E9BB180.6080506@mc.net>
     [not found] ` <4E9C0497.2000605@siriusit.co.uk>
     [not found]   ` <4E9C3703.3040109@mc.net>
2011-10-17 21:20     ` Richard Henderson
2011-10-17 21:32       ` [Qemu-devel] " Blue Swirl
2011-10-17 22:23         ` Richard Henderson
2011-10-17 22:56       ` Bob Breuer
2011-10-18  2:06         ` Kai Tietz
2011-10-18  4:20           ` Bob Breuer
2011-10-18  4:22             ` Kai Tietz
2011-10-20  3:26               ` Bob Breuer
2011-10-20  4:18                 ` Richard Henderson
2011-10-20  6:08                 ` xunxun
2011-10-20 15:01                   ` Kai Tietz
2011-10-20 17:12                     ` Kai Tietz
2011-10-21 22:47                       ` jojelino
2011-10-22 12:30                         ` xunxun
2011-10-22 13:18                           ` xunxun
2011-10-22 14:21                             ` Kai Tietz [this message]
2011-10-22 22:59                       ` asmwarrior
2011-10-24 20:05                       ` [Qemu-devel] " Bob Breuer
2011-10-24 23:25                         ` Kai Tietz
2011-10-25 17:00                           ` Bob Breuer
2011-10-20 14:16                 ` jojelino

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=CAEwic4ZrFOHq8yn5vM+cNeGet4QpvhumTEydg+BznjT5FMzzdg@mail.gmail.com \
    --to=ktietz70@googlemail.com \
    --cc=gcc@gcc.gnu.org \
    --cc=jojelino@gmail.com \
    --cc=qemu-devel@nongnu.org \
    --cc=xunxun1982@gmail.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).