-
Notifications
You must be signed in to change notification settings - Fork 335
Rename image copies -> texel copies #4838
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
c3bb6d3
to
472d734
Compare
Previews, as seen when this build job started (f828d32): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a breaking change either from what I can tell, since these are all dictionaries.
GPU Web WG 2024-09-04 Atlantic-time
|
Here are my suggestions:
|
From meeting discussion:
|
c3f70aa
to
0f92005
Compare
64384cb
to
f828d32
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM again, thanks for continuing to push this forward!
* [subst] GPUImageDataLayout -> GPUTexelCopyBufferLayout * [subst] GPUImageCopyBuffer -> GPUTexelCopyBufferInfo * [subst] GPUImageCopyTexture -> GPUTexelCopyTextureInfo * [subst] GPUImageCopyTextureTagged -> GPUCopyExternalImageDestInfo * [subst] GPUImageCopyExternalImage -> GPUCopyExternalImageSourceInfo * [subst] GPUImageCopyExternalImageSource -> GPUCopyExternalImageSource * image {copy,data} -> texel {copy,data} * image copy -> [=texel copy=] * update section headers * [subst] |imageCopyTexture| -> |texelCopyTextureInfo| * [subst] Update algorithm name * [subst] |dataLayout| -> |bufferLayout| * Add docs to explain the names * Restore approximate link for #typedefdef-gpuimagecopyexternalimagesource
GPU Web WG 2024-10-29/30 Mountain View F2F
|
This commit was authored by running the following Nushell script, using the `nu` binary and the lovely `fastmod` tool: ```nushell # Copy-pasted from the OP in [`gpuweb`gfx-rs#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update old { strip_gpu_prefix | str trim } | update new { strip_gpu_prefix | str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) def strip_gpu_prefix []: string -> string { $in | str replace --regex '^GPU' '' } # Rename image APIs. for entry in $renames_table { fastmod --accept-all --fixed-strings $entry.old $entry.new --iglob '!CHANGELOG.md' --iglob "!xtask/src/vendor_web_sys.rs" --iglob '!wgpu/src/backend/webgpu/webgpu_sys/' --iglob '!deno_webgpu/' } cargo fmt ``` …and cleaning up `deno_webgpu/`'s Rust compilation errors.
This commit was authored by running the following Nushell script, using the `nu` binary and the lovely `fastmod` tool: ```nushell # Copy-pasted from the OP in [`gpuweb`gfx-rs#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update old { strip_gpu_prefix | str trim } | update new { strip_gpu_prefix | str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) def strip_gpu_prefix []: string -> string { $in | str replace --regex '^GPU' '' } # Rename image APIs. for entry in $renames_table { fastmod --accept-all --fixed-strings $entry.old $entry.new --iglob '!CHANGELOG.md' --iglob "!xtask/src/vendor_web_sys.rs" --iglob '!wgpu/src/backend/webgpu/webgpu_sys/' --iglob '!deno_webgpu/' --iglob '!wgpu/src/backend/webgpu.rs' } cargo fmt ``` …and cleaning up `deno_webgpu/`'s Rust compilation errors.
This commit was authored by running the following Nushell script, using the `nu` binary and the lovely `fastmod` tool: ```nushell # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update old { strip_gpu_prefix | str trim } | update new { strip_gpu_prefix | str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) def strip_gpu_prefix []: string -> string { $in | str replace --regex '^GPU' '' } # Rename image APIs. for entry in $renames_table { fastmod --accept-all --fixed-strings $entry.old $entry.new --iglob '!CHANGELOG.md' --iglob "!xtask/src/vendor_web_sys.rs" --iglob '!wgpu/src/backend/webgpu/webgpu_sys/' --iglob '!deno_webgpu/' --iglob '!wgpu/src/backend/webgpu.rs' } cargo fmt ``` …and cleaning up `deno_webgpu/`'s Rust compilation errors.
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193 UltraBlame original commit: 08a24ec855174eaf82c2da1069d7778f2edc70fc
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193 UltraBlame original commit: 155ce9b483bd2e947c85fa85b24c9c0866240432
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193 UltraBlame original commit: 08a24ec855174eaf82c2da1069d7778f2edc70fc
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193 UltraBlame original commit: 155ce9b483bd2e947c85fa85b24c9c0866240432
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193 UltraBlame original commit: 08a24ec855174eaf82c2da1069d7778f2edc70fc
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193 UltraBlame original commit: 155ce9b483bd2e947c85fa85b24c9c0866240432
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193
…m upstream IDL r=webgpu-reviewers,webidl,teoxoy,emilio Driven by [gpuweb#4838](gpuweb/gpuweb#4838). The vast majority of this script was implemented with a Nushell script, using the `nu` binary and the wonderful `fastmod` tool ``` # Copy-pasted from the OP in [`gpuweb`#4838](gpuweb/gpuweb#4838). let renames_table = ' Type Old New Used in dict GPUImageDataLayout GPUTexelCopyBufferLayout "writeTexture, parent type of ↙" dict GPUImageCopyBuffer "GPUTexelCopyBufferInfo extends ↑" T2B, B2T dict GPUImageCopyTexture GPUTexelCopyTextureInfo T2B, B2T, T2T, writeTexture dict GPUImageCopyTextureTagged "GPUCopyExternalImageDestInfo extends ↑" copyExternalImageToTexture dict GPUImageCopyExternalImage GPUCopyExternalImageSourceInfo copyExternalImageToTexture union GPUImageCopyExternalImageSource GPUCopyExternalImageSource member of ↖ ' let renames_table = $renames_table | from tsv | select 'Old ' 'New ' | rename old new | update new { $in | lines | get 0 } # only the first line has the renamed symbol identifier | update new { str trim } | update old { str trim } | sort-by old | reverse # Replace most specific symbol names first (some have the same "word segments" but with fewer segments) # Rename image APIs. let rename_paths = [ ...("dom/webgpu/*.{cpp,h}" | str expand) "dom/webidl/WebGPU.webidl" ] | each { glob $in } | flatten for entry in $renames_table { print $'replacing ($entry.old | to nuon) with ($entry.new | to nuon)' fastmod --accept-all $'\b($entry.old)' $entry.new ...$rename_paths } ``` Differential Revision: https://phabricator.services.mozilla.com/D230193
Re-done against
main
, with new names, 2024-10-30.Commits titled
[subst]
are done by strict (case-sensitive, whole word) find-and-replace.GPUImageDataLayout
GPUTexelCopyBufferLayout
parent type of ↙
GPUImageCopyBuffer
GPUTexelCopyBufferInfo
extends ↑
GPUImageCopyTexture
GPUTexelCopyTextureInfo
GPUImageCopyTextureTagged
GPUCopyExternalImageDestInfo
extends ↑
GPUImageCopyExternalImage
GPUCopyExternalImageSourceInfo
GPUImageCopyExternalImageSource
GPUCopyExternalImageSource
Fixes #4573