From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9A1FDA04AF; Sun, 3 May 2020 22:32:41 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8E9C41D52E; Sun, 3 May 2020 22:32:24 +0200 (CEST) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by dpdk.org (Postfix) with ESMTP id 6DE4F1D513 for ; Sun, 3 May 2020 22:32:22 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1588537941; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=/3YI06BlpIsR0NPmEJEljunRSaKum4nGd2gpkIw1qoc=; b=N7XEzKp2MULsgoz1I93SrHFHi0+JcqMjbhxO7TI6Js0yMJl4AdIPADFME7SKicnADwEqim l76S5e9TIVamiQW6SIZSu0+VEneYxoYgFeL451OvbsCOv4ouizxUnyfNTk5HUqHITDGHIf xJxEDuaN1/3yAU4Z/p0deQQirT4tpSg= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-171-B-N9MhpxOkGWJ4VymoAhGw-1; Sun, 03 May 2020 16:32:14 -0400 X-MC-Unique: B-N9MhpxOkGWJ4VymoAhGw-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 1B65D46B; Sun, 3 May 2020 20:32:12 +0000 (UTC) Received: from dmarchan.remote.csb (unknown [10.40.192.236]) by smtp.corp.redhat.com (Postfix) with ESMTP id 86DB76F972; Sun, 3 May 2020 20:32:07 +0000 (UTC) From: David Marchand To: dev@dpdk.org Cc: thomas@monjalon.net, Jerin Jacob , Sunil Kumar Kori , John McNamara , Marko Kovacevic , Declan Doherty , Ferruh Yigit , Andrew Rybchenko , Olivier Matz Date: Sun, 3 May 2020 22:31:29 +0200 Message-Id: <20200503203135.6493-3-david.marchand@redhat.com> In-Reply-To: <20200503203135.6493-1-david.marchand@redhat.com> References: <20200503203135.6493-1-david.marchand@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Subject: [dpdk-dev] [PATCH 2/8] trace: simplify trace point registration X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" RTE_TRACE_POINT_DEFINE and RTE_TRACE_POINT_REGISTER must come in pairs. Merge them and let RTE_TRACE_POINT_REGISTER handle the constructor part. Signed-off-by: David Marchand --- app/test/test_trace_register.c | 12 +- doc/guides/prog_guide/trace_lib.rst | 12 +- lib/librte_cryptodev/cryptodev_trace_points.c | 84 +++---- .../common/eal_common_trace_points.c | 164 ++++++-------- lib/librte_eal/include/rte_eal_trace.h | 122 +++++------ lib/librte_eal/include/rte_trace_point.h | 14 +- .../include/rte_trace_point_register.h | 6 +- lib/librte_ethdev/ethdev_trace_points.c | 44 ++-- lib/librte_eventdev/eventdev_trace_points.c | 205 +++++++----------- lib/librte_mempool/mempool_trace_points.c | 124 ++++------- 10 files changed, 309 insertions(+), 478 deletions(-) diff --git a/app/test/test_trace_register.c b/app/test/test_trace_register.= c index 8f40822cad..7feacfbabc 100644 --- a/app/test/test_trace_register.c +++ b/app/test/test_trace_register.c @@ -5,13 +5,5 @@ =20 #include "test_trace.h" =20 -/* Define trace points */ -RTE_TRACE_POINT_DEFINE(app_dpdk_test_tp); -RTE_TRACE_POINT_DEFINE(app_dpdk_test_fp); - -RTE_INIT(register_valid_trace_points) -{ -=09RTE_TRACE_POINT_REGISTER(app_dpdk_test_tp, app.dpdk.test.tp); -=09RTE_TRACE_POINT_REGISTER(app_dpdk_test_fp, app.dpdk.test.fp); -} - +RTE_TRACE_POINT_REGISTER(app_dpdk_test_tp, app.dpdk.test.tp) +RTE_TRACE_POINT_REGISTER(app_dpdk_test_fp, app.dpdk.test.fp) diff --git a/doc/guides/prog_guide/trace_lib.rst b/doc/guides/prog_guide/tr= ace_lib.rst index 6a2016c7dc..9cad4ff4ac 100644 --- a/doc/guides/prog_guide/trace_lib.rst +++ b/doc/guides/prog_guide/trace_lib.rst @@ -101,12 +101,7 @@ Register the tracepoint =20 #include =20 - RTE_TRACE_POINT_DEFINE(app_trace_string); - - RTE_INIT(app_trace_init) - { - RTE_TRACE_POINT_REGISTER(app_trace_string, app.trace.string); - } + RTE_TRACE_POINT_REGISTER(app_trace_string, app.trace.string) =20 The above code snippet registers the ``app_trace_string`` tracepoint to trace library. Here, the ``my_tracepoint_provider.h`` is the header file @@ -119,9 +114,6 @@ There is no requirement for the tracepoint function and= its name to be similar. However, it is recommended to have a similar name for a better naming convention. =20 -The user must register the tracepoint before the ``rte_eal_init`` invocati= on. -The user can use the ``RTE_INIT`` construction scheme to achieve this. - .. note:: =20 The ``RTE_TRACE_POINT_REGISTER_SELECT`` must be defined before includin= g the @@ -129,7 +121,7 @@ The user can use the ``RTE_INIT`` construction scheme t= o achieve this. =20 .. note:: =20 - The ``RTE_TRACE_POINT_DEFINE`` defines the placeholder for the + The ``RTE_TRACE_POINT_REGISTER`` defines the placeholder for the ``rte_trace_point_t`` tracepoint object. The user must export a ``__`` symbol in the library ``.map`` file for thi= s tracepoint to be used out of the library, in shared builds. diff --git a/lib/librte_cryptodev/cryptodev_trace_points.c b/lib/librte_cry= ptodev/cryptodev_trace_points.c index 7d03c93882..aa31103404 100644 --- a/lib/librte_cryptodev/cryptodev_trace_points.c +++ b/lib/librte_cryptodev/cryptodev_trace_points.c @@ -6,70 +6,50 @@ =20 #include "rte_cryptodev_trace.h" =20 -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_configure); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_start); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_stop); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_close); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_queue_pair_setup); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_sym_session_pool_create); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_sym_session_create); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_asym_session_create); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_sym_session_free); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_asym_session_free); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_sym_session_init); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_asym_session_init); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_sym_session_clear); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_asym_session_clear); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_enqueue_burst); -RTE_TRACE_POINT_DEFINE(rte_cryptodev_trace_dequeue_burst); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_configure, +=09lib.cryptodev.configure) =20 -RTE_INIT(cryptodev_trace_init) -{ -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_configure, -=09=09lib.cryptodev.configure); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_start, +=09lib.cryptodev.start) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_start, -=09=09lib.cryptodev.start); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_stop, +=09lib.cryptodev.stop) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_stop, -=09=09lib.cryptodev.stop); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_close, +=09lib.cryptodev.close) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_close, -=09=09lib.cryptodev.close); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_queue_pair_setup, +=09lib.cryptodev.queue.pair.setup) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_queue_pair_setup, -=09=09lib.cryptodev.queue.pair.setup); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_pool_create, +=09lib.cryptodev.sym.pool.create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_pool_create, -=09=09lib.cryptodev.sym.pool.create); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_create, +=09lib.cryptodev.sym.create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_create, -=09=09lib.cryptodev.sym.create); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_asym_session_create, +=09lib.cryptodev.asym.create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_asym_session_create, -=09=09lib.cryptodev.asym.create); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_free, +=09lib.cryptodev.sym.free) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_free, -=09=09lib.cryptodev.sym.free); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_asym_session_free, +=09lib.cryptodev.asym.free) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_asym_session_free, -=09=09lib.cryptodev.asym.free); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_init, +=09lib.cryptodev.sym.init) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_init, -=09=09lib.cryptodev.sym.init); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_asym_session_init, +=09lib.cryptodev.asym.init) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_asym_session_init, -=09=09lib.cryptodev.asym.init); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_clear, +=09lib.cryptodev.sym.clear) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_sym_session_clear, -=09=09lib.cryptodev.sym.clear); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_asym_session_clear, +=09lib.cryptodev.asym.clear) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_asym_session_clear, -=09=09lib.cryptodev.asym.clear); +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_enqueue_burst, +=09lib.cryptodev.enq.burst) =20 -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_enqueue_burst, -=09=09lib.cryptodev.enq.burst); - -=09RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_dequeue_burst, -=09=09lib.cryptodev.deq.burst); -} +RTE_TRACE_POINT_REGISTER(rte_cryptodev_trace_dequeue_burst, +=09lib.cryptodev.deq.burst) diff --git a/lib/librte_eal/common/eal_common_trace_points.c b/lib/librte_e= al/common/eal_common_trace_points.c index 7611977a15..d1d8d1875c 100644 --- a/lib/librte_eal/common/eal_common_trace_points.c +++ b/lib/librte_eal/common/eal_common_trace_points.c @@ -6,110 +6,70 @@ =20 #include =20 -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_void); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_u64); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_u32); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_u16); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_u8); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_i64); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_i32); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_i16); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_i8); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_int); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_long); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_float); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_double); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_ptr); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_str); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_func); +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_void, +=09lib.eal.generic.void) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_u64, +=09lib.eal.generic.u64) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_u32, +=09lib.eal.generic.u32) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_u16, +=09lib.eal.generic.u16) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_u8, +=09lib.eal.generic.u8) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_i64, +=09lib.eal.generic.i64) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_i32, +=09lib.eal.generic.i32) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_i16, +=09lib.eal.generic.i16) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_i8, +=09lib.eal.generic.i8) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_int, +=09lib.eal.generic.int) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_long, +=09lib.eal.generic.long) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_float, +=09lib.eal.generic.float) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_double, +=09lib.eal.generic.double) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_ptr, +=09lib.eal.generic.ptr) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_str, +=09lib.eal.generic.string) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_func, +=09lib.eal.generic.func) =20 -RTE_TRACE_POINT_DEFINE(rte_eal_trace_alarm_set); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_alarm_cancel); +RTE_TRACE_POINT_REGISTER(rte_eal_trace_alarm_set, +=09lib.eal.alarm.set) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_alarm_cancel, +=09lib.eal.alarm.cancel) =20 -RTE_TRACE_POINT_DEFINE(rte_eal_trace_mem_zmalloc); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_mem_malloc); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_mem_realloc); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_mem_free); +RTE_TRACE_POINT_REGISTER(rte_eal_trace_mem_zmalloc, +=09lib.eal.mem.zmalloc) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_mem_malloc, +=09lib.eal.mem.malloc) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_mem_realloc, +=09lib.eal.mem.realloc) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_mem_free, +=09lib.eal.mem.free) =20 -RTE_TRACE_POINT_DEFINE(rte_eal_trace_memzone_reserve); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_memzone_lookup); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_memzone_free); +RTE_TRACE_POINT_REGISTER(rte_eal_trace_memzone_reserve, +=09lib.eal.memzone.reserve) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_memzone_lookup, +=09lib.eal.memzone.lookup) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_memzone_free, +=09lib.eal.memzone.free) =20 -RTE_TRACE_POINT_DEFINE(rte_eal_trace_thread_remote_launch); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_thread_lcore_ready); +RTE_TRACE_POINT_REGISTER(rte_eal_trace_thread_remote_launch, +=09lib.eal.thread.remote.launch) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_thread_lcore_ready, +=09lib.eal.thread.lcore.ready) =20 -RTE_TRACE_POINT_DEFINE(rte_eal_trace_intr_callback_register); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_intr_callback_unregister); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_intr_enable); -RTE_TRACE_POINT_DEFINE(rte_eal_trace_intr_disable); - -RTE_INIT(eal_trace_init) -{ -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_void, -=09=09lib.eal.generic.void); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_u64, -=09=09lib.eal.generic.u64); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_u32, -=09=09lib.eal.generic.u32); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_u16, -=09=09lib.eal.generic.u16); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_u8, -=09=09lib.eal.generic.u8); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_i64, -=09=09lib.eal.generic.i64); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_i32, -=09=09lib.eal.generic.i32); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_i16, -=09=09lib.eal.generic.i16); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_i8, -=09=09lib.eal.generic.i8); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_int, -=09=09lib.eal.generic.int); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_long, -=09=09lib.eal.generic.long); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_float, -=09=09lib.eal.generic.float); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_double, -=09=09lib.eal.generic.double); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_ptr, -=09=09lib.eal.generic.ptr); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_str, -=09=09lib.eal.generic.string); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_func, -=09=09lib.eal.generic.func); - -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_alarm_set, -=09=09lib.eal.alarm.set); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_alarm_cancel, -=09=09lib.eal.alarm.cancel); - -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_mem_zmalloc, -=09=09lib.eal.mem.zmalloc); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_mem_malloc, -=09=09lib.eal.mem.malloc); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_mem_realloc, -=09=09lib.eal.mem.realloc); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_mem_free, -=09=09lib.eal.mem.free); - -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_memzone_reserve, -=09=09lib.eal.memzone.reserve); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_memzone_lookup, -=09=09lib.eal.memzone.lookup); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_memzone_free, -=09=09lib.eal.memzone.free); - -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_thread_remote_launch, -=09=09lib.eal.thread.remote.launch); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_thread_lcore_ready, -=09=09lib.eal.thread.lcore.ready); - -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_intr_callback_register, -=09=09lib.eal.intr.register); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_intr_callback_unregister, -=09=09lib.eal.intr.unregister); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_intr_enable, -=09=09lib.eal.intr.enable); -=09RTE_TRACE_POINT_REGISTER(rte_eal_trace_intr_disable, -=09=09lib.eal.intr.disable); -} +RTE_TRACE_POINT_REGISTER(rte_eal_trace_intr_callback_register, +=09lib.eal.intr.register) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_intr_callback_unregister, +=09lib.eal.intr.unregister) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_intr_enable, +=09lib.eal.intr.enable) +RTE_TRACE_POINT_REGISTER(rte_eal_trace_intr_disable, +=09lib.eal.intr.disable) diff --git a/lib/librte_eal/include/rte_eal_trace.h b/lib/librte_eal/includ= e/rte_eal_trace.h index 1ebb2905a9..923200f054 100644 --- a/lib/librte_eal/include/rte_eal_trace.h +++ b/lib/librte_eal/include/rte_eal_trace.h @@ -19,6 +19,26 @@ extern "C" { #include #include =20 +/* Alarm */ +RTE_TRACE_POINT( +=09rte_eal_trace_alarm_set, +=09RTE_TRACE_POINT_ARGS(uint64_t us, rte_eal_alarm_callback cb_fn, +=09=09void *cb_arg, int rc), +=09rte_trace_point_emit_u64(us); +=09rte_trace_point_emit_ptr(cb_fn); +=09rte_trace_point_emit_ptr(cb_arg); +=09rte_trace_point_emit_int(rc); +) + +RTE_TRACE_POINT( +=09rte_eal_trace_alarm_cancel, +=09RTE_TRACE_POINT_ARGS(rte_eal_alarm_callback cb_fn, void *cb_arg, +=09=09int count), +=09rte_trace_point_emit_ptr(cb_fn); +=09rte_trace_point_emit_ptr(cb_arg); +=09rte_trace_point_emit_int(count); +) + /* Generic */ RTE_TRACE_POINT( =09rte_eal_trace_generic_void, @@ -117,24 +137,52 @@ RTE_TRACE_POINT( =20 #define RTE_EAL_TRACE_GENERIC_FUNC rte_eal_trace_generic_func(__func__) =20 -/* Alarm */ +/* Interrupt */ RTE_TRACE_POINT( -=09rte_eal_trace_alarm_set, -=09RTE_TRACE_POINT_ARGS(uint64_t us, rte_eal_alarm_callback cb_fn, -=09=09void *cb_arg, int rc), -=09rte_trace_point_emit_u64(us); -=09rte_trace_point_emit_ptr(cb_fn); -=09rte_trace_point_emit_ptr(cb_arg); +=09rte_eal_trace_intr_callback_register, +=09RTE_TRACE_POINT_ARGS(const struct rte_intr_handle *handle, +=09=09rte_intr_callback_fn cb, void *cb_arg, int rc), =09rte_trace_point_emit_int(rc); +=09rte_trace_point_emit_int(handle->vfio_dev_fd); +=09rte_trace_point_emit_int(handle->fd); +=09rte_trace_point_emit_int(handle->type); +=09rte_trace_point_emit_u32(handle->max_intr); +=09rte_trace_point_emit_u32(handle->nb_efd); +=09rte_trace_point_emit_ptr(cb); +=09rte_trace_point_emit_ptr(cb_arg); ) - RTE_TRACE_POINT( -=09rte_eal_trace_alarm_cancel, -=09RTE_TRACE_POINT_ARGS(rte_eal_alarm_callback cb_fn, void *cb_arg, -=09=09int count), -=09rte_trace_point_emit_ptr(cb_fn); +=09rte_eal_trace_intr_callback_unregister, +=09RTE_TRACE_POINT_ARGS(const struct rte_intr_handle *handle, +=09=09rte_intr_callback_fn cb, void *cb_arg, int rc), +=09rte_trace_point_emit_int(rc); +=09rte_trace_point_emit_int(handle->vfio_dev_fd); +=09rte_trace_point_emit_int(handle->fd); +=09rte_trace_point_emit_int(handle->type); +=09rte_trace_point_emit_u32(handle->max_intr); +=09rte_trace_point_emit_u32(handle->nb_efd); +=09rte_trace_point_emit_ptr(cb); =09rte_trace_point_emit_ptr(cb_arg); -=09rte_trace_point_emit_int(count); +) +RTE_TRACE_POINT( +=09rte_eal_trace_intr_enable, +=09RTE_TRACE_POINT_ARGS(const struct rte_intr_handle *handle, int rc), +=09rte_trace_point_emit_int(rc); +=09rte_trace_point_emit_int(handle->vfio_dev_fd); +=09rte_trace_point_emit_int(handle->fd); +=09rte_trace_point_emit_int(handle->type); +=09rte_trace_point_emit_u32(handle->max_intr); +=09rte_trace_point_emit_u32(handle->nb_efd); +) +RTE_TRACE_POINT( +=09rte_eal_trace_intr_disable, +=09RTE_TRACE_POINT_ARGS(const struct rte_intr_handle *handle, int rc), +=09rte_trace_point_emit_int(rc); +=09rte_trace_point_emit_int(handle->vfio_dev_fd); +=09rte_trace_point_emit_int(handle->fd); +=09rte_trace_point_emit_int(handle->type); +=09rte_trace_point_emit_u32(handle->max_intr); +=09rte_trace_point_emit_u32(handle->nb_efd); ) =20 /* Memory */ @@ -223,54 +271,6 @@ RTE_TRACE_POINT( =09rte_trace_point_emit_string(cpuset); ) =20 -/* Interrupt */ -RTE_TRACE_POINT( -=09rte_eal_trace_intr_callback_register, -=09RTE_TRACE_POINT_ARGS(const struct rte_intr_handle *handle, -=09=09rte_intr_callback_fn cb, void *cb_arg, int rc), -=09rte_trace_point_emit_int(rc); -=09rte_trace_point_emit_int(handle->vfio_dev_fd); -=09rte_trace_point_emit_int(handle->fd); -=09rte_trace_point_emit_int(handle->type); -=09rte_trace_point_emit_u32(handle->max_intr); -=09rte_trace_point_emit_u32(handle->nb_efd); -=09rte_trace_point_emit_ptr(cb); -=09rte_trace_point_emit_ptr(cb_arg); -) -RTE_TRACE_POINT( -=09rte_eal_trace_intr_callback_unregister, -=09RTE_TRACE_POINT_ARGS(const struct rte_intr_handle *handle, -=09=09rte_intr_callback_fn cb, void *cb_arg, int rc), -=09rte_trace_point_emit_int(rc); -=09rte_trace_point_emit_int(handle->vfio_dev_fd); -=09rte_trace_point_emit_int(handle->fd); -=09rte_trace_point_emit_int(handle->type); -=09rte_trace_point_emit_u32(handle->max_intr); -=09rte_trace_point_emit_u32(handle->nb_efd); -=09rte_trace_point_emit_ptr(cb); -=09rte_trace_point_emit_ptr(cb_arg); -) -RTE_TRACE_POINT( -=09rte_eal_trace_intr_enable, -=09RTE_TRACE_POINT_ARGS(const struct rte_intr_handle *handle, int rc), -=09rte_trace_point_emit_int(rc); -=09rte_trace_point_emit_int(handle->vfio_dev_fd); -=09rte_trace_point_emit_int(handle->fd); -=09rte_trace_point_emit_int(handle->type); -=09rte_trace_point_emit_u32(handle->max_intr); -=09rte_trace_point_emit_u32(handle->nb_efd); -) -RTE_TRACE_POINT( -=09rte_eal_trace_intr_disable, -=09RTE_TRACE_POINT_ARGS(const struct rte_intr_handle *handle, int rc), -=09rte_trace_point_emit_int(rc); -=09rte_trace_point_emit_int(handle->vfio_dev_fd); -=09rte_trace_point_emit_int(handle->fd); -=09rte_trace_point_emit_int(handle->type); -=09rte_trace_point_emit_u32(handle->max_intr); -=09rte_trace_point_emit_u32(handle->nb_efd); -) - #ifdef __cplusplus } #endif diff --git a/lib/librte_eal/include/rte_trace_point.h b/lib/librte_eal/incl= ude/rte_trace_point.h index 4d956ec164..dbd648c054 100644 --- a/lib/librte_eal/include/rte_trace_point.h +++ b/lib/librte_eal/include/rte_trace_point.h @@ -29,10 +29,6 @@ extern "C" { /** The tracepoint object. */ typedef uint64_t rte_trace_point_t; =20 -/** Macro to define the tracepoint. */ -#define RTE_TRACE_POINT_DEFINE(tp) \ -rte_trace_point_t __attribute__((section("__rte_trace_point"))) __##tp - /** * Macro to define the tracepoint arguments in RTE_TRACE_POINT macro. =20 @@ -64,7 +60,7 @@ _tp _args \ * * @param tp * Tracepoint object. Before using the tracepoint, an application needs = to - * define the tracepoint using RTE_TRACE_POINT_DEFINE macro. + * define the tracepoint using RTE_TRACE_POINT_REGISTER macro. * @param args * C function style input arguments to define the arguments to tracepoin= t * function. @@ -72,7 +68,7 @@ _tp _args \ * Define the payload of trace function. The payload will be formed usin= g * rte_trace_point_emit_* macros. Use ";" delimiter between two payloads= . * - * @see RTE_TRACE_POINT_ARGS, RTE_TRACE_POINT_DEFINE, rte_trace_point_emit= _* + * @see RTE_TRACE_POINT_ARGS, RTE_TRACE_POINT_REGISTER, rte_trace_point_em= it_* */ #define RTE_TRACE_POINT(tp, args, ...) \ =09__RTE_TRACE_POINT(generic, tp, args, __VA_ARGS__) @@ -85,7 +81,7 @@ _tp _args \ * * @param tp * Tracepoint object. Before using the tracepoint, an application needs = to - * define the tracepoint using RTE_TRACE_POINT_DEFINE macro. + * define the tracepoint using RTE_TRACE_POINT_REGISTER macro. * @param args * C function style input arguments to define the arguments to tracepoin= t. * function. @@ -115,7 +111,7 @@ _tp _args \ * Register a tracepoint. * * @param trace - * The tracepoint object created using RTE_TRACE_POINT_DEFINE. + * The tracepoint object created using RTE_TRACE_POINT_REGISTER. * @param name * The name of the tracepoint object. * @return @@ -262,7 +258,7 @@ void __rte_trace_point_emit_field(size_t sz, const char= *field, * Use RTE_TRACE_POINT_REGISTER macro for tracepoint registration. * * @param trace - * The tracepoint object created using RTE_TRACE_POINT_DEFINE. + * The tracepoint object created using RTE_TRACE_POINT_REGISTER. * @param name * The name of the tracepoint object. * @param register_fn diff --git a/lib/librte_eal/include/rte_trace_point_register.h b/lib/librte= _eal/include/rte_trace_point_register.h index 4e2306f1af..26e383a8bb 100644 --- a/lib/librte_eal/include/rte_trace_point_register.h +++ b/lib/librte_eal/include/rte_trace_point_register.h @@ -14,8 +14,12 @@ RTE_DECLARE_PER_LCORE(volatile int, trace_point_sz); =20 #define RTE_TRACE_POINT_REGISTER(trace, name) \ +rte_trace_point_t __attribute__((section("__rte_trace_point"))) __##trace;= \ +RTE_INIT(trace##_init) \ +{ \ =09__rte_trace_point_register(&__##trace, RTE_STR(name), \ -=09=09(void (*)(void)) trace) +=09=09(void (*)(void)) trace); \ +} =20 #define __rte_trace_point_emit_header_generic(t) \ =09RTE_PER_LCORE(trace_point_sz) =3D __RTE_TRACE_EVENT_HEADER_SZ diff --git a/lib/librte_ethdev/ethdev_trace_points.c b/lib/librte_ethdev/et= hdev_trace_points.c index 05de34f3ca..5be377521c 100644 --- a/lib/librte_ethdev/ethdev_trace_points.c +++ b/lib/librte_ethdev/ethdev_trace_points.c @@ -6,38 +6,26 @@ =20 #include =20 -RTE_TRACE_POINT_DEFINE(rte_ethdev_trace_configure); -RTE_TRACE_POINT_DEFINE(rte_ethdev_trace_rxq_setup); -RTE_TRACE_POINT_DEFINE(rte_ethdev_trace_txq_setup); -RTE_TRACE_POINT_DEFINE(rte_ethdev_trace_start); -RTE_TRACE_POINT_DEFINE(rte_ethdev_trace_stop); -RTE_TRACE_POINT_DEFINE(rte_ethdev_trace_close); -RTE_TRACE_POINT_DEFINE(rte_ethdev_trace_rx_burst); -RTE_TRACE_POINT_DEFINE(rte_ethdev_trace_tx_burst); +RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_configure, +=09lib.ethdev.configure) =20 -RTE_INIT(ethdev_trace_init) -{ -=09RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_configure, -=09=09lib.ethdev.configure); +RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_rxq_setup, +=09lib.ethdev.rxq.setup) =20 -=09RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_rxq_setup, -=09=09lib.ethdev.rxq.setup); +RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_txq_setup, +=09lib.ethdev.txq.setup) =20 -=09RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_txq_setup, -=09=09lib.ethdev.txq.setup); +RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_start, +=09lib.ethdev.start) =20 -=09RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_start, -=09=09lib.ethdev.start); +RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_stop, +=09lib.ethdev.stop) =20 -=09RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_stop, -=09=09lib.ethdev.stop); +RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_close, +=09lib.ethdev.close) =20 -=09RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_close, -=09=09lib.ethdev.close); +RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_rx_burst, +=09lib.ethdev.rx.burst) =20 -=09RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_rx_burst, -=09=09lib.ethdev.rx.burst); - -=09RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_tx_burst, -=09=09lib.ethdev.tx.burst); -} +RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_tx_burst, +=09lib.ethdev.tx.burst) diff --git a/lib/librte_eventdev/eventdev_trace_points.c b/lib/librte_event= dev/eventdev_trace_points.c index 2aa6e6bcf5..221a62b71c 100644 --- a/lib/librte_eventdev/eventdev_trace_points.c +++ b/lib/librte_eventdev/eventdev_trace_points.c @@ -7,167 +7,114 @@ #include "rte_eventdev_trace.h" =20 /* Eventdev trace points */ -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_configure); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_queue_setup); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_port_setup); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_port_link); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_port_unlink); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_start); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_stop); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_close); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_enq_burst); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_deq_burst); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_configure, +=09lib.eventdev.configure) =20 -/* Eventdev Rx adapter trace points */ -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_rx_adapter_create); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_rx_adapter_free); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_rx_adapter_queue_add); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_rx_adapter_queue_del); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_rx_adapter_start); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_rx_adapter_stop); - -/* Eventdev Tx adapter trace points */ -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_tx_adapter_create); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_tx_adapter_free); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_tx_adapter_queue_add); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_tx_adapter_queue_del); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_tx_adapter_start); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_tx_adapter_stop); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_eth_tx_adapter_enqueue); - -/* Eventdev Timer adapter trace points */ -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_timer_adapter_create); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_timer_adapter_start); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_timer_adapter_stop); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_timer_adapter_free); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_timer_arm_burst); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_timer_arm_tmo_tick_burst); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_timer_cancel_burst); - -/* Eventdev Crypto adapter trace points */ -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_crypto_adapter_create); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_crypto_adapter_free); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_crypto_adapter_queue_pair_add); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_crypto_adapter_queue_pair_del); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_crypto_adapter_start); -RTE_TRACE_POINT_DEFINE(rte_eventdev_trace_crypto_adapter_stop); - -RTE_INIT(eventdev_trace_init) -{ -=09/* Eventdev trace points */ -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_configure, -=09=09lib.eventdev.configure); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_queue_setup, +=09lib.eventdev.queue.setup) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_queue_setup, -=09=09lib.eventdev.queue.setup); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_port_setup, +=09lib.eventdev.port.setup) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_port_setup, -=09=09lib.eventdev.port.setup); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_port_link, +=09lib.eventdev.port.link) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_port_link, -=09=09lib.eventdev.port.link); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_port_unlink, +=09lib.eventdev.port.unlink) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_port_unlink, -=09=09lib.eventdev.port.unlink); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_start, +=09lib.eventdev.start) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_start, -=09=09lib.eventdev.start); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_stop, +=09lib.eventdev.stop) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_stop, -=09=09lib.eventdev.stop); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_close, +=09lib.eventdev.close) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_close, -=09=09lib.eventdev.close); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_enq_burst, +=09lib.eventdev.enq.burst) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_enq_burst, -=09=09lib.eventdev.enq.burst); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_deq_burst, +=09lib.eventdev.deq.burst) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_deq_burst, -=09=09lib.eventdev.deq.burst); - - -=09/* Eventdev Rx adapter trace points */ -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_create, -=09=09lib.eventdev.rx.adapter.create); - -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_free, -=09=09lib.eventdev.rx.adapter.free); +/* Eventdev Rx adapter trace points */ +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_create, +=09lib.eventdev.rx.adapter.create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_queue_add, -=09=09lib.eventdev.rx.adapter.queue.add); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_free, +=09lib.eventdev.rx.adapter.free) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_queue_del, -=09=09lib.eventdev.rx.adapter.queue.del); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_queue_add, +=09lib.eventdev.rx.adapter.queue.add) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_start, -=09=09lib.eventdev.rx.adapter.start); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_queue_del, +=09lib.eventdev.rx.adapter.queue.del) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_stop, -=09=09lib.eventdev.rx.adapter.stop); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_start, +=09lib.eventdev.rx.adapter.start) =20 -=09/* Eventdev Tx adapter trace points */ -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_create, -=09=09lib.eventdev.tx.adapter.create); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_rx_adapter_stop, +=09lib.eventdev.rx.adapter.stop) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_free, -=09=09lib.eventdev.tx.adapter.free); +/* Eventdev Tx adapter trace points */ +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_create, +=09lib.eventdev.tx.adapter.create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_queue_add, -=09=09lib.eventdev.tx.adapter.queue.add); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_free, +=09lib.eventdev.tx.adapter.free) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_queue_del, -=09=09lib.eventdev.tx.adapter.queue.del); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_queue_add, +=09lib.eventdev.tx.adapter.queue.add) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_start, -=09=09lib.eventdev.tx.adapter.start); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_queue_del, +=09lib.eventdev.tx.adapter.queue.del) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_stop, -=09=09lib.eventdev.tx.adapter.stop); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_start, +=09lib.eventdev.tx.adapter.start) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_enqueue, -=09=09lib.eventdev.tx.adapter.enq); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_stop, +=09lib.eventdev.tx.adapter.stop) =20 +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_eth_tx_adapter_enqueue, +=09lib.eventdev.tx.adapter.enq) =20 -=09/* Eventdev Timer adapter trace points */ -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_adapter_create, -=09=09lib.eventdev.timer.create); +/* Eventdev Timer adapter trace points */ +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_adapter_create, +=09lib.eventdev.timer.create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_adapter_start, -=09=09lib.eventdev.timer.start); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_adapter_start, +=09lib.eventdev.timer.start) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_adapter_stop, -=09=09lib.eventdev.timer.stop); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_adapter_stop, +=09lib.eventdev.timer.stop) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_adapter_free, -=09=09lib.eventdev.timer.free); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_adapter_free, +=09lib.eventdev.timer.free) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_arm_burst, -=09=09lib.eventdev.timer.burst); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_arm_burst, +=09lib.eventdev.timer.burst) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_arm_tmo_tick_burst, -=09=09lib.eventdev.timer.tick.burst); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_arm_tmo_tick_burst, +=09lib.eventdev.timer.tick.burst) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_cancel_burst, -=09=09lib.eventdev.timer.cancel); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_timer_cancel_burst, +=09lib.eventdev.timer.cancel) =20 -=09/* Eventdev Crypto adapter trace points */ -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_create, -=09=09lib.eventdev.crypto.create); +/* Eventdev Crypto adapter trace points */ +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_create, +=09lib.eventdev.crypto.create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_free, -=09=09lib.eventdev.crypto.free); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_free, +=09lib.eventdev.crypto.free) =20 -=09RTE_TRACE_POINT_REGISTER( -=09=09=09rte_eventdev_trace_crypto_adapter_queue_pair_add, -=09=09lib.eventdev.crypto.queue.add); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_queue_pair_add, +=09lib.eventdev.crypto.queue.add) =20 -=09RTE_TRACE_POINT_REGISTER( -=09=09=09rte_eventdev_trace_crypto_adapter_queue_pair_del, -=09=09lib.eventdev.crypto.queue.del); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_queue_pair_del, +=09lib.eventdev.crypto.queue.del) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_start, -=09=09lib.eventdev.crypto.start); +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_start, +=09lib.eventdev.crypto.start) =20 -=09RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_stop, -=09=09lib.eventdev.crypto.stop); -} +RTE_TRACE_POINT_REGISTER(rte_eventdev_trace_crypto_adapter_stop, +=09lib.eventdev.crypto.stop) diff --git a/lib/librte_mempool/mempool_trace_points.c b/lib/librte_mempool= /mempool_trace_points.c index afab8dff68..3dac0bc536 100644 --- a/lib/librte_mempool/mempool_trace_points.c +++ b/lib/librte_mempool/mempool_trace_points.c @@ -6,102 +6,74 @@ =20 #include "rte_mempool_trace.h" =20 -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_ops_dequeue_bulk); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_ops_dequeue_contig_blocks); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_ops_enqueue_bulk); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_generic_put); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_put_bulk); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_generic_get); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_get_bulk); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_get_contig_blocks); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_create); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_create_empty); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_free); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_populate_iova); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_populate_virt); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_populate_default); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_populate_anon); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_cache_create); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_cache_free); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_default_cache); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_get_page_size); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_cache_flush); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_ops_populate); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_ops_alloc); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_ops_free); -RTE_TRACE_POINT_DEFINE(rte_mempool_trace_set_ops_byname); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_dequeue_bulk, +=09lib.mempool.ops.deq.bulk) =20 -RTE_INIT(mempool_trace_init) -{ -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_dequeue_bulk, -=09=09lib.mempool.ops.deq.bulk); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_dequeue_contig_blocks, +=09lib.mempool.ops.deq.contig) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_dequeue_contig_blocks, -=09=09lib.mempool.ops.deq.contig); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_enqueue_bulk, +=09lib.mempool.ops.enq.bulk) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_enqueue_bulk, -=09=09lib.mempool.ops.enq.bulk); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_generic_put, +=09lib.mempool.generic.put) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_generic_put, -=09=09lib.mempool.generic.put); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_put_bulk, +=09lib.mempool.put.bulk) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_put_bulk, -=09=09lib.mempool.put.bulk); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_generic_get, +=09lib.mempool.generic.get) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_generic_get, -=09=09lib.mempool.generic.get); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_get_bulk, +=09lib.mempool.get.bulk) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_get_bulk, -=09=09lib.mempool.get.bulk); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_get_contig_blocks, +=09lib.mempool.get.blocks) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_get_contig_blocks, -=09=09lib.mempool.get.blocks); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_create, +=09lib.mempool.create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_create, -=09=09lib.mempool.create); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_create_empty, +=09lib.mempool.create.empty) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_create_empty, -=09=09lib.mempool.create.empty); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_free, +=09lib.mempool.free) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_free, -=09=09lib.mempool.free); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_populate_iova, +=09lib.mempool.populate.iova) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_populate_iova, -=09=09lib.mempool.populate.iova); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_populate_virt, +=09lib.mempool.populate.virt) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_populate_virt, -=09=09lib.mempool.populate.virt); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_populate_default, +=09lib.mempool.populate.default) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_populate_default, -=09=09lib.mempool.populate.default); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_populate_anon, +=09lib.mempool.populate.anon) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_populate_anon, -=09=09lib.mempool.populate.anon); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_cache_create, +=09lib.mempool.cache_create) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_cache_create, -=09=09lib.mempool.cache_create); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_cache_free, +=09lib.mempool.cache.free) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_cache_free, -=09=09lib.mempool.cache.free); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_default_cache, +=09lib.mempool.default.cache) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_default_cache, -=09=09lib.mempool.default.cache); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_get_page_size, +=09lib.mempool.get.page.size) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_get_page_size, -=09=09lib.mempool.get.page.size); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_cache_flush, +=09lib.mempool.cache.flush) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_cache_flush, -=09=09lib.mempool.cache.flush); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_populate, +=09lib.mempool.ops.populate) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_populate, -=09=09lib.mempool.ops.populate); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_alloc, +=09lib.mempool.ops.alloc) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_alloc, -=09=09lib.mempool.ops.alloc); +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_free, +=09lib.mempool.ops.free) =20 -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_ops_free, -=09=09lib.mempool.ops.free); - -=09RTE_TRACE_POINT_REGISTER(rte_mempool_trace_set_ops_byname, -=09=09lib.mempool.set.ops.byname); -} +RTE_TRACE_POINT_REGISTER(rte_mempool_trace_set_ops_byname, +=09lib.mempool.set.ops.byname) --=20 2.23.0