Browse Source

i965: Use WARN_ONCE instead of open coding it.

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
tags/17.1-branchpoint
Kenneth Graunke 8 years ago
parent
commit
5177231670
1 changed files with 4 additions and 9 deletions
  1. 4
    9
      src/mesa/drivers/dri/i965/brw_compute.c

+ 4
- 9
src/mesa/drivers/dri/i965/brw_compute.c View File

@@ -219,15 +219,10 @@ brw_dispatch_compute_common(struct gl_context *ctx)
fail_next = true;
goto retry;
} else {
if (intel_batchbuffer_flush(brw) == -ENOSPC) {
static bool warned = false;

if (!warned) {
fprintf(stderr, "i965: Single compute shader dispatch "
"exceeded available aperture space\n");
warned = true;
}
}
int ret = intel_batchbuffer_flush(brw);
WARN_ONCE(ret == -ENOSPC,
"i965: Single compute shader dispatch "
"exceeded available aperture space\n");
}
}


Loading…
Cancel
Save