diff options
author | greg-lunarg <greg@lunarg.com> | 2020-03-12 07:19:52 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-12 09:19:52 -0400 |
commit | 1fe9bcc10824c1fa35bd9b697188340132d39213 (patch) | |
tree | 6f82277f348a8d623ec718a5e651d19ac49b1fd1 /include/spirv-tools/instrument.hpp | |
parent | 6428ad05e706567945faf0fa0ae6257bb6006733 (diff) | |
download | spirv-tools-1fe9bcc10824c1fa35bd9b697188340132d39213.tar.gz |
Instrument: Debug Printf support (#3215)
Create a pass to instrument OpDebugPrintf instructions. This pass replaces all OpDebugPrintf instructions with instructions to write a record containing the string id and the all specified values into a special printf output buffer (if space allows). This pass is designed to support the printf validation in the Vulkan validation layers.
Fixes #3210
Diffstat (limited to 'include/spirv-tools/instrument.hpp')
-rw-r--r-- | include/spirv-tools/instrument.hpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/spirv-tools/instrument.hpp b/include/spirv-tools/instrument.hpp index 2dcb3331..d3180e44 100644 --- a/include/spirv-tools/instrument.hpp +++ b/include/spirv-tools/instrument.hpp @@ -208,6 +208,9 @@ static const int kDebugInputBindingBindless = 1; // The binding for the input buffer read by InstBuffAddrCheckPass. static const int kDebugInputBindingBuffAddr = 2; +// This is the output buffer written by InstDebugPrintfPass. +static const int kDebugOutputPrintfStream = 3; + // Bindless Validation Input Buffer Format // // An input buffer for bindless validation consists of a single array of |