recentpopularlog in

mcherm : parallelprogramming   70

DBMS Musings: It’s Time to Move on from Two Phase Commit
This author proposes to keep ACID but get rid of two phase commit. The secret is to make systems that are not allowed to fail.
database  via:HackerNews  concurrency  parallelprogramming 
january 2019 by mcherm
Race-Safe Strategies
A review of ways to protect an object shared between threads. Despite the author's claim, I am dubious about this being exhaustive.
programming  concurrentprogramming  parallelprogramming  via:reddit 
december 2018 by mcherm
André Staltz - Promises are not neutral enough
The promises added to JavaScript are eager (lazy would be nicer), have no cancellation, do not resolve until after the current event loop, and then() mixes "map" and "flatmap" behavior. Author says these were poor design choices; Hacker News commentary disagrees.
javascript  concurrency  concurrentprogramming  parallelprogramming  via:HackerNews 
february 2018 by mcherm
JavaScript Promises: an Introduction  |  Web Fundamentals  |  Google Developers
About doing promises (and thus useful concurrency) natively in JavaScript that works in nearly all major browsers.
javascript  webdevelopment  concurrentprogramming  parallelprogramming  programming 
january 2018 by mcherm
Using JDK 9 Memory Order Modes
Doug Lea talks about new changes to the Java memory model (for threading) that are coming in JDK9.
DougLea  concurrency  parallelprogramming  java  jvm  via:HackerNews 
march 2017 by mcherm
Leapfrog Probing
An implementation of a lock-free concurrent hashtable -- and the writeup is REALLY excellent. (Read the whole chain of previous articles to get the entire story.)
concurrentprogramming  concurrency  parallelprogramming  hash  programming  computerscience 
may 2016 by mcherm
Semaphores are Surprisingly Versatile
Nice little writeup on a basic piece of synchronization, along with the C++ library.
concurrentprogramming  parallelprogramming  programming 
april 2015 by mcherm
How to miscompile programs with “benign” data races [PDF]
A paper on the kinds of transformations that compilers can do and why data races aren't OK ever in any compiled language.
programming  concurrency  concurrentprogramming  parallelprogramming  via:HackerNews 
february 2015 by mcherm
Working simultaneously vs waiting simultaneously
You have apps that WAIT for many things at once, and those that do many CALCULATIONS at once. The former works well with languages like Go or Erlang; the latter works well with languages like C, or with SIMD in the extreme. This article explains why.
concurrency  concurrentprogramming  threading  parallelprogramming  via:HackerNews 
may 2014 by mcherm
Immutability, MVCC, and garbage collection at Xaprb
Why databases using immutable data structures always sound exciting, but mature databases don't ever look like that. A combination of concurrency and improving performance lead one away from the elegant design of true immutability to small continuous cleanup.
datastructures  database  programming  concurrency  immutable  parallelprogramming 
december 2013 by mcherm
It's "locking" if it's blocking
What's the difference between code with locks and "lock free" code? It's "lock free" if it's never going to have a harder time because some other thread gets suspended. OS support for locks is because only the OS can help when the problem is a different thread. Also, locking & lock-free are equivalent but optimistic/pessimistic in approach.
via:YossiKreinin  parallelprogramming  concurrentprogramming  programming 
december 2012 by mcherm
So what's wrong with 1975 programming?
Not since 1975 have computers had two speeds of storage, "disk" and "RAM". If you program like that you create unnecessary inefficiencies. Also the many levels of cache make shared variables (or worse, shared CACHE LINES) very slow; allocate your memory in a way that avoids this.
programming  memory  concurrentprogramming  parallelprogramming 
december 2012 by mcherm
Java's Atomic and volatile, under the hood on x86 - Marc's Blog
At the assembly-language level, comparing normal, volatile, and atomic variables (for X86 machines).
via:HackerNews  programming  java  parallelprogramming  concurrentprogramming 
november 2012 by mcherm
This Is Why They Call It a Weakly-Ordered CPU
An example created to demonstrate that the CPU can reorder memory access (not the compiler). It's surprisingly hard to demonstrate.
via:reddit  parallelprogramming  concurrentprogramming  programmming 
october 2012 by mcherm
PyPy Status Blog: STM with threads
Armin's no-GIL pypy is now running only 4x slower than the default version.
threading  python  parallelprogramming  ArminRigo  via:HackerNews  softwaretransactionalmemory 
june 2012 by mcherm
PyPy Status Blog: STM update: back to threads?
Armin explains that he's now using STM in PyPy to just provide normal threading, plus an ability to create a "transaction". It is course-grained, but he says that's OK. I tried reasoning about a common problem (web application threading) and found that it backed up his claim.
stm  softwaretransactionalmemory  python  pypy  mypostings  ArminRigo  programming  threading  concurrentprogramming  parallelprogramming  via:HackerNews 
may 2012 by mcherm
SIP-14 - Futures and Promises - Scala Documentation
A scalar library for futures. Uses asynchronous callbacks. Which thread does it run in, I wonder?
scala  parallelprogramming  concurrentprogramming  via:twitter 
january 2012 by mcherm
PyPy Status Blog: Transactional Memory (II)
A summary of what transactional memory (especially software transactional memory) is and why Armin Rigo thinks it might be really, REALLY good for Python. Nothing here that was new to me, but the simple, clear explanation is quite good.
via:HackerNews  ArminRigo  PyPy  concurrency  concurrentprogramming  parallelprogramming  stm  programming 
january 2012 by mcherm
The problem with STM: your languages still suck
Software Transactional Memory (STM) doesn't play well with anything imperative or mutable. It's a natural for Haskell but every other programming language is in trouble. And it might be the only way to sanely use ever-increasing numbers of cores.
programming  functional  concurrency  haskell  stm  via:reddit  BrianHurt  threading  concurrentprogramming  parallelprogramming  softwaretransactionalmemory 
august 2011 by mcherm
A concurrent programming architecture that runs it all on one CPU
They needed to handle 6 million transactions/second. Managing queues took most of their time. So they re-architected so that separate threads managed input and output but the core computation was all on a single thread. They also ensured only one thread writing to any given memory scan line. Resulting architecture was unusual and successful.
via:MartinFowler  MartinFowler  concurrentprogramming  parallelprogramming  concurrency  programming  architecture 
august 2011 by mcherm
TameJS from the creators of OkCupid
An incredibly simple and powerful library for building code with asynchronous callbacks, from the guys at OKCupid.
via:HackerNews  javascript  library  programming  asynchronous  concurrentprogramming  parallelprogramming  OkCupid  languagedesign 
july 2011 by mcherm
Paul Tyma: Writing Java Multithreaded Servers - whats old is new (PDF Slides)
nio may actually performed WORSE than thread-per-connection in modern JVMs with good data structures.
java  programming  threading  concurrency  scalability  via:HackerNews  io  parallelprogramming  architecture 
april 2011 by mcherm
Dabeaz: Python Thread Deadlock Avoidance
A with clause ("Context Manager") in Python to ensure that locks are obtained in a strict global order. Really a rather cool feature -- shows off the power of the with clause and also might prove useful as long as your python program doesn't grab any locks from within C code.
programming  python  concurrency  concurrentprogramming  parallelprogramming  via:reddit 
january 2011 by mcherm
Is Transactional Programming Actually Easier? | Lambda the Ultimate
A study compared software transactional programming with locks using 150 undergraduate students. STM did extremely well in objective measurements.
concurrency  stm  parallelprogramming 
september 2010 by mcherm
A Dismal Guide to Concurrency | Facebook
A nice overview of the state of concurrent programming: what the big problems are.
parallelprogramming  concurrentprogramming  programming  threading  concurrency  via:HackerNews 
april 2010 by mcherm
Node.js is genuinely exciting
A web application framework in server-side javascript. What I find most interesting is that the language and libraries are all tuned for writing an an event-driven style rather than a threaded style -- even things like file IO are done via callbacks.
programming  via:SimonWillison  SimonWillison  scalability  concurrency  parallelprogramming  eventdriven  asynchronous 
november 2009 by mcherm
Programming and politics: Concurrency Patterns: Java, Scala, and Clojure
One person's comparison of locking, STM, and actors as mechanisms for coordinating concurrent programming.
concurrency  java  scala  programming  parallelprogramming  concurrentprogramming  clojure  stm  computerscience  via:HackerNews 
october 2009 by mcherm
The Transactional Memory / Garbage Collection Analogy: Dan Grossman
In this academic paper, the author presents and defends an extensive analogy between garbage collection as a solution for memory allocation and Software Transactional Memory as a solution for concurrent programming.
programming  stm  concurrency  concurrentprogramming  garbagecollection  parallelprogramming  research  computerscience 
october 2009 by mcherm
EVE Evolved: EVE Online's server model - Massively
The game EVE Online does not use "sharding" all the players are in a single shared world. This article discusses how that is implemented and also what affects it has had on the game play (fairly significant effects, it appears).
via:slashdot  mmorpg  gamedev  programing  concurrency  parallelprogramming  eveonline  scalability  socialcomputing 
october 2009 by mcherm
Swarm: Distributed Computation in the Cloud on Vimeo
Video presentation describing "Swarm", a new project for a language that tries to implement cloud computing by moving the computation to where the data is. Relies on the (not yet released) version of Scala which provides continuations that can be saved and/or moved to a different machine before being resumed. They do that by rewriting the program for continuations instead of trying to save the contents of the stack. Interesting.
swarm  programming  scala  scalability  continuations  stm  parallelprogramming  concurrency 
october 2009 by mcherm
Swarm: A true distributed programming language - Blog -
An interesting idea in concurrent programming. Instead of moving the data to the computation, move the computation to the data. He built a working prototype.
concurrency  parallelprogramming  scala  swarm  via:slashdot 
october 2009 by mcherm
1024 by 2012! | Enfranchised Mind
Some technical reasons why VERY multithreaded programs are going to be a key feature of the future of computing.
hardware  parallelprogramming  concurrentprogramming 
september 2009 by mcherm
Responses to The Problem with STM | Enfranchised Mind
Interesting observation: pure immutable data structures tend not to be compatible with concurrent programming, because sharing between threads would require a mutable current-state-of-the-structure variable.
programming  immutable  concurrency  parallelprogramming  via:BrianHurt  BrianHurt  softwaretransactionalmemory 
may 2009 by mcherm
The "C is Efficient" Language Fallacy : Good Math, Bad Math
People often say "C is fast" because "C is close to the machine". But it's not true. C is close to how machines used to work long ago. Today, they have caching, pipelining and lots of other tricks. Often C is primitive enough that the compiler doesn't dare be "smart" (because of things like "aliasing" -- do these 2 pointers point to the same memory?). Mark Chu-Carroll tried several different languages (well optimized) on a real-world problem and found OCaml to be fastest!
optimization  programming  parallelprogramming  languages  compiler  via:reddit  markcc  ocaml 
may 2009 by mcherm
The problem with STM: your languages still suck » Enfranchised Mind
Software Transactional Memory works GREAT in Haskell, but it's just never going to work in Java, C, and such because they are too full of side effects -- it's just not a good match for the behavior of STM. STM is the best of possible solutions to concurrent programming (I don't think I agree with that!), so programming languages will have to change.
concu  concurrency  concurrentprogramming  languagedesign  haskell  functional  stm  softwaretransactionalmemory  progra  programming  parallelprogramming  BrianHurt 
january 2009 by mcherm
Software transactional memory
A report by some researchers at IBM who have spent the past two years building a software Transactional Memory system. They say the performance sucks and there's little hope for improvement. Perhaps some hardware support will help, but frankly they are VERY pessimistic -- and that's from people who believe enough to spend 2 years actually building it!
programming  research  softwaretransactionalmemory  via:LarryOBrien  concurrency  concurrentprogramming  parallelprogramming 
november 2008 by mcherm
Windows & .NET Watch: Transaction crowd gets a boost - SD Times On The Web
Prediction: Software Transactional Memory (STM) is taking over, and it will eventually replace threading as the preeminent mechanism for concurrent programming.
LarryOBrien  via:LarryOBrien  programming  concurrency  concurrentprogramming  parallelprogramming  threading  softwaretransactionalmemory 
november 2008 by mcherm
Software Transactional Memory in Scala - Code Commit
An implementation of software transactional memory for Scala. Demonstrates the power of scala's implicit parameters, and goes into great detail about the particulars of this technique for concurrency.
programming  concurrency  concurrentprogramming  parallelprogramming  softwaretransactionalmemory  scala  via:DanielSpiewak  DanielSpiewak  implicit 
november 2008 by mcherm
Java theory and practice: Managing volatility
Brief description of "volitile" in Java. Includes some quite useful patterns of safe use for volitile.
java  concurrency  parallelprogramming  threading  patterns  programming 
october 2008 by mcherm
Cool Threads | I, Cringely . The Pulpit .
Cringely talks about threading. As usual, he doesn't *really* get it, but he presents it well anyhow. Curiously, he uses an example of optimistic concurrency where an ATM machine is accepting a deposit and has to spit the money back out. In the obvious withdrawal scenario, it can't suck the money back in!
cringely  concurrency  threading  parallelprogramming  optimisticconcurrency 
october 2008 by mcherm
Threadsafe Java Servlets - a solution : Dragons in the Algorithm
Description of an approach to storing data in a web application session without incurring threading problems.
myblog  mypostings  threading  parallelprogramming  java  webdevelopment  webdev 
october 2008 by mcherm
Higher-Order Fork/Join Operators
Tricky stuff... using monads to combine low-level parallelizable tasks into bigger parallelizable tasks. I didn't fully understand it.
scala  concurrency  threading  parallelprogramming  DanielSpiewak  via:DanielSpiewak 
september 2008 by mcherm
Scaling Out | Engineering @ Facebook's Notes
When Facebook wanted a second data center with its own DB, how did they need to change their application? (1) make one DB read-only and replacate from the main datacenter; modify MySQL to clear memcache on replication. (isn't open source cool?) (2) all pages doing edits go to main data center. For the first few seconds after a user makes a change, send that user to main data center as the other may still have the old value.
scalability  JasonSobel  memcache  opensource  mysql  mypostings  concurrency  parallelprogramming  via:DebasishGhosh  programming 
august 2008 by mcherm
InfoQ: JavaOne: Cliff Click on a Scalable Non-Blocking Coding Style
Article talks about a data structure implementation that's tweaked to work well with large numbers (hundreds) of processors.
parallelprogramming  java  datastructures  concurrency  via:digg 
may 2008 by mcherm
Minimizing Code Paths in Asychronous Code | Oliver Steele
"The general principle here is if a function sometimes has to call its callback asynchronously, always call it asynchronously, to minimize the number of possible code paths through the application."
programming  javascript  ajax  threading  parallelprogramming 
april 2008 by mcherm
Software Secret Weapons: Doug Lea is a Grandfather of all Scala Actors
Pavel Simakov looks at Scala's actors library (message passing) and asks how it works and whether it could be done in Java. The answer is (of course) "yes, but more verbosely".
scala  java  programming  threading  parallelprogramming  DougLea  concurrency 
april 2008 by mcherm
Paul Stovell says… » Locking Rule #71
We know locks should be obtained in a consistent order to avoid simple deadlock. But if you're calling into library code you don't own it might obtain the locks out of order. So never call code you don't own while holding a lock you don't own.
programming  threading  parallelprogramming  mypostings 
april 2008 by mcherm
Code Smart: Pod Racing: How to synchronize threads across multiple JVMs
Tools exist to synchronize threads withing the same JVM, but what if the threads live in multiple JVMs? Terracotta is a "network attached memory" tool that supports everything (including synchronization) in "memory" across the internet.
java  terracotta  programming  parallelprogramming  threading 
march 2008 by mcherm
Erlang-style concurrency - comp.lang.functional | Google Groups
A rather insightful summary of what the key features are of Erlang's approach to parallel programming.
programming  languagedesign  erlang  parallelprogramming  threading 
february 2008 by mcherm
the.codist{} - Writing Multithreaded Code Is Like Juggling Chainsaws
Watch out: avoiding deadlocks isn't *too* difficult, and protecting shared data can be done if you're careful, but threaded programmers still need to worry about making sure that all the threads are busy rather than all waiting for something.
threading  java  programming  parallelprogramming 
february 2008 by mcherm
Good Math, Bad Math : Databases are hammers; MapReduce is a screwdriver.
Some thoughts on why the map-reduce tool is not the same as a relational database.
mapreduce  parallelprogramming  programming 
january 2008 by mcherm
Diploma Thesis: An Object-Oriented Programming Model for Event-Based Actors
The thesis which lead to the creation of Scala's Actor model, a useful approach to parallel programming which can run on the JVM but is NOT the same as the threading model.
programming  scala  articles/programming  parallelprogramming  threading 
january 2008 by mcherm
SD Times - Larry O’Brien: Talkin’ Concurrency
Some thoughts on parallel programming. Says that the threads & locks paradigm is fundamentally broken (I agree) and points out several alternatives: message passing (nothing shared), STM (optimistic concurrency for RAM), and functional programming.
programming  parallelprogramming  LarryOBrien 
december 2007 by mcherm
The Byzantine Generals Problem at Mark Nelson
A useful explanation of the solution to the Byzantine Generals problem (agreement among not-necessarily-trustworthy participants in a decision).
programming  computerscience  algorithm  parallelprogramming  algorithms  threading 
september 2007 by mcherm
C# From a Java Developer's Perspective
A comparison between C# and Java by someone who should know.
parallelprogramming  c#  java  languages 
may 2007 by mcherm

Copy this bookmark:

to read