[llvm-bugs] [Bug 49480] New: Regression: lld/mac at 203731d2c82 is ~4% slower than lld/mac at 13f439a1872b5

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Mar 8 13:26:52 PST 2021


https://bugs.llvm.org/show_bug.cgi?id=49480

            Bug ID: 49480
           Summary: Regression: lld/mac at 203731d2c82 is ~4% slower than
                    lld/mac at 13f439a1872b5
           Product: lld
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: MachO
          Assignee: unassignedbugs at nondot.org
          Reporter: nicolasweber at gmx.de
                CC: gkm at fb.com, jezreel at gmail.com,
                    llvm-bugs at lists.llvm.org, smeenai at fb.com

1. Download repro zip from https://bugs.llvm.org/show_bug.cgi?id=48657#c0

2. Run `time ~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew
@response.txt`, with lld built at different revisions.


On my machine, lld built at 13f439a1872b5 takes about 3.57s. lld built at
203731d2c82 takes about 3.71s. It's not a huge difference, but big enough to be
consistent. (I didn't do ministat tests , but it looks fairly clearly apart).

I tried `git bisect`ing, but didn't succeed. My bisect log is below. Maybe
someone else wants to try if they can repro, and if they have more luck
bisecting.



My lld in this case was built using a regular cmake build, with the following
args (you don't need the C_COMPILER and COMPILER_LAUNCHER stuff; that's just so
I can use a distributed compilation service we have -- in fact, you don't need
any of these, it's mostly a vanilla release build with assertions enabled):


/Applications/CMake.app/Contents/bin/cmake -GNinja -DCMAKE_BUILD_TYPE=Release
-DLLVM_ENABLE_ASSERTIONS=ON
-DLLVM_ENABLE_PROJECTS='clang;compiler-rt;clang-tools-extra;lld'
-DLLVM_APPEND_VC_REV=NO -DLLVM_TARGETS_TO_BUILD='X86;AMDGPU'
-DCMAKE_C_COMPILER=$PWD/../chrome/src/third_party/llvm-build/Release+Asserts/bin/clang
-DCMAKE_CXX_COMPILER=$PWD/../chrome/src/third_party/llvm-build/Release+Asserts/bin/clang++
-DCMAKE_C_COMPILER_LAUNCHER=$(goma_ctl goma_dir)/gomacc
-DCMAKE_CXX_COMPILER_LAUNCHER=$(goma_ctl goma_dir)/gomacc
-DCMAKE_OSX_SYSROOT=/Users/thakis/src/llvm-project/sysroot/MacOSX.sdk
-DDARWIN_macosx_CACHED_SYSROOT=/Users/thakis/src/llvm-project/sysroot/MacOSX.sdk
-DDARWIN_iphoneos_CACHED_SYSROOT=/Users/thakis/src/llvm-project/sysroot/iPhoneOS.sdk
-DDARWIN_iphonesimulator_CACHED_SYSROOT=/Users/thakis/src/llvm-project/sysroot/iPhoneSimulator.sdk
../llvm-project/llvm



cmake build
git bisect init -- lld


13f439a1872b559d72ee2b5951395310ce4393cc

~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.72s
user 0.80s system 98% cpu 3.581 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.72s
user 0.78s system 98% cpu 3.565 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.70s
user 0.80s system 98% cpu 3.552 total



203731d2c82bc1ba0cfaeb8f3d38e696158ca2cd

ld64.lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.88s
user 0.78s system 98% cpu 3.712 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
ld64.lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.87s
user 0.77s system 98% cpu 3.695 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
ld64.lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.88s
user 0.80s system 97% cpu 3.761 total



7605a9a009b5fa3bdac07e3131c8d82f6d08feb7 both bad and good, went with bad for
now

~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.83s
user 0.75s system 98% cpu 3.635 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.83s
user 0.75s system 97% cpu 3.656 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.84s
user 0.76s system 98% cpu 3.651 total



b99147b4fa7b361fba4eeefdb443dca72b8ee87f

thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.68s
user 0.77s system 98% cpu 3.507 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.71s
user 0.77s system 98% cpu 3.528 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.72s
user 0.78s system 97% cpu 3.586 total



5369517d20dd362a178a1b2d6c398d8898ee4620

thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.66s
user 0.78s system 98% cpu 3.495 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.66s
user 0.78s system 97% cpu 3.525 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.71s
user 0.79s system 98% cpu 3.548 total



e59d336e75f4670b1a702c2281b3fed27ba4c426

thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  3.18s
user 0.87s system 98% cpu 4.091 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  3.14s
user 0.86s system 98% cpu 4.051 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  3.23s
user 0.85s system 98% cpu 4.132 total



d3e8b9fdc0de18ff92764f1be0a9b5a13fbbe9de


thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.71s
user 0.77s system 98% cpu 3.533 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.68s
user 0.77s system 97% cpu 3.537 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.66s
user 0.77s system 98% cpu 3.488 total



0d9b17d0efe065f23b7f1c1f8f2b2b32491abd45 bad-ish

thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.96s
user 0.87s system 98% cpu 3.874 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.99s
user 0.86s system 98% cpu 3.903 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  3.03s
user 0.86s system 98% cpu 3.945 total




0ef25cf558bfaffda4820c8b4e4f2a02d52b0334

thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.73s
user 0.77s system 98% cpu 3.554 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.69s
user 0.75s system 97% cpu 3.518 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.72s
user 0.77s system 98% cpu 3.545 total



3949a3ed49bbd95235c3c616bf4dbae4ecac48bc

thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.71s
user 0.78s system 98% cpu 3.536 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.75s
user 0.78s system 98% cpu 3.578 total
thakis at MBP chromium_framework % time ~/src/llvm-build-project/bin/ld64.lld
-flavor darwinnew @response.txt
lld: warning: Option `-dead_strip' is not yet implemented. Stay tuned...
~/src/llvm-build-project/bin/ld64.lld -flavor darwinnew @response.txt  2.66s
user 0.76s system 97% cpu 3.504 total

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210308/738d5c60/attachment-0001.html>


More information about the llvm-bugs mailing list