[webkit-changes] [WebKit/WebKit] 3c5f1d: [WGSL] Fill callee map in CallGraph
Tadeu Zagallo
noreply at github.com
Tue May 23 00:02:42 PDT 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 3c5f1d037db65f8c010e200b0591a2c52ef8ad79
https://github.com/WebKit/WebKit/commit/3c5f1d037db65f8c010e200b0591a2c52ef8ad79
Author: Tadeu Zagallo <tzagallo at apple.com>
Date: 2023-05-23 (Tue, 23 May 2023)
Changed paths:
M Source/WebGPU/WGSL/CallGraph.cpp
M Source/WebGPU/WGSL/CallGraph.h
M Source/WebGPU/WGSL/Metal/MetalFunctionWriter.cpp
Log Message:
-----------
[WGSL] Fill callee map in CallGraph
https://bugs.webkit.org/show_bug.cgi?id=257137
rdar://109667946
Reviewed by Dan Glastonbury.
So far, the CallGraph has only been used as a list of entry points in addition
to the ShaderModule. This patch actually builds the map from any reachable
function to all its callees. For each callee we also list all the call sites,
which will be helpful in a follow-up patch when we write each call site to
pass the globals around.
* Source/WebGPU/WGSL/CallGraph.cpp:
(WGSL::CallGraphBuilder::initializeMappings):
(WGSL::CallGraphBuilder::visit):
* Source/WebGPU/WGSL/CallGraph.h:
(WGSL::CallGraph::callees const):
* Source/WebGPU/WGSL/Metal/MetalFunctionWriter.cpp:
(WGSL::Metal::FunctionDefinitionWriter::visit):
Canonical link: https://commits.webkit.org/264407@main
More information about the webkit-changes
mailing list