Change integer test for TIMEOUT

Use regexes rather than this `-ne` hack.
Split up TIMEOUT functionality

Give finer-grained control over the various TIMEOUTs in the
codebase. This introduces several new options:

* START_TIMEOUT
* STOP_TIMEOUT
* CMD_TIMEOUT
* PREGEN_TIMEOUT
Document *_TIMEOUT options