Re: [PATCH 4/6] kvm tools: Add rwlock wrapper

Ingo Molnar
2011-05-27T13:08:15Z

* Mathieu Desnoyers <mathieu.desnoyers@efficios.com> wrote:

> > instead of bringing in yet another library which is a IIRC a
> > distant copy of the kernel code to begin with.
>
> This is either a lie, or immensely misinformed. You should go and
> look at the source before doing nonsensical assumptions like this.
> What you are saying cannot be further from the truth.

I was merely immensely misinformed, which (distinct!) possibility i
tried to signal via the 'IIRC' qualifier as well ;-)

While right now i cannot clone the repository itself:

$ git clone git://git.lttng.org/urcu
Cloning into urcu...
fatal: The remote end hung up unexpectedly

(tried it several times today, same failure)

I found a tarball of the package so could have a look again.

Despite my initial impression of it being kernel RCU code related (it
has system.h, smp_mb, list_head, etc.), a closer look indeed suggests
that the RCU implementation itself does not use the kernel RCU
concepts so it sadly cannot be a distant copy of the kernel RCU code!

Which is too bad IMO: i don't think user-space RCU should necessarily
be so different from kernel-space RCU. I think the two codebases
could be shared, or at least they could become closer relatives! :-)

That could be done using the migration event notification trick i
suggested in the previous mail.

Thanks,

Ingo