History

Multi-thread-fixed:RBC#1720:iMaxSliceNumConstraint replaced by iMaxSliceNum

huade committed 9 years ago

Commit c2e37d51 parent c917d315 files · +31 −36Browse files

Showing the changes to codec/encoder/core/src/slice_multi_threading.cpp (1 of 5 files). Show all

Unified · Split

codec/encoder/core/src/slice_multi_threading.cpp+3−4
@@ -688,7 +688,6 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 687 unmodified lines
688 WelsEventSignal (688 WelsEventSignal (
689 &pEncPEncCtx->pSliceThreading->pSliceCodedMasterEvent);689 &pEncPEncCtx->pSliceThreading->pSliceCodedMasterEvent);
690 } else { // for SM_SIZELIMITED_SLICE parallelization690 } else { // for SM_SIZELIMITED_SLICE parallelization
691 SSliceCtx* pSliceCtx = &pCurDq->sSliceEncCtx;
692 const int32_t kiPartitionId = iThreadIdx;691 const int32_t kiPartitionId = iThreadIdx;
693 const int32_t kiSliceIdxStep = pEncPEncCtx->iActiveThreadsNum;692 const int32_t kiSliceIdxStep = pEncPEncCtx->iActiveThreadsNum;
694 const int32_t kiFirstMbInPartition = pCurDq->pFirstMbIdxOfPartition[kiPartitionId];693 const int32_t kiFirstMbInPartition = pCurDq->pFirstMbIdxOfPartition[kiPartitionId];
@@ -702,14 +701,14 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 7 unmodified lines
702 pCurDq->pLastCodedMbIdxOfPartition[kiPartitionId] = 0;701 pCurDq->pLastCodedMbIdxOfPartition[kiPartitionId] = 0;
703 702
704 while (iAnyMbLeftInPartition > 0) {703 while (iAnyMbLeftInPartition > 0) {
705 if (iSliceIdx >= pSliceCtx->iMaxSliceNumConstraint) {704 if (iSliceIdx >= pCurDq->iMaxSliceNum) {
706 // TODO: need exception handler for not large enough of MAX_SLICES_NUM related memory usage705 // TODO: need exception handler for not large enough of MAX_SLICES_NUM related memory usage
707 // No idea about its solution due MAX_SLICES_NUM is fixed lenght in relevent pData structure706 // No idea about its solution due MAX_SLICES_NUM is fixed lenght in relevent pData structure
708 uiThrdRet = 1;707 uiThrdRet = 1;
709 WelsLog (&pEncPEncCtx->sLogCtx, WELS_LOG_WARNING,708 WelsLog (&pEncPEncCtx->sLogCtx, WELS_LOG_WARNING,
710 "[MT] CodingSliceThreadProc Too many slices: coding_idx %d, iSliceIdx %d, pSliceCtx->iMaxSliceNumConstraint %d",709 "[MT] CodingSliceThreadProc Too many slices: coding_idx %d, iSliceIdx %d, pCurDq->iMaxSliceNum %d",
711 pParamInternal->iCodingIndex,710 pParamInternal->iCodingIndex,
712 iSliceIdx, pSliceCtx->iMaxSliceNumConstraint);711 iSliceIdx, pCurDq->iMaxSliceNum);
713 WELS_THREAD_SIGNAL_AND_BREAK (pEncPEncCtx->pSliceThreading->pSliceCodedEvent,712 WELS_THREAD_SIGNAL_AND_BREAK (pEncPEncCtx->pSliceThreading->pSliceCodedEvent,
714 pEncPEncCtx->pSliceThreading->pSliceCodedMasterEvent,713 pEncPEncCtx->pSliceThreading->pSliceCodedMasterEvent,
715 iEventIdx);714 iEventIdx);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t