Reading List

The Selfish Gene
The Psychopath Test: A Journey Through the Madness Industry
Bad Science
The Feynman Lectures on Physics
The Theory of Everything: The Origin and Fate of the Universe


ifknot's favorite books »
Showing posts with label concurrency. Show all posts
Showing posts with label concurrency. Show all posts

Monday, 1 January 2018

C++ Mellor-Crummey & Scott (MCS) Lock - Milestones In Computer Science


I have been reading Herlihy, Maurice; Shavit, Nir. The Art of Multiprocessor Programming, Revised Reprint. Elsevier Science. (Kindle Edition) and converting the Java lock code into C++ here is my favourite so far: 

The Mellor-Crummey & Scott Spin Lock

The Mellor-Crummey & Scott (MCS) Lock, due to John Mellor-Crummey and Michael Scott improves upon their ticket lock by expanding a spinlock into a per-thread structure, an MCS lock is able to eliminate much of the cache-line bouncing experienced by simpler locks, especially in the contended case. 

The MCS Lock use an explicit linked list of synchronization variables, into which threads' synchronization variables are enqueued by order of arrival and avoids thread starvation by guaranteeing that an enqueued thread will, eventually, get access.

The MCS Lock is, therefore, fair and scalable and is the primary example of linked list queue lock family of locking strategies.

Its creators were awarded the 2006 Edsger W. Dijkstra Prize in Distributed Computing for their 1991 paper, "Algorithms for Scalable Synchronization on Shared-Memory Multiprocessors."

Saturday, 10 September 2016

Migrating to Bitbucket and turning my markdown frown upside down with Dillinger WYSIWYG and Cloudup image drop spot.

Check out my fancy markdown https://bitbucket.org/ifknot/liblog


Why move from GitHub to Bitbucket?


Bitbucket, similar to GitHub, is a web based GIT hosting service for your projects. It offers free private repositories with free private wikis on accounts of up to 5 users(!) and you can switch any repo public and back again anytime. So develop in private and publicise when you're ready. 

GitHub’s  free account doesn’t allow for private repos and their lowest paid option (for organizations) only allows up to 10 private repos. Bitbucket, on the other hand, offers unlimited private repos. 

It's easy to import directly from GitHub with the click of a button - well done Bitbucket.

What to move first?

I moved over liblog the logging software that I first blogged about way back in Jan 2014 but wanted to have a nice front piece for when I chose to make it public. This can be easily achieved using markdown in a README.md file pushed to the repo. 


Markdown frown. 

dillinger.io
Markdown is (quite) easy but slow to hand roll but with the excellent online WYSIWYG markdown editor Dillinger "Type some Markdown on the left... see HTML in the right" I found it pleasurable to work with and get some decent looking results.

Gratis image drop.

A free account on Cloudup gives you space to drop pics/vids/music/docs and have nifty short URLS to them for your markdown/blog/web

Tuesday, 14 June 2016

4 Interesting Comments

Getting my daily dose of tech-trash-talk from the Vulture came across this interesting article:

http://www.theregister.co.uk/2016/06/07/from_iwarp_to_knights_landing_james_reinders_leaves_intel/

About Intel's guru of parallelism taking early retirement, but it was the 4 comments that I liked as short insightful thoughts on the current state of concurrency despite long term work over decades:

http://forums.theregister.co.uk/forum/1/2016/06/07/from_iwarp_to_knights_landing_james_reinders_leaves_intel/

As someone who dabbles in the field and with an MSc based on CSP by Sir Tony it is a shame that we are not much further on.