1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 18:54:02 +01:00
Go to file
Alexandre Ganea 41c38f2370 Re-land [ThinLTO] Re-order modules for optimal multi-threaded processing
This reverts 9b5b3050237db3642ed7ab1bdb3ffa2202511b99 and fixes the unwanted re-ordering when generating ThinLTO indexes.

The goal of this patch is to better balance thread utilization during ThinLTO in-process linking (in llvm-lto2 or in LLD). Before this patch, large modules would often be scheduled late during execution, taking a long time to complete, thus starving the thread pool.

We now sort modules in descending order, based on each module's bitcode size, so that larger modules are processed first. By doing so, smaller modules have a better chance to keep the thread pool active, and thus avoid starvation when the bitcode compilation is almost complete.

In our case (on dual Intel Xeon Gold 6140, Windows 10 version 2004, two-stage build), this saves 15 sec when linking `clang.exe` with LLD & -flto=thin, /opt:lldltojobs=all, no ThinLTO cache, -DLLVM_INTEGRATED_CRT_ALLOC=d:\git\rpmalloc.

Before patch: 100 sec
After patch: 85 sec

Inspired by the work done by David Callahan in D60495.

Differential Revision: https://reviews.llvm.org/D87966
2020-10-13 21:54:15 -04:00
benchmarks
bindings [bindings/go] Fix TestAttributes after D88241 2020-09-25 20:31:45 -07:00
cmake [cmake] Unconditionally set the force flag when codesigning 2020-10-13 16:50:54 -07:00
docs [DebugInfo][docs] Document DILabel in LangRef 2020-10-13 18:26:41 +00:00
examples [ORC][examples] Temporarily remove LLJITWithChildProcess until ORC TPC lands 2020-10-01 10:25:13 +02:00
include Re-land [ThinLTO] Re-order modules for optimal multi-threaded processing 2020-10-13 21:54:15 -04:00
lib Re-land [ThinLTO] Re-order modules for optimal multi-threaded processing 2020-10-13 21:54:15 -04:00
projects
resources
runtimes [CMake] Don't use CMakePushCheckState 2020-10-02 17:13:34 -07:00
test [GISel] Add combine for constant G_PTR_ADD offsets. 2020-10-13 17:26:12 -07:00
tools Reland [CFGuard] Add address-taken IAT tables and delay-load support 2020-10-13 13:20:52 -07:00
unittests Support: Allow use of MemoryBufferRef with line_iterator 2020-10-13 16:43:49 -04:00
utils [gn build] Port f0875971249 2020-10-13 20:50:32 +00:00
.clang-format
.clang-tidy
.gitattributes
.gitignore [clangd] Store index in '.cache/clangd/index' instead of '.clangd/index' 2020-07-07 14:53:45 +02:00
CMakeLists.txt Guard find_library(tensorflow_c_api ...) by checking for TENSORFLOW_C_LIB_PATH to be set by the user 2020-09-28 22:15:55 +00:00
CODE_OWNERS.TXT [CSKY 1/n] Add basic stub or infra of csky backend 2020-10-10 10:44:08 +08:00
configure
CREDITS.TXT [NFC] Add contributors names to CREDITS.TXT 2020-10-07 13:22:55 -04:00
LICENSE.TXT
llvm.spec.in
LLVMBuild.txt
README.txt
RELEASE_TESTERS.TXT

The LLVM Compiler Infrastructure
================================

This directory and its subdirectories contain source code for LLVM,
a toolkit for the construction of highly optimized compilers,
optimizers, and runtime environments.

LLVM is open source software. You may freely distribute it under the terms of
the license agreement found in LICENSE.txt.

Please see the documentation provided in docs/ for further
assistance with LLVM, and in particular docs/GettingStarted.rst for getting
started with LLVM and docs/README.txt for an overview of LLVM's
documentation setup.

If you are writing a package for LLVM, see docs/Packaging.rst for our
suggestions.