enlarge initial allocation

to be able to move start forward to an aligned position.
This commit is contained in:
Yann Collet 2018-03-21 06:18:58 -07:00
parent 8762a1d5f4
commit 47128513a9

View File

@ -346,7 +346,7 @@ static int BMK_benchFiles(const char** fileNamesTable, int nbFiles, U32 specific
static int BMK_benchInternal(size_t keySize, int specificTest)
{
void* const buffer = calloc(keySize+3, 1);
void* const buffer = calloc(keySize+16+3, 1);
void* const alignedBuffer = ((char*)buffer+15) - (((size_t)((char*)buffer+15)) & 0xF); /* align on next 16 bytes */
if(!buffer) {
DISPLAY("\nError: not enough memory!\n");