[FFmpeg-devel] [PATCH] avutil/ppc/cpu: Fix power8 linux detection

Lauri Kasanen cand at gmx.com
Thu Jan 10 19:21:06 EET 2019


On Thu, 10 Jan 2019 18:09:21 +0100
Carl Eugen Hoyos <ceffmpeg at gmail.com> wrote:

> >> > -                goto out;
> >>
> >> This seems like an unrelated change.
> >
> > It's necessary. HWCAP appears before HWCAP2 in the array, so if the
> > code jumps out in HWCAP, it never gets to checking the CAP2 bits like
> > power8.
> 
> The next line (that I unfortunately cut) is:
> } else if (buf[i] == AT_HWCAP2) {
> indicating afaict that it is only reached if buf[i] is not equal
> to HWCAP.
> What do I miss?

The surrounding context is a loop over all bytes:
for (i = 0; i < count / sizeof(*buf); i += 2) {

While the out: label is after the loop.

- Lauri


More information about the ffmpeg-devel mailing list