mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 09:28:07 +02:00
Turn DBG output on/off with INTEL_DEBUG=bufs
This commit is contained in:
parent
11c0215bf8
commit
5ec38fb2ea
2 changed files with 9 additions and 13 deletions
|
|
@ -158,7 +158,9 @@ void bmFlushDrawCache( struct bufmgr *bm );
|
|||
|
||||
void bm_fake_NotifyContendedLockTake( struct bufmgr * );
|
||||
|
||||
extern int INTEL_DEBUG;
|
||||
#define DEBUG_BUFMGR 0x2000
|
||||
|
||||
#define DBG(...) do { if (0) _mesa_printf(__VA_ARGS__); } while(0)
|
||||
#define DBG(...) do { if (INTEL_DEBUG & DEBUG_BUFMGR) _mesa_printf(__VA_ARGS__); } while(0)
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -55,6 +55,8 @@
|
|||
#include "intel_ioctl.h"
|
||||
#include "intel_batchbuffer.h"
|
||||
|
||||
#include "bufmgr.h"
|
||||
|
||||
#include "utils.h"
|
||||
#ifndef INTEL_DEBUG
|
||||
int INTEL_DEBUG = (0);
|
||||
|
|
@ -237,6 +239,7 @@ static const struct dri_debug_control debug_control[] =
|
|||
{ "sync", DEBUG_SYNC },
|
||||
{ "sleep", DEBUG_SLEEP },
|
||||
{ "pix", DEBUG_PIXEL },
|
||||
{ "buf", DEBUG_BUFMGR },
|
||||
{ NULL, 0 }
|
||||
};
|
||||
|
||||
|
|
@ -581,13 +584,6 @@ void intelGetLock( intelContextPtr intel, GLuint flags )
|
|||
__DRIscreenPrivate *sPriv = intel->driScreen;
|
||||
drmI830Sarea * sarea = intel->sarea;
|
||||
int me = intel->hHWContext;
|
||||
static int foo = 0;
|
||||
|
||||
/* _mesa_printf("%s\n", __FUNCTION__); */
|
||||
/* if (foo++ > 1) { */
|
||||
/* _mesa_printf("%s - foo\n", __FUNCTION__); */
|
||||
/* abort(); */
|
||||
/* } */
|
||||
|
||||
drmGetLock(intel->driFd, intel->hHWContext, flags);
|
||||
|
||||
|
|
@ -599,17 +595,15 @@ void intelGetLock( intelContextPtr intel, GLuint flags )
|
|||
if (dPriv)
|
||||
DRI_VALIDATE_DRAWABLE_INFO(sPriv, dPriv);
|
||||
|
||||
/* If we lost context, need to dump all registers to hardware.
|
||||
* Note that we don't care about 2d contexts, even if they perform
|
||||
* accelerated commands, so the DRI locking in the X server is even
|
||||
* more broken than usual.
|
||||
/* Lost context?
|
||||
*/
|
||||
|
||||
if (sarea->ctxOwner != me) {
|
||||
intel->perf_boxes |= I830_BOX_LOST_CONTEXT;
|
||||
sarea->ctxOwner = me;
|
||||
}
|
||||
|
||||
/* Drawable changed?
|
||||
*/
|
||||
if (dPriv && intel->lastStamp != dPriv->lastStamp) {
|
||||
intelWindowMoved( intel );
|
||||
intel->lastStamp = dPriv->lastStamp;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue