urcu:master

Last commit made on 2024-05-02
Get this branch:
git clone -b master https://git.launchpad.net/urcu

Branch merges

Branch information

Name:
master
Repository:
lp:urcu

Recent commits

9922f33... by Benjamin Marzinski via lttng-dev <email address hidden>

fix: handle EINTR correctly in get_cpu_mask_from_sysfs

If the read() in get_cpu_mask_from_sysfs() fails with EINTR, the code is
supposed to retry, but the while loop condition has (bytes_read > 0),
which is false when read() fails with EINTR. The result is that the code
exits the loop, having only read part of the string.

Use (bytes_read != 0) in the while loop condition instead, since the
(bytes_read < 0) case is already handled in the loop.

Signed-off-by: Benjamin Marzinski <email address hidden>
Signed-off-by: Mathieu Desnoyers <email address hidden>
Change-Id: I565030d4625ae199cabc4c2ab5eb8ac49ea4dfcb

02a024d... by Mathieu Desnoyers

Relicense src/compat-smp.h to MIT

Relicense the code in src/compat-smp.h from LGPLv2.1 to MIT to match the
copies in the following projects:

- lttng-ust
- libside
- librseq

This code is entirely authored by EfficiOS.

This relicensing initially appeared in the lttng-ust project after
the code was imported into liburcu:

  commit 4159f02937a2740abd7f5b113f376b198a86bc71 (test-struct-tls)
  Author: Mathieu Desnoyers <email address hidden>
  Date: Tue Oct 25 12:32:12 2022 -0400

      Relicense common/smp.c common/smp.h to MIT

Signed-off-by: Mathieu Desnoyers <email address hidden>
Change-Id: Ib7edb6c18fd3c004503b9c023ba4e280241ede14

ae5712d... by Olivier Dion <email address hidden>

uatomic/x86: Remove redundant memory barriers

When liburcu is configured to _not_ use atomic builtins, the
implementation of atomic operations is done using inline assembler for
each architecture.

Because we control the emitted assembler, we know whether specific
operations (e.g. lock; cmpxchg) already have an implicit memory barrier.
In those cases, emitting an explicit cmm_smp_mb() before/after the
operation is redundant and hurts performance.

Remove those redundant barriers on x86.

Change-Id: Ic1f6cfe9c2afe250946549cf6187f8fa88f5b009
Signed-off-by: Olivier Dion <email address hidden>
Signed-off-by: Mathieu Desnoyers <email address hidden>

6b071d7... by Michael Jeanson <email address hidden>

cleanup: move rand_r compat code to tests

This compat code is only used in the tests, move it there as it should
probably not be used in the library.

Change-Id: I0a36e790c236bb90d07a711af9cc6f8388fa4c81
Signed-off-by: Michael Jeanson <email address hidden>
Signed-off-by: Mathieu Desnoyers <email address hidden>

5307e3a... by Mathieu Desnoyers

ppc: Document cache line size choice

Signed-off-by: Mathieu Desnoyers <email address hidden>
Change-Id: I63603aaf5529e9a7810cfeffe19f32aea0dd13df

8c5aef6... by Mathieu Desnoyers

Fix: change order of _cds_lfht_new_with_alloc parameters

The "flavor" parameter should come before the "alloc" parameter
to match the order of cds_lfht_new_with_flavor_alloc() parameters.

Signed-off-by: Mathieu Desnoyers <email address hidden>
Change-Id: Ia704a0fd9cb90af966464e25e6202fed1a952eed

ac73525... by Xenofon Foukas <email address hidden>

Add support for custom memory allocators for rculfhash

The current implementation of rculfhash relies on calloc()
to allocate memory for its buckets. This can in some cases
lead to latency spikes when accessing the hash table, which
can be avoided by using an optimized custom memory allocator.
However, there is currently no way of replacing the default
allocator with a custom one.

This commit allows custom allocators to be used during the
table initialization. The default behavior of the hash table
remains unaffected, by using the stdlib calloc() and free(),
if no custom allocator is given.

Signed-off-by: Xenofon Foukas <email address hidden>
Signed-off-by: Mathieu Desnoyers <email address hidden>
Change-Id: Id9a405e5dc42e5564ff8623394c86056a4d1ff48

c6fbc27... by Sergey Fedorov

ppc.h: use mftb on ppc

Older versions of GNU as do not support mftbl. The issue affects Darwin
PowerPC, as well as some older versions of NetBSD and Linux. Since mftb
is equivalent and universally understood, just use that.

Signed-off-by: Mathieu Desnoyers <email address hidden>
Change-Id: I098b70fa8bb077143d2d658835586b6b059b879f

54bb03c... by Olivier Dion <email address hidden>

rcutorture: Check histogram of ages

Ensure that the histogram of ages for all threads are valid after a stress test.

Change-Id: Iadc46f47fe8835ac0e2d8967b6a16a83335a9541
Signed-off-by: Olivier Dion <email address hidden>
Signed-off-by: Mathieu Desnoyers <email address hidden>

70a1c7c... by Kienan Stewart <email address hidden>

docs: Add links to project resources

Indicate that Gerrit (https://review.lttng.org) is the principal place
where patches are submitted and reviewed, rather than the mailing list.

Based on feedback received on the mailing list:
https://lists.lttng.org/pipermail/lttng-dev/2023-November/030670.html

Change-Id: I19f1459045355c57a1f9932a3b540807ba3d4a1c
Signed-off-by: Kienan Stewart <email address hidden>
Signed-off-by: Mathieu Desnoyers <email address hidden>