Monthly Archive for February, 2007

News Flash: Tech Interviews Don’t Work

There’s been a lot of buzz around the blogosphere lately about various issues with interviewing programmers.

One of these days I’d like to do a study. I’d find a very brave employer who needs to hire 100 people. We would use traditional interview techniques to fill 50 positions. For the other half, we’d pluck reasonable resumes from a pile, choose 50 at random, and just hire them.

After a year, I would return and talk to management. My guess is there would be no significant difference in the performance of the two groups.

If you are anything like me, you’ve been on both sides of the “hiring table” enough times to know that my hypothesis is probably right. There are just too many ways that an interview can fail.

If you don’t ask any tech questions at all, you can end up hiring someone who literally cannot code. Most employers are terrified of these “false positives” and so, instead, they make their interviews highly technical. They only hire people who can remember, on the day of the interview, how to solve the dining philosophers problem, or how heapsort works. However, nerd brains have aggressive garbage collectors which quickly expunge unused information. In English: they forget stuff. This leads to a high “false negative” rate — which is a more insidious problem because it tends to inhibit diversity.

A team with 5 heapsort experts is likely to suck for the same reason that a rock band with 5 drummers would suck. But I digress.

The typical whiteboard question is highly ego-centric. We go into a little room with a question that we’ve asked a dozen times and understand fully. We pose this question to a “lesser” nerd, in a high pressure environment, and carefully note all the missed semicolons. We chuckle to ourselves, secure in our supreme geekhood.

Ego deflation alert: 100% of these candidates could turn around and immediately ask an “interview question” that we could not answer. Oops. Who’s the idiot now?

By focusing on the whiteboard, interviews typically fail to evaluate candidates on many orthogonal — but critically important — axes. For example, how well does the candidate learn? How well do they teach? Do they ask good questions? Are they able to speak and write clearly?

Almost regardless of what questions you ask, there are a number of things that your interview cannot possibly measure. These are things which require months, not hours, to ascertain: work ethic, initiative, team skills, personality, team compatibility, self-motivation, ability to compromise, creativity, etc.

I think the only way to fix this system is to restructure the entire employment process. The root cause is that it’s currently way too hard to fire someone. If professional programmers were more like professional athletes — hired on a contract basis for a specific duration — things would be much different.

Stop Vim From Indenting Public/Private/Protected

It always bugged me that Vim indents the code following public, private, or protected. It seems like a waste of space. Here’s how to turn it off.

Assuming you are already using cindent, simply add this to your vimrc:


    set cinoptions=h0

See the official vim indent documentation for full details.

Are You Being DoS’d?

My network connection was “teh suck” all weekend until I did this:


      iptables -A INPUT -s 212.17.87.173 -j DROP

Who, you might ask, is 212.17.87.173? I have no freaking clue, except that he’s Austrian and really loves photos of my wedding. It was harder to diagnose this problem than you might expect. Apache apparently writes it’s access.log after a request has completed. Thank god for netstat, or I might never have figured this one out.

Thanks to the oh-so-typically-condescending folks on freenode #apache, I’ve enabled mod_status with ExtendedStatus On, so that I can view HTTP requests in-flight.

Next I’ll try to install mod_evasive.

Videos of Stanford Computer Systems Colloquia

Add Stanford’s EE380 site to your list of killer video sites. My TV is getting more and more useless every day. I’m just finishing Dave Patterson’s talk, it’s great. I can’t wait for Ian Piumarta’s either — I expect it will pertain to his NSF work with Alan Kay.

With net video like this, who needs TechTV anyway?

(thanks to Mike Wall)

Know Your Roots: Optimizing for the 286 and 386

I just read this old Mike Abrash article (warning, 3.5M PDF) from Byte magazine about optimizing for the 286 and 386. If you don’t know Mike Abrash’s name, you almost certainly know his work.

This is fascinating stuff.

Probably the most amazing thing is how much instruction fetch dominates 286/386 performance. Abrash frequently counts instruction bytes and includes this in his calculations for expected execution speed. After a bit of Googling, this made more sense: these were the days before instruction cache.

(Although it’s still possible, you rarely see fetch-limited code on something like a K8.)

So, if you think x86 is an ugly instruction set, consider this heritage. Variable instruction length actually made a lot of sense back then. It was a form of compression. For the same reason, Intel added complex instructions like BOUNDS and REP MOVSW. These compactly express a whole bunch of work.

I guess some things never change. I still do the same kind of measurements that Abrash did all those years ago. There are small differences — he calls a timer routine, where I can simply execute rdtsc — but the method is the same. I find this remarkable, considering how different the machines are.

(via Osterman’s blog)




Creative Commons Attribution-NonCommercial 3.0 United States
Creative Commons Attribution-NonCommercial 3.0 United States