public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/47611] New: [trans-mem] memory allocated by default new/new_vec operator can be considered as transaction local
@ 2011-02-04 20:27 patrick.marlier at gmail dot com
  2011-02-04 21:11 ` [Bug c++/47611] " aldyh at gcc dot gnu.org
  2011-11-21 16:51 ` torvald at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: patrick.marlier at gmail dot com @ 2011-02-04 20:27 UTC (permalink / raw)
  To: gcc-bugs

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

           Summary: [trans-mem] memory allocated by default new/new_vec
                    operator can be considered as transaction local
           Product: gcc
           Version: trans-mem
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: patrick.marlier@gmail.com
                CC: rth@gcc.gnu.org, aldyh@gcc.gnu.org


This is an improvement with a *LOW* priority. Only if spare time (hey could be
a nice homework).

See comments in 
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46941


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

* [Bug c++/47611] [trans-mem] memory allocated by default new/new_vec operator can be considered as transaction local
  2011-02-04 20:27 [Bug c++/47611] New: [trans-mem] memory allocated by default new/new_vec operator can be considered as transaction local patrick.marlier at gmail dot com
@ 2011-02-04 21:11 ` aldyh at gcc dot gnu.org
  2011-11-21 16:51 ` torvald at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: aldyh at gcc dot gnu.org @ 2011-02-04 21:11 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P5
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2011.02.04 21:11:43
     Ever Confirmed|0                           |1

--- Comment #1 from Aldy Hernandez <aldyh at gcc dot gnu.org> 2011-02-04 21:11:43 UTC ---
Bringing in a note from the other PR...

The reason memory allocated by the C++ new operator does not get
optimized by the TM-memopt pass is not because of a missing ECF_MALLOC
attribute, but because the alias oracle in GCC considers the chunk of memory as
possibly able to escape from the current function.

That is, the following hunk of code returns true in the TM-memopt pass:

      if (ptr_deref_may_alias_global_p (x))

Apparently, since new/delete operators may be overridden by class specific
hooks, the memory must be considered escaped.


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

* [Bug c++/47611] [trans-mem] memory allocated by default new/new_vec operator can be considered as transaction local
  2011-02-04 20:27 [Bug c++/47611] New: [trans-mem] memory allocated by default new/new_vec operator can be considered as transaction local patrick.marlier at gmail dot com
  2011-02-04 21:11 ` [Bug c++/47611] " aldyh at gcc dot gnu.org
@ 2011-11-21 16:51 ` torvald at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: torvald at gcc dot gnu.org @ 2011-11-21 16:51 UTC (permalink / raw)
  To: gcc-bugs

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

torvald at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |torvald at gcc dot gnu.org
         Resolution|                            |INVALID

--- Comment #2 from torvald at gcc dot gnu.org 2011-11-21 16:39:40 UTC ---
If the alias oracle considers the memory region returned from new/delete to be
potentially escaping to code outside of the transaction, then I think we need
to respect this.  If you think this should not be possible, please file another
bug against the alias oracle.


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

end of thread, other threads:[~2011-11-21 16:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-04 20:27 [Bug c++/47611] New: [trans-mem] memory allocated by default new/new_vec operator can be considered as transaction local patrick.marlier at gmail dot com
2011-02-04 21:11 ` [Bug c++/47611] " aldyh at gcc dot gnu.org
2011-11-21 16:51 ` torvald 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).