https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110137
--- Comment #9 from Jan Hubicka <hubicka at ucw dot cz> --- Doing global flag has a problem since with LTO or using optimize attribute user may mix code compiled with and without sane operator new. When function with insane operator new gets inlined to a function with sane, we will assume sanity for calls that technically may not be sane. So I think we do need to tag the declaration or call instead of using flag_sane_operator_new in middle-end...