Performance: add missing "caa_unlikely" on fast-path
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 21 Nov 2016 20:58:29 +0000 (15:58 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 21 Nov 2016 20:58:29 +0000 (15:58 -0500)
There is a missing branch prediction hint on the return value of
lib_ring_buffer_reserve().

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
liblttng-ust/lttng-ring-buffer-client.h

index c5867dc1b697f2434a5bf17e74a98de85878661c..6ed067105d8e7fd0f8a280e3f09caa0375186836 100644 (file)
@@ -715,7 +715,7 @@ int lttng_event_reserve(struct lttng_ust_lib_ring_buffer_ctx *ctx,
        }
 
        ret = lib_ring_buffer_reserve(&client_config, ctx);
-       if (ret)
+       if (caa_unlikely(ret))
                goto put;
        if (caa_likely(ctx->ctx_len
                        >= sizeof(struct lttng_ust_lib_ring_buffer_ctx))) {
This page took 0.024807 seconds and 4 git commands to generate.