pipebuffer: Don't synchronize when checking for buffer overflows.
authorJosé Fonseca <jfonseca@vmware.com>
Tue, 16 Feb 2010 15:51:34 +0000 (15:51 +0000)
committerJosé Fonseca <jfonseca@vmware.com>
Mon, 22 Feb 2010 21:46:19 +0000 (21:46 +0000)
To avoid masking synchronization issues in debug builds.

src/gallium/auxiliary/pipebuffer/pb_bufmgr_debug.c

index c2593cf16537de6a45ac4e5c92eb2f66db964be1..a5dbded2bce75926b996580bcdb797c1dac89ec8 100644 (file)
@@ -179,7 +179,9 @@ pb_debug_buffer_check(struct pb_debug_buffer *buf)
 {
    uint8_t *map;
    
-   map = pb_map(buf->buffer, PIPE_BUFFER_USAGE_CPU_READ);
+   map = pb_map(buf->buffer,
+                PIPE_BUFFER_USAGE_CPU_READ |
+                PIPE_BUFFER_USAGE_UNSYNCHRONIZED);
    assert(map);
    if(map) {
       boolean underflow, overflow;