[PATCH] D61343: [llvm-objcopy] Cache gnu_debuglink's target CRC
MichaĆ Janiszewski via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 30 14:40:03 PDT 2019
janisozaur created this revision.
janisozaur added reviewers: jakehehrlich, echristo.
janisozaur added a project: LLVM.
Herald added subscribers: llvm-commits, MaskRay, arichardson, emaste.
Herald added a reviewer: espindola.
Herald added a reviewer: alexshap.
Herald added a reviewer: rupprecht.
Herald added a reviewer: jhenderson.
.gnu_debuglink section contains information regarding file with
debugging symbols, identified by its CRC32. This target file is not
intended to ever change or it would invalidate the stored checksum, yet
the checksum is calculated over and over again for each of the objects
inside the archive, usually hundreds of time.
This patch precomputes the CRC32 of the target once and then reuses the
value where required, saving lots of redundant I/O.
The error message reported should stay the same, although now it might
be reported earlier.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D61343
Files:
llvm/tools/llvm-objcopy/CopyConfig.cpp
llvm/tools/llvm-objcopy/CopyConfig.h
llvm/tools/llvm-objcopy/ELF/ELFObjcopy.cpp
llvm/tools/llvm-objcopy/ELF/Object.cpp
llvm/tools/llvm-objcopy/ELF/Object.h
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61343.197444.patch
Type: text/x-patch
Size: 5631 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190430/e58f72ba/attachment.bin>
More information about the llvm-commits
mailing list