test/multi_stress_watch: use condition_variable for level triggering
* use mutex+condition_variable instead of POSIX semaphore, for
couple reasons:
- for using POSIX semaphore, we should set the initial value:
before this change, sem_init() is not called, so the initial
value of the semaphore is not set.
- use condition_variable::wait_for() instead of TestAlarm. simpler
this way. and avoid hiding the magic numbers -- if we choose to
live with them, make them more visible.
- use RAII to avoid sem_init() and sem_destroy()
- use a member variable for being level triggered. as notify()
could be called before wait() is called.
* define 10000 using a constant variable: NR_ITERATIONS
* remove unused `#include <sstream>` and using declaration.
* use cout for printing informative messages