Reducing Stack Usage

The stack available to an application on target hardware is smaller than the giant stack available to the emulator in the Windows NT environment. This can lead to code that appears to run perfectly in the WINS/WINSCW emulator not running on the hardware, with apparently random panics. Reducing stack usage is not easy, but there are a couple of things to watch out for: