This is an archive of the discontinued LLVM Phabricator instance.

[lld/mac] Parallelize code signature computation
ClosedPublic

Authored by thakis on Jun 21 2022, 12:32 PM.

Details

Reviewers
oontvoo
MaskRay
Group Reviewers
Restricted Project
Commits
rG0baf13e282ab: [lld/mac] Parallelize code signature computation
Summary

According to ministat, this is a small but measurable speedup
(using the repro in PR56121):

N           Min           Max        Median           Avg        Stddev

x 10 3.7439518 3.7783802 3.7730219 3.7655502 0.012375226
+ 10 3.6149218 3.692198 3.6519327 3.6502951 0.025905601
Difference at 95.0% confidence

-0.115255 +/- 0.0190746
-3.06078% +/- 0.506554%
(Student's t, pooled s = 0.0203008)

(Without 858e8b17f7365, this change here to use parallelFor is an 18% speedup,
and doing 858e8b17f7365 on top of this change is just a 2.55 +/- 0.58% win.
Doing both results in a total speedup of 20.85 +/- 0.44%.)

Diff Detail

Event Timeline

thakis created this revision.Jun 21 2022, 12:32 PM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptJun 21 2022, 12:32 PM
thakis requested review of this revision.Jun 21 2022, 12:32 PM

Anyone interested in a 3% speedup? :)

oontvoo accepted this revision.Jun 21 2022, 4:27 PM
oontvoo added a subscriber: oontvoo.

LG - i'm surprised that this is *only* ~3% (which is still good), because when I did a profile a few months ago, the hashing/coding signing function was hottest (~30-50% of the total time) when linking Youtube.

This revision is now accepted and ready to land.Jun 21 2022, 4:27 PM
MaskRay accepted this revision.Jun 21 2022, 4:36 PM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptJun 21 2022, 5:41 PM