Spdk/lib/trace
Jim Harris a9be4f2c2f trace: add likely/unlikely hints to _spdk_trace_record
This helps generate slightly better code in this function,
which can have a noticeable impact for high trace
event workloads.

Tested with bdevperf, single malloc or null bdev,
qd=32, 512B randreads on a single Xeon core.
Specify "-e bdev" to enable bdev trace events.

Null:
Before: 8.09M/s (123ns per IO)
After: 8.68M/s (115ns per IO)

Malloc:
Before: 4.21M/s (237ns per IO)
After: 4.34M/s (230ns per IO)

Note that each bdev I/O generates two trace events (START
and END) - meaning this change removes 7-8ns of overhead
for every 2 trace events, at least on my system.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: I7021b7f9e28b4a7cb16f8a97b4d4004ae165efd2
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/15096
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
2022-10-21 07:18:37 +00:00
..
Makefile nvme/pcie, nvme/tcp: add cb_arg context tracepoint argument 2022-08-19 11:06:31 +00:00
spdk_trace.map trace: make trace_create_tpoint_group_mask() external 2022-01-05 08:52:40 +00:00
trace_flags.c trace: update trace help inside SPDK target 2022-09-27 19:41:17 +00:00
trace_rpc.c Replace most BSD 3-clause license text with SPDX identifier. 2022-06-09 07:35:12 +00:00
trace.c trace: add likely/unlikely hints to _spdk_trace_record 2022-10-21 07:18:37 +00:00