xmalloc_chunk_return(): added assertion check when last block is returned.
thread-test: allow -P with -X to add concurrent (discovered) POSIX threads.
thread-test: added -r to let a fraction of the objects be freed remotely by -X.

During memory allocation tests, it is now possible to request that a random
percentage of the allocated objects be freed by a remote thread, to exercise
cross-thread freeing of objects.
mutex_thread(): initialize the element to NULL when running in "fast" mode.
Pre-allocate the thread elements for discovered threads.

This allows thread_get_element() to immediately have a thread_element structure
available when it discovers a new thread, since we cannot safely allocate new
memory until the thread is properly instantiated by our runtime.