Remove unneccessary operations in the hot path.