https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98895
Bug ID: 98895
Summary: C++ module generates too many dead code
Product: gcc
Version: 11.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: unlvsur at live dot com
Target Milestone: ---
It is a general issue. Any module unit will generate a dead entry that is
completely unused.
If those issues cannot be solved, I am sorry, I would only say C++20 modules
failed completely.
I do not think it has anything to do with tree-optimizations. The compiler just
should NOT emit any code to the middle-end because of the module tbh. The
module should not affect how the assembly is generated.