rte_trace.h(3)
π rte_trace.h β Library Functions Manual π
okay bestie, sit down, hydrate, and let's talk about rte_trace.h(3) because this one is genuinely iconic π₯ it's the RTE Trace API header, and it's giving main character energy for your whole application's tracing setup. let's get into it β¨
β¨ NAME β¨
rte_trace.h β that's the whole name, she's simple like that π
π¦ SYNOPSIS π¦
first things first, the girlies she needs to include:
#include <stdbool.h>
#include <stdio.h>
#include <rte_common.h>
#include <rte_compat.h>
πΈ Enumerations
enum rte_trace_mode { RTE_TRACE_MODE_OVERWRITE, RTE_TRACE_MODE_DISCARD }
π Functions
__rte_experimental bool rte_trace_is_enabled (void)
static __rte_experimental __rte_always_inline bool
rte_trace_feature_is_enabled (void)
__rte_experimental void rte_trace_mode_set (enum rte_trace_mode mode)
__rte_experimental enum rte_trace_mode rte_trace_mode_get (void)
__rte_experimental int rte_trace_pattern (const char *pattern, bool
enable)
__rte_experimental int rte_trace_regexp (const char *regex, bool enable)
__rte_experimental int rte_trace_save (void)
__rte_experimental int rte_trace_metadata_dump (FILE *f)
__rte_experimental void rte_trace_dump (FILE *f)
π Detailed Description π
RTE Trace API β periodt β¨
This file provides the trace API to RTE applications. literally that's the whole vibe, she's here to let your RTE app do tracing π
β οΈ Warning: EXPERIMENTAL: this API may change without prior notice. no cap, she's experimental, so guard your heart (and your builds) accordingly π
Definition in file rte_trace.h.
π Enumeration Type Documentation π
enum rte_trace_mode
Enumerate trace mode operation. it's giving "pick your fighter" π«Ά
Enumerator
RTE_TRACE_MODE_OVERWRITEβ In this mode, when no space is left in the trace buffer, the subsequent events overwrite the old events. out with the old, in with the new πRTE_TRACE_MODE_DISCARDβ In this mode, when no space is left in the trace buffer, the subsequent events shall not be recorded. buffer's full? new events simply don't get an invite π
Definition at line 61 of file rte_trace.h.
π Function Documentation π
__rte_experimental bool rte_trace_is_enabled (void )
Test if trace is enabled. girl is just checking if the lights are on π₯
Returns
true if trace is enabled, false otherwise.
__rte_experimental __rte_always_inline bool rte_trace_feature_is_enabled (void ) [static]
β οΈ Warning: EXPERIMENTAL: this API may change, or be removed, without prior notice π
Test if trace feature is enabled at compile time. note the compile time part bestie, she's decided before your program even wakes up πΈ
Returns
true if trace feature is enabled, false otherwise.
Definition at line 49 of file rte_trace.h.
__rte_experimental void rte_trace_mode_set (enum rte_trace_mode mode)
Set the trace mode. you're the one choosing her outfit today π
Parameters
modeβ Trace mode.
__rte_experimental enum rte_trace_mode rte_trace_mode_get (void )
Get the trace mode. asking her what she's wearing rn π
Returns
The current trace mode.
__rte_experimental int rte_trace_pattern (const char * pattern, bool enable)
Enable/Disable a set of tracepoints based on globbing pattern. globbing!! she's flexible like that β¨
Parameters
patternβ The globbing pattern identifying the tracepoint.enableβtrueto enable tracepoint,falseto disable the tracepoint, upon match.
Returns
0: Success and no pattern match.1: Success and found pattern match.(-ERANGE): Tracepoint object is not registered. π
__rte_experimental int rte_trace_regexp (const char * regex, bool enable)
Enable/Disable a set of tracepoints based on regular expression. so regex girlies, this one's for you π
Parameters
regexβ A regular expression identifying the tracepoint.enableβtrueto enable tracepoint,falseto disable the tracepoint, upon match.
Returns
0: Success and no pattern match.1: Success and found pattern match.(-ERANGE): Tracepoint object is not registered.(-EINVAL): Invalid regular expression rule. she said no to that regex π
__rte_experimental int rte_trace_save (void )
Save the trace buffer to the trace directory. bookmarking, but make it systems programming π
By default, trace directory will be created at $HOME directory and this can be overridden by --trace-dir EAL parameter. iykyk π
Returns
0: Success.<0: Failure.
__rte_experimental int rte_trace_metadata_dump (FILE * f)
Dump the trace metadata to a file. the lore, archived π
Parameters
fβ A pointer to a file for output
Returns
0: Success.<0: Failure.
__rte_experimental void rte_trace_dump (FILE * f)
Dump the trace subsystem status to a file. the whole vibe check, written down πΈ
Parameters
fβ A pointer to a file for output
π¦ Author π¦
Generated automatically by Doxygen for DPDK from the source code. not a human, just a robot doing her little documentation slay π€β¨
and that's the whole page bestie, you ate this π π
kisses, and remember: this was DPDK, Version 25.11.3, from the rte_trace.h(3) manual page β experimental API, so stay flexible, stay hydrated, and go trace something gorgeous π«Άπ
π¦ where this page comes from
- ubuntu resolute: dpdk-doc 25.11.3-0ubuntu0.26.04.1 Β· BSD-3-Clause
- ubuntu stonking: dpdk-doc 25.11.3-1 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms