这是indexloc提供的服务,不要输入任何密码
Skip to content

Consolidate *loadOp and clear* into a unioned field #283

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

Merged
merged 4 commits into from
Jul 22, 2019

Conversation

kainino0x
Copy link
Contributor

@kainino0x kainino0x commented May 8, 2019

Followup to #276.


Preview | Diff

spec/index.bs Outdated
"load"
"load",
"opaqueBlack",
"zero"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

opaqueBlack and zero are up for discussion.

Copy link
Contributor

Choose a reason for hiding this comment

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

Prefer not to duplicate functionality of GPUColor.

Copy link
Contributor

@kdashg kdashg left a comment

Choose a reason for hiding this comment

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

TBH I think I prefer using a nullable clearColor, such that "load" is the default, but we'll clear instead if users specify a clearColor.
"load" is the conceptual default, so I think it's not completely crazy.

spec/index.bs Outdated
"load"
"load",
"opaqueBlack",
"zero"
Copy link
Contributor

Choose a reason for hiding this comment

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

Prefer not to duplicate functionality of GPUColor.

Copy link
Contributor

@kdashg kdashg left a comment

Choose a reason for hiding this comment

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

I'll mark this "request changes", but you can convince me otherwise.

@kvark
Copy link
Contributor

kvark commented May 8, 2019

@jdashg

TBH I think I prefer using a nullable clearColor, such that "load" is the default, but we'll clear instead if users specify a clearColor.

That's exactly what #276 did, and your feedback was that it was "gross".
The reasoning was discussed in the call as well as in #276 (comment).

TL;DR: defaulting to non-clear is bad for performance

@kdashg
Copy link
Contributor

kdashg commented May 8, 2019

My opinions are mutable, and my comment was made for my /Approval/ of that PR!

My preferences:

  1. loadOp: "clear", "load"
    clearColor with default
  2. clearColor nullable, null => load
  3. This PR

@kvark
Copy link
Contributor

kvark commented May 8, 2019

@jdashg understood. Please also check out #284

@kainino0x
Copy link
Contributor Author

Merging with verbal approval in the meeting from Myles, Rafael, and others.

@kainino0x kainino0x closed this Jul 22, 2019
@kainino0x kainino0x reopened this Jul 22, 2019
@kainino0x kainino0x merged commit 1569432 into gpuweb:master Jul 22, 2019
@kainino0x kainino0x deleted the loadops branch July 22, 2019 22:20
aarongable pushed a commit to chromium/chromium that referenced this pull request Jul 24, 2019
Following WebGPU spec change at gpuweb/gpuweb#283,
this CL makes sure *loadOp and clear* are consolidated into an unioned
field in GPURenderPassColorAttachmentDescriptor and
GPURenderPassDepthStencilAttachmentDescriptor.

Bug: 877147
Change-Id: I4a676e8cfa52844f2df54b6201e6db453c1d9e9f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1715267
Reviewed-by: Kentaro Hara <haraken@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: François Beaufort <beaufort.francois@gmail.com>
Cr-Commit-Position: refs/heads/master@{#680373}
ben-clayton pushed a commit to ben-clayton/gpuweb that referenced this pull request Sep 6, 2022
* Add texture usage validation scope test

Resource usages validation should be done per each render pass.
Inside a pass, resource usage conflict should always validated.
But resource usage conflict between passes is not a problem.

* Address Kai's feedback: put createNoOpRenderPipeline to a function in ValidationTest

* code rebase

* Address Kai's feedback: separate into a few tests
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.

3 participants