This is an archive of the discontinued LLVM Phabricator instance.

[ELF] Use llvm::xxh3_64bits for MergeInputSection::splitStrings
ClosedPublic

Authored by MaskRay on Jul 9 2023, 8:18 PM.

Diff Detail

Event Timeline

MaskRay created this revision.Jul 9 2023, 8:18 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 9 2023, 8:18 PM
MaskRay requested review of this revision.Jul 9 2023, 8:18 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 9 2023, 8:18 PM
MaskRay added a comment.EditedJul 9 2023, 8:19 PM

MergeInputSection::splitNonStrings requires fixing 6 more tests. I haven't done that in this patch. I'll do that after this patch lands. MergeInputSection::splitNonStrings takes negligible time (output .rodata.cst4 is just 0x11c bytes) compared with MergeInputSection::splitStrings

Looks like dependency between patches is not set, and thats why build fails with 'error C3861: 'xxh3_64bits': identifier not found'

PiotrZSL accepted this revision.Jul 18 2023, 8:47 AM

LGTM, but probably someone else should look into this also.

This revision is now accepted and ready to land.Jul 18 2023, 8:47 AM

LGTM, but probably someone else should look into this also.

Thank you! I think this is a non-controversial change. The benefit for Linux x86-64 can be "significant" (e.g., 2%).
I am a primary maintainer of lld/ELF and I'll land this soon before the release/17.x branch...