summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/nouveau/nvc0
diff options
context:
space:
mode:
authorIlia Mirkin <[email protected]>2019-07-25 23:23:08 -0400
committerIlia Mirkin <[email protected]>2019-07-27 18:24:11 -0400
commit23dfff0669ef351372379b517b455cee2f9bb9c7 (patch)
treec610076e92c7d3622cb104b668df5f17da3defac /src/gallium/drivers/nouveau/nvc0
parent9f8ed5aa6783a3dabefa96fe68d0367703dec91c (diff)
nouveau: flip DEBUG -> !NDEBUG
The meson conversion chose to change the meaning of DEBUG to "used for debugging" to be "used for expensive things for debugging", primarily for nir_validate. Flip things over so that we get nice things with optimizations enabled. While we're at it, also kill off nouveau_statebuf.h which is unused (and has a mention of DEBUG which is how I found it). Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Karol Herbst <[email protected]>
Diffstat (limited to 'src/gallium/drivers/nouveau/nvc0')
-rw-r--r--src/gallium/drivers/nouveau/nvc0/nvc0_program.c8
-rw-r--r--src/gallium/drivers/nouveau/nvc0/nve4_compute.c6
2 files changed, 7 insertions, 7 deletions
diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_program.c b/src/gallium/drivers/nouveau/nvc0/nvc0_program.c
index 180b31ea893..32487248c7a 100644
--- a/src/gallium/drivers/nouveau/nvc0/nvc0_program.c
+++ b/src/gallium/drivers/nouveau/nvc0/nvc0_program.c
@@ -544,7 +544,7 @@ nvc0_program_create_tfb_state(const struct nv50_ir_prog_info *info,
return tfb;
}
-#ifdef DEBUG
+#ifndef NDEBUG
static void
nvc0_program_dump(struct nvc0_program *prog)
{
@@ -594,7 +594,7 @@ nvc0_program_translate(struct nvc0_program *prog, uint16_t chipset,
return false;
}
-#ifdef DEBUG
+#ifndef NDEBUG
info->target = debug_get_num_option("NV50_PROG_CHIPSET", chipset);
info->optLevel = debug_get_num_option("NV50_PROG_OPTIMIZE", 3);
info->dbgFlags = debug_get_num_option("NV50_PROG_DEBUG", 0);
@@ -714,7 +714,7 @@ nvc0_program_translate(struct nvc0_program *prog, uint16_t chipset,
prog->num_gprs, info->bin.instructions,
info->bin.codeSize);
-#ifdef DEBUG
+#ifndef NDEBUG
if (debug_get_option("NV50_PROG_CHIPSET", NULL) && info->dbgFlags)
nvc0_program_dump(prog);
#endif
@@ -880,7 +880,7 @@ nvc0_program_upload(struct nvc0_context *nvc0, struct nvc0_program *prog)
nvc0_program_upload_code(nvc0, prog);
-#ifdef DEBUG
+#ifndef NDEBUG
if (debug_get_bool_option("NV50_PROG_DEBUG", false))
nvc0_program_dump(prog);
#endif
diff --git a/src/gallium/drivers/nouveau/nvc0/nve4_compute.c b/src/gallium/drivers/nouveau/nvc0/nve4_compute.c
index 022aace73db..91c26718fbe 100644
--- a/src/gallium/drivers/nouveau/nvc0/nve4_compute.c
+++ b/src/gallium/drivers/nouveau/nvc0/nve4_compute.c
@@ -27,7 +27,7 @@
#include "codegen/nv50_ir_driver.h"
-#ifdef DEBUG
+#ifndef NDEBUG
static void nve4_compute_dump_launch_desc(const struct nve4_cp_launch_desc *);
static void gp100_compute_dump_launch_desc(const struct gp100_cp_launch_desc *);
#endif
@@ -741,7 +741,7 @@ nve4_launch_grid(struct pipe_context *pipe, const struct pipe_grid_info *info)
nve4_compute_upload_input(nvc0, info);
-#ifdef DEBUG
+#ifndef NDEBUG
if (debug_get_num_option("NV50_PROG_DEBUG", 0)) {
if (nvc0->screen->compute->oclass >= GP100_COMPUTE_CLASS)
gp100_compute_dump_launch_desc(desc);
@@ -878,7 +878,7 @@ nve4_compute_validate_textures(struct nvc0_context *nvc0)
}
-#ifdef DEBUG
+#ifndef NDEBUG
static const char *nve4_cache_split_name(unsigned value)
{
switch (value) {