diff options
author | Nathaniel Shead <nathanieloshead@gmail.com> | 2025-01-22 21:24:03 +1100 |
---|---|---|
committer | Nathaniel Shead <nathanieloshead@gmail.com> | 2025-01-23 17:37:43 +1100 |
commit | 21cccfa91e6ed172062e0c62682422269c914937 (patch) | |
tree | b9777e1b01437cde1d5623246a72f2ce60c1e0a4 /gcc/dwarf2asm.h | |
parent | 9ddf4a6cc650360e620c8fd97f550bf833cc177a (diff) | |
download | gcc-21cccfa91e6ed172062e0c62682422269c914937.zip gcc-21cccfa91e6ed172062e0c62682422269c914937.tar.gz gcc-21cccfa91e6ed172062e0c62682422269c914937.tar.bz2 |
c++/modules: Fix exporting temploid friends in header units [PR118582]
When we started streaming the bit to handle merging of imported temploid
friends in r15-2807, I unthinkingly only streamed it in the
'!state->is_header ()' case.
This patch reworks the streaming logic to ensure that this data is
always streamed, including for unique entities (in case that ever comes
up somehow). This does make the streaming slightly less efficient, as
functions and types will need an extra byte, but this doesn't appear to
make a huge difference to the size of the resulting module; the 'std'
module on my machine grows by 0.2% from 30671136 to 30730144 bytes.
PR c++/118582
gcc/cp/ChangeLog:
* module.cc (trees_out::decl_value): Always stream
imported_temploid_friends information.
(trees_in::decl_value): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/modules/pr118582_a.H: New test.
* g++.dg/modules/pr118582_b.H: New test.
* g++.dg/modules/pr118582_c.H: New test.
Signed-off-by: Nathaniel Shead <nathanieloshead@gmail.com>
Diffstat (limited to 'gcc/dwarf2asm.h')
0 files changed, 0 insertions, 0 deletions