From patchwork Thu Dec 12 00:33:08 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Niedermayer X-Patchwork-Id: 16745 Return-Path: X-Original-To: patchwork@ffaux-bg.ffmpeg.org Delivered-To: patchwork@ffaux-bg.ffmpeg.org Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by ffaux.localdomain (Postfix) with ESMTP id 3B19144A081 for ; Thu, 12 Dec 2019 02:33:17 +0200 (EET) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 23F7868AABC; Thu, 12 Dec 2019 02:33:17 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [217.70.183.196]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 21E0F68A3E6 for ; Thu, 12 Dec 2019 02:33:11 +0200 (EET) X-Originating-IP: 213.47.68.29 Received: from localhost (213-47-68-29.cable.dynamic.surfer.at [213.47.68.29]) (Authenticated sender: michael@niedermayer.cc) by relay4-d.mail.gandi.net (Postfix) with ESMTPSA id 31FF3E0006 for ; Thu, 12 Dec 2019 00:33:09 +0000 (UTC) Date: Thu, 12 Dec 2019 01:33:08 +0100 From: Michael Niedermayer To: FFmpeg development discussions and patches Message-ID: <20191212003308.GO3089@michaelspb> References: <20191211220006.1286-1-jamrial@gmail.com> <20191211231514.GN3089@michaelspb> MIME-Version: 1.0 In-Reply-To: <20191211231514.GN3089@michaelspb> Subject: Re: [FFmpeg-devel] [PATCH] avcodec/cbs_av1: fix array size for ar_coeffs_cb_plus_128 and ar_coeffs_cr_plus_128 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" On Thu, Dec 12, 2019 at 12:15:14AM +0100, Michael Niedermayer wrote: > On Wed, Dec 11, 2019 at 07:00:06PM -0300, James Almer wrote: > > Taking into account the code > > > > fb(2, ar_coeff_lag); > > num_pos_luma = 2 * current->ar_coeff_lag * (current->ar_coeff_lag + 1); > > if (current->num_y_points) > > num_pos_chroma = num_pos_luma + 1; > > else > > num_pos_chroma = num_pos_luma; > > > > Max value for ar_coeff_lag is 3 (two bits), for num_pos_luma 24, and for > > num_pos_chroma 25. > > > > Both ar_coeffs_cb_plus_128 and ar_coeffs_cr_plus_128 may have up to > > num_pos_chroma values. > > > > Signed-off-by: James Almer > > --- > > libavcodec/cbs_av1.h | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > LGTM and i should have realized this when i looked at the fuzzer case This needs a update to fate though TEST wmav1-encode Test cbs-av1-av1-1-b8-23-film_grain-50 failed. Look at tests/data/fate/cbs-av1-av1-1-b8-23-film_grain-50.err for details. make: *** [fate-cbs-av1-av1-1-b8-23-film_grain-50] Error 1 Test cbs-av1-av1-1-b10-23-film_grain-50 failed. Look at tests/data/fate/cbs-av1-av1-1-b10-23-film_grain-50.err for details. make: *** [fate-cbs-av1-av1-1-b10-23-film_grain-50] Error 1 Thanks [...] --- ./tests/ref/fate/cbs-av1-av1-1-b8-23-film_grain-50 2019-12-11 15:53:24.616370434 +0100 +++ tests/data/fate/cbs-av1-av1-1-b8-23-film_grain-50 2019-12-12 01:25:39.813093782 +0100 @@ -1 +1 @@ -93e578da4b2bdb70ce0a92262da930ec +2556d6d30469c647c6262130d8eb0531 --- ./tests/ref/fate/cbs-av1-av1-1-b10-23-film_grain-50 2019-12-11 15:53:24.616370434 +0100 +++ tests/data/fate/cbs-av1-av1-1-b10-23-film_grain-50 2019-12-12 01:25:39.825093782 +0100 @@ -1 +1 @@ -5fe6622ac6cb22dd10dfbe9e70e82d4e +aaddbf87bdf9b5ac4b1ab4fe802c410b