C++ Logo

std-proposals

Advanced search

Re: [std-proposals] Fwd: set_new_handler extension

From: Phil Bouchard <boost_at_[hidden]>
Date: Tue, 21 Feb 2023 06:11:23 -0500
On 2/21/23 03:26, Frederick Virchanza Gotham via Std-Proposals wrote:
> On Tue, Feb 21, 2023 at 4:01 AM Phil Bouchard <boost_at_[hidden]> wrote:
>>
>> So yeah Frederick, if you don't mind I'll use your code and add
>> garbage-collector-style deallocations, make it thread-local, allocation
>> rate-based and type-based as a new project in my own Github with can
>> simply link to under Linux and LGPL it:
>> https://github.com/philippeb8
>
>
> Fork this: https://github.com/healytpk/cplusplus-overload-new
>
> I've replaced the hardcoded '8' with 'alignof(max_align_t)'.
>
> With GNU g++, you need to include <new> otherwise you get a compiler
> error for the 'noexcept'. On LVM clang++, I think you have to remove
> the 'noexcept' to get it to compile.

You're right; it's around ~6x faster:
https://github.com/philippeb8/cplusplus-overload-new

But I'll follow up in private.

I just wanted to share to the public that "clang++ -O2" ignores the
operator overrides across shared libraries. So you need to use "g++ -O2".


Thank you,

-- 
Logo <https://www.fornux.com/>  
*Phil Bouchard*  facebook icon
<https://www.linkedin.com/in/phil-bouchard-5723a910/> 
CTO
T: (819) 328-4743
E: phil_at_[hidden]| www.fornux.com <http://www.fornux.com>
8 rue de la Baie| Gatineau (Qc), J8T 3H3 Canada
Banner <https://goglobalawards.org/> Le message ci-dessus, ainsi que les
documents l'accompagnant, sont destinés uniquement aux personnes
identifiées et peuvent contenir des informations privilégiées,
confidentielles ou ne pouvant être divulguées. Si vous avez reçu ce
message par erreur, veuillez le détruire.
This communication (and/or the attachments) is intended for named
recipients only and may contain privileged or confidential information
which is not to be disclosed. If you received this communication by
mistake please destroy all copies.

Received on 2023-02-21 11:11:25