mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-04 15:40:11 +01:00
freedreno: Slight perf_debug rework
Allow ctx to be NULL in perf_debug_ctx() and make perf_debug() a shortcut for perf_debug_ctx(NULL, ...) to simplify things slightly in the next patch. Signed-off-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9264>
This commit is contained in:
parent
fd4d759622
commit
13d0d2db1a
1 changed files with 5 additions and 5 deletions
|
|
@ -104,15 +104,15 @@ extern bool fd_binning_enabled;
|
|||
__FUNCTION__, __LINE__, ##__VA_ARGS__); } while (0)
|
||||
|
||||
#define perf_debug_ctx(ctx, ...) do { \
|
||||
perf_debug(__VA_ARGS__); \
|
||||
pipe_debug_message(&(ctx)->debug, PERF_INFO, __VA_ARGS__); \
|
||||
} while(0)
|
||||
|
||||
#define perf_debug(...) do { \
|
||||
if (FD_DBG(PERF)) \
|
||||
mesa_logw(__VA_ARGS__); \
|
||||
struct fd_context *__c = (ctx); \
|
||||
if (__c) \
|
||||
pipe_debug_message(&__c->debug, PERF_INFO, __VA_ARGS__); \
|
||||
} while(0)
|
||||
|
||||
#define perf_debug(...) perf_debug_ctx(NULL, __VA_ARGS__)
|
||||
|
||||
struct fd_context;
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue