Re: [PATCH][WIP] libstdc++: Make certain exceptions transaction_safe.

2015-12-24 Thread Jonathan Wakely
On 23/12/15 18:35 +0100, Torvald Riegel wrote: It's possible we can make this work for the old ABI too, but this is OK for now. The old ABI always uses COW strings, but that's what the code you've written deals with anyway. OK. I would have to write the wrappers for the new strings too then, a

Re: [PATCH][WIP] libstdc++: Make certain exceptions transaction_safe.

2015-12-24 Thread Jonathan Wakely
On 23/12/15 15:56 -0500, Jason Merrill wrote: On 12/23/2015 12:35 PM, Torvald Riegel wrote: +//#if !defined (HAVE_ELF_STYLE_WEAKREF) Can I assume weak refs to be supported, or how do I check for whether they are? What's your preference? G++ does support targets without weak symbols, but I ima

Re: [PATCH][WIP] libstdc++: Make certain exceptions transaction_safe.

2015-12-23 Thread Jason Merrill
On 12/23/2015 12:35 PM, Torvald Riegel wrote: +//#if !defined (HAVE_ELF_STYLE_WEAKREF) Can I assume weak refs to be supported, or how do I check for whether they are? What's your preference? G++ does support targets without weak symbols, but I imagine we can decide not to support libitm on su

Re: [PATCH][WIP] libstdc++: Make certain exceptions transaction_safe.

2015-12-23 Thread Torvald Riegel
On Wed, 2015-12-16 at 21:05 +, Jonathan Wakely wrote: > Sorry for the delay finishing this review, some of the code kept > melting my brain ;-) I know what you mean :) Thanks for the review! > On 14/11/15 20:45 +0100, Torvald Riegel wrote: > >diff --git a/libstdc++-v3/config/abi/pre/gnu.ver

Re: [PATCH][WIP] libstdc++: Make certain exceptions transaction_safe.

2015-12-17 Thread Jonathan Wakely
On 14/11/15 20:45 +0100, Torvald Riegel wrote: +void +_txnal_cow_string_D1(void *that) +{ + typedef std::basic_string bs_type; + bs_type::_Rep *rep = reinterpret_cast( + const_cast(_txnal_cow_string_c_str(that))) - 1; + + // The string can be shared, in which case we would need to decreme

Re: [PATCH][WIP] libstdc++: Make certain exceptions transaction_safe.

2015-12-16 Thread Jonathan Wakely
Sorry for the delay finishing this review, some of the code kept melting my brain ;-) On 14/11/15 20:45 +0100, Torvald Riegel wrote: diff --git a/libstdc++-v3/config/abi/pre/gnu.ver b/libstdc++-v3/config/abi/pre/gnu.ver index 1b3184a..d902b03 100644 --- a/libstdc++-v3/config/abi/pre/gnu.ver ++