[llvm] 6c4931e - [docs] Fix codeblock.
Alina Sbirlea via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 17 15:54:37 PDT 2022
Author: Alina Sbirlea
Date: 2022-03-17T15:53:20-07:00
New Revision: 6c4931e7d085510930e56656ad141e745b1ca72e
URL: https://github.com/llvm/llvm-project/commit/6c4931e7d085510930e56656ad141e745b1ca72e
DIFF: https://github.com/llvm/llvm-project/commit/6c4931e7d085510930e56656ad141e745b1ca72e.diff
LOG: [docs] Fix codeblock.
Added:
Modified:
llvm/docs/MemorySSA.rst
Removed:
################################################################################
diff --git a/llvm/docs/MemorySSA.rst b/llvm/docs/MemorySSA.rst
index 2052531d619a5..46e06603ea337 100644
--- a/llvm/docs/MemorySSA.rst
+++ b/llvm/docs/MemorySSA.rst
@@ -293,6 +293,7 @@ to it.
A code snippet for such a walk looks like this:
.. code-block:: c++
+
MemoryDef *Def; // find who's optimized or defining for this MemoryDef
for (auto& U : Def->uses()) {
MemoryAccess *MA = cast<MemoryAccess>(Use.getUser());
@@ -309,6 +310,7 @@ clobbered by that store by walking the immediate and transitive uses of
the store.
.. code-block:: c++
+
checkUses(MemoryAccess *Def) { // Def can be a MemoryDef or a MemoryPhi.
for (auto& U : Def->uses()) {
MemoryAccess *MA = cast<MemoryAccess>(Use.getUser());
More information about the llvm-commits
mailing list