[vlc-devel] [PATCH] [RFC] picture: disable the extra 2 lines per picture in debug builds

Rémi Denis-Courmont remi at remlab.net
Tue Apr 24 09:31:44 CEST 2018


Le 24 avril 2018 09:36:46 GMT+03:00, Steve Lhomme <robux4 at ycbcr.xyz> a écrit :
>Following this thread [1] we probably don't need these lines anymore.
>
>For now we can give it a try in debug/nightly builds to see if we hit
>any wall.
>
>1:
>https://mailman.videolan.org/pipermail/vlc-devel/2018-April/118535.html
>---
> src/misc/picture.c | 2 ++
> 1 file changed, 2 insertions(+)
>
>diff --git a/src/misc/picture.c b/src/misc/picture.c
>index f6abd6016a..a2e177cc74 100644
>--- a/src/misc/picture.c
>+++ b/src/misc/picture.c
>@@ -140,9 +140,11 @@ int picture_Setup( picture_t *p_picture, const
>video_format_t *restrict fmt )
>     width = width / i_modulo_w * i_modulo_w;
>     height = height / i_modulo_h * i_modulo_h;
> 
>+#ifndef NDEBUG /* legacy code, probably not needed anymore */
>     /* Hack: append two scan lines for some SIMD assembler */
>     if (unlikely(add_overflow(height, 2 * i_ratio_h, &height)))
>         return VLC_EGENERIC;
>+#endif
> 
>     /* plane_t uses 'int'. */
>     if (unlikely(width > INT_MAX) || unlikely(height > INT_MAX))
>-- 
>2.16.2
>
>_______________________________________________
>vlc-devel mailing list
>To unsubscribe or modify your subscription options:
>https://mailman.videolan.org/listinfo/vlc-devel

This patch looks like it might cause Heisenbugs.
-- 
Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez excuser ma brièveté.


More information about the vlc-devel mailing list