Tested on ArchLinux's GCC 7.2.0 and also the Anaconda Distribution's gxx_linux-64 (also 7.2.0), reproducer is: echo "" | g++ -fdump-passes -fdisable-tree-einline -c -x c++ - ipa-opt_local_passes : ON tree-fixup_cfg3 : ON *rebuild_cgraph_edges : ON tree-inline_param1 : ON g++: internal compiler error: Segmentation fault (program cc1plus) Another reproducer with a different message is: echo "" | gcc -fdump-passes -fdisable-tree-einline -c -x c - ipa-opt_local_passes : ON tree-fixup_cfg3 : ON *rebuild_cgraph_edges : ON tree-inline_param1 : ON Internal compiler error: Error reporting routines re-entered.
-fdump-passes is somewhat of a hack and appearantly doesn't mix well with -fdisable-*
Both cases are not reproducible using current Arch Linux's GCC 10.2.0 now. Context: I'm dealing with some compiler performance issues on opt_local_passes for this specific source: https://github.com/FrankHB/YSLib/blob/master/YFramework/source/NPL/NPLA1Forms.cpp, with -O -fsanitizer=.... I've met endless compilation (> 4 hours) for this file combined with -g and optimization flags and -fno-var-tracking-assignments would work around, but this time it seems a different case.
Dup of bug 93874 (note even though that bug report is newer, it was the one where the patch was recorded to fix it). *** This bug has been marked as a duplicate of bug 93874 ***