[llvm] r371445 - [SDAG] Add a isSimple cover functon to MemSDNode, just as we have in IR/MI [NFC]
Philip Reames via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 9 13:06:19 PDT 2019
Author: reames
Date: Mon Sep 9 13:06:19 2019
New Revision: 371445
URL: http://llvm.org/viewvc/llvm-project?rev=371445&view=rev
Log:
[SDAG] Add a isSimple cover functon to MemSDNode, just as we have in IR/MI [NFC]
Uses are in reviews D66322 and D66318. Submitted separately to control rebuild times.
Modified:
llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h
Modified: llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h?rev=371445&r1=371444&r2=371445&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h (original)
+++ llvm/trunk/include/llvm/CodeGen/SelectionDAGNodes.h Mon Sep 9 13:06:19 2019
@@ -1361,6 +1361,9 @@ public:
/// aliasing rules.
bool isUnordered() const { return MMO->isUnordered(); }
+ /// Returns true if the memory operation is neither atomic or volatile.
+ bool isSimple() const { return !isAtomic() && !isVolatile(); }
+
/// Return the type of the in-memory value.
EVT getMemoryVT() const { return MemoryVT; }
More information about the llvm-commits
mailing list