diff options
author | wm4 <wm4@nowhere> | 2014-04-19 17:09:24 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-04-19 17:10:56 +0200 |
commit | 0cff5836c3f410136e3fdb3e2f9e24bb81dd9a87 (patch) | |
tree | 04d756999fb23a8fc83b161c950facce1fc30f8d /video/filter | |
parent | 061c7eba9770ca5f29dd3c0e5b64a276feca30cc (diff) | |
download | mpv-0cff5836c3f410136e3fdb3e2f9e24bb81dd9a87.tar.bz2 mpv-0cff5836c3f410136e3fdb3e2f9e24bb81dd9a87.tar.xz |
Remove CPU detection and inline asm handling
Not needed anymore. I'm not opposed to having asm, but inline asm is too
much of a pain, and it was planned long ago to eventually get rid fo all
inline asm uses.
For the note, the inline asm use that was removed with the previous
commits was almost worthless. It was confined to video filters, and most
video filtering is now done with libavfilter. Some mpv filters (like
vf_pullup) actually redirect to libavfilter if possible.
If asm is added in the future, it should happen in the form of external
files.
Diffstat (limited to 'video/filter')
-rw-r--r-- | video/filter/vf_divtc.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/video/filter/vf_divtc.c b/video/filter/vf_divtc.c index 869d7462d1..8e21df1f82 100644 --- a/video/filter/vf_divtc.c +++ b/video/filter/vf_divtc.c @@ -21,6 +21,7 @@ #include <string.h> #include <limits.h> #include <math.h> +#include <stdint.h> #include "config.h" #include "common/msg.h" @@ -97,13 +98,15 @@ static unsigned int checksum_plane(unsigned char *p, unsigned char *z, } */ +#define FAST_64BIT (UINTPTR_MAX >= UINT64_MAX) + static unsigned int checksum_plane(unsigned char *p, unsigned char *z, int w, int h, int s, int zs, int arg) { unsigned int shift; uint32_t sum, t; unsigned char *e, *e2; -#if HAVE_FAST_64BIT +#if FAST_64BIT typedef uint64_t wsum_t; #else typedef uint32_t wsum_t; @@ -118,7 +121,7 @@ static unsigned int checksum_plane(unsigned char *p, unsigned char *z, for(wsum=0, e2=e-sizeof(wsum_t)+1; p<e2; p+=sizeof(wsum_t)) wsum^=*(wsum_t *)p; -#if HAVE_FAST_64BIT +#if FAST_64BIT t=be2me_32((uint32_t)(wsum>>32^wsum)); #else t=be2me_32(wsum); |