[OpenMP] Make linker wrapper thin-lto default thread count use all

Summary:
Currently there is no option to configure the number of thin-backend
threads to use when performing thin-lto on the device, but we should
default to use all the threads rather than just one. In the future we
should use the same arguments that gold / lld use and parse it here.
This commit is contained in:
Joseph Huber 2022-04-01 09:42:21 -04:00
parent 73c0333dee
commit 69a77771a9
1 changed files with 2 additions and 2 deletions

View File

@ -858,8 +858,8 @@ std::unique_ptr<lto::LTO> createLTO(
lto::Config Conf;
lto::ThinBackend Backend;
// TODO: Handle index-only thin-LTO
Backend = lto::createInProcessThinBackend(
llvm::heavyweight_hardware_concurrency(1));
Backend =
lto::createInProcessThinBackend(llvm::heavyweight_hardware_concurrency());
Conf.UseDefaultPipeline = true;
Conf.CPU = Arch.str();