avoid deoptimization in update