[x265] [PATCH 09 of 13] stats: include loop filter processing and all overhead in worker wall time
Steve Borho
steve at borho.org
Wed Jan 28 21:32:24 CET 2015
# HG changeset patch
# User Steve Borho <steve at borho.org>
# Date 1422471251 21600
# Wed Jan 28 12:54:11 2015 -0600
# Node ID ff6eec030551334108130963d1d39b8a83a6c004
# Parent 451e21c4c66b968eb3604c6eb7d6866f2b0c4a86
stats: include loop filter processing and all overhead in worker wall time
diff -r 451e21c4c66b -r ff6eec030551 source/encoder/frameencoder.cpp
--- a/source/encoder/frameencoder.cpp Wed Jan 28 12:46:03 2015 -0600
+++ b/source/encoder/frameencoder.cpp Wed Jan 28 12:54:11 2015 -0600
@@ -685,6 +685,7 @@
void FrameEncoder::processRow(int row, int threadId)
{
+ int64_t startTime = x265_mdate();
ATOMIC_INC(&m_activeWorkerCount);
const uint32_t realRow = row >> 1;
@@ -706,6 +707,7 @@
}
ATOMIC_DEC(&m_activeWorkerCount);
+ m_totalWorkerElapsedTime += x265_mdate() - startTime; // not thread safe, but good enough
}
// Called by worker threads
@@ -740,7 +742,6 @@
FrameData& curEncData = *m_frame->m_encData;
Slice *slice = curEncData.m_slice;
- int64_t startTime = x265_mdate();
const uint32_t numCols = m_numCols;
const uint32_t lineStartCUAddr = row * numCols;
bool bIsVbv = m_param->rc.vbvBufferSize > 0 && m_param->rc.vbvMaxBitrate > 0;
@@ -938,7 +939,6 @@
{
curRow.active = false;
curRow.busy = false;
- m_totalWorkerElapsedTime += x265_mdate() - startTime; // not thread safe, but good enough
ATOMIC_INC(&m_countRowBlocks);
return;
}
@@ -995,7 +995,6 @@
}
}
- m_totalWorkerElapsedTime += x265_mdate() - startTime; // not thread safe, but good enough
curRow.busy = false;
}
More information about the x265-devel
mailing list