Skip to content

Commit

Permalink
[js/web] update browser launch cmd flags (microsoft#17658)
Browse files Browse the repository at this point in the history
### Description
update Chromium browser launch command line flags

Canary already using dxc so no need to specify
'--enable-dawn-features=use_dxc' for canary.
  • Loading branch information
fs-eire authored Sep 25, 2023
1 parent f50fa46 commit b2b1408
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions js/web/script/test-runner-cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -493,19 +493,13 @@ async function main() {
karmaArgs.push('--force-localhost');
}
if (webgpu) {
if (browser.includes('Canary')) {
chromiumFlags.push('--enable-dawn-features=allow_unsafe_apis,use_dxc');
} else {
chromiumFlags.push('--enable-dawn-features=use_dxc');
chromiumFlags.push('--disable-dawn-features=disallow_unsafe_apis');
}
// flag 'allow_unsafe_apis' is required to enable experimental features like fp16 and profiling inside pass.
// flag 'use_dxc' is required to enable DXC compiler.
chromiumFlags.push('--enable-dawn-features=allow_unsafe_apis,use_dxc');
}
if (webnn) {
chromiumFlags.push('--enable-experimental-web-platform-features');
}
if (config.options.globalEnvFlags?.webgpu?.profilingMode === 'default') {
chromiumFlags.push('--disable-dawn-features=disallow_unsafe_apis');
}
karmaArgs.push(`--bundle-mode=${args.bundleMode}`);
karmaArgs.push(...chromiumFlags.map(flag => `--chromium-flags=${flag}`));
if (browser.startsWith('Edge')) {
Expand Down

0 comments on commit b2b1408

Please sign in to comment.