RFR: 8233359: Add global sized operator delete definitions

Kim Barrett kim.barrett at oracle.com
Mon Nov 4 19:34:18 UTC 2019


> On Nov 4, 2019, at 2:17 PM, Thomas Stüfe <thomas.stuefe at gmail.com> wrote:
> 
> Hi,
> 
> I now get:
> 
> /shared/projects/openjdk/jdk-jdk/source/src/hotspot/share/memory/operator_new.cpp:92:6: error: 'void operator delete(void*, size_t)' is a usual (non-placement) deallocation function in C++14 (or with -fsized-deallocation) [-Werror=c++14-compat]
>  void operator delete(void* p, size_t size) throw() {
>       ^
> /shared/projects/openjdk/jdk-jdk/source/src/hotspot/share/memory/operator_new.cpp:96:6: error: 'void operator delete [](void*, size_t)' is a usual (non-placement) deallocation function in C++14 (or with -fsized-deallocation) [-Werror=c++14-compat]
>  void operator delete [](void* p, size_t size) throw() {
>       ^

Where is -Wc++14-compat being turned on?  Hm, that’s in -Wall?  That’s really rude!
So why doesn’t a more recent gcc version (we’re using 8.3 now) complain too?

> when building on Ubuntu 16.4 using gcc 5.4.0.
> 
> This used to build without problems on Ubuntu 16.4 with the stock compiler. This is really a pain :(

Agreed.

I guess we can add "-Wno-c++11-compat -Wno-c++14-compat -Wno-c++17-compat” for now.



More information about the hotspot-runtime-dev mailing list