[x264-devel] [PATCH 1/1] aarch64: fix x264_mbtree_propagate_cost_neon

Martin Storsjö martin at martin.st
Thu Sep 3 08:14:01 CEST 2015


On Thu, 3 Sep 2015, Janne Grunau wrote:

> The branch conditon caused the loop to execute one time more than
> intended. Detected by a memory corruption on arm with the 1 to 1 port of
> the function.
> ---
> common/aarch64/mc-a.S | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/common/aarch64/mc-a.S b/common/aarch64/mc-a.S
> index faec277..f448bf5 100644
> --- a/common/aarch64/mc-a.S
> +++ b/common/aarch64/mc-a.S
> @@ -1556,7 +1556,7 @@ function x264_mbtree_propagate_cost_neon, export=1
>     sqxtn       v0.4h,  v20.4s
>     sqxtn2      v0.8h,  v21.4s
>     st1         {v0.8h},  [x0], #16
> -    b.ge        8b
> +    b.gt        8b
>     ret
> endfunc
>
> -- 
> 2.5.0

LGTM, thanks for finding!

// Martin


More information about the x264-devel mailing list