Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 3d3c9d7305a521d954325bac38b15dd7f4c2fc6d
      
https://github.com/WebKit/WebKit/commit/3d3c9d7305a521d954325bac38b15dd7f4c2fc6d
  Author: Tadeu Zagallo <[email protected]>
  Date:   2023-06-07 (Wed, 07 Jun 2023)

  Changed paths:
    M Source/WebGPU/WGSL/GlobalVariableRewriter.cpp
    M Source/WebGPU/WGSL/tests/valid/global-used-by-callee.wgsl

  Log Message:
  -----------
  [WGSL] Only rewrite globals in callees once
https://bugs.webkit.org/show_bug.cgi?id=257716
rdar://110265430

Reviewed by Dan Glastonbury.

A callee might be reached through multiple paths in the call graph (e.g. f->h 
and
f->g->h), so we need to keep track of the callees we already visited. However, 
when
we encounter a callee we already visited we (might) still need to rewrite all 
the
call sites to that callee if its signature was modified (i.e. if it needs global
variable(s) to be passed to it).

* Source/WebGPU/WGSL/GlobalVariableRewriter.cpp:
(WGSL::RewriteGlobalVariables::visitCallee):
* Source/WebGPU/WGSL/tests/valid/global-used-by-callee.wgsl:

Canonical link: https://commits.webkit.org/264931@main


_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to