Better file distribution algorithm for hadd
Added debug message