summaryrefslogtreecommitdiffstats
path: root/src/compiler/spirv/nir_spirv.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/spirv/nir_spirv.h')
-rw-r--r--src/compiler/spirv/nir_spirv.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/compiler/spirv/nir_spirv.h b/src/compiler/spirv/nir_spirv.h
index 234b0ce3444..f129a205764 100644
--- a/src/compiler/spirv/nir_spirv.h
+++ b/src/compiler/spirv/nir_spirv.h
@@ -42,6 +42,12 @@ struct nir_spirv_specialization {
};
};
+enum nir_spirv_debug_level {
+ NIR_SPIRV_DEBUG_LEVEL_INFO,
+ NIR_SPIRV_DEBUG_LEVEL_WARNING,
+ NIR_SPIRV_DEBUG_LEVEL_ERROR,
+};
+
struct spirv_to_nir_options {
struct {
bool float64;
@@ -54,6 +60,14 @@ struct spirv_to_nir_options {
bool multiview;
bool variable_pointers;
} caps;
+
+ struct {
+ void (*func)(void *private_data,
+ enum nir_spirv_debug_level level,
+ size_t spirv_offset,
+ const char *message);
+ void *private_data;
+ } debug;
};
nir_function *spirv_to_nir(const uint32_t *words, size_t word_count,