The computer part. Once we get past on and off it gets a little gray.......
OK. Lemme 'splain..
A dive computer monitors your depth and time and uses that to calculate, based on various tissue absorption and bubble formation models, your nitrogen loading (for decompression) and (if you're diving a gas other than air) your oxygen exposure (to avoid oxygen toxicity, since seizures at depth tend to be fatal...), the depth and time of decompression stops, if any are needed.
All clear now?