KhronosGroup / Vulkan-LoaderAndValidationLayers

**Deprecated repository** for Vulkan loader and validation layers
Apache License 2.0
414 stars 172 forks source link

Providing stack trace in messages when validation is delayed #2641

Open fduranleau-gl opened 6 years ago

fduranleau-gl commented 6 years ago

We know that some validation can not be done immediately when recording a command (e.g. tracking image layout). So some of them are deferred at submission time. However, if we hit an error (or a warning) there, then we lose the context from where the offending command comes.

So, a nice (and non-intrusive) feature that would be very practical is if, for such deferred validation, information about the call stack could be saved (at record time) and displayed along with messages. This should be possible to implement at least on some platforms.

mark-lunarg commented 6 years ago

Thanks @fduranleau-gl!

chrisforbes commented 6 years ago

This is a really neat idea, but likely expensive to do... :+1:

fduranleau-gl commented 6 years ago

There certainly is a cost. Maybe it could be an opt-in feature?