Erlang and IBM Power8 in the cloud: super-high single-system parallelism
erlang.org
erlang.org
Otherwise the x86 comes out looking a lot better -- lower 95th percentile, lower max, lower average.
(Modulo usual complaints about benchmark porn: single run, lack of standard deviation, unknown configuration differences etc etc).
* 4x hardware threads per core (8-way SMT vs. 2)
* 1/4th FP throughput per core (8 SP flops/cycle vs. 32)
* 3x bandwidth to RAM (230 GB/s vs. 68) [edit: updated for Haswell-EP]
https://en.wikipedia.org/wiki/POWER8#Specifications
http://www.redbooks.ibm.com/abstracts/tips1153.html
What is it good for?
Running very demanding single-system software. It's the sort of box you'd install DB2 or Oracle on, especially if you've already tied your business to IBM solutions in the past.
Haswell-EP supports 4 DDR4-2133 channels, or 68 GB/s (theoretical). TDP on POWER8 is almost double and it's much more expensive, so we should think about it as having perhaps double the DRAM bandwidth (still excellent).
Note that POWER8 gets this bandwidth through many more channels, which favors the use of many memory streams. This has been the case historically, with POWER favoring data structures that result in many streams, while the same transformation has been catastrophic for memory performance on Blue Gene's PPC, with its limited prefetch engine and small number of outstanding memory requests.
The problem I see with power is it has a different endiannes and even though compilers know how to handle it, a lot of libraries and code might just assume some specific ordering (little endian) and thus fail un-expectedly on POWER.
Well, heck, that's great then.
(It's been a long time since I last typed "PowerPC", gave me a strange feeling of nostalgia...)
edit: Straight from IBM https://www.ibm.com/developerworks/community/blogs/fe313521-...
Googling "DFP instructions" led me to nothing but DoubleClick links.
Java, however, is a special case. Since Java bytecode does not have a BigDecimal type, there's no way to update the JVM to take advantages of this hardware unfortunately.
Of course, even if that is true, it is a different architecture. But still, if they made the change on one architecture, it would be silly not to make it on the other one as well.
Unless that was intentional to keep some sort of advantage for zSeries.
http://www.ibm.com/developerworks/rational/cafe/docBodyAttac...
If higher level languages implemented in C/C++ implement their decimal support using the built-in C/C++ types, they'll get the speed boost.
Going only by specs, it seems that in many other cases each Power8 core has about 2-4x the resources of a Haswell core:
64KB vs 32KB L1D
512KB vs 64KB L2
8MB vs 2.5MB L3
16 vs 10(?) outstanding L1 requests
8 vs 4 instructions issued per cycle
2 vs 1 stores per cycle (or 4 vs 2 loads if no stores)
3 vs 4/5 cycle L1 latency for 64-bit data
5 vs 6/7 cycle L1 latency for vector data
2048 vs 512 TLB entries (integrated with huge pages)
Specs that aren't higher than Haswell are usually the same --- skimming, I haven't found any that are lower. This makes me think that a 4xSMT or 8xSMT Power8 core will probably be about equivalent to a 2xSMT (hyperthreaded) Haswell core. Dedicated core operation (non-hyperthreaded) will vary more based on workload, but likely be 1x to 2x in favor of Power8.
But these are guesses based on written specs -- I'm eager to see more real benchmarks.e.g. Snabb Switch 20x10GbE on x86 https://lukego.github.io/blog/2013/06/23/echoing-packets-wit...
I've also seen some stuff on Power8 networking but it's not public.
By my experience with Power7, the price/performance ratio is much lower on Power then Intel systems. Maybe it changed but i'm not holding my breath, even if IBM seems much more aggressive on pricing with P8 then they were with P5-P7. The
Quick calculation, absolutely unscientific:
Seeing that the price is 0.14$/hour for the 6-core xeon and 1.08$/hour on the 176 core P8, it would have to be roughly 8-10x faster to justify the cost difference, not sure it will be the case.
RDBMSes are a classic example. Some kinds of compute-heavy problems too -- simulations with lots of coupled components, video compression etc.
That said, for a lot of interesting use cases, like that king-hell postgres database sitting in the middle of the swarm, or video processing, or streams processing, or indeed any situation in which thousands-to-millions of simultaneous actors need to work on the same shared state, this sort of system starts looking real interesting.
As a thought experiment, think of this system like a GPU, except every single processor is a fully capable 2 GHz i5 running Unix, and instead of having to deal with the CUDA or OpenCL API, you can just write erlang (or haskell; .. or whatever) code and it will run. And instead of having 2-8G of RAM, you have 48G. And instead of having arcane debug tools, you have recon and gdb and ddd.
I don't think there is a pendulum, I think there's a spectrum and has always been one; pragmatism should always rule, and your use case is not my use case. There isn't going to be an objective winner ever, no matter how close Intel may get to covering much of the sweet spot.
As long as order of evaluation does not matter (for a pure-functional code) some [major] parts of a program could be evaluated in parallel by runtime without any changes in the code (especially when a high-order function composition - map/filter/reduce/etc is the primary pattern). So, Haskell, for example, will do it too.
The big difference between Erlang and Haskell is that Erlang fundamentally encourages the programmer to think in terms of individual processes that communicate by message-passing. Programmers have also been taught that spawning processes is cheap so idiomatic Erlang code typically have tons of them.
The green threads in Haskell are just as cheap, in some cases, cheaper than Erlang's processes. Haskell programmers are similarly encouraged.
Concurrency and parallelism are pretty easy in Haskell.
You're going to see what Erlang did atomized, implemented piecemeal, and reconstructed. Cloud Haskell burnt too much goodwill in pursuit of a mostly pointless feature.
That's how we ended up with slave-thread…the beginnings of supervisor trees.
Haskellers would rather pick and choose. It's worked well so far.
In theory, we could re-write almost any part of OTP in Haskell, in practice, however, "runtime is hard" and the biggest selling point of Erlang is that its runtime and standard library (OTP) has been evolved for almost 20 years and is based on the same principles of a functional language (except, perhaps lazyness by default) as Haskell.
In other words, while Haskell is a "playground for researches of type theory in context of programming languages and compilers" Erlang/OT is a "telecom industry-standard toolkit".
A close analogy, in my opinion, could be the pair of Scheme/Racket and CL. The first was mostly an academic teaching and research tool, while second is a pragmatic (but unfortunately bloated) tool-set.
By "will do it" you mean "would, in theory, support a compiler that parallelized significant amounts of idiomatic code with no source changes"? Maybe. I don't think any existing Haskell compiler does that, though.
Of course, you could theoretically just write an actor library that did the exact same thing as erlang.