util: Remove MESA_TRACE_BEGIN/END
authorCorentin Noël <corentin.noel@collabora.com>
Wed, 20 Sep 2023 15:50:20 +0000 (17:50 +0200)
committerMarge Bot <emma+marge@anholt.net>
Mon, 23 Oct 2023 17:20:03 +0000 (17:20 +0000)
There are no user of these macros anymore, simplify the cpu_trace header.

Signed-off-by: Corentin Noël <corentin.noel@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25308>

src/util/perf/cpu_trace.h
src/virtio/vulkan/vn_common.h

index cfa75849e38ecfd218b18af3e78875c317b4986f..6cebb51bafdd4ad4f09fa614ed855dceff11ac07 100644 (file)
 
 #endif /* HAVE_GPUVIS */
 
-
-#define _MESA_COMBINED_TRACE_BEGIN(name)                                     \
-   do {                                                                      \
-      _MESA_TRACE_BEGIN(name);                                               \
-      _MESA_GPUVIS_TRACE_BEGIN(name);                                        \
-   } while (0)
-
-#define _MESA_COMBINED_TRACE_END()                                           \
-   do {                                                                      \
-      _MESA_GPUVIS_TRACE_END();                                              \
-      _MESA_TRACE_END();                                                     \
-   } while (0)
-
 #if __has_attribute(cleanup) && __has_attribute(unused)
 
 #define _MESA_TRACE_SCOPE_VAR_CONCAT(name, suffix) name##suffix
 static inline int
 _mesa_trace_scope_begin(const char *name)
 {
-   _MESA_COMBINED_TRACE_BEGIN(name);
+   _MESA_TRACE_BEGIN(name);
+   _MESA_GPUVIS_TRACE_BEGIN(name);
    return 0;
 }
 
 static inline void
 _mesa_trace_scope_end(UNUSED int *scope)
 {
-   _MESA_COMBINED_TRACE_END();
+   _MESA_GPUVIS_TRACE_END();
+   _MESA_TRACE_END();
 }
 
 #else
@@ -110,8 +99,6 @@ _mesa_trace_scope_end(UNUSED int *scope)
 
 #endif /* __has_attribute(cleanup) && __has_attribute(unused) */
 
-#define MESA_TRACE_BEGIN(name) _MESA_COMBINED_TRACE_BEGIN(name)
-#define MESA_TRACE_END() _MESA_COMBINED_TRACE_END()
 #define MESA_TRACE_SCOPE(name) _MESA_TRACE_SCOPE(name)
 #define MESA_TRACE_FUNC() _MESA_TRACE_SCOPE(__func__)
 
index 7deff7c4dedf6d5e378e5284ca6e9ae8f90adf61..da9a8ae8c18a01d18dbef39350d10e70b06b8bbe 100644 (file)
@@ -55,8 +55,6 @@
 #define vn_result(instance, result)                                          \
    ((result) >= VK_SUCCESS ? (result) : vn_error((instance), (result)))
 
-#define VN_TRACE_BEGIN(name) MESA_TRACE_BEGIN(name)
-#define VN_TRACE_END() MESA_TRACE_END()
 #define VN_TRACE_SCOPE(name) MESA_TRACE_SCOPE(name)
 #define VN_TRACE_FUNC() MESA_TRACE_SCOPE(__func__)