Revision ccf22d3e libavcodec/ppc/dsputil_ppc.c

View differences:

libavcodec/ppc/dsputil_ppc.c
23 23
#include "libavcodec/dsputil.h"
24 24
#include "dsputil_altivec.h"
25 25

  
26
int mm_support(void)
27
{
28
    int result = 0;
29
#if HAVE_ALTIVEC
30
    if (has_altivec()) {
31
        result |= AV_CPU_FLAG_ALTIVEC;
32
    }
33
#endif /* result */
34
    return result;
35
}
36

  
37 26
/* ***** WARNING ***** WARNING ***** WARNING ***** */
38 27
/*
39 28
clear_blocks_dcbz32_ppc will not work properly on PowerPC processors with a
......
179 168
#if HAVE_ALTIVEC
180 169
    if(CONFIG_H264_DECODER) dsputil_h264_init_ppc(c, avctx);
181 170

  
182
    if (has_altivec()) {
171
    if (mm_support() & AV_CPU_FLAG_ALTIVEC) {
183 172
        dsputil_init_altivec(c, avctx);
184 173
        if(CONFIG_VC1_DECODER)
185 174
            vc1dsp_init_altivec(c, avctx);

Also available in: Unified diff