Hi Thomas, > On 29 Jul 2024, at 10:06, Thomas Schwinge <tschwi...@baylibre.com> wrote: > On 2019-11-17T10:28:26+0000, Iain Sandoe <i...@sandoe.co.uk> wrote: >> There are two categories of test: >> >> 1. Checks for correctly formed source code and the error reporting. >> 2. Checks for transformation and code-gen. >> >> The second set are run as 'torture' tests for the standard options >> set, including LTO. These are also intentionally run with no options >> provided (from the coroutines.exp script). > > I recently was confused why I'm seeing the same test case first without > and then again with torture testing options; non-standard in the GCC test > suite, per my experience at least? Should we therefore add a short > rationale comment to the 'find' in 'g++.dg/coroutines/coroutines.exp', > why 'g++.dg/coroutines/torture/' test cases are not being filtered out > there, despite more specific 'g++.dg/coroutines/torture/coro-torture.exp' > testing these, too?
Well, I’d say not “more specific” so much as “additional cases” - the torture tests do not usually** include the default (i.e. no options case). I wanted the default to be included - and this was a reasonable way to do it (as would be adding another case to the torture list). It’s quite convenient to get at least the default case run for every test with: ` make check-gcc-c++ RUNTESTFLAGS=coroutines.exp ` having said that, if concensus would be to add an additional case to the torture list (I think that this can be done per directory) then I’d also be OK with that, cheers Iain ** last I checked anyway - if that has changed then we should adjust the current setup. > > > Grüße > Thomas > > >> --- /dev/null >> +++ b/gcc/testsuite/g++.dg/coroutines/coroutines.exp >> @@ -0,0 +1,50 @@ > >> +foreach test [lsort [find $srcdir/$subdir {*.[CH]}]] { >> + if [runtest_file_p $runtests $test] { >> + set nshort [file tail [file dirname $test]]/[file tail $test] >> + verbose "Testing $nshort $DEFAULT_COROFLAGS" 1 >> + dg-test $test "" $DEFAULT_COROFLAGS >> + set testcase [string range $test [string length "$srcdir/"] end] >> + } > >> --- /dev/null >> +++ b/gcc/testsuite/g++.dg/coroutines/torture/coro-torture.exp > >> +gcc-dg-runtest [lsort [glob $srcdir/$subdir/*.C]] "" $DEFAULT_COROFLAGS