Washing does two things mainly:
Originally Posted by Andrey
1. Washing removes fixer - we want to remove fixer from the emulsion and if printing paper, from the paper base. Fixer is necessary to make a permanent image, but needs to be removed once it has done it's work.
2. Washing removes fixation by-products. Fix converts undeveloped silver halides in the emulsion into soluble compounds, and makes washing possible. Washing removes silver fixation by-products from film. Fresh full strength fix makes the most soluble set of silver byproducts possible and therefore the most washable..
Washing must also remove any remaining developer and stop bath in the film.