shrink drmemtrace buffer redzone
This issue covers taking two courses of action regarding drmemtrace's redzone size.
First, is the redzone large enough?
Second, we'd like a tighter bound on the redzone, so we can shrink it if possible to reduce general overhead and particularly to reduce wasted space when using drmemtrace_buffer_handoff() (xref #2006 (closed)) where the entire mmap is handed off.
Going beyond the main buffer into the redzone, how many memrefs can we hit before we detect and write the buffer out? No loop can execute: only one execution of a single basic block, which could be up to 256 instructions with default client options. Each memref takes up 8 bytes in the buffer. If each instruction were a VSIB with 4 distinct memrefs we could get up to 8K extra but that is extremely pathological.
We could require containing tools to set -max_bb_instrs if that helps.