[x265] [PATCH 10 of 13] stats: report wall time of wait for reference rows
Steve Borho
steve at borho.org
Wed Jan 28 21:32:25 CET 2015
# HG changeset patch
# User Steve Borho <steve at borho.org>
# Date 1422474298 21600
# Wed Jan 28 13:44:58 2015 -0600
# Node ID 766e91256991ae9ab6754da3101838e1c0861a24
# Parent ff6eec030551334108130963d1d39b8a83a6c004
stats: report wall time of wait for reference rows
diff -r ff6eec030551 -r 766e91256991 source/encoder/encoder.cpp
--- a/source/encoder/encoder.cpp Wed Jan 28 12:54:11 2015 -0600
+++ b/source/encoder/encoder.cpp Wed Jan 28 13:44:58 2015 -0600
@@ -215,7 +215,7 @@
fprintf(m_csvfpt, "RateFactor, ");
fprintf(m_csvfpt, "Y PSNR, U PSNR, V PSNR, YUV PSNR, SSIM, SSIM (dB), List 0, List 1");
/* detailed performance statistics */
- fprintf(m_csvfpt, ", Row0Wait ms, Wall time ms, FrameEnd ms, Total CTU time ms, Avg WPP, Row Blocks\n");
+ fprintf(m_csvfpt, ", Row0Wait ms, Wall time ms, Ref Wait Wall ms, Total CTU time ms, Avg WPP, Row Blocks\n");
}
else
fputs(summaryCSVHeader, m_csvfpt);
@@ -1190,7 +1190,7 @@
fprintf(m_csvfpt, ", %.1lf, %.1lf, %.1lf, %.1lf",
ELAPSED_MSEC(curEncoder->m_startCompressTime, curEncoder->m_row0WaitTime),
ELAPSED_MSEC(curEncoder->m_row0WaitTime, curEncoder->m_endCompressTime),
- ELAPSED_MSEC(curEncoder->m_endCompressTime, curEncoder->m_endFrameTime),
+ ELAPSED_MSEC(curEncoder->m_row0WaitTime, curEncoder->m_allRowsAvailableTime),
ELAPSED_MSEC(0, curEncoder->m_totalWorkerElapsedTime));
if (curEncoder->m_totalActiveWorkerCount)
fprintf(m_csvfpt, ", %.3lf", (double)curEncoder->m_totalActiveWorkerCount / curEncoder->m_activeWorkerCountSamples);
diff -r ff6eec030551 -r 766e91256991 source/encoder/frameencoder.cpp
--- a/source/encoder/frameencoder.cpp Wed Jan 28 12:54:11 2015 -0600
+++ b/source/encoder/frameencoder.cpp Wed Jan 28 13:44:58 2015 -0600
@@ -643,6 +643,7 @@
}
}
+ m_allRowsAvailableTime = x265_mdate();
m_completionEvent.wait();
WaveFront::dequeue();
@@ -673,6 +674,8 @@
if (!i)
m_row0WaitTime = x265_mdate();
+ else if (i == m_numRows - 1)
+ m_allRowsAvailableTime = x265_mdate();
processRowEncoder(i, *m_tld);
}
diff -r ff6eec030551 -r 766e91256991 source/encoder/frameencoder.h
--- a/source/encoder/frameencoder.h Wed Jan 28 12:54:11 2015 -0600
+++ b/source/encoder/frameencoder.h Wed Jan 28 13:44:58 2015 -0600
@@ -169,9 +169,11 @@
volatile int m_countRowBlocks; // count of workers forced to abandon a row because of top dependency
int64_t m_startCompressTime; // timestamp when frame encoder is given a frame
int64_t m_row0WaitTime; // timestamp when row 0 is allowed to start
+ int64_t m_allRowsAvailableTime; // timestamp when all reference dependencies are resolved
int64_t m_endCompressTime; // timestamp after all CTUs are compressed
int64_t m_endFrameTime; // timestamp after RCEnd, NR updates, etc
- int64_t m_totalWorkerElapsedTime;
+ int64_t m_totalWorkerElapsedTime; // total elapsed time spent by worker threads processing CTUs
+ int64_t m_totalNoWorkerTime; // total elapsed time without any active worker threads
Encoder* m_top;
x265_param* m_param;
More information about the x265-devel
mailing list