Add 'enable_thread_cache' call to hooks API

Add a new call to the allocator hooks API, allowing the caller to
enable/disable any thread caching for the calling thread. Implement
the API for jemalloc.

Change-Id: I005728775197865e2c1f4a4622cee90f39ed3a7b
Reviewed-on: http://review.couchbase.org/41487
Reviewed-by: Trond Norbye <trond.norbye@gmail.com>
Tested-by: Trond Norbye <trond.norbye@gmail.com>