Commonly used in micro-controllers to control timing accurately, however most likely to be written in Assembler (or inline assembler in a C programmer) as the programmer then has absolute control over the instructions used, hence the time taken.