[llvm] Extend MemoryEffects to Support Target-Specific Memory Locations (PR #148650)
Paul Walker via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 14 08:35:04 PDT 2025
================
@@ -640,6 +640,13 @@ std::string Attribute::getAsString(bool InAttrGrp) const {
if (MR == OtherMR)
continue;
+ // Dont Print Target Location if MR and target_mems ModRefInfo
+ // are NoModRef.
+ // Printing Inacessiblemem: none implies that target_mems are also
+ // not affected.
+ if (ME.isTargetMemLoc(Loc) && (MR == ModRefInfo::NoModRef))
+ continue;
----------------
paulwalker-arm wrote:
It just occurred to me that if we're using short hand to reduce the IR output then you'll need to update `LLParser::parseMemoryAttr` because it must be applied in reverse when reading the IR back in.
https://github.com/llvm/llvm-project/pull/148650
More information about the llvm-commits
mailing list