[gstreamer-bugs] [Bug 320820] Investigate on the usage of -DRUNTIME_CPUDETECT

GStreamer (bugzilla.gnome.org) bugzilla-daemon at bugzilla.gnome.org
Sun Nov 13 08:20:05 PST 2005


Do not reply to this via email (we are currently unable to handle email
responses and they get discarded).  You can add comments to this bug at
http://bugzilla.gnome.org/show_bug.cgi?id=320820
 GStreamer | gst-ffmpeg | Ver: 0.8.x





------- Additional Comments From Loïc Minier  2005-11-13 16:20 -------
Please correct me if I'm wrong, but this seems pretty useful in 
libavcodec/libpostproc/postprocess.c:
#ifdef RUNTIME_CPUDETECT
#if defined(ARCH_X86) || defined(ARCH_X86_64)
...
#else
#ifdef ARCH_POWERPC
#ifdef HAVE_ALTIVEC
        if(c->cpuCaps & PP_CPU_CAPS_ALTIVEC)
                postProcess_altivec(src, srcStride, dst, dstStride, width,
height, QPs, QPStride, isColor, c);
        else
#endif
#endif
                postProcess_C(src, srcStride, dst, dstStride, width, height,
QPs, QPStride, isColor, c);
#endif
#else //RUNTIME_CPUDETECT
#ifdef HAVE_MMX2
...
#elif defined (HAVE_ALTIVEC)
        postProcess_altivec(src, srcStride, dst, dstStride, width, height, QPs,
QPStride, isColor, c);
...
#endif //!RUNTIME_CPUDETECT

I understand that as:
- if you build with HAVE_ALTIVEC, then Altivec will be used if run on PPC
- if you build with HAVE_ALTIVEC and RUNTIME_CPUDETECT, then Altivec will be
used if available

I agree that RUNTIME_CPUDETECT is not widely used, but it seems quite useful for
precisely for Altivec.

Bye,

------- You are receiving this mail because: -------
You are the assignee for the bug.
You are the QA contact for the bug.




More information about the Gstreamer-bugs mailing list