[Bug c++/46941] [trans-mem] new/delete operator are unsafe
patrick.marlier at gmail dot com
gcc-bugzilla@gcc.gnu.org
Wed Feb 2 14:17:00 GMT 2011
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46941
Patrick Marlier <patrick.marlier at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|FIXED |
--- Comment #7 from Patrick Marlier <patrick.marlier at gmail dot com> 2011-02-02 14:17:23 UTC ---
(In reply to comment #6)
> Fixed
> http://gcc.gnu.org/ml/gcc-patches/2011-01/msg00776.html
Please considered this...
http://gcc.gnu.org/ml/gcc-patches/2011-01/msg01206.html
It must be **transaction_safe** not transaction_pure.
Moreover I think we should also add ECF_MALLOC (malloc attribute) because
otherwise the allocated memory will not be considered as local.
Extract from trans-mem.c: thread_private_new_memory()
if (stmt && is_gimple_call (stmt) && gimple_call_flags (stmt) & ECF_MALLOC)
/* Thread-local or transaction-local. */
;
else
retval = mem_non_local;
Thanks.
More information about the Gcc-bugs
mailing list