Added iterator macro EACH.
Use common format for XLOG/XFLOG, XDBG/XFDBG, XASSERT/XFASSERT (no newline)
to easily convert XLOG to XFLOG and void missing newlines.
Added test for pthread thread local storage using
pthread_setspecific/pthread_getspecific.