Tag Archives: parallel architecture

State Change

A couple of weeks ago I started ‘preparatory drawings’ for a great work of the blogging art about application portability. That was hard. This is a quick caricature of the resultant pile of half-sorted words.

I decided to learn to code in Python, having dismissed several other options; including Java, Ruby, HTML5 and JavaScript. I’d even considered having another go at Lisp but dismissed that as impractical. Surprisingly, I didn’t consider Perl, for my laziness http://c2.com/cgi/wiki?LazinessImpatienceHubris.

Since I went to that Clojure talk I’ve referred to before, I can’t shake the feeling that there was something about immutability that I shouldn’t ignore. Conventionally, I’d replace the assignment of ‘Python’ to the variable LanguageToLearnNext with the new value ‘Clojure’. There would be no trace of the fact that the language I WAS going to learn next was Python – but I’ve written about it several times and now I’ve broken the links. If this was code, that would be a problem.

Variables have no time dimension. Neither does the relational model. Michael ‘JSP/JSD’ Jackson told me that. At around the same time, there was a buzz around parallel architectures and programming. There is again now, if you talk to people who are ahead of the game. They call it concurrency now. Physics has caught up, overtaken the hardware engineer’s RISC wizardry and erected its road-blocks again. We don’t know how to make our processes go faster; so there need to be more of them spinning. We live in a word of multi-core processors.

Clojure is immutable by default, which prevents concurrency scrambling coders’ brains. In Clojure, there is still yesterday’s LanguageToLearnNext and now there is a LanguageToLearnNext for today. Variables are so last century.

See: http://clojure.org/state if you want this explained properly.