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

Behavior of endPass() and pass commands after pass has ended #2464

@kainino0x

Description

@kainino0x

#2264:

While working on #2452 I found I would like to extend this to passes as well: once a pass has ended, attempting to encode commands generates a validation error instead of marking the encoder as invalid.

This is nice because it means invalid commands can just "locally" make their pass encoder invalid instead of needing a way to reach out to the top-level encoder and make that invalid after endPass() has already happened.

In #2452 I changed the behavior and then forgot about it before landing it.

So we have to determine: when you endPass() or encode a pass command after a pass has ended:

  1. (Before 2452) silently make the top-level encoder invalid? (This is exceptional if you consider validity to be local to the pass, and in 2452 I've made it so pass commands don't otherwise affect the top-level encoder)
  2. (After 2452) generate a GPUValidationError? (This is exceptional if you consider "pass must be open" to be just another validation rule rather than a special rule in encoding pass commands)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions