1
0
mirror of https://github.com/facebook/zstd.git synced 2026-01-06 11:21:19 +03:00

Changed : input divided into roughly equal parts.

Debug : can measure time waiting for mutexes to unlock.
This commit is contained in:
Yann Collet
2016-12-29 01:24:01 +01:00
parent 6c0ed9483a
commit e70912c72b
2 changed files with 48 additions and 16 deletions

View File

@@ -159,8 +159,6 @@ static int BMK_benchMem(const void* srcBuffer, size_t srcSize,
U32 nbBlocks;
UTIL_time_t ticksPerSecond;
ZSTDMT_CCtx* const mtcctx = ZSTDMT_createCCtx(g_nbThreads);
/* checks */
if (!compressedBuffer || !resultBuffer || !blockTable || !ctx || !dctx)
EXM_THROW(31, "allocation error : not enough memory");
@@ -228,6 +226,8 @@ static int BMK_benchMem(const void* srcBuffer, size_t srcSize,
const char* const marks[NB_MARKS] = { " |", " /", " =", "\\" };
U32 markNb = 0;
ZSTDMT_CCtx* const mtcctx = ZSTDMT_createCCtx(g_nbThreads);
UTIL_getTime(&coolTime);
DISPLAYLEVEL(2, "\r%79s\r", "");
while (!cCompleted || !dCompleted) {