[x265] [PATCH] search: removed redundant context store

ashok at multicorewareinc.com ashok at multicorewareinc.com
Fri Oct 17 16:12:32 CEST 2014


# HG changeset patch
# User Ashok Kumar Mishra<ashok at multicorewareinc.com>
# Date 1413555079 -19800
#      Fri Oct 17 19:41:19 2014 +0530
# Node ID 8ffdcf053db2562fcfb79c2c18b7dba75cca1edb
# Parent  d05635e818c5bb1e5f1f93d7618c6c16dbdb3132
search: removed redundant context store

diff -r d05635e818c5 -r 8ffdcf053db2 source/encoder/search.cpp
--- a/source/encoder/search.cpp	Fri Oct 17 15:05:40 2014 +0530
+++ b/source/encoder/search.cpp	Fri Oct 17 19:41:19 2014 +0530
@@ -480,11 +480,11 @@
         X265_CHECK(m_qtTempShortYuv[qtLayer].m_size == MAX_CU_SIZE, "width is not max CU size\n");
         const uint32_t reconQtStride = MAX_CU_SIZE;
 
+        // store original entropy coding status
+        m_entropyCoder.store(m_rdContexts[fullDepth].rqtRoot);
+
         if (checkTransformSkip || checkTQbypass)
         {
-            // store original entropy coding status
-            m_entropyCoder.store(m_rdContexts[fullDepth].rqtRoot);
-
             uint32_t  singleDistYTmp = 0;
             uint32_t  singlePsyEnergyYTmp = 0;
             uint32_t  singleCbfYTmp  = 0;
@@ -569,8 +569,6 @@
         }
         else
         {
-            m_entropyCoder.store(m_rdContexts[fullDepth].rqtRoot);
-
             cu->setTransformSkipSubParts(0, TEXT_LUMA, absPartIdx, fullDepth);
             singleDistY = calcIntraLumaRecon(mode, cuData, absPartIdx, log2TrSize, reconQt, reconQtStride, coeffY, singleCbfY);
             if (m_rdCost.m_psyRd)
@@ -601,8 +599,6 @@
             m_entropyCoder.store(m_rdContexts[fullDepth].rqtTest);
             m_entropyCoder.load(m_rdContexts[fullDepth].rqtRoot);
         }
-        else
-            m_entropyCoder.store(m_rdContexts[fullDepth].rqtRoot);
 
         // code splitted block
         uint64_t splitCost     = 0;


More information about the x265-devel mailing list