https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88740
Bug ID: 88740 Summary: [7/8/9 Regression] libstdc++ tests no longer print assertion failure messages Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: redi at gcc dot gnu.org Target Milestone: --- r241069 redefined the VERIFY macro so that instead of using assert it does: #define VERIFY(fn) \ do \ { \ if (! (fn)) \ { \ __builtin_printf("%s:%d: %s: Assertion '%s' failed.\n", \ __FILE__, __LINE__, __PRETTY_FUNCTION__, #fn); \ __builtin_abort(); \ } \ } while (false) Unlike assert, this prints to stdout not stderr. Due to some unidentified issue in dejagnu (or expect or tcl or something else) unflushed output sent to stdout does not get captured by dejagnu and written to the test logs on recent versions of Fedora (and maybe other distros). This means that testsuite failures don't show the reason for failure, just an unhelpful: spawn [open ...] FAIL: 27_io/filesystem/operations/remove.cc execution test The expected result is: spawn [open ...] /home/jwakely/src/gcc/libstdc++-v3/testsuite/27_io/filesystem/operations/remove.cc:38: void test01(): Assertion '!ec' failed. FAIL: 27_io/filesystem/operations/remove.cc execution test The missing output can be fixed by including <cstdio> in testsuite_hooks.h and then either changing __builtin_printf(...) to __builtin_fprintf(stderr, ...) or alternatively adding a call to fflush(stdout) before the __builtin_abort().