IDF 2009 Larrabee demo

Intel showed their new Larrabee GPU publicly for the first time at their annual developer conference. They showed Larrabee running a ray tracer that was rendering QuakeWars geometry. The enthusiast scene (e.g. beyond3d) was not impressed by this demo, because, frankly, it wasn’t very impressive at an emotional level. The scene was static, no people in it, just waves and a few very small helicopters. It’s strange that they didn’t even move the camera, which is something that a ray tracing engine should easily be able to to. The camera angle they chose was effective for showing dynamic reflections, but keeping the camera locked down meant a much less interesting demo. For the same amount of effort they could have come up with a much more visually and emotionally interesting demo. For example, a cascade of brightly colored chrome balls tumbling down a staircase, which would show off both physics and ray tracing. That they didn’t use this early opportunity to sell Larrabee indicates that they don’t know how to market add-on GPUs to consumers. Which makes sense, since it has been many years since they’ve needed to do this. Their current demos are all targeted to (a) test out Larrabee features, and (b) educate developers as to the potential strengths of Larrabee. They are similar to Microsoft DirectX samples. But I think Intal also needs to develop showy “AMD/ATI Ruby” style demos to win the hearts of enthusiasts. Groo at semiaccurate.com suggests that the IDF demo was shown on early, barely functional Larrabee silicon. If true, that could help explain why the demo was so limited. But by this time in the GPU’s lifecycle there should be more marketing – even if totally pre-rendered – showing what the GPU will do. So far the bland GDC2009 meteor demo is the only thing we’ve seen. I think Larrabee needs more sizzle, like this early Sony Playstation 2 demo reel. (Sony also had some great interactive tech demos of things like feathers and pollen particles, but I haven’t been able to find online videos in my limited searching.) Intel’s current marketing approach seems to indicate that they are not serious about competing for the enthusiast add-on GPU market. Perhaps they are just waiting until it’s closer to the time Larrabee is available for market, but my guess is that they just don’t understand how to play the game. It would be a shame if Larrabee is a technical success but a sales failure due to poor marketing execution.

Brick Break - a Javascript Breakout clone

Brick Break game screenshot

This weekend I wrote a Javascript clone of the old Atari “Breakout” game. Thanks to the “Canvas” tag it was very easy to write, but I did run into a few problems:

  • Javascript math is always floating point, so I had to use the “Math.floor” function to convert the results of a division to an integer. This was in the brick collision detection logic, where I am converting the ball’s (x,y) coordinates to the bricks that the ball might be hitting.

  • I was evaluating document.getElementById too early in the document lifecycle, before the corresponding elements existed. This took me a long time to diagnose – I ended up just moving the getElementById calls to their run-time use, rather than trying to cache the results.

Jack’s Brick Break Breakout clone

ICFP 2009 paper on Haskell in the Real World

Here’s a good paper on using Haskell to write a commercial application. The authors are practical commercial programmers who tried Haskell to see if it was a more effective language than Ruby: Experience Report: Haskell in the “Real World” Writing a Commercial Application in a Lazy Functional Language Of special interest is the “Problems and Disadvantages” section. It seems that space leaks which are a continuing source of trouble in the authors’ application. Reading this paper reminds me of Tenerife Skunkworks Haskell vs Erlang Reloaded. In that experiment a developer found that Erlang was much better than Haskell for real-time programming.

Back to gnome

Well, 8 hours using wmii was enough for me. Too many apps didn’t quite work right. So I’m back to plain-old-boring-but-familiar Gnome.

Technology Trends I'm Keeping an Eye On

In no particular order, here’s what I’ve been studying lately:

  • Javascript. I’ve avoided this language over the years because of its low speed and shoddy reputation. But the language implementations seem to be getting faster and the available libraries seem to be getting more interesting. I’ve just watched all of Doug Crockford’s YUI lectures on JavaScript, and I’m thinking about trying to use the language in some toy projects.
  • git gui - this git command, available in recent builds of git, make Git changes pretty easy to author.
  • The Undercover Economist - this is a great book about economic theory. It’s pretty easy to read while shaving, or waiting for compiles. Lots of good anecdotes and tools for modeling the behavior of consumers and firms. I took 3 economics classes in college, and they didn’t teach me as much practical information as I’ve learned from reading this book.
  • Hacker News - this link voting site has replaced alterslash and reddit programming as my daily comp-sci news site. I like the emphasis on start-up news.
  • wmii - yet another tiling window manager. I tried a bunch of tiling window managers, and this one seemed to “click” with me. I found that I could customize it easily, and it mostly “just worked” the way I wanted it to. We’ll see if I stick with it or go back to Gnome. [Follow-up. I went back to Gnome (and then to OSX). Oh well.]
  • Chrome - now that the Linux and OSX versions have Flash support, Chrome has become my default web browser. I like its clean UI.

Dual XHD7714 Road Trip Report

After a month of using the Dual XHD7714, during which my family and I took a 4000 mile road trip, I have to say it’s a pretty nice system. We used it almost exclusively as an MP3 player, rather than an HD Radio or a CD player. I loaded 800 songs from our home music collection onto an 8GB memory stick. It was great introducing my kids to some new music. By the end of the trip their favorite songs were Shock the Monkey and The Magical Mr. Mistoffelees.

Some problems specific to the Dual XHD7714:

Bluetooth issues:

  • Bluetooth headset mode only syncs with one phone at a time. This seems to be a common limitation of low-end bluetooth car stereos, but it’s quite frustrating for two-driver families like mine.
  • Bluetooth audio streaming mode doesn’t sound very good on this radio. However, I didn’t experiment with this very much, so it may have been source-material related.

USB MP3 player issues:

  • It takes about 5 seconds per GB to index USB stick music each time it starts up.
  • It only recognizes US-ASCII characters. If any non-ASCII characters are present in the album or song name the entire name is replaced with the string “Not supported”. We had a lot of Chinese-language tracks that displayed that way, making them very difficult to navigate.
  • It can’t fast-forward or rewind through MP3s.
  • When you turn on the radio, it does remember where in the current MP3 it is playing, but it takes a long time to resume playing an MP3 in the middle. So it’s awkward listening to long podcasts.

Still, even with all these flaws, I’m quite happy with the radio. We really enjoyed being able to conveniently listen to so many different songs during our trip.

Nehalem machines are very fast

I’ve just had a chance to use a Nehalem HP Z600 workstation with 2 Xeon E5520 CPUs. The machine has 8 cores, 16 hardware threads, and an absurd 12 GB of RAM.

It’s very fast. It’s about 2.5 times as fast (when building the Android sources) as the previously fastest machine I’d used, which was an HP xw6600 with a single Xeon E5420 CPU.

The machine’s relatively small, no larger than an ordinary ATX tower. One way that HP kept the case small is by making the motherboard an odd shape: it is “C” shaped, with a cutout that leaves room for the DVD drive.

Too Many Words about Car Stereos

The other day my wife said to me, “Jack, we’re going on a road trip soon. Is there any way we could hook up our MP3 player to the car stereo, so that the kids could listen to their favorite songs during the trip?”

Twenty hours of web research and $250 later we’ve got a new car stereo. It’s a Dual XHD7714 from Crutchfield. I’m getting it installed by Best Buy tomorrow. Let’s hope their AV installers do a good job!

First, why did I get a new stereo at all? Well, all I wanted to do was hook up an MP3 player. But there was no easy way to do that. My 2005 minivan came with a factory installed stereo that didn’t have an auxiliary input. There are cheap FM transmitter systems that work with any radio, but they look clunky and the sound quality is supposed to be poor. A lot of web searching turned up some aftermarket accessories that allow hooking up either an audio input jack ($75

  • $50 installation = $125) or an MP3 player and/or iPod ($125 + $50 = $175.) But the for just a little more money I was able to get a a whole new radio with lot of additional features.

Why this particular model? It was well reviewed and relatively inexpensive. The features I was interested in were:

  • MP3 player / USB memory stick player.
  • Hands-free bluetooth calling with a built-in microphone.
  • Streaming audio from a bluetooth phone.
  • Charging USB devices.
  • HD radio.
  • Good fast text UI for navigating a MP3 player.
  • Play MP3s stored on CDs.
  • Wireless remote control for “back seat DJs”

General thoughts on the car stereo market

  • Crutchfield is a good place to research and buy car stereos. For research purposes they have a wide selection, and they have very good information, especially in the form of user reviews. For buying they offer free shipping and more importantly a free installation and wiring kit. They also seem to offer very good telephone help for do-it-yourself installers.
  • The add-on car stereo market is in long-term decline. I think that in the next few years the car stereo will become little more than a mobile phone docking station. People will keep their music collection on their phone, or stream it from the internet.
  • Car stereo makers are not going down without a fight. They are experimenting with iPhone-inspired full-screen touch-screen UIs and built-in internet radios. While very creative, I don’t think people will buy them. They will just use their phones instead.
  • Many people want to connect their iPods to their car stereo. In the short term Apple is making this difficult by changing their communication protocols with every generation of iPod. In the long term iPods are going to be replaced by iPhones, which will probably be forced to support bluetooth stereo streaming.

Using a Mac keyboard with Ubuntu Linux

I frequently switch between Mac and Linux, and it’s been troublesome to remember to type Command-whatever on the Mac, but Control-whatever on Linux. (For copy-and paste, for example.)

I did a quick web search and found out that it’s easy to make Ubuntu Linux recognize the Command keys as an extra set of control keys:

Choose menu: System : Preferences : Keyboard
Select the Layouts tab
Choose "Layout Options"
Open the "Alt / Win Key Behaviour" tab
Check the "Control is mapped to the Win-keys" checkbox.