util/perf: use ALWAYS_INLINE for tracepoints

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18309>
This commit is contained in:
Chia-I Wu 2022-09-02 11:26:05 -07:00 committed by Marge Bot
parent 4d747d5690
commit c93173fcec
2 changed files with 3 additions and 2 deletions

View file

@ -28,6 +28,7 @@
#include <stdint.h> #include <stdint.h>
#include <stdio.h> #include <stdio.h>
#include "util/macros.h"
#include "util/u_atomic.h" #include "util/u_atomic.h"
#include "util/u_queue.h" #include "util/u_queue.h"
@ -284,7 +285,7 @@ void u_trace_perfetto_stop(void);
* Return whether instrumentations should be enabled or not. This is called * Return whether instrumentations should be enabled or not. This is called
* from tracepoints. * from tracepoints.
*/ */
static inline bool static ALWAYS_INLINE bool
u_trace_instrument(void) u_trace_instrument(void)
{ {
extern int _u_trace_instrument; extern int _u_trace_instrument;

View file

@ -243,7 +243,7 @@ void __trace_${trace_name}(
, ${arg.type} ${arg.var} , ${arg.type} ${arg.var}
% endfor % endfor
); );
static inline void trace_${trace_name}( static ALWAYS_INLINE void trace_${trace_name}(
struct u_trace *ut struct u_trace *ut
% if need_cs_param: % if need_cs_param:
, void *cs , void *cs