Archive for June, 2010

Debunking the 100X GPU vs. CPU Myth: an Intel Paper

Monday, June 28th, 2010

Download and read the intel paper about debunking the myth of GPU being 100X faster than CPU on some tasks.

This paper is interesting, there are flaw in it, but I truly think the whole part is honest, and this honesty goes up to the point where Intel is saying that nVidia GPU are 14X faster than Intel’s CPU at best, and average 2.5X faster. I think that depending on the selected set of tasks, it might be true or a little conservative. Anyway Intel honestly said that their CPU are lagging far behind GPU.

They compared a $600 CPU and a $300 GPU, and the GPU was 2.5X faster average. Depending if money or performance interest you, you could consider different conclusions…

Upgrade to an old PC

To upgrade an old PCI-Express PC, you could add a $100-$120 graphic card, to obtain performance-level of a brand-new Core i7 960 PC. Core i7 960 needs new socket so an old PC won’t be compatible, you will have to spend $1000 for it (or more!). Given you resell your old PC for $300, Intel CPU are juste 6X-7X more expensive…

High-Performance PC

You may prefer to invest on a high-performance computer, because you need it, so you could choose for example a Mac Pro with 8-core 2.93Ghz (2 quad-core Nehalem CPU), that is 1.8X faster than the Core i7 960 in pure computing, for a tag price of $5899. Or for the same average computation power, take a $500 desktop and add it a $200 GeForce GTX260, $700 investment total. 8.4X more expensive on Intel CPU.

Desktop Supercomputing

Or maybe compare a high-performance 8-core PC/Mac with what this money could give you in term of performance for the $5899 tag price, giving you are buying a basic Mac Pro 4×2.66 Ghz $2499 and upgrade it with $3400 worth of GPU and second power… $1000 for a superb 1000W power, and 3xGeForce GTX 480 (each one at least 1.5X faster than GTX 285), PCI-Express expander.

On my left 8×2.93 Intel CPU power, at my right 3xGeForce GTX 480, for the same budget, on high-end computing, you will get 5X to 6X more performance average, and sometimes 20X to 30X if your task is GPU-oriented. Ouch!

Conclusions

If you want to upgrade an old PC to double it’s computing power or more on CUDA-enabled tasks, consider buying a new high-end PC/Mac, or want to have the fastest desktop supercomputer, wether it’s performance/price that drives you or performance-level, in any case there’s no competition to GPU.

Intel isn’t competing anymore in high-end supercomputing when we are talking about tasks that GPU handle correctly and are massively scalable. Whatever your metric is, nVidia GPUs are far better.

Danke sehr Herr Srdja

Sunday, June 20th, 2010

I am in communication with a german student that is working on OpenCL implementation of chess engine (read he’s blog about Chess on OpenCL), and it’s truly interesting in many ways.

We are not following the same path, we are of 2 different generation, with different backgrounds, on similar (or derived) technologies, with the same goal: writing a chess-engine. And sharing ideas, exchanging documents with him make my mind being much more creative, as I solved indirectly my move generation problem, and even the memory contention that I had, and branch divergence at once.

Seems incredible, but exchanging ideas with people trying to solve the same problem not only enrich you directly, but also give you the ability to mix them and finally come with surprising things! Thanks :-)

I also posted a ZIP containing a list of open-source chess engine that inspired me, as well as PDF documentation and interview about chess computing, and the people that made it possible.

It was originally for Srdja, but I think that the time I took to find them might be really useful for anyone interested in chess computing. Will probably update it regularly to include more documents and code.

Sargon source-code & 1KB Chess source-code & Shannon article

Saturday, June 19th, 2010

I found 2 resources on the web, Sargon I full source-code for Z80 (the book content in fact), and Sinclair ZX81 1KB chess source-code (Z80 too).

Naturally Sargon is impressive, but having a chess program fully running (even if primitive) on 1KB RAM (code+data) is hot! It’s not a good chess program and will only challenge beginners, true beginners, but still it plays chess!

PS: The original article from Claude Shannon “Programming a Computer for Playing Chess” in PDF in Philosophical Magazine. A must-read, probably before everything else, or maybe competing with Turing article on Chess!

Datapoint 2200 : the common ancestor!

Thursday, June 17th, 2010

I wrote a post on my hackintosh blog about Datapoint 2200: the ancestor of all our modern computer in so many ways…

blog-datapoint2200

The funny thing is that this 1971 “terminal”, with hundreds TTL modules that support Intel 8008 instruction-set and up to 8KB RAM on original model, could have run the Sargon chess program (adapted), in 1971! Datapoint 2200 on Wikipedia

Sargon Book by Dan & Kathe Spracklen

Thursday, June 17th, 2010

I read many many things these days, including interviews of Dan Spracklen & Kathe Spracklen. They have written computer chess history since their first tournament in 1978, that they unexpectedly win, they share many world champion prices, and they owe it. Sargon was their first and mainstream program for years, on Z80, 6502, 68000.

blog-sargon-book

Today I receive the “Sargon book”, by Hayden editor, that contain full source-code of Sargon, fully annotated, for Zilog Z80 CPU (a faster clone of Intel 8080 that was cloned itself many times, for example the NSC 800 a buggy version on the Canon x-07 hand-held computer). This book needs to be read, annotated, by anyone willing to make an efficient chess program. I saw some code that might be rewritten to be faster (ie mul 8bx8b that loop 8 times even if multiplier has no more set bit after right rotation, and code should have been unrolled), but honestly it’s a masterpiece!

They even ended-up beating a 6 million dollar Amdahl mainframe with a personal computer that cost thousands less!

On my collection I have the Fidelity Electronics Chess Challenger Excel Mach III Excel (first USCF Master rated electronic chess computer!) with their program on it. It plays a beautiful chess, that is solid and elegant (for a 1987 program!) with a 2079 ELO rating.

The most surprising, given their incredible achievement, is their humility. Thanks for your incredible work on chess computing! An interview of Dan & Kathe Spracklen you have to read here (PDF)

PS: Full source-code in Z80 assembly language of Sargon chess program here. Enjoy, and appreciate the comment they put, some young programmers might take a lesson or two!