The theory is that the heavier particles will stick to the water, and stay in the water, while the smoke will pass right through I believe. This isn't really all that true in practice as bongs don't filter out much carcinogens, and you'd have to show me a very convincing report that proves that warm water is a better filter than cold.

I really wanted to write because it gets you high, but I realized that wouldn't make much sense.