[PATCH] D103225: [AMDGPU] Replace non-kernel function uses of LDS globals by pointers.

Jay Foad via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 27 02:34:47 PDT 2021


foad added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/Utils/AMDGPULDSUtils.cpp:44
+
+  // Collect all reachable call graph nodes from given call graph node.
+  SmallPtrSet<CallGraphNode *, 8> collectCGNodes(CallGraphNode *CGN) {
----------------
You say "all reachable ... nodes" but then you only iterate over an SCC, which is different, and will miss some reachable nodes.

If you really want all reachable nodes then use depth_first_ext which will do it all for you. (See EliminateUnreachableBlocks in BasicBlockUtils.cpp for an example of how to use it.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D103225/new/

https://reviews.llvm.org/D103225



More information about the llvm-commits mailing list