[llvm-branch-commits] [lld] feadc37 - [lld/mac] Make X86_64::getImplicitAddend not do heap allocations (original) (raw)

Nico Weber via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Mon Dec 7 06:24:13 PST 2020


Author: Nico Weber Date: 2020-12-07T09:23:51-05:00 New Revision: feadc3798d9ab123057a7a1064897188ac8de934

URL: https://github.com/llvm/llvm-project/commit/feadc3798d9ab123057a7a1064897188ac8de934 DIFF: https://github.com/llvm/llvm-project/commit/feadc3798d9ab123057a7a1064897188ac8de934.diff

LOG: [lld/mac] Make X86_64::getImplicitAddend not do heap allocations

Speeds up linking Chromium's base_unittests almost 10%. According to ministat:

N           Min           Max        Median           Avg        Stddev

x 5 0.72193289 0.73073196 0.72560811 0.72565799 0.0032265649

Differential Revision: https://reviews.llvm.org/D92734

Added:

Modified: lld/MachO/Arch/X86_64.cpp

Removed:

################################################################################ diff --git a/lld/MachO/Arch/X86_64.cpp b/lld/MachO/Arch/X86_64.cpp index 19e62a919caf..7f4024cc998d 100644 --- a/lld/MachO/Arch/X86_64.cpp +++ b/lld/MachO/Arch/X86_64.cpp @@ -52,9 +52,8 @@ static std::string getErrorLocation(MemoryBufferRef mb, const section_64 &sec,

static void validateLength(MemoryBufferRef mb, const section_64 &sec, const relocation_info &rel,



More information about the llvm-branch-commits mailing list