Bug 949878 - Switch to integer indexes to avoid pathological array slowdown, r=terrence

--HG--
extra : rebase_source : 93cd0bdd1bb2b1b4f104112613b3609ee4235ddd