[PATCH] D52785: [PseudoSourceValue] New category to represent floating-point status

Hal Finkel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 4 19:54:35 PDT 2018


hfinkel added a comment.

> I'm not sure where it's documented, but MMOs are definitely not guaranteed to be preserved (except in global-isel, the verifier enforces this for some of the G_* instructions). I'm not aware of anywhere specifically dropping them, but code is not required to preserve them.

Why do you say this?

> I had thought that we'd already need to preserve MMOs, since they contain flags like atomic, nontemporal, or volatile accesses, which likewise would change semantics if dropped.

Not all of these things are equivalent, as their semantics are assumed to be also part of the instruction. Volatile, however, is not, and that needs to be preserved. I believe that we depend on the fact that MachineInstr::isDereferenceableInvariantLoad returns false for volatile MMOs to prevent MachineCSE from removing some volatile loads.


Repository:
  rL LLVM

https://reviews.llvm.org/D52785





More information about the llvm-commits mailing list