Opened 2 weeks ago

Last modified 7 days ago

#571 new defect

RPR - Multiplication Overflow

Reported by: bheng Owned by:
Priority: minor Milestone:
Component: VTM Version: VTM-6.1
Keywords: Cc: ksuehring, XiangLi, fbossen, jvet@…

Description

The following 32-bit multiplications in xPredInterBlkRPR( ) can overflow the signed 32-bit range before the result is assigned to the 64-bit x0Int/y0Int output.

x0Int = ( ( blk.pos().x << ( 4 + ::getComponentScaleX( compID, chFmt ) ) ) + mv.getHor() )* scalingRatio.first;

y0Int = ( ( blk.pos().y << ( 4 + ::getComponentScaleY( compID, chFmt ) ) ) + mv.getVer() )* scalingRatio.second;

I would recommend type-casting the scaling ratios to (int64_t) first in order to use 64-bit multiplications.

Change history (1)

comment:1 Changed 7 days ago by bheng

Potential fixes for this issue are available in the following merge request:

https://vcgit.hhi.fraunhofer.de/jvet/VVCSoftware_VTM/merge_requests/997

Note: See TracTickets for help on using tickets.