Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • L linux
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Kirill Smelkov
  • linux
  • Repository
You need to sign in or sign up before continuing.
  • linux
  • scripts
  • Makefile.modfinal
Find file BlameHistoryPermalink
  • Sami Tolvanen's avatar
    kbuild: Fix TRIM_UNUSED_KSYMS with LTO_CLANG · 850ded46
    Sami Tolvanen authored Aug 16, 2021
    With CONFIG_LTO_CLANG, we currently link modules into native
    code just before modpost, which means with TRIM_UNUSED_KSYMS
    enabled, we still look at the LLVM bitcode in the .o files when
    generating the list of used symbols. As the bitcode doesn't
    yet have calls to compiler intrinsics and llvm-nm doesn't see
    function references that only exist in function-level inline
    assembly, we currently need a whitelist for TRIM_UNUSED_KSYMS to
    work with LTO.
    
    This change moves module LTO linking to happen earlier, and
    thus avoids the issue with LLVM bitcode and TRIM_UNUSED_KSYMS
    entirely, allowing us to also drop the whitelist from
    gen_autoksyms.sh.
    
    Link: https://github.com/ClangBuiltLinux/linux/issues/1369
    
    
    Signed-off-by: default avatarSami Tolvanen <samitolvanen@google.com>
    Reviewed-by: default avatarAlexander Lobakin <alobakin@pm.me>
    Tested-by: default avatarAlexander Lobakin <alobakin@pm.me>
    Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
    850ded46
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7