Is rest used to mean the same thing in the next two sentences?

He threw away the rest.

The boulder came to rest just behind the house after rolling down the mountain.
different meanings