Re: [PATCH 1/2] tracing/function-return-tracer: Make the function return tracer lockless
From: Andi Kleen
Date: Thu Nov 13 2008 - 12:25:43 EST
> So the answer to this is:
>
> i = index++;
> barrier();
> write to index i (not index);
That was my first thought when I wrote the original email,
but the disadvantage is that barrier() is a big hammer
that flushes everything and can make the code much worse.
That is why I suggested local_add_return() instead.
-Andi
--
ak@xxxxxxxxxxxxxxx
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/