https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98613
Martin Sebor <msebor at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |diagnostic --- Comment #4 from Martin Sebor <msebor at gcc dot gnu.org> --- Yes, I think so. I see code in the optimized dump that the warning should trigger for even on x86_64 but doesn't due to a known bug/limitation in how GCC determines the context into which a function defined in a system header has been inlined. All the calls to operator delete with _S_empty_rep should trigger it: $ /build/gcc-master/gcc/xg++ -B /build/gcc-master/gcc -nostdinc++ -I /build/gcc-master/x86_64-pc-linux-gnu/libstdc++-v3/include/x86_64-pc-linux-gnu -I /build/gcc-master/x86_64-pc-linux-gnu/libstdc++-v3/include -I /src/gcc/master/libstdc++-v3/libsupc++ -I /src/gcc/master/libstdc++-v3/include/backward -I /src/gcc/master/libstdc++-v3/testsuite/util -L /build/gcc-master/x86_64-pc-linux-gnu/libstdc++-v3/src/.libs -O3 -Wall -fdump-tree-optimized=/dev/stdout /src/gcc/master/libstdc++-v3/testsuite/ext/vstring/cons/moveable.cc | grep delete operator delete (_17, _21); [tail call] operator delete (_35, _37); operator delete (_38, _40); operator delete (&MEM <struct _Rep> [(void *)&_S_empty_rep], _156); operator delete (_220, _224); operator delete (_288, _292); operator delete (_318, _322); operator delete (&MEM <struct _Rep> [(void *)&_S_empty_rep], _328); operator delete (&MEM <struct _Rep> [(void *)&_S_empty_rep], _334); [tail call]