WL#3021: Use a lock-free memory allocator

Affects: WorkLog-3.4   —   Status: Un-Assigned

Situation
---------

Currently, the server uses a lock-based (standard) allocator to handle
memory requests.

Problem
-------

When the number of concurrent memory requests grow, the memory
allocator becomes a bottleneck for achiving performance of the server.
This is partially handled by keeping separate memory pools for each
client, which entirely avoids the use of a concurrent allocator at the
cost of keeping, potentially large, memory pools.


Solution
--------

Instead of using a lock-based memory allocator, a lock-free could
offer superior performance for CMP and SMP architectures.  In
addition, if the performance of a lock-free concurrent allocator is
sufficiently effective, memory usage could be reduced since it would
not be necessary to keep separate memory pools for each client.

There is potential to get a linear speedup relative the number of
concurrent processes, compared to the constant speedup of 2 achived by
traditional libc ``malloc()`` [Mag04].

For more information, see the references.

References
----------

.. [Ber02] Memory Management for High-Performance
   Applications : http://citeseer.ist.psu.edu/berger02memory.html
.. [GPT04] Allocating Memory in a Lock-Free Manner :
   http://citeseer.ist.psu.edu/gidenstam04allocating.html
.. [Mag04] Scalable Lock-Free Dynamic Memory Allocation. *Proceedings
   of PLDI'04*
-- WL#3229