[all-commits] [llvm/llvm-project] d8a3be: [NFC][IR][GlobalValue] Move externalize helpers to...

MaoJiaping via All-commits all-commits at lists.llvm.org
Wed Sep 16 11:34:27 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: d8a3beaf45538daa59294e7c59987f6fbfe3f491
      https://github.com/llvm/llvm-project/commit/d8a3beaf45538daa59294e7c59987f6fbfe3f491
  Author: MaoJiaping <maojiaping1 at huawei.com>
  Date:   2026-09-16 (Wed, 16 Sep 2026)

  Changed paths:
    M llvm/include/llvm/IR/GlobalValue.h
    R llvm/include/llvm/Transforms/Utils/SplitModuleCommon.h
    M llvm/lib/Target/AMDGPU/AMDGPUSplitModule.cpp
    M llvm/lib/Transforms/Utils/CMakeLists.txt
    M llvm/lib/Transforms/Utils/SplitModule.cpp
    R llvm/lib/Transforms/Utils/SplitModuleCommon.cpp
    M llvm/test/tools/llvm-split/unnamed.ll

  Log Message:
  -----------
  [NFC][IR][GlobalValue] Move externalize helpers to GlobalValue (#223654)

This PR is a revised refactoring of #221181.
To improve generality, it makes the splitting helpers
externalizeGlobal() and nameUnnamedGlobalValue() generic members of
GlobalValue and removes SplitModuleCommon:

- GlobalValue::externalize() promotes a local-linkage global to external
+ hidden and names it if unnamed.
- GlobalValue::nameUnnamed() names unnamed globals __llvm_unnamed.

Co-authored-by: maojiaping <maojiaping1.huawei.com>



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