nir_validate.c's #endif already had the correct NDEBUG comment
Fixes: dcb1acdea00a8f2c29777 "nir/validate: Only build in debug mode"
Fixes: 9ff71b649b4b3808a9e17 "i965/nir: Validate that NIR passes call nir_metadata_preserve()"
Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
#include "compiler/shader_info.h"
#include <stdio.h>
-#ifdef DEBUG
+#ifndef NDEBUG
#include "util/debug.h"
-#endif /* DEBUG */
+#endif /* NDEBUG */
#include "nir_opcodes.h"
nir_shader *nir_shader_serialize_deserialize(void *mem_ctx, nir_shader *s);
-#ifdef DEBUG
+#ifndef NDEBUG
void nir_validate_shader(nir_shader *shader);
void nir_metadata_set_validation_flag(nir_shader *shader);
void nir_metadata_check_validation_flag(nir_shader *shader);
static inline bool should_clone_nir(void) { return false; }
static inline bool should_serialize_deserialize_nir(void) { return false; }
static inline bool should_print_nir(void) { return false; }
-#endif /* DEBUG */
+#endif /* NDEBUG */
#define _PASS(nir, do_pass) do { \
do_pass \
impl->valid_metadata &= preserved;
}
-#ifdef DEBUG
+#ifndef NDEBUG
/**
* Make sure passes properly invalidate metadata (part 1).
*
/* Since this file is just a pile of asserts, don't bother compiling it if
* we're not building a debug build.
*/
-#ifdef DEBUG
+#ifndef NDEBUG
/*
* Per-register validation state.