MCPcopy Create free account
hub / github.com/F-Stack/f-stack / BMK_benchCLevel

Function BMK_benchCLevel

freebsd/contrib/zstd/programs/benchzstd.c:662–689  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

660}
661
662static BMK_benchOutcome_t BMK_benchCLevel(const void* srcBuffer, size_t benchedSize,
663 const size_t* fileSizes, unsigned nbFiles,
664 int cLevel, const ZSTD_compressionParameters* comprParams,
665 const void* dictBuffer, size_t dictBufferSize,
666 int displayLevel, const char* displayName,
667 BMK_advancedParams_t const * const adv)
668{
669 const char* pch = strrchr(displayName, '\\'); /* Windows */
670 if (!pch) pch = strrchr(displayName, '/'); /* Linux */
671 if (pch) displayName = pch+1;
672
673 if (adv->realTime) {
674 DISPLAYLEVEL(2, "Note : switching to real-time priority \n");
675 SET_REALTIME_PRIORITY;
676 }
677
678 if (displayLevel == 1 && !adv->additionalParam) /* --quiet mode */
679 DISPLAY("bench %s %s: input %u bytes, %u seconds, %u KB blocks\n",
680 ZSTD_VERSION_STRING, ZSTD_GIT_COMMIT_STRING,
681 (unsigned)benchedSize, adv->nbSeconds, (unsigned)(adv->blockSize>>10));
682
683 return BMK_benchMemAdvanced(srcBuffer, benchedSize,
684 NULL, 0,
685 fileSizes, nbFiles,
686 cLevel, comprParams,
687 dictBuffer, dictBufferSize,
688 displayLevel, displayName, adv);
689}
690
691BMK_benchOutcome_t BMK_syntheticTest(int cLevel, double compressibility,
692 const ZSTD_compressionParameters* compressionParams,

Callers 2

BMK_syntheticTestFunction · 0.70
BMK_benchFilesAdvancedFunction · 0.70

Calls 2

strrchrFunction · 0.85
BMK_benchMemAdvancedFunction · 0.85

Tested by

no test coverage detected