Samy Al Bahra
721cc0605c
regressions: Remove -g from ck_rwcohort build flags.
12 years ago
Samy Al Bahra
895ff34aab
regressions: Add ck_rwcohort to top-level Makefile.
12 years ago
Samy Al Bahra
b36e35ec76
Merge branch 'master' of https://github.com/bscheinman/ck
12 years ago
Samy Al Bahra
768b5b3597
ck_rwlock: Add adaptive elision and unit tests.
12 years ago
Samy Al Bahra
ac4a703525
regressions: Get rid of debug flags in ck_rwlock benchmark.
12 years ago
Samy Al Bahra
671f82d7a8
ck_rwlock: Migrate to ck_elide.h.
12 years ago
Samy Al Bahra
143bc4b336
regressions: Add ck_spinlock locked coverage.
12 years ago
Samy Al Bahra
4d2ccfe497
ck_rwlock: Add basic RTM interface to rwlock.
...
It is possible this will be moved to a self-contained file.
For a majority of architectures, RTM is an unnecessary
implementation-specific optimization.
12 years ago
Samy Al Bahra
7f5216c4c6
regressions/ck_sequence: Add fast-path latency measurement.
12 years ago
Brendon Scheinman
cb0a7c8ce6
Merge branch 'master' of https://github.com/sbahra/ck
12 years ago
Samy Al Bahra
d0745f51ee
regressions: Lower wait factor for ck_ticket_pb.
12 years ago
Samy Al Bahra
b63fe45460
regressions: Fix uninitialized usage in ck_hs parallel_bytestring.
12 years ago
Samy Al Bahra
03efd38742
regressions: Testing of ck_hs_fas functionality.
12 years ago
Brendon Scheinman
cbfa095108
Merge branch 'master' of https://github.com/sbahra/ck
12 years ago
Samy Al Bahra
137fb49951
regressions: Fix link order.
12 years ago
Brendon Scheinman
eacaacdb6e
ck_rwcohort: Fixed Makefile for automated regression testing
12 years ago
Brendon Scheinman
444df7dfe5
Merge branch 'master' of https://github.com/sbahra/ck
12 years ago
Samy Al Bahra
ca35d3bb75
regressions/ck_hs: Fix typo in Copyright statement.
12 years ago
Samy Al Bahra
4132ec4998
ck_epoch: Add ck_epoch_reclaim function.
...
This function allows for explicit execution of all
deferred callbacks in an epoch_record. The primary
motivation is currently for performance profiling
but there are other use-cases where best-effort
semantics could be applied.
12 years ago
Samy Al Bahra
281b5ad045
Merge branch 'master' of https://github.com/davidjoseph/ck
12 years ago
Brendon Scheinman
cc4b248bcb
ck_rwcohort: Renamed ck_rwcohort namespace
12 years ago
Brendon Scheinman
e0f46e6045
merged from upstream repo
12 years ago
Brendon Scheinman
0d20391563
ck_rw_cohort: Added benchmark tests for reader-writer cohort locks
12 years ago
Brendon Scheinman
f693a16253
ck_rw_cohort: Added neutral reader-writer lock
12 years ago
Brendon Scheinman
21750b9321
ck_rw_cohort: Added read-preference logic and updated validation test to use it
12 years ago
Samy Al Bahra
16e8b1c672
regressions/ck_ring: Allow for buffers of size 4 or more.
12 years ago
David Joseph
adc1e28856
regressions: Windows header and define fixes.
12 years ago
David Joseph
d17d8e87bb
regressions: Remove void * casting.
12 years ago
David Joseph
ce3426ffaf
Merge branch 'master' of git://git.concurrencykit.org/ck
12 years ago
David Joseph
7b94d7c13d
regressions: Make clean and gettimeofday fixes.
12 years ago
David Joseph
a4cd7f2ef2
Revert "regressions: Remove exes with make clean."
...
This reverts commit 9d37e38580
.
12 years ago
Samy Al Bahra
099ec934b2
regressions/ck_queue: Remove stale include file.
...
This was added during testing to verify parity with
sys/queue.h.
12 years ago
David Joseph
9d37e38580
regressions: Remove exes with make clean.
12 years ago
Samy Al Bahra
d05fb25cfd
regressions: Remove ITERATION specialization silliness.
12 years ago
Samy Al Bahra
7de2d45d1a
Merge branch 'master' of https://github.com/davidjoseph/ck
12 years ago
Brendon Scheinman
a352b46d0b
ck_rw_cohort: renamed ck_rw_cohort namespace
12 years ago
Samy Al Bahra
011a9751a6
ck_queue: Add traversal-safe SPMC STAILQ.
12 years ago
Samy Al Bahra
9cf089b157
regressions/ck_list: Coverage for INSERT_AFTER/INSERT_BELOW.
12 years ago
David Joseph
ebc58ede20
regressions: fix common_gettimeofday.
...
Accidentally moved code that sets tv_sec/usec outside of tv NULL check.
12 years ago
David Joseph
8c88190557
regressions: fix printing timevalues in MinGW.
12 years ago
David Joseph
ef2ad6b998
regressions: Implement common_gettimeofday.
...
Windows uses GetSystemTimeAsFileTime, which has some differences
with Unix' gettimeofday.
This commit also reduces the number of iterations for the ck_ticket_pb
validation to 1000 - the test was taking too long on MinGW systems.
12 years ago
David Joseph
36a2ba143a
Merge branch 'master' of https://github.com/sbahra/ck
12 years ago
Samy Al Bahra
34a5bf4266
regressions/ck_cohort: Whitespace cleanup.
12 years ago
Samy Al Bahra
676f8fed88
Merge branch 'cohort_trylock' of git://github.com/bscheinman/ck
12 years ago
Samy Al Bahra
5c90d917f7
regressions/ck_ring: More improvements and _size coverage.
...
SPMC path exercises random delays. Coverage exists for
the new *_enqueue_*_size
12 years ago
Brendon Scheinman
3fefa3b5a3
ck_cohort: Fixed regression tests based on ck_cohort_rw changes
12 years ago
Brendon Scheinman
77ff96b15a
ck_cohort_rw: Added latency and throughput benchmark regression tests
12 years ago
Brendon Scheinman
114c916fea
ck_cohort_rw: Cleaned up regression files from last commit
12 years ago
Brendon Scheinman
5e1b614108
ck_cohort_rw: Initial implementation with validation test.
...
I still need to implement benchmark tests and write documentation. The reader-writer cohort locks also required that I add a method to the existing ck_cohort framework to determine whether or not a cohort lock is currently in a locked state.
12 years ago
Brendon Scheinman
3c8728b214
ck_cohort: Added trylock support to cohort framework
12 years ago
Brendon Scheinman
78fbe93caa
ck_cohort: fixed regression tests to match new CK_COHORT_PROTOTYPE signature
12 years ago
Brendon Scheinman
ed5292546f
merged changes from main ck repo
12 years ago
David Joseph
60873b9af5
Merge branch 'master' of https://github.com/sbahra/ck
12 years ago
David Joseph
9640eabba8
regressions: Fix for common alarm init.
12 years ago
David Joseph
aaebc6b31b
regressions: Fix for common alarm prefixes.
12 years ago
David Joseph
da23134615
regressions: Fix for alarm interface.
12 years ago
David Joseph
0784be7ff0
regressions: Fix tests that use common alarm.
12 years ago
David Joseph
339a1bd639
regressions: Add prefix to common alarm interface.
12 years ago
Samy Al Bahra
7e9a020abd
regressions: Add ck_pflock clean target.
12 years ago
Samy Al Bahra
f6a53fd9de
ck_cohort: First-cut implementation of generalized cohort interface.
...
This work was contributed by Brendon Scheinman. This work is based
off "Lock Cohorting: A General Technique for Designing NUMA Locks".
12 years ago
Brendon Scheinman
5914bbe2c2
ck_cohort: Moved locks to separate cachelines in throughput test
12 years ago
Brendon Scheinman
c4e3edfeac
Merge branch 'master' of https://github.com/sbahra/ck into cohort
12 years ago
Brendon Scheinman
81a90e41a2
review: A couple more changes based on ck_cohort review
...
I added an extra argument to the CK_COHORT_INIT macro to allow users to specify custom pass limits
when using it. I also added a reference to the paper on which the cohort implementation was based.
12 years ago
Brendon Scheinman
803073b024
interface: Made ck_cohort interface more flexible for custom types
12 years ago
Brendon Scheinman
44ea3a4688
review: First round of review changes
...
The constants and macros in ck_cohort.h didn't conform to CK naming conventions. Additionally, I was able to remove a lot of unnecessary atomic operations and memory fences, which reduced latency by 10-20% and increased throughput using ticket locks by nearly an order of magnitude.
12 years ago
Samy Al Bahra
7ce276f5eb
regressions: Add ck_pflock to make check target.
12 years ago
Samy Al Bahra
54845bb8e7
ck_pflock: Phase-fair read-write lock implementation.
...
John Wittrock has contributed a phase-fair reader-writer
lock implementation. These locks allow phase fairness
guarantees between readers and writers. This work includes
additional changes and clean-up.
Follow-up work is expected.
Thanks to John Wittrock for patches and Professor Gabriel
Parmer (http://www.seas.gwu.edu/~gparmer/ ) for advising.
12 years ago
Brendon Scheinman
e06b4a26ff
cleanup: Removed unnecessary code copied from ck_spinlock's throughput test
12 years ago
Brendon Scheinman
2492f16ec9
whitespace: Added missing space to usage message
12 years ago
Brendon Scheinman
c6cd9e5be8
testing: Added throughput test for ck_cohort
12 years ago
Brendon Scheinman
2cb79b0658
testing: Added latency test for ck_cohort
12 years ago
Samy Al Bahra
27d454248d
ck_spinlock: Add ticket lock with trylock operation.
...
Upon popular request, added a variant of the ticket spinlock
with trylock support. This is pending additional verification
on other architectures besides x86*. It is still unclear whether
this implementation will be the default as it is has slower
fast path.
Add trylock support to the ck_spinlock validation tests.
It currently only tests ck_spinlock_ticket_t trylock
functionality if available.
12 years ago
Brendon Scheinman
59cc30b671
testing: ck_cohort validation
...
The ck_cohort validation test had an error that would cause an uneven distribution of threads among cohorts when the affinity delta was set above 1.
12 years ago
Brendon Scheinman
d5c05309b4
cleanup: ck_cohort validation test
...
Removed unnecessary includes and fixed shadowed variable warning.
12 years ago
Brendon Scheinman
0a826ca93b
gitignore: Removed ck_cohort validation binary from git
12 years ago
Brendon Scheinman
dbe49215ac
testing: Added validation test for cohorts.
12 years ago
David Joseph
10c3b22e48
Merge remote-tracking branch 'upstream/master'
...
Fix regressions for linux systems.
12 years ago
Samy Al Bahra
aef827b5a3
regressions: Remove unnecessary include.
12 years ago
Samy Al Bahra
81b9313e10
build: Fix regression introduced by MingW32 port.
12 years ago
David Joseph
8f1c31aa2c
Style changes to common.h's alarm macros.
12 years ago
David Joseph
3e469d7fb5
Namespace changes to regressions/common.h (alarm).
...
Add "local_name" to COMMON_ALARM_DECLARE_LOCAL and
COMMON_ALARM_DECLARE_INIT to avoid namespace conflicts.
12 years ago
Samy Al Bahra
9c298fc78b
whitespace: Remove unnecessary newline.
12 years ago
David Joseph
1298a6c335
Add support for MinGW32.
...
This primarily involved changing the configure script and adding
several utility functions to regressions/common.h for unit testing.
Signed-off-by: Samy Al Bahra <sbahra@appnexus.com>
12 years ago
Samy Al Bahra
9152cc7cea
regressions/ck_hp_fifo_donner: This was submitted from a Windows editor.
...
Switch to using UNIX EOL.
12 years ago
Samy Al Bahra
f9a484a10d
build: Disclaimer that regressions are unsupported for out-of-source builds.
12 years ago
Samy Al Bahra
cff7b1b21f
regressions/ck_queue: Add coverage for previous regression.
12 years ago
Samy Al Bahra
e517126247
regressions: Enable rdtsc for x86-32 targets.
12 years ago
Samy Al Bahra
72855320c4
regressions/ck_hs: Do not rely on ck_pr_add_64 for benchmarks.
...
ck_hs now officially targets the 32-bit ports. No advantage
to using ck_pr_*_64 operations here.
12 years ago
Samy Al Bahra
5d1fff2e06
regressions/ck_pr: Place double tests under feature flag.
12 years ago
Samy Al Bahra
33a9222923
legal: Update Copyright statements.
12 years ago
Samy Al Bahra
ca6637a57c
regressions/ck_pr: Utilize _GNU_SOURCE for ck_pr_store unit test.
12 years ago
Samy Al Bahra
3293cde2d2
regressions/common: Add missing header files in common.h
12 years ago
Samy Al Bahra
cb650246e2
regressions/ck_hp: Do not use empty loop body.
...
Fixes some GCC warnings in 4.7+.
12 years ago
Samy Al Bahra
0866206c1f
regressions/ck_ring: Add ck_ring_spmc to fast path test.
12 years ago
Samy Al Bahra
fbdc512304
regressions/ck_ring: Use variable for ring size.
12 years ago
Samy Al Bahra
0631e396e0
ck_backoff: Replace ck_backoff_eb with ck_backoff_gb.
...
The distinction between additive/exponential implementation
and geometric implementation does little but confuse users.
The terminology used in ck_backoff now reflects terminology
used in literature.
ck_backoff_gb has been removed.
12 years ago
Samy Al Bahra
d55e588ee4
regressions/ck_ring: Fix use of uninitialized data.
...
Execution history exists such that first thread will dequeue
from an uninitialized ring buffer. The unit test has been
(un)fortunate in that it would busy-wait during dequeue.
Full barrier semantics will enforce visibility.
Reported by: Maxime Henrion <mhenrion@gma....>.
12 years ago
Samy Al Bahra
1f13c75a66
regressions/ck_pr_store: Add coverage for double.
...
It appears GCC doesn't handle IMM constraint gracefully
for double. This isn't an issue with clang.
12 years ago
Samy Al Bahra
56bd0b7424
regressions/ck_fifo: cache align MPMC fifo.
12 years ago
Samy Al Bahra
3f0a90813a
ck_ring: Unit test coverage for ck_ring_trydequeue.
12 years ago
Samy Al Bahra
5c93ee3add
regressions: Do not use ck_error for debug output.
12 years ago
Samy Al Bahra
f1be36b6d2
regressions/ck_ring: Fix erroneous usage of ck_error.
12 years ago
Samy Al Bahra
6bd946d019
regressions: Add ck_error convenience function.
...
Prints a message and then executes exit(EXIT_FAILURE).
12 years ago
Samy Al Bahra
90745e4d60
regressions/ck_ring: Silence GCC false positives.
12 years ago
Samy Al Bahra
911909ef31
regressions/ck_ring: Add ck_ring_spmc_template unit test.
12 years ago
Samy Al Bahra
b07c7808ce
regressions/ck_ring: Add strict fence around barrier and cache align ring.
12 years ago
Samy Al Bahra
d705e02b76
ck_ring: Replace MPMC variant with SPMC variant for starters.
...
Immediate use-case is SPMC. Next is MPSC, then I will generalize
to MPMC (unfortunately, I don't have an algorithm that avoids CAS2
yet for MPMC).
12 years ago
Samy Al Bahra
8d90fa28ed
regressions/ck_ring: Add missing header file.
12 years ago
Samy Al Bahra
8d8f76845b
regressions/ck_ring: Add MPMC unit test.
12 years ago
Samy Al Bahra
68e6752e53
ck_ring: Due to popular request, add MPMC variants of enqueue/dequeue.
...
Fencing semantics are heavier-weight than they need to be.
12 years ago
Samy Al Bahra
cb1c72d36b
ck_queue: Add CK_?LIST_MOVE operation.
...
This operation is of format:
CK_S*LIST_MOVE(a, b, linkage) and is equivalent to intializing
a with the contents of b. This is done in a manner that is atomic
with respect to readers. Read-only operations are still valid in
b, but behavior is undefined for write-side operations on b after
a MOVE operation.
12 years ago
Samy Al Bahra
533136627f
regressions/ck_stack: Cache align stack.
12 years ago
Samy Al Bahra
b0277346b8
regressions/ck_bytelock: Cache-align bytelock.
...
Signed-off-by: Samy Al Bahra <sbahra@repnop.org>
12 years ago
Samy Al Bahra
ac50efbeaf
regressions/ck_epoch: GCC 4.6.3 ignores used attribute in this case.
12 years ago
Samy Al Bahra
ddfdda3649
regressions/ck_epoch: Force generation of stack dereference in ck_epoch_synchronize.
12 years ago
Samy Al Bahra
099f13a24d
regressions/ck_epoch: Force generation of stack pointer.
12 years ago
Samy Al Bahra
31040a925d
regressions/ck_ht: Use random get counter.
...
We were erroneously printing reverse get results in serial.
12 years ago
Samy Al Bahra
ee2ae5a50f
regressions/ck_epoch: Update check target.
...
Makefile was ignored due to bogus gitignore entry.
12 years ago
Samy Al Bahra
690782aa67
ck_hs: Add hash function wrapper to maintain opacity of ck_hs_t.
...
This is in the form of CK_HS_HASH(X, Y, Z) which expands to
Y(Z, X.seed).
12 years ago
Samy Al Bahra
43b24d9f28
regressions/ck_hs: Initialize n_state.
12 years ago
Samy Al Bahra
44b845a53a
regressions/ck_hs: Use (char *) for debug output.
12 years ago
Samy Al Bahra
bc7a3e5606
regressions/ck_bag: Add status around sleep.
12 years ago
Samy Al Bahra
ece2895e9e
ck_hs: Drop ck_hs_hash_t abstraction.
...
No need for opaque type anymore.
12 years ago
Samy Al Bahra
adaf20b31c
ck_ht: Add ck_ht_stat function.
...
This can be used to expose certain performance metrics.
12 years ago
Samy Al Bahra
a40b724270
regressions/ck_hs: Add Makefile for benchmarks.
12 years ago
Samy Al Bahra
0f5e540afa
ck_hs: Lock-free set loosely modeled after ck_ht.
...
Currently only SPMC, but MPMC transformation is relatively trivial.
Documentation will come in a follow-up commit.
12 years ago
Samy Al Bahra
67895cb87e
regressions/ck_epoch: Add support for multiple writers in poll unit test.
12 years ago
Samy Al Bahra
375a9eb816
regressions/ck_epoch: Drop debug flags.
12 years ago
Samy Al Bahra
034759c3b9
regressions: Update callers to ck_epoch_call.
12 years ago
Samy Al Bahra
657c50f823
regressions/ck_epoch: Multiple writers for synchronize unit test.
12 years ago
Samy Al Bahra
5293ad2348
regressions/ck_epoch: Reduce number of poll iterations, change peak calculation in synchronize.
12 years ago
Samy Al Bahra
57104fcde7
ck_epoch: Change to epoch semantics, bump grace period to 4.
12 years ago
Samy Al Bahra
ce7278140c
regressions/ck_epoch: Add missing header files.
12 years ago
Samy Al Bahra
c274e8bc54
ck_epoch: Major redesign and rewrite.
...
I had the pleasure of spending a significant amount of time at the most
recent LPC with Mathieu Desnoyers and Paul McKenney. In discussing
RCU semantics in relation to epoch reclamation, it was argued that
epoch reclamation is a specialisation of RCU (rather than a generalization).
In light of this discussion, I thought it would make more sense to not expose
write-side synchronization semantics aside from ck_epoch_call (similar to
RCU call), ck_epoch_poll (identical to tick), ck_epoch_barrier and
ck_epoch_synchronization (similar to ck_epoch_synchronization). Writers will
now longer have to use write-side epoch sections but can instead rely on
epoch_barrier/synchronization for blocking semantics and ck_epoch_poll
for old tick semantics.
One advantage of this is we can avoid write-side recursion for certain workloads.
Additionally, for infrequent writes, epoch_barrier and epoch_synchronization both
allow for blocking semantics to be used so you don't have to pay the cost of
epoch_entry for non-blocking dispatch.
Example usage:
e = stack_pop(mystack);
ck_epoch_synchronize(...);
free(e);
read_begin and read_end has been replaced with ck_epoch_begin and ck_epoch_end.
If multiple writers need SMR guarantees, then they can also use ck_epoch_begin
and ck_epoch_end. Any dispatch in presence of multiple writers should be done
with-in an epoch section (for now).
There are some follow-up commits to come.
12 years ago
Samy Al Bahra
b220e50f54
regressions/ck_pr: Disable rest of width checks on bi-endian platforms.
12 years ago
Samy Al Bahra
6961547dfe
regressions/ck_pr: Remove unnecessary assignment in Makefile.
12 years ago
Samy Al Bahra
98660bf560
regressions/ck_pr: Disable width checks on bi-endian architectures.
12 years ago
Samy Al Bahra
7ebbcf55b1
regressions/ck_spinlock: Disable linux_spinlock on unsupported platforms.
12 years ago
Samy Al Bahra
d72ca391f6
ck_bytelock: Switch to RMO model.
12 years ago
Samy Al Bahra
bac1c1d26a
regressions/ck_stack: Disable various TRYMPMC benchmarks on unsupported platforms.
12 years ago
Samy Al Bahra
3e4aa8239a
regressions: Add _GNU_SOURCE to ck_backoff. Don't apply to all.
12 years ago
Samy Al Bahra
f4e50d16d8
regressions: Use _GNU_SOURCE by default on Linux.
12 years ago
Samy Al Bahra
8043f52130
ck_pr: Add ck_pr_barrier for compiler barrier.
...
CK_CC_BARRIER isn't idiomatic, roll this into PR memory model
instead.
12 years ago
Samy Al Bahra
7e9a0d8751
regressions/ck_brlock: Reduce number of iterations.
12 years ago
Samy Al Bahra
f8c19a89b4
regressions/ck_hp: LLVM's optimizer keeps getting the best of us.
...
If I see more regressions in LLVM, I may end up enforcing compiler
barriers in all inlined code.
12 years ago
Samy Al Bahra
f567513f8c
regressions/ck_hp: Add Donner's unit test.
12 years ago
Samy Al Bahra
3f6a3660eb
regressions/ck_stack: Add trypush unit tests to check target.
...
Submitted by Andrew Schorr <aschorr@telemetry-inves....>.
12 years ago
Samy Al Bahra
d454f729e0
regressions/ck_fifo: Add dependency to ck_fifo.h.
12 years ago
Samy Al Bahra
290add2e50
build/regressions: Add CORES option, add "check" target.
...
The check target will attempt to run the unit tests with some
sane defaults.
12 years ago
Samy Al Bahra
1a8b3db453
ck_ht: Various performance improvements.
...
Though a new implementation is in the works, roll in
some performance improvements in the mean time.
The probe routines have been broken out into separate
reader/writer variants. These variants are much less
branch-intensive (and don't involve predict to stall
in many cases).
New implementation is attempting to deal with
interface-induced overheads.
12 years ago
Samy Al Bahra
e1ec55819e
regressions/common. Move edx/eax to x86_64 block.
12 years ago
Samy Al Bahra
a56cac3a38
regressions/ck_sequence: Work-around LLVM bug.
...
For some reason, load operations were being re-ordered with respect
to read begin operation (even with explicit compiler barriers).
12 years ago
Samy Al Bahra
59158c824b
ck_ht: Do not re-hash on growth for non-PP case.
...
We already store the hash value in the hash table entry
if pointer packing is not enabled.
13 years ago
Samy Al Bahra
72a8adb599
ck_ht: Add support for per-hash-table allocator.
...
Documentation and regressions tests have been updated to reflect this.
This functionality allows for individual hash tables use to different
allocation functions. Thanks to Wez Furlong for pointing out the necessary
documentation update for ck_ht.
13 years ago
Samy Al Bahra
af7b877414
regressions/ck_ht: Turn off CK_MD_RDTSCP by default.
13 years ago
Samy Al Bahra
cc23781512
regressions/ck_ht: Switch to a format that is more readable by R.
...
This allows me to use read.table with minimal changes.
13 years ago
Samy Al Bahra
9a3909163f
regressions/ck_ht: Drop secondary sequence table.
...
It is unnecessary, we primarily end up measuring cache miss costs
with it.
13 years ago
Samy Al Bahra
0b32fd064e
regressions/ck_ht: Previous commit was in fact shuffled insertion.
...
Add actual shuffled get.
13 years ago
Samy Al Bahra
efdae8f77b
regressions/ck_ht: Extend serial benchmark.
...
Add key shuffle get test.
13 years ago
Samy Al Bahra
3b5a3c857e
regressions: Update out-of-date comment.
13 years ago
Samy Al Bahra
da9e0f58f1
regressions: Use RDTSCP in presence of CK_MD_RDTSCP.
13 years ago
Samy Al Bahra
b353ebe8c2
regressions: Remove debug build flags.
13 years ago
Samy Al Bahra
314ce3ad81
ck_rwlock: Drop factor argument to trylock API.
...
Remove read-side recursion tests, it is an unsupported
feature to begin with.
13 years ago
Samy Al Bahra
512bbc050b
ck_rwlock: Add recursive trylock operations.
...
Unlike ck_rwlock, there is no spin factor associated with these.
13 years ago
Samy Al Bahra
380dd410c6
ck_backoff: Saturate geometric back-off.
...
A simple regression test has been added to verify this behavior.
13 years ago
Samy Al Bahra
fc2517947b
regressions/ck_ht: Use user-specified hash function for direct benchmark.
13 years ago
Samy Al Bahra
18d74f55a1
ck_ht: Add support for user-specified hash functions.
13 years ago
Samy Al Bahra
606afe0f23
ck_rwlock: Add ck_rwlock_recursive facility.
...
Allows for write-side recurion. Added upon request by
other users. Regression test has been updated.
13 years ago
Samy Al Bahra
402c31ca9a
ck_hp_fifo: Add try{enqueue,dequeue} variants.
...
Regression test has been updated and passes.
13 years ago
Samy Al Bahra
a90b402c0c
regressions/ck_fifo: Add test for try{enqueue,dequeue} API.
13 years ago
Samy Al Bahra
ff6f4d94f4
ck_stack: Add wait-free trypop and trypush operations.
...
Regression tests have been updated to test these operations as
equivalents to regular looping push/pop operations.
13 years ago
Samy Al Bahra
2b2e44203b
Merge pull request #5 from abelmathew/master
...
ck_bag: Merge from abelmathew/master.
13 years ago
Abel Mathew
6a6f1d53c8
ck_bag: Validate block_size > block_overhead during ck_bag_init.
...
Check ck_bag_init return value in unit test.
13 years ago
Abel Mathew
bbc6f584fd
ck_bag: Various Bug Fixes and Cleanup.
...
Migrate available block list to CK_LIST.
New blocks are only allocated when the available list is exhausted.
Remove bag->avail_tail.
Print out number of writer iterations for unit test.
Lengthen duration of unit test.
13 years ago
Samy Al Bahra
099a6c7b04
ck_bitmap: Add bitmap iterator functions.
...
These can do with some optimization. A majority of this
work is based off an earlier patch submitted by
Shreyas Prasad <sprasad@appne....>.
13 years ago
Samy Al Bahra
3cf265cba0
all: Strip trailing whitespaces.
13 years ago
Samy Al Bahra
10d86b6424
ck_bitmap: Overhaul API for improved support of static instances.
...
This changes comes at the cost of clear linearizability, which
is suitable for my use-case. Users can easily implement linereazability
through an additional level of indirection to the ck_bitmap object.
13 years ago
Samy Al Bahra
9d4541d703
ck_bitmap: Fix ck_bitmap_init.
...
Refs #85
13 years ago
Samy Al Bahra
773ceb8257
regressions: Add necessary header file for sleep.
13 years ago
Samy Al Bahra
ab73676ee4
ck_bitmap: Lock-free MPMC contiguous bitset implementation.
...
Rather trivial data structure but driven by sufficient user-demand.
Manual pages to come.
13 years ago
Abel Mathew
eaa8ad1d4d
ck_bag: Various bug fixes.
...
Add necessary load fence to iterator.
Initialize iterator appropriately for empty bags.
Improve unit test.
Fix bag linkage bug for non x86_64 targets.
Fix block accounting on removal.
13 years ago
Samy Al Bahra
2111824c9e
regressions: Add ck_bag regressions.
13 years ago
Samy Al Bahra
a6dce3abff
regressions/ck_bag: Use epoch reclamation, allow for user-defined block size.
13 years ago
Abel Mathew
431c24a90a
ck_bag: Lock-Free SPMC bag/collection for x86_64. A bag is a linked list of blocks, with each block containing an array. Insertions are on the order of O(1) and deletions are on the order of O(N). This data structure is meant to act as a lock-free vector implementation.
...
Signed-off-by: Samy Al Bahra <sbahra@repnop.org>
13 years ago
Samy Al Bahra
0bcb0b48b2
regressions: Add ck_ht parallel direct microbenchmark.
13 years ago
Samy Al Bahra
706fd07de7
legal: Update Copyright statements.
13 years ago
Samy Al Bahra
519a14b7f3
ck_ht: Add CK_F_HT feature flag.
13 years ago
Samy Al Bahra
3ad9f7e63d
ck_ht: Add support for other 64-bit platforms.
...
Specifically, any platform that has CK support for 64-bit
load/store operations.
Additional improvements have been made to the unit tests
to disambiguate put/get failures.
13 years ago
Samy Al Bahra
516381da4c
regressions: Remove CORES definition from ck_ht ubenches.
13 years ago
Samy Al Bahra
cef7de2c5f
regressions: ck_ht parallel benchmark makes use of affinerator.
...
Currently, it will default to RR behavior across cores with no
delta support.
13 years ago
Samy Al Bahra
d9017b3e5b
regressions: Add multi-threaded SPMC synthetic benchmark for ck_ht.
13 years ago
Samy Al Bahra
9f786337f7
ck_ht: Lock-free SPMC hash table, for x86_64.
...
This is a hash table that is optimized for architectures that
implement total store ordering and workloads that are read-heavy
involving a single writer and multiple readers. Unlike traditional
non-blocking multi-producer/multi-consumer hash table
implementations this version allows for immediate re-use of deleted
buckets (no need for explicit reclamation cycles) and is more
conducive to traditional safe memory reclamation schemes used in
unmanaged languages (otherwise, we would require key duplication).
It is relatively heavy-weight for MPMC workloads on architectures
which do not implement TSO in comparison to Click's MPMC hash
table. However, it still has better performance characteristics
than a blocking hash table.
The committed version currently only provides x86_64 support. This is
being committed for review by peers and for a silent release that will
allow us to test ck_ht_spmc under high production workloads.
Next public release will include additional documentation as well as
support for other architectures.
In the mean time, please see the unit tests for example usage. Included in
this commit: Dropped -Wbad-function-cast from GCC port.
13 years ago
Samy Al Bahra
84535028d9
regressions: ck_ring_spsc_template explicit power of 2 parameter.
13 years ago
Samy Al Bahra
d7bba58c0f
regressions: ck_ring_spsc is now explicit about power-of-2 parameter.
13 years ago
Samy Al Bahra
3fa28d9a95
regressions: Fix typo in ck_queue regressions, _GNU_SOURCE also needed.
13 years ago
Samy Al Bahra
02109beef7
regressions: Fix ck_queue, remove debug CFLAGS, inherit PTHREAD_CFLAGS.
...
Reported by Johan Bergstrom (http://github.com/jbergstroem ).
13 years ago
Samy Al Bahra
674e69f259
ck_queue: Add BSD-derived queue.h facility.
...
Writer-side synchronization is still necessary. My current use-cases call for
SLIST and LIST implementations, and as such, I've only implemented support
for these. TAILQ facilities will be developed when the time comes that I require
them or if there is sufficient user-demand.
13 years ago
Samy Al Bahra
4d2f01b84d
regressions: Do not break strict aliasing rules in ck_pr validation tests.
...
Signed-off-by: Samy Al Bahra <sbahra@appnexus.com>
13 years ago
Samy Al Bahra
941bc25734
regressions: Add missing include for memset.
...
Signed-off-by: Samy Al Bahra <sbahra@appnexus.com>
13 years ago
Samy Al Bahra
544de60849
ck_pr: Add appropriate casts to ck_pr_cas unit test.
13 years ago