Re: [Mesa-dev] [PATCH 7/7] i915: Only emit program errors when INTEL_DEBUG=wm

2011-08-02 Thread Kenneth Graunke
On 08/01/2011 10:50 AM, Eric Anholt wrote:
 On Mon,  1 Aug 2011 10:20:23 -0700, Ian Romanick i...@freedesktop.org 
 wrote:
 From: Ian Romanick ian.d.roman...@intel.com

 This makes piglit a lot more happy.
 
 I'd include DEBUG_FALLBACK, too.  That's what's about to happen when
 someone uses the program, and when people are hitting swrast we tell
 them to look at INTEL_DEBUG=fall.

I agree with Eric.  We definitely want both.

___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev


[Mesa-dev] [PATCH 7/7] i915: Only emit program errors when INTEL_DEBUG=wm

2011-08-01 Thread Ian Romanick
From: Ian Romanick ian.d.roman...@intel.com

This makes piglit a lot more happy.
---
 src/mesa/drivers/dri/i915/i915_program.c |   14 --
 1 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/src/mesa/drivers/dri/i915/i915_program.c 
b/src/mesa/drivers/dri/i915/i915_program.c
index ca1949b..304ceec 100644
--- a/src/mesa/drivers/dri/i915/i915_program.c
+++ b/src/mesa/drivers/dri/i915/i915_program.c
@@ -442,14 +442,16 @@ i915_emit_param4fv(struct i915_fragment_program * p, 
const GLfloat * values)
 void
 i915_program_error(struct i915_fragment_program *p, const char *fmt, ...)
 {
-   va_list args;
+   if (unlikely(INTEL_DEBUG  DEBUG_WM)) {
+  va_list args;
 
-   fprintf(stderr, i915_program_error: );
-   va_start(args, fmt);
-   vfprintf(stderr, fmt, args);
-   va_end(args);
+  fprintf(stderr, i915_program_error: );
+  va_start(args, fmt);
+  vfprintf(stderr, fmt, args);
+  va_end(args);
 
-   fprintf(stderr, \n);
+  fprintf(stderr, \n);
+   }
p-error = 1;
 }
 
-- 
1.7.4.4

___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH 7/7] i915: Only emit program errors when INTEL_DEBUG=wm

2011-08-01 Thread Eric Anholt
On Mon,  1 Aug 2011 10:20:23 -0700, Ian Romanick i...@freedesktop.org wrote:
 From: Ian Romanick ian.d.roman...@intel.com
 
 This makes piglit a lot more happy.

I'd include DEBUG_FALLBACK, too.  That's what's about to happen when
someone uses the program, and when people are hitting swrast we tell
them to look at INTEL_DEBUG=fall.


pgpXreIBlYSzz.pgp
Description: PGP signature
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev