[llvm] [NFCI][BitcodeReader]Read real GUID from VI as opposed to storing it in map (PR #107735)
Kazu Hirata via llvm-commits
llvm-commits at lists.llvm.org
Sat Sep 7 23:14:01 PDT 2024
kazutakahirata wrote:
Nice finding! Let me see if I understand things correctly.
- We always create an instance of `ValueInfo` with the same GUID as `std::get<2>`.
- Once an instance of `ValueInfo` is created, its pointer portion never changes.
- The pointer portion of `ValueInfo` points to an key-value pair of `GlobalValueSummaryMapTy`, so the key portion, `GUID`, shouldn't change.
So, `std::get<2>(VIAndOriginalGUID)` and `VIAndOriginalGUID.first.getGUID()` must be always the same.
Did I get this right?
https://github.com/llvm/llvm-project/pull/107735
More information about the llvm-commits
mailing list