public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/52141] New: [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm
@ 2012-02-06 20:50 patrick.marlier at gmail dot com
  2012-02-07  9:31 ` [Bug middle-end/52141] " rguenth at gcc dot gnu.org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: patrick.marlier at gmail dot com @ 2012-02-06 20:50 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52141

             Bug #: 52141
           Summary: [trans-mem] ICE due to asm statement in
                    trans-mem.c:expand_block_tm
    Classification: Unclassified
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: patrick.marlier@gmail.com
                CC: aldyh@gcc.gnu.org, rth@gcc.gnu.org


Created attachment 26591
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26591
testcase ICE with -fgnu-tm -O1

In the continuation of PRs: 46269, 47606, 51443.

../../trunk-debug/gcc/xgcc -B ../../trunk-debug/gcc -fgnu-tm -O1 -S -o
ICE-inline.s ICE-inline2.c
ICE-inline2.c:2:13: warning: always_inline function might not be inlinable
[-Wattributes]
ICE-inline2.c:13:5: internal compiler error: in expand_block_tm, at
trans-mem.c:2366

(gdb) bt
...
#5  0x0000000000b1714f in expand_block_tm (region=0x1b99160, bb=0x7ffff69aa208)
at ../../trunk/gcc/trans-mem.c:2366
#6  0x0000000000b17455 in execute_tm_mark () at
../../trunk/gcc/trans-mem.c:2467
#7  0x0000000000a1672f in execute_one_pass (pass=0x196c0a0) at
../../trunk/gcc/passes.c:2081
...


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug middle-end/52141] [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm
  2012-02-06 20:50 [Bug middle-end/52141] New: [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm patrick.marlier at gmail dot com
@ 2012-02-07  9:31 ` rguenth at gcc dot gnu.org
  2012-02-07 17:16 ` rth at gcc dot gnu.org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-02-07  9:31 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52141

--- Comment #1 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-02-07 09:30:45 UTC ---
Might I suggest to instead of

        case GIMPLE_ASM:
          gcc_unreachable ();

use

        case GIMPLE_ASM:
          sorry ("asm statements not allowed in transactions");

?  It's not a compiler but a user error (well, usually).

Btw, what you really want is some simple IPA propagation of the various
transaction attributes similar to how we handle pure/const.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug middle-end/52141] [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm
  2012-02-06 20:50 [Bug middle-end/52141] New: [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm patrick.marlier at gmail dot com
  2012-02-07  9:31 ` [Bug middle-end/52141] " rguenth at gcc dot gnu.org
@ 2012-02-07 17:16 ` rth at gcc dot gnu.org
  2012-02-20 23:46 ` aldyh at gcc dot gnu.org
  2012-02-21  0:23 ` aldyh at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: rth at gcc dot gnu.org @ 2012-02-07 17:16 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52141

--- Comment #2 from Richard Henderson <rth at gcc dot gnu.org> 2012-02-07 17:15:41 UTC ---
It is a compiler error, because we're supposed to have handled
a transaction involving asms differently, earlier in compilation.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug middle-end/52141] [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm
  2012-02-06 20:50 [Bug middle-end/52141] New: [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm patrick.marlier at gmail dot com
  2012-02-07  9:31 ` [Bug middle-end/52141] " rguenth at gcc dot gnu.org
  2012-02-07 17:16 ` rth at gcc dot gnu.org
@ 2012-02-20 23:46 ` aldyh at gcc dot gnu.org
  2012-02-21  0:23 ` aldyh at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: aldyh at gcc dot gnu.org @ 2012-02-20 23:46 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52141

--- Comment #3 from Aldy Hernandez <aldyh at gcc dot gnu.org> 2012-02-20 23:43:35 UTC ---
Author: aldyh
Date: Mon Feb 20 23:43:31 2012
New Revision: 184417

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=184417
Log:
        PR middle-end/52141
        * trans-mem.c (ipa_tm_scan_irr_block): Error out on GIMPLE_ASM's
        in a transaction safe function.


Added:
    trunk/gcc/testsuite/gcc.dg/tm/pr52141.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/trans-mem.c


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug middle-end/52141] [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm
  2012-02-06 20:50 [Bug middle-end/52141] New: [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm patrick.marlier at gmail dot com
                   ` (2 preceding siblings ...)
  2012-02-20 23:46 ` aldyh at gcc dot gnu.org
@ 2012-02-21  0:23 ` aldyh at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: aldyh at gcc dot gnu.org @ 2012-02-21  0:23 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52141

Aldy Hernandez <aldyh at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED

--- Comment #4 from Aldy Hernandez <aldyh at gcc dot gnu.org> 2012-02-20 23:45:58 UTC ---
fixed in trunk


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-02-20 23:46 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-02-06 20:50 [Bug middle-end/52141] New: [trans-mem] ICE due to asm statement in trans-mem.c:expand_block_tm patrick.marlier at gmail dot com
2012-02-07  9:31 ` [Bug middle-end/52141] " rguenth at gcc dot gnu.org
2012-02-07 17:16 ` rth at gcc dot gnu.org
2012-02-20 23:46 ` aldyh at gcc dot gnu.org
2012-02-21  0:23 ` aldyh at gcc dot gnu.org

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).