Skip to content

Add component governance manifest for WebGPU EP#28599

Open
adrastogi wants to merge 1 commit into
mainfrom
adrastogi/webgpu-cg-manifest
Open

Add component governance manifest for WebGPU EP#28599
adrastogi wants to merge 1 commit into
mainfrom
adrastogi/webgpu-cg-manifest

Conversation

@adrastogi
Copy link
Copy Markdown
Contributor

Description

Added a WebGPU-specific Component Governance manifest for Dawn and related dependencies.

Added documentation for the manifest scope, dependency classification, and maintenance steps. Added a validation script to catch Dawn and DXC pin drift.

Motivation and Context

WebGPU builds depend on Dawn and related components that are not part of vanilla ONNX Runtime builds.

Downstream WebGPU packaging needs ORT-owned metadata to generate complete third-party notices without maintaining a duplicate dependency inventory.

Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can commit the suggested changes from lintrunner.

Comment on lines +110 to +112
raise ValueError(
f"Dawn manifest commit {git['commitHash']} does not match {DEPS_TXT} commit {expected_commit}"
)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
raise ValueError(
f"Dawn manifest commit {git['commitHash']} does not match {DEPS_TXT} commit {expected_commit}"
)
raise ValueError(f"Dawn manifest commit {git['commitHash']} does not match {DEPS_TXT} commit {expected_commit}")

from pathlib import Path
from typing import Any


Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change

@@ -0,0 +1,168 @@
#!/usr/bin/env python3
@@ -0,0 +1,168 @@
#!/usr/bin/env python3

"""Validate WebGPU Component Governance manifest drift."""

from __future__ import annotations
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a WebGPU-scoped Component Governance manifest and supporting tooling/docs so WebGPU packaging pipelines can generate accurate third-party notices for Dawn/DXC and Dawn-derived dependencies without treating them as global ORT deps.

Changes:

  • Added cgmanifests/webgpu/cgmanifest.json capturing Dawn, DXC, and Dawn DEPS-derived git dependencies with classification metadata.
  • Added documentation describing the manifest scope, dependency classification policy, and update workflow.
  • Added a Python validator to detect drift between the manifest and the pinned Dawn commit (cmake/deps.txt) and DXC release (plugin-win-webgpu-stage.yml).
Show a summary per file
File Description
tools/python/validate_webgpu_cgmanifest.py Adds a drift-check script for Dawn commit + DXC release pins referenced by WebGPU builds.
cgmanifests/webgpu/README.md Documents scope, classification policy, and maintenance steps for the WebGPU manifest.
cgmanifests/webgpu/cgmanifest.json New WebGPU-specific dependency inventory (Dawn root + DEPS graph + DXC release metadata).
cgmanifests/README.md Notes the existence/scope of the WebGPU-specific manifest.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 4/4 changed files
  • Comments generated: 4

Comment thread cgmanifests/webgpu/cgmanifest.json
Comment thread tools/python/validate_webgpu_cgmanifest.py
Comment thread cgmanifests/README.md
See [here](https://docs.opensource.microsoft.com/tools/cg/cgmanifest.html) for details. No newline at end of file
See [here](https://docs.opensource.microsoft.com/tools/cg/cgmanifest.html) for details.

The WebGPU-specific manifest is in `webgpu\cgmanifest.json`. It is scoped to builds that enable the WebGPU
Comment on lines +28 to +32
1. Update the Dawn registration to match the `dawn` entry in `cmake\deps.txt`.
2. Re-audit the pinned upstream Dawn `DEPS` file and update Dawn-derived registrations, comments, and
`dependencyRoots`.
3. If the Windows WebGPU plugin pipeline changes the downloaded DXC release, update the DirectXShaderCompiler release
registration to match `tools\ci_build\github\azure-pipelines\stages\plugin-win-webgpu-stage.yml`.

1. Update the Dawn registration to match the `dawn` entry in `cmake\deps.txt`.
2. Re-audit the pinned upstream Dawn `DEPS` file and update Dawn-derived registrations, comments, and
`dependencyRoots`.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this a manual process or is it possible to script it? if it's manual, it would be good to have more detailed instructions on how to do this.

1. Update the Dawn registration to match the `dawn` entry in `cmake\deps.txt`.
2. Re-audit the pinned upstream Dawn `DEPS` file and update Dawn-derived registrations, comments, and
`dependencyRoots`.
3. If the Windows WebGPU plugin pipeline changes the downloaded DXC release, update the DirectXShaderCompiler release
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is the one we're downloading different from Dawn's DirectXShaderCompiler commit?

https://github.com/google/dawn/blob/ec7b457e5bb1fcec6f59733c4f3dd84d2f885a38/DEPS#L373

@guschmue do you know?

Comment thread cgmanifests/README.md
See [here](https://docs.opensource.microsoft.com/tools/cg/cgmanifest.html) for details.

The WebGPU-specific manifest is in `webgpu\cgmanifest.json`. It is scoped to builds that enable the WebGPU
Execution Provider and should be selected explicitly by WebGPU packaging or NOTICE-generation pipelines.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a way to configure this scoping? IIRC, all the cgmanifest.json files were picked up by default.

@@ -0,0 +1,168 @@
#!/usr/bin/env python3
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

perhaps we can put this helper script in the cgmanifests/webgpu directory. it's most relevant there

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants