How do collisions of rocks with planets help planets evolve?