In logStream.hpp, the _smallbuf member is 64 chars long. If I am not misunderstanding the code, this will create malloc-free calls for almost each and every LogStream. Would be nice to align this size to vwrite_buffer_size (512) in logTagSet.cpp.
Also update the bad comments regarding stack allocation (they are always stack allocated):
// Helper class, maintains the line buffer. For small line lengths,
// we avoid malloc and use a fixed sized member char array. If LogStream
// is allocated on the stack, this means small lines are assembled
// directly on the stack.
.
.
.
// Prevent operator new for LogStream.
static void* operator new (size_t);
static void* operator new[] (size_t);
Also update the bad comments regarding stack allocation (they are always stack allocated):
// Helper class, maintains the line buffer. For small line lengths,
// we avoid malloc and use a fixed sized member char array. If LogStream
// is allocated on the stack, this means small lines are assembled
// directly on the stack.
.
.
.
// Prevent operator new for LogStream.
static void* operator new (size_t);
static void* operator new[] (size_t);