camera ready version of the MSR 2010 paper