Skip to content
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

Prefix every wgpu-generated label with (wgpu). #2590

Merged
merged 1 commit into from
Apr 16, 2022
Merged

Conversation

kpreid
Copy link
Contributor

@kpreid kpreid commented Apr 12, 2022

This is intended to help developers new to wgpu or to graphics debugging quickly recognize in a debugging tool which items are wgpu-generated, as opposed to either part of their program or part of the platform graphics system.

I also removed existing marker-like text such as leading underscores and angle brackets. I'm not sure if this was the right decision, but they seemed arbitrary.

Testing

  • The wgpu test suite gets as far as it does on my machine without this change.
  • Running with a GPU debugger (Xcode/Metal) shows the changed labels as I expect.

Copy link
Member

@cwfitzgerald cwfitzgerald left a comment

Choose a reason for hiding this comment

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

I think this is a good change, but we might want to say like (wgpu internal) to be clear that it's an internal resource, not just one made with wgpu

This is intended to help developers new to wgpu or to graphics debugging
quickly recognize in a debugging tool which items are wgpu-generated, as
opposed to either part of their program or part of the platform graphics
system.

I also removed existing marker-like text such as leading underscores and
angle brackets.
@kpreid
Copy link
Contributor Author

kpreid commented Apr 12, 2022

… but we might want to say like (wgpu internal)

Done.

@kpreid
Copy link
Contributor Author

kpreid commented Apr 12, 2022

Another idea I had while working on this: some of the objects could be usefully labeled after the other object they're being used to operate on. However, that would require allocating strings, so it would make more sense as an optional feature for debugging.

@kpreid
Copy link
Contributor Author

kpreid commented Apr 16, 2022

The check failure log doesn't give any information other than

        FAIL [   0.485s]              wgpu::example/shadow shadow

and it doesn't look like the shadow test should care about labels. Should I be doing something here?

@kvark
Copy link
Member

kvark commented Apr 16, 2022

@cwfitzgerald same lavapipe issue?

@cwfitzgerald
Copy link
Member

Just needs to be rebased on top of master.

@kvark kvark merged commit cb7ad30 into gfx-rs:master Apr 16, 2022
@kvark
Copy link
Member

kvark commented Apr 16, 2022

easy peasy

@kpreid kpreid deleted the label branch July 2, 2022 15:11
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