#1603 closed defect (fixed)

The array mvFieldNeighbours of the class MergeCtx has overflowed.

Reported by: Haruhiko Owned by:
Priority: major Milestone: VTM-21.0
Component: VTM Version: VTM-20.0
Keywords: Cc: ksuehring, XiangLi, fbossen, jvet@…


In the function MergeItem::importMergeInfo, the variable mergeIdx becomes larger than MRG_MAX_NUM_CANDS and overflows the array mergeCtx.mvFieldNeighbours.
This seems to occur when the function importMergeInfo is called from EncCu::addMmvdCandsToPruningList, so the value of mmvdIdx.val in the argument of mmvdMerge->importMergeInfo appears to be incorrect.

Change history (5)

comment:1 Changed 12 months ago by XiangLi

Thanks for the report. Could you provide the command line setting and encoding log of an overflow case so that we could reproduce the issue?

comment:2 Changed 12 months ago by fbossen

Looks like the following shouldn't be executed when mergeItemType is equal to MergeItemType::MMVD because the value of mergeIdx is too large. Note that all these fields are set later in the function.

  if (mergeItemType != MergeItemType::GPM)
    mvField[0][REF_PIC_LIST_0] = mergeCtx.mvFieldNeighbours[mergeIdx][REF_PIC_LIST_0];
    mvField[0][REF_PIC_LIST_1] = mergeCtx.mvFieldNeighbours[mergeIdx][REF_PIC_LIST_1];
    interDir = mergeCtx.interDirNeighbours[mergeIdx];
    bcwIdx = mergeCtx.bcwIdx[mergeIdx];
    useAltHpelIf = mergeCtx.useAltHpelIf[mergeIdx];

comment:3 Changed 12 months ago by XiangLi

Frank is right. We should not do it for MMVD. I just submitted a fix https://vcgit.hhi.fraunhofer.de/jvet/VVCSoftware_VTM/-/merge_requests/2626. @Haruhiko, please check whether it solves the issue. Thanks.

comment:4 Changed 12 months ago by Haruhiko

The mentioned changes have resolved the overflow issue. Thank you.

comment:5 Changed 12 months ago by XiangLi

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.