Like cars, they have a manual that has instructions on how often and in what manner to clean the machine. It varies from one machine to another depending on what sort of filters they use. The most common I've seen are lint filters on the side of the top-load drums that should be cleaned every couple of months or so, depending on how heavily used it is.
If the good book doesn't have that information, you will be able to tell by the looks of the drum if there are deposit build-ups that you need to worry about. In other words, if there are visible residue on the drum, there would be similar deposits on the tub. These deposits could chip off in large bits and either chew up the pump or water seal.