GithubHelp home page GithubHelp logo

hongwliu / pr Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jonatanlinden/pr

0.0 0.0 0.0 134 KB

A lock-free priority queue implementation

License: BSD 3-Clause "New" or "Revised" License

C 90.09% C++ 5.82% Python 2.77% Makefile 1.32%

pr's Introduction

A Lock-Free Skiplist-Based Priority Queue

License Build Status

A linearizable skiplist-based lock-free priority queue implementation minimizing the number of required CAS-instructions per operation. The skiplist implementation is adapted from Keir Fraser's skiplist (http://www.cl.cam.ac.uk/techreports/UCAM-CL-TR-579.pdf).

For more information about the priority queue, see http://user.it.uu.se/~jonli208/priorityqueue.

Build

make perf_meas

Usage

Run the benchmark application as:

./perf_meas -n 8 -o 64 -t 42 

This will start a benchmark run with 8 threads, the offset parameter of the algorithm will be set to 64, and the benchmark will run for 42 seconds. Per default, the inserted keys are uniformly distributed, operations (deletemin, insert) are randomly selected (50%/50%) and the queue is prefilled with 2^15 elements.

Run

./perf_meas -h

for more information about the available parameters.

Extras

A model for the SPIN model checker (http://spinroot.com) is included, with linearizability checks of the operations. The -O flag has to be used (if SPIN version >= 6), the model is using the old scope rules. To perform a bit state space analysis:

spin -O -a prioq_model.pml
gcc -O2 -DMEMLIM=2048 -DBITSTATE -o pan pan.c
./pan -w33

pr's People

Contributors

jonatanlinden avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.