Message ID | 20170217102412.18872-1-hugo@beauzee.fr |
---|---|
State | New |
Headers | show |
2017-02-17 11:24 GMT+01:00 Hugo Beauzée-Luyssen <hugo@beauzee.fr>:
> The function is not defined when building for x86_64
But it is declared unconditionally.
How can the issue you are trying to fix be reproduced?
Why is this the only occurrence?
Carl Eugen
On Fri, Feb 17, 2017, at 11:50 AM, Carl Eugen Hoyos wrote: > 2017-02-17 11:24 GMT+01:00 Hugo Beauzée-Luyssen <hugo@beauzee.fr>: > > The function is not defined when building for x86_64 > > But it is declared unconditionally. > > How can the issue you are trying to fix be reproduced? > Why is this the only occurrence? > > Carl Eugen Hi, This problem arose while building VLC for Android-x86_64. I'm quite convinced there is a similar issue for VP8, but we don't use that module in our builds. It could be a good idea to conditionally declare the function as well indeed. Regards,
2017-02-17 11:56 GMT+01:00 Hugo Beauzée-Luyssen <hugo@beauzee.fr>: > On Fri, Feb 17, 2017, at 11:50 AM, Carl Eugen Hoyos wrote: >> 2017-02-17 11:24 GMT+01:00 Hugo Beauzée-Luyssen <hugo@beauzee.fr>: >> > The function is not defined when building for x86_64 >> >> But it is declared unconditionally. >> >> How can the issue you are trying to fix be reproduced? >> Why is this the only occurrence? >> >> Carl Eugen > > Hi, > > This problem arose while building VLC for Android-x86_64. How can we reproduce the issue? > I'm quite convinced there is a similar issue for VP8, but we don't use > that module in our builds. You also disable huffyuv? > It could be a good idea to conditionally declare the function as well > indeed. I would prefer not to add more conditionals to the files and I wonder why this issue triggers only in this file for you - dead code elimination is needed in many places when compiling FFmpeg. Carl Eugen
On Fri, Feb 17, 2017 at 11:56 AM, Hugo Beauzée-Luyssen <hugo@beauzee.fr> wrote: > On Fri, Feb 17, 2017, at 11:50 AM, Carl Eugen Hoyos wrote: >> 2017-02-17 11:24 GMT+01:00 Hugo Beauzée-Luyssen <hugo@beauzee.fr>: >> > The function is not defined when building for x86_64 >> >> But it is declared unconditionally. >> >> How can the issue you are trying to fix be reproduced? >> Why is this the only occurrence? >> >> Carl Eugen > > Hi, > > This problem arose while building VLC for Android-x86_64. > I'm quite convinced there is a similar issue for VP8, but we don't use > that module in our builds. > It could be a good idea to conditionally declare the function as well > indeed. There is already a condition that will exclude actually using the function on x86_64, and all our regular builds pass just fine. Note that FFmpeg currently relies on DCE (Dead Code Eliminiation) to strip references to unused functions, like in this case, so if your build system doesn't provide DCE, then FFmpeg build can and will fail. - Hendrik
diff --git a/libavcodec/x86/rv34dsp_init.c b/libavcodec/x86/rv34dsp_init.c index 7310122458..116beb31fc 100644 --- a/libavcodec/x86/rv34dsp_init.c +++ b/libavcodec/x86/rv34dsp_init.c @@ -35,8 +35,10 @@ av_cold void ff_rv34dsp_init_x86(RV34DSPContext* c) { int cpu_flags = av_get_cpu_flags(); - if (ARCH_X86_32 && EXTERNAL_MMX(cpu_flags)) +#if ARCH_X86_32 + if (EXTERNAL_MMX(cpu_flags)) c->rv34_idct_dc_add = ff_rv34_idct_dc_add_mmx; +#endif if (EXTERNAL_MMXEXT(cpu_flags)) { c->rv34_inv_transform_dc = ff_rv34_idct_dc_noround_mmxext; c->rv34_idct_add = ff_rv34_idct_add_mmxext;