[webkit-changes] [WebKit/WebKit] 178b3a: [WGSL] Continuing should not apply to its own block

Tadeu Zagallo noreply at github.com
Wed Jan 31 05:55:28 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 178b3aea111f889d396cf6de333314186deb20f7
      https://github.com/WebKit/WebKit/commit/178b3aea111f889d396cf6de333314186deb20f7
  Author: Tadeu Zagallo <tzagallo at apple.com>
  Date:   2024-01-31 (Wed, 31 Jan 2024)

  Changed paths:
    M Source/WebGPU/WGSL/Metal/MetalFunctionWriter.cpp
    M Source/WebGPU/WGSL/tests/valid/loop.wgsl

  Log Message:
  -----------
  [WGSL] Continuing should not apply to its own block
https://bugs.webkit.org/show_bug.cgi?id=268397
rdar://121520338

Reviewed by Mike Wyrzykowski.

Take the following code:
  loop { continuing { loop { continue; } } }

The continuing block does not apply to the nested continue statement, so we need
to clear the reference to the continuing while visiting its block.

* Source/WebGPU/WGSL/Metal/MetalFunctionWriter.cpp:
(WGSL::Metal::FunctionDefinitionWriter::visit):
* Source/WebGPU/WGSL/tests/valid/loop.wgsl:

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




More information about the webkit-changes mailing list