[llvm] [RFC] Memory Model Relaxation Annotations (PR #78569)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 16 01:48:22 PDT 2024
================
@@ -496,7 +497,8 @@ void Instruction::dropUBImplyingAttrsAndMetadata() {
// !noundef and various AA metadata must be dropped, as it generally produces
// immediate undefined behavior.
unsigned KnownIDs[] = {LLVMContext::MD_annotation, LLVMContext::MD_range,
- LLVMContext::MD_nonnull, LLVMContext::MD_align};
+ LLVMContext::MD_nonnull, LLVMContext::MD_align,
+ LLVMContext::MD_mmra};
----------------
nikic wrote:
The statement you are making here is (basically) that it is fine to speculate a load with `!mmra` metadata, without dropping the metadata. That doesn't sound right?
(I doubt it matters in practice given that the load would presumably be atomic and we'd not speculative it because of that anyway, but this still looks suspect to me.)
https://github.com/llvm/llvm-project/pull/78569
More information about the llvm-commits
mailing list