On 11/6/20 1:50 AM, Thomas Schwinge wrote: > Hi! > > On 2018-09-25T16:00:14-0400, David Malcolm <dmalc...@redhat.com> wrote: >> The patch adds "dg-optimized" and "dg-missed" directives > Another small thing I just noticed: > >> --- a/gcc/testsuite/lib/gcc-dg.exp >> +++ b/gcc/testsuite/lib/gcc-dg.exp >> +# Handle output from -fopt-info for MSG_OPTIMIZED_LOCATIONS: >> +# a successful optimization. >> + >> +proc dg-optimized { args } { >> + # Make this variable available here and to the saved proc. >> + upvar dg-messages dg-messages >> + >> + process-message saved-dg-error "optimized: " "$args" >> +} >> + >> +# Handle output from -fopt-info for MSG_MISSED_OPTIMIZATION: >> +# a missed optimization. >> + >> +proc dg-missed { args } { >> + # Make this variable available here and to the saved proc. >> + upvar dg-messages dg-messages >> + >> + process-message saved-dg-error "missed: " "$args" >> +} > These currently print "(test for *errors*, line [...])". However, these > diagnostics are not actually error diagnostics (fatal, meaning: causes > compilation to fail) but rather warning diagnostics (non-fatal, doesn't > cause compilation to fail). Thus, same as 'dg-message', these should use > 'saved-dg-warning' instead of 'saved-dg-error', which will print: "(test > for *warnings*, line [...])". OK to change that after regression > testing?
Yes. jeff