[all-commits] [llvm/llvm-project] 8de789: [ThinLTO] Populate declaration import status excep...
Mingming Liu via All-commits
all-commits at lists.llvm.org
Sun May 19 22:23:08 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 8de7890572296830b27b6e6db39b36810bc98c31
https://github.com/llvm/llvm-project/commit/8de7890572296830b27b6e6db39b36810bc98c31
Author: Mingming Liu <mingmingl at google.com>
Date: 2024-05-19 (Sun, 19 May 2024)
Changed paths:
M llvm/include/llvm/IR/ModuleSummaryIndex.h
M llvm/include/llvm/Transforms/IPO/FunctionImport.h
M llvm/lib/LTO/LTO.cpp
M llvm/lib/LTO/LTOBackend.cpp
M llvm/lib/Transforms/IPO/FunctionImport.cpp
M llvm/test/ThinLTO/X86/funcimport-stats.ll
A llvm/test/ThinLTO/X86/import_callee_declaration.ll
M llvm/test/Transforms/FunctionImport/funcimport.ll
M llvm/tools/llvm-link/llvm-link.cpp
Log Message:
-----------
[ThinLTO] Populate declaration import status except for distributed ThinLTO under a default-off new option (#88024)
The goal is to populate `declaration` import status if a new flag`-import-declaration` is on.
* For in-process ThinLTO, the `declaration` status is visible to backend
`function-import` pass, so `FunctionImporter::importFunctions` should
read the import status and be no-op for declaration summaries.
Basically, the postlink pipeline is updated to keep its current behavior
(import definitions), but not updated to handle `declaration` summaries.
Two use cases (better call-graph sort and cross-module auto-init)
would use this bit differently.
* For distributed ThinLTO, the `declaration` status is not serialized to
bitcode. As discussed, https://github.com/llvm/llvm-project/pull/87600
will do this.
[1] https://discourse.llvm.org/t/rfc-for-better-call-graph-sort-build-a-more-complete-call-graph-by-adding-more-indirect-call-edges/74029#support-cross-module-function-declaration-import-5
[2] https://github.com/llvm/llvm-project/pull/87597#discussion_r1556067195
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list