Skip to content
This repository has been archived by the owner on Jan 18, 2019. It is now read-only.
/ scal Public archive
forked from cksystemsgroup/scal

High-performance multicore-scalable data structures and benchmarks

License

Notifications You must be signed in to change notification settings

levpachmanov/scal

 
 

Repository files navigation

Scal Build Status

Scal is an open-source benchmarking framework that provides (1) software infrastructure for executing concurrent data structure algorithms, (2) workloads for benchmarking their performance and scalability, and (3) implementations of a large set of concurrent data structures.

Homepage: http://scal.cs.uni-salzburg.at
Paper: Scal: A Benchmarking Suite for Concurrent Data Structures

Data structures

Name Semantics Year Ref
Lock-based Singly-linked List Queue strict queue 1968 [1]
Michael Scott (MS) Queue strict queue 1996 [2]
Flat Combining Queue strict queue 2010 [3]
Wait-free Queue strict queue 2012 [4]
Linked Cyclic Ring Queue (LCRQ) strict queue 2013 [5]
Timestamped (TS) Queue strict queue 2015 [6]
Cooperative TS Queue strict queue 2015 [7]
Segment Queue k-relaxed queue 2010 [8]
Random Dequeue (RD) Queue k-relaxed queue 2010 [8]
Bounded Size k-FIFO Queue k-relaxed queue, pool 2013 [9]
Unbounded Size k-FIFO Queue k-relaxed queue, pool 2013 [9]
b-RR Distributed Queue (DQ) k-relaxed queue, pool 2013 [10]
Least-Recently-Used (LRU) DQ k-relaxed queue, pool 2013 [10]
Locally Linearizable DQ
(static, dynamic)
locally linearizable queue, pool 2015 [11]
Locally Linearizable k-FIFO Queue locally linearizable queue
k-relaxed queue, pool
2015 [11]
Relaxed TS Queue quiescently consistent
queue (conjectured)
2015 [7]
Lock-based Singly-linked List Stack strict stack 1968 [1]
Treiber Stack strict stack 1986 [12]
Elimination-backoff Stack strict stack 2004 [13]
Timestamped (TS) Stack strict stack 2015 [6]
k-Stack k-relaxed stack 2013 [14]
b-RR Distributed Stack (DS) k-relaxed stack, pool 2013 [10]
Least-Recently-Used (LRU) DS k-relaxed stack, pool 2013 [10]
Locally Linearizable DS
(static, dynamic)
locally linearizable stack, pool 2015 [11]
Locally Linearizable k-Stack locally linearizable stack
k-relaxed queue, pool
2015 [11]
Timestamped (TS) Deque strict deque (conjectured) 2015 [7]
d-RA DQ and DS strict pool 2013 [10]

Dependencies

On Ubuntu (≥ 14.04) based systems:

sudo apt-get install --fix-missing google-perftools libgoogle-perftools-dev cmake libgtest-dev libgflags-dev

On Debian (jessie) based systems:

sudo apt-get install build-essential autoconf libtool google-perftools libgoogle-perftools-dev cmake libgtest-dev libgflags2 libgflags-dev

Building

Note: We switched from autotools to gyp for building the framework. The old files are still present in the checkout but will be removed once everything is converted.

This is as easy as

tools/make_deps.sh
build/gyp/gyp --depth=. scal.gyp
V=1 BUILDTYPE=Debug make
V=1 BUILDTYPE=Release make

The debug and release builds reside in out/.

Additional data files, such as graph files, are available as submodule

git submodule init
git submodule update data

The resulting files reside in data/.

Examples

Producer/consumer

The most common parameters are:

  • consumers: Number of consuming threads
  • producers: Number of producing threads
  • c: The computational workload (iterative pi calculation) between two data structure operations
  • operations: The number of put/enqueue operations the should be performed by a producer

The following runs the Michael-Scott queue in a producer/consumer benchmark:

./prodcon-ms -producers=15 -consumers=15 -operations=100000 -c=250

And the same for the bounded-size k-FIFO queue:

./prodcon-bs-kfifo -producers=15 -consumers=15 -operations=100000 -c=250

And for Distributed Queue with a 1-random balancer:

./prodcon-dds-1random-ms -producers=15 -consumers=15 -operations=100000 -c=250

Try ./prodcon-<data_structure> --help to see the full list of available parameters.

References

  1. D. E. Knuth. The Art of Computer Programming, Volume 1 (3rd Ed.): Fundamental Algorithms. Addison Wesley, Redwood City, CA, USA, 1997.

  2. M.M. Michael and M.L. Scott. Simple, fast, and practical non-blocking and blocking concurrent queue algorithms. In Proc. Symposium on Principles of Distributed Computing (PODC), pages 267–275. ACM, 1996.

  3. D. Hendler, I. Incze, N. Shavit, and M. Tzafrir. Flat combining and the synchronization-parallelism tradeoff. In Proc. Symposium on Parallelism in Algorithms and Architectures (SPAA), pages 355–364. ACM, 2010.

  4. A. Kogan and E. Petrank. A methodology for creating fast wait-free data structures. In Proc. Symposium on Principles and Practice of Parallel Programming (PPoPP), pages 141–150. ACM, 2012.

  5. A. Morrison and Y. Afek. Fast concurrent queues for x86 processors. In Proc. Symposium on Principles and Practice of Parallel Programming (PPoPP), pages 103–112. ACM, 2013.

  6. M. Dodds, A. Haas, and C.M. Kirsch. A scalable, correct time-stamped stack. In Proc. Symposium on Principles of Programming Languages (POPL), pages 233– 246. ACM, 2015.

  7. A. Haas. Fast Concurrent Data Structures Through Timestamping. PhD thesis, University of Salzburg, Salzburg, Austria, 2015.

  8. Y. Afek, G. Korland, and E. Yanovsky. Quasi-linearizability: Relaxed consistency for improved concurrency. In Proc. Conference on Principles of Distributed Systems (OPODIS), pages 395–410. Springer, 2010.

  9. C.M. Kirsch, M. Lippautz, and H. Payer. Fast and scalable, lock-free k-fifo queues. In Proc. International Conference on Parallel Computing Technologies (PaCT), LNCS, pages 208–223. Springer, 2013.

  10. A. Haas, T.A. Henzinger, C.M. Kirsch, M. Lippautz, H. Payer, A. Sezgin, and A. Sokolova. Distributed queues in shared memory—multicore performance and scalability through quantitative relaxation. In Proc. International Conference on Computing Frontiers (CF). ACM, 2013.

  11. A. Haas, T.A. Henzinger, A.Holzer, C.M. Kirsch, M. Lippautz, H. Payer, A. Sezgin, A. Sokolova, and H. Veith. Local linearizability. CoRR, abs/1502.07118, 2015.

  12. R.K. Treiber. Systems programming: Coping with parallelism. Technical Report RJ-5118, IBM Research Center, 1986.

  13. D. Hendler, N. Shavit, and L. Yerushalmi. A scalable lock-free stack algorithm. In Proc. Symposium on Parallelism in Algorithms and Architectures (SPAA), pages 206–215. ACM, 2004.

  14. T.A. Henzinger, C.M. Kirsch, H. Payer, A. Sezgin, and A. Sokolova. Quantitative relaxation of concurrent data structures. In Proc. Symposium on Principles of Programming Languages (POPL), pages 317–328. ACM, 2013.

License

Copyright (c) 2012-2016, the Scal Project Authors. All rights reserved. Please see the AUTHORS file for details.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

The views and conclusions contained in the software and documentation are those of the authors and should not be interpreted as representing official policies, either expressed or implied, of the Scal Project.

About

High-performance multicore-scalable data structures and benchmarks

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C++ 82.9%
  • Python 7.9%
  • C 6.4%
  • Makefile 2.2%
  • Other 0.6%