Adding primitives to mark wait condition processing.

This will allow processors waiting on their wait conditions to stay asleep
when other wait conditions finish.

This assumes that wait conditions don't modify state (this is bad anyway),
but this makes it so that if wait conditions do modify state then that
state change may not be picked up by other waiting processors.

It also requires a change to code generation, which has not yet been
implemented.