diff options
| author | Haojian Wu <hokein@google.com> | 2018-10-18 10:43:50 +0000 |
|---|---|---|
| committer | Haojian Wu <hokein@google.com> | 2018-10-18 10:43:50 +0000 |
| commit | b515fabb3bca172f13a52d144824b56180dad158 (patch) | |
| tree | 8e42e51c85f40ccc3ead9705d52e028a91a6a882 /llvm/lib/ProfileData/Coverage/CoverageMappingWriter.cpp | |
| parent | 59041687bee841f46c520f4b6a7cb8f97b4efd05 (diff) | |
| download | bcm5719-llvm-b515fabb3bca172f13a52d144824b56180dad158.tar.gz bcm5719-llvm-b515fabb3bca172f13a52d144824b56180dad158.zip | |
[clangd] Encode Line/Column as a 32-bits integer.
Summary:
This would buy us more memory. Using a 32-bits integer is enough for
most human-readable source code (up to 4M lines and 4K columns).
Previsouly, we used 8 bytes for a position, now 4 bytes, it would save
us 8 bytes for each Ref and each Symbol instance.
For LLVM-project binary index file, we save ~13% memory.
| Before | After |
| 412MB | 355MB |
Reviewers: sammccall
Subscribers: ilya-biryukov, ioeric, MaskRay, jkorous, arphaman, kadircet, cfe-commits
Differential Revision: https://reviews.llvm.org/D53363
llvm-svn: 344735
Diffstat (limited to 'llvm/lib/ProfileData/Coverage/CoverageMappingWriter.cpp')
0 files changed, 0 insertions, 0 deletions

