main loop

The top-level control flow construct in an input- or event-driven program, the one which receives and acts or dispatches on the program's input events.

See also driver.

[Jargon File]