Fri, 28 May 2010
Dell has entered the League of Evil Empires at Number 7. Dell claim to want to sell you a new computer
where you choose whether to have Ubuntu or Windows installed as the operating system. However, they
refuse to offer for sale any computers running Ubuntu, they all run Windows. This is Evil.
In the completely and totally unsurprising section, Apple retain their Number 1 position. They used to
offer GNU Go to iPhone users in violation of the GPL, but instead of complying with the GPL, they removed
the software. Apple only allow you to run software they approve of and for which you pay them, their
licence is very restrictive and designed to create and maintain a monopoly over what you can do with
equipment you supposedly own. This is Very Evil.
If you are a C++ programmer and you do anything with threads in C++ then you really need just::thread, it
is a good implementation of the C++0x standard. Version 1.4.0 just came out as noted
at http://www.stdthread.co.uk/.
Shared memory multi-threading is anathema, futures are the future.
Having finally got libboost-mpi-dev and the version specific packages into Debian and thence
Ubuntu, it seems the Ubuntu management have decided it's far too much trouble and have now removed all
Boost.MPI packages from Ubuntu, cf. the notification
and proof
it's not in Maverick. Debian are going the other way and providing backports of Boost.MPI so all
versions of Debian support it,
cf. proof
it's in all version in one form or another.
The conclusion is clearly that whilst Debian are supporting all tools associated with multicore systems
and HPC programming, the Ubuntu management have decided that C++ and MPI are an irrelevance to the future
of Ubuntu.
Conclusion will be drawn. Mostly with the blue pencil of censorship.
If you care about having Boost.MPI in Ubuntu please visit this
bug report and add your comment/support.
Sat, 22 May 2010
Wiley got
someone to translate Developing Java Software by myself
and Graham Roberts into Simplified Chinese. I
haven't a clue how good the result is as I do not read Chinese. If anyone can give me a comparison
between the English original and the Chinese translation, I'd be very interested.
Given the fact that the world is partitioned by language, enforcing one script as the only script for URLs
is a form of cultural imperialism. So it seems a natural evolution of the Internet that non-English URLs
should be allowed. However this means the Internet is now being partitioned in a way that allows greater
state control and censorship – even more than there is already.
The story of the Tower of Babel, which appears in one guise or another in many ancient books, relates how
there used to be one language and that everyone could communicate with each other, but that hubris and
vanity led, indirectly, to the breaking up of society into tribes each using their own language.
It may not be vanity or hubris that is leading, directly or indirectly, to the partitioning of the
Internet, but breaking up it certainly is doing. One just hopes that this isn't going to lead to
ghettoization.
The Internet had been a tool for allowing one language, English, to become the lingua franca (and
there is indeed irony in that phrase), to create a single world of communication. It is a pity that some
tribes in the world saw this as imposition rather than opportunity. Maybe hubris and vanity are involved
after all. More likely though it is power and politics. Sad.
Wed, 19 May 2010
GPars is a framework of concurrency and parallelism constructs
for Groovy programmers. GPars provides actors, CSP and dataflow
constructs. Underlying GPars are the JSR166 libraries and JCSP, so the foundations are good and solid.
GPars gives using these concurrency and parallelism tools a Groovily idiomatic feel.
So HTC has signed a deal paying Microsoft royalties for HTCs use of Android in their smartphones.
Microsoft are of course marketing this is part of their “Linux violates patents held by
Microsoft” campaign. The question is Why has HTC really succumbed to this patent bullying
tactic?
Microsoft of course claim this is because they have proved to HTC that their patent claims are real and
genuine. Clearly this is just not the case, otherwise Microsoft would be chasing the really big Linux
users. I guess that Microsoft have said to HTC that if HTC didn't pay up over Android then HTC would not be
allowed to use Windows Mobile. But then does Windows Mobile matter any more in the smartphone market?
Perhaps then Microsoft are playing a “long game”: by obtaining lots of smaller organizations
actually paying royalties, they build up a snowball of opinion that the patent violation is real. This
way they create a perception of truth of their claim without ever having to prove their case in court.
Perhaps then the question is: Are Microsoft channeling funds back to HTC in some way to pay them back
for participating in this long game patent scam?
Thu, 13 May 2010
30+ years ago Tony Hoare and colleagues developed CSP, a mathematically sound model of how to structure
software so as to deal as safely as possible with concurrency. Parallelism wasn't such an issue then as
it is now, post the beginning of the Multicore Revolution; at the time of development of CSP very few
computers offered applications more than one processor.
Now as we enter a period of massive change in computer hardware structures (uniprocessor architectures are
giving way to multiprocessor architectures), it is becoming increasingly clear that shared-memory
multi-threading cannot be the software architecture of future applications. The need to correctly manage
locks, mutexes and monitors, as is required in shared-memory multi-threading, is just too complicated to
get right.
Erlang has been the major proponent of using lightweight processes and
message passing over the last 25+ years. It's successes in the telecoms industry have generally been ignored
by the wider computing industry as it rushed headlong into the quagmire that is shared-memory multi-threading.
Joe Armstrong has noted in the past that although Erlang does not directly realize the Actor Model or CSP they
were very strong inspirations in the development of the language.
The HPC (high performance computing) community have been working with parallel systems since almost the
beginning of computing. Many models have been tried over the years, but the current winner is a
combination of SPMD (single program multiple data) architecture with annotations to handle local thread
management: MPI and OpenMP are the tools of handling parallelism with C, C++ and Fortran the programming
languages of choice. No Actor Model, and certainly no CSP. Given the unwillingness of the HPC community
to rewrite any of the codes they have developed over the last 40+ years, it seems likely that the
traditional HPC community will become an increasingly irrelevant backwater of computing innovation.
On the Go (the programming language being developed by Google) programming
language users mailing list, Rob 'Commander' Pike reminded us in one thread that although
the goroutine concept in Go appears to have some inspiration from CSP, most of the ideas were
developed independently during the development of the Squeak, Newsqueak, Alef and Limbo programming
languages. He also pointed out that occam and Erlang were separate developments with there being no
interchange of ideas.
Parallel and independent emergence of essentially the same idea is a strong indicator that some version of
that idea is a great innovation. This has been shown many times in many different fields of human
endeavour.
In the data mining arena, there is increasing dissatisfaction with SQL-based approaches; they are too slow
to be useful. Employing a dataflow software architecture (an event-based approach based on lightweight
independent operators, which is basically a subset of CSP), there is a revolution in the approach to data
mining. SQL-based approaches gain no benefit from parallel processors, dataflow approaches gain huge
benefit, and are now massively outperforming SQL-based approaches.
Thus it seems there is an "emergent property" appearing to come form all this: independent lightweight
processes with no shared state is a good model of applications programming in a world increasingly
dominated by parallel computers. Actor Model, dataflow and CSP are, increasingly, the future for
software. The JVM world is heading that way, Scala has Actor
Model, GPars provides Actor Model, dataflow and CSP to Groovy and
Java programmers. Even the Python world is heading that way,
cf. Python-CSP.
CSP is not a silver bullet, there are
none in computing, but it is likely one of the best ways forward for structuring software in the post
Multicore Revolution, massively parallel world of applications development.
Wed, 12 May 2010
Two weeks ago the Cons and the LibDems were at each others throats, trying to convince the voters how
appalling and evil the other was, and that the Labs were worse. As of yesterday, the Cons and the LibDems
are the best of friends, indeed they are fawning over each other. Fawning is ugly at the best of time but
this definitely appears as though they are mocking the voters.
Given that the Cons and the LibDems supposedly agree on very little and disagree on so much – well
at least that is what they told the voters two weeks ago – it is fairly difficult to see what there
is that can form the core of the programme for this government.
Clearly a politicians need to be in power overrides any thought of principles and policies.
I suspect the coming Queen's Speech will be entertaining.
Tue, 11 May 2010
So Gordon Brown has resigned (as Prime Minister and leader of the Labour party) and the Queen has invited
David Cameron to be Prime Minister. The Conservatives (Con) have declared a full coalition with the
Liberal Democrats (Lib Dem) – whatever that means in reality. The question is whether the Lib Dems
are stringing the Cons along or whether the Cons are stringing the Lib Dems along. What is truly certain
is that the political, ethical and moral differences between them are far more than the similarities. A
very strange collaboration. So who is more desperate for power, David Cameron or Nick Clegg?
I suspect the telling point is that the Conservative party has enough money to fight another general
election, but the other parties do not. What odds on a second election in 2010 with the Conservative
party going for an overall majority so as to drop the Lib Dems?
What we can predict is that all the politicians will be ensuring they get money in their and their friends
pockets. The voters will lose. Whatever politicians say in public, you know they are not averse to
lying. Blatantly.
Sat, 08 May 2010
The Conservatives threatened the markets with panic if there was a hung parliament, there is a hung
parliament, and the markets did a bit of panicking. Is this behaviour built into the system, or are
traders a bunch of lemmings easily fooled by FUD? Rhetorical question.
We have a hung parliament for the first time in 34 years. Now we see politicians negotiating with each
other in a desperate scramble for power. Fairly ugly in itself. Interestingly though, if the UK moves to
proportional representation, we will see this sort of “horse trading” after every
election. The “first past the post” system has its benefits as well as its clear unfairnesses
compared to proportional representation. I wonder if there will be proper debate about this, or whether
the political classes will just impose the solution that is best for the political classes on the
electorate. Do the political classes just see the electorate as sheep to be herded? Not a rhetorical
question.
Thu, 06 May 2010
Many moons ago (about 1996), Web browsers included Java to provide client-side computation capability
– applets became all the rage. Sadly most computers weren't really powerful enough at that time to
properly support applets that weren't just trivial, and so client-side Java died off to be replaced by
JavaScript (aka ECMAScript or whatever it is called this year). Actually client-side computation became
unfashionable and seen as a “bad thing”. Everything moved to being server-side, generally to
the detriment of good human–computer interaction (HCI) in the Web browser.
Fashions change. Now it is cool to do things client-side: AJAX, etc. mean that client-side is now
considered a “good thing” – actually this could be good for quality HCI in browser-based
application, sadly it rarely is as the developers all too often have no idea about HCI and what makes a
good user interface.
Now there are rumours that people who like Mono are saying that CLI should be included in all browsers.
Apart from all the software patent issues because Microsoft own patents in CLI, is this just Mono folk
being shills for Microsoft trying to get .NET as the standard for all Internet-based activity?
History tells us that the JVM (of which CLI is a rip-off) can already be used client-side in browsers, so
why not just return to using Java applets? Computers are now vastly more powerful than they were when
applets stopped being all the rage. Perhaps if they were tried again, they could become all the rage
again.
So today is a general election in the UK. The only real outcome of this is that later tonight one tribe
of people will be drinking a lot and smiling, and all the other tribes of people will be drinking a lot and
frowning. The outcome for tomorrow will be just another bunch of politicians trying to tell us what we can
and cannot do, whilst lining their own pockets by redirecting money we pay in tax into their own personal
bank accounts.
If one party gets in the very rich will be happy and will set about putting more money in their pockets
at the expense of everyone else. The rest of use will be shafted. If any other party gets in then the
spongers on society will be happy as they will set about putting more money in their pockets
at the expense of everyone else. The rest of use will be shafted.
So if you are in the middle, i.e. the vast majority of people in this country, then prepare to be shafted
as of tomorrow morning.
Depressing, but sadly too true.
Sat, 01 May 2010
Recently I have been taking a look at the Go programming language. I find
it very interesting and feel it could have a great future. As with anything new though, people are
studying it without appreciating the history that leads up to it. In one particular case, you get
comments along the lines of: “their concept of Go routines and Channels, and I wanted to see if this
really was a new paradigm for multi-threaded, multi-tasking programming.”
(from http://gohelp.wordpress.com/). The answer is clearly
“No” since the Go paradigm for handling concurrency and parallelism (goroutines and channels)
is based fairly and squarely on CSP (Communicating Sequential Processes) which Tony Hoare and
collaborators invented and about which he published a book in 1984. The Go documentation clearly points
out this historical background to the goroutine concept. The problem is that people are either not
reading it, or are choosing to ignore it. Fortunately the developers of Go are less dismissive of
history. Possibly because some of the team were involved in making it 30+ years ago.
“Standing on the shoulders of giants&rdquo is a well used phrase to describe moving things forward
by using the great work that people have done in the past. The Go development team are doing this. It is
a pity that too many people are not realizing this, because they have failed to appreciate the history of
their subject.