[PATCH] D91516: [AMDGPU][WIP] Lower Function Local LDS Variables.
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 26 19:45:16 PST 2021
arsenm added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/AMDGPULowerFunctionLocalLDS.cpp:376-379
+ // Push the `CallGraphNode` associated with all the callees of the kernel`K`
+ // into into `CGNodeStack`, and the corresponding call sites into
+ // `CallBaseStack`.
+ pushCallGraphNodes(KernCGNode, CGNodeStack, CallBaseStack);
----------------
hsmhsm wrote:
> arsenm wrote:
> > I think you're overcomplicating the CallGraph usage by ignoring most of what it gives you. You should be able to just iterate directly through the CallGraph to get functions reachable from the parent
> As far as I understand it, llvm `CallGraph` infrastructure does not provide any facility as such. Implementer needs to explicitly iterate the callees of the caller.
The CallGraph as a whole gives you the functions reachable from each other. I don't think you need to do a stack walk to find the callees. You don't need to care about which functions specifically call which, just that they are all connected
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91516/new/
https://reviews.llvm.org/D91516
More information about the llvm-commits
mailing list