diff options
Diffstat (limited to 'llvm/lib/Transforms/Utils/Local.cpp')
-rw-r--r-- | llvm/lib/Transforms/Utils/Local.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Utils/Local.cpp b/llvm/lib/Transforms/Utils/Local.cpp index 509b6d6..6cbfa12 100644 --- a/llvm/lib/Transforms/Utils/Local.cpp +++ b/llvm/lib/Transforms/Utils/Local.cpp @@ -3336,8 +3336,9 @@ void llvm::combineMetadata(Instruction *K, const Instruction *J, K->setMetadata(Kind, MDNode::intersect(JMD, KMD)); break; case LLVMContext::MD_access_group: - K->setMetadata(LLVMContext::MD_access_group, - intersectAccessGroups(K, J)); + if (DoesKMove) + K->setMetadata(LLVMContext::MD_access_group, + intersectAccessGroups(K, J)); break; case LLVMContext::MD_range: if (DoesKMove || !K->hasMetadata(LLVMContext::MD_noundef)) |