[clang] [llvm] [InstrProf] Remove PGO name reading and writing (PR #214134)

Teresa Johnson via cfe-commits cfe-commits at lists.llvm.org
Wed Sep 2 09:58:07 PDT 2026


================
@@ -558,8 +513,9 @@ Error InstrProfSymtab::addVTableWithName(GlobalVariable &VTable,
       return E;
 
     bool Inserted = true;
-    std::tie(std::ignore, Inserted) = MD5VTableMap.try_emplace(
-        GlobalValue::getGUIDAssumingExternalLinkage(Name), &VTable);
+    uint64_t GUID = VTable.getGUIDIfAssigned().value_or(
----------------
teresajohnson wrote:

I see this same pattern ( getGUIDIfAssigned().value_or(GlobalValue::getGUIDAssumingExternalLinkage(Name)) ) repeating a couple times in this PR - does it make sense for it to be a method on the GV? Or is it pretty limited to these 2 instances?

https://github.com/llvm/llvm-project/pull/214134


More information about the cfe-commits mailing list