On Wed, Mar 15, 2023 at 02:39:43PM +0000, Richard Biener via Gcc-patches wrote:
> I've tested and most of the -Wuse-after-free testcases work with -Og
> before and after the change (unfortunately adding -Og via RUNTESTFLAGS
> doesn't work since explicit -O2 in the testcases overrides that).
> 
> We also do not have much test coverage here and I'm hesitant to change
> this now.
> 
> That said, with the adjusted first patch and the split out fix for
> g++.dg/warn/Wuse-after-free3.C the following is what I propose now.
> There's extra adjustments in gcc.dg/Wuse-after-free-2.c as we now
> mention the pointer that is used.
> 
> I do think not running these kind of diagnostics very late, at least
> a diagnostic like this that's prone to false positives due to
> code motion.  But I'm also happy to leave the state of affairs as-is
> for GCC 13, but I don't promise to be able to pick up things during
> next stage1 again.
> 
> Re-re-re-bootstrap & regtest running on x86_64-unknown-linux-gnu.
> 
> Unless I get clear opinions I'm going to throw some dice whether
> to apply 1/2 and will "defer" this one.

Let's go with both patches then, if somebody files false negative issues
for this warning later on, we can amend it further later.

        Jakub

Reply via email to