src: extend overhead_cmpxchg to measure xchg and lock/unlocked cmpxchg

xchg is implicitly lock prefixed. The xchg code is more-or-less
just copied from lttng/userspace-rcu code. I have not verifed its
correctness.

Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com>