optimise linker in linux standalone tarballs

Trick the linker into not doing unncessary work searching for optimised
libraries that are not present, by symlinking the directories where
optimised libs would be to the main lib dir.

This reduces the ENOENT of git-annex init by about 1/2. The linker always
finds the files where it looks first time now. I have not looked at what
the wall clock speedup might be, it's probably rather small.

If a x86-64-v5 comes to be, the list will need to be extended. And there
may be other directories used on some machines that I have missed. Not done
for arm64 yet, or any uncommon architectures.

Sponsored-by: Dartmouth College's Datalad project
This commit is contained in:
Joey Hess 2022-08-30 15:20:04 -04:00
parent 345e60a623
commit a93163d6f7
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
4 changed files with 64 additions and 0 deletions

View file

@ -51,3 +51,5 @@ pr-55/build-ubuntu.yaml-799-32886238-failed/test-annex-more/6_Seek of dynlibs.tx
anything to be done or should we just raise the bar to 140 in that test?
[[!tag projects/datalad]]
> [[done]] --[[Joey]]

View file

@ -0,0 +1,12 @@
[[!comment format=mdwn
username="joey"
subject="""comment 4"""
date="2022-08-30T19:14:50Z"
content="""
Implemented that idea now, so you may want to drop your test
back down to 40 or 50.
So far it's only implemented for amd64, i386, and arm. Other architectures
might also have such directories that could be symlinked, I have not
investigated.
"""]]