How do marine mammals, whose very survival depends on regular diving, manage to avoid decompression sickness or "the bends?" Do they, indeed, avoid it?
I think I got the answer....
The primary anatomical adaptations for pressure of a deep-diving mammal such as the sperm whale center on air-containing spaces and the prevention of tissue barotrauma. Air cavities, when present, are lined with venous plexuses, which are thought to fill at depth, obliterate the air space, and prevent "the squeeze." The lungs collapse, which prevents lung rupture and (important with regard to physiology) blocks gas exchange in the lung. Lack of nitrogen absorption at depth prevents the development of nitrogen narcosis and decompression sickness.
Source: Scientific American
I concur with @souvik.bhattacharya but I wish to elaborate on it. The lung collapse indeed stops gas exchange in marine mammals by keeping the air away from the lung tissue that normally exchanges O2, CO2 and N2. Build up of N2 results in the bends after the pressure drops when re-surfacing (McDonald & Ponganis, 2012). However, a study by Hooker et al. (2012) showed that beached whales, dolphins and seals did show signs of bubble formation in the internal organs, which was linked to exposure to noise and sonar, or other factors such as cold water that may disrupt the functionality of preventive measures such as the lung collapse. So to get back to your question - Yes they avoid it by lung collapse, but under certain conditions this mechanism may fail.