Mercurial > libavcodec.hg
comparison ppc/dsputil_altivec.c @ 2068:4a0ec9031804 libavcodec
hadamard/AltiVec: fix to compiler fix, again by (Romain Dolbeau <dolbeau at irisa dot fr>)
author | michael |
---|---|
date | Tue, 08 Jun 2004 02:41:41 +0000 |
parents | 4c663228e020 |
children | 0f937b191cc3 |
comparison
equal
deleted
inserted
replaced
2067:f37b6ffc81ed | 2068:4a0ec9031804 |
---|---|
1300 | 1300 |
1301 POWERPC_PERF_STOP_COUNT(altivec_put_no_rnd_pixels16_xy2_num, 1); | 1301 POWERPC_PERF_STOP_COUNT(altivec_put_no_rnd_pixels16_xy2_num, 1); |
1302 #endif /* ALTIVEC_USE_REFERENCE_C_CODE */ | 1302 #endif /* ALTIVEC_USE_REFERENCE_C_CODE */ |
1303 } | 1303 } |
1304 | 1304 |
1305 #if (__GNUC__ * 100 + __GNUC_MINOR__ * 10 >= 330) | 1305 #ifdef CONFIG_DARWIN |
1306 int hadamard8_diff8x8_altivec(/*MpegEncContext*/ void *s, uint8_t *dst, uint8_t *src, int stride, int h){ | 1306 int hadamard8_diff8x8_altivec(/*MpegEncContext*/ void *s, uint8_t *dst, uint8_t *src, int stride, int h){ |
1307 POWERPC_PERF_DECLARE(altivec_hadamard8_diff8x8_num, 1); | 1307 POWERPC_PERF_DECLARE(altivec_hadamard8_diff8x8_num, 1); |
1308 int sum; | 1308 int sum; |
1309 POWERPC_PERF_START_COUNT(altivec_hadamard8_diff8x8_num, 1); | 1309 POWERPC_PERF_START_COUNT(altivec_hadamard8_diff8x8_num, 1); |
1310 register const_vector unsigned char vzero = (const_vector unsigned char)vec_splat_u8(0); | 1310 register const_vector unsigned char vzero = (const_vector unsigned char)vec_splat_u8(0); |
1610 score += hadamard8_diff16x8_altivec(s, dst, src, stride, 8); | 1610 score += hadamard8_diff16x8_altivec(s, dst, src, stride, 8); |
1611 } | 1611 } |
1612 POWERPC_PERF_STOP_COUNT(altivec_hadamard8_diff16_num, 1); | 1612 POWERPC_PERF_STOP_COUNT(altivec_hadamard8_diff16_num, 1); |
1613 return score; | 1613 return score; |
1614 } | 1614 } |
1615 #endif // GCC >= 3.3 | 1615 #endif //CONFIG_DARWIN |
1616 | 1616 |
1617 int has_altivec(void) | 1617 int has_altivec(void) |
1618 { | 1618 { |
1619 #ifdef CONFIG_DARWIN | 1619 #ifdef CONFIG_DARWIN |
1620 int sels[2] = {CTL_HW, HW_VECTORUNIT}; | 1620 int sels[2] = {CTL_HW, HW_VECTORUNIT}; |