diff options
author | Ramiro Polla <ramiro.polla@gmail.com> | 2009-07-09 02:20:29 +0000 |
---|---|---|
committer | Ramiro Polla <ramiro.polla@gmail.com> | 2009-07-09 02:20:29 +0000 |
commit | 16c2e21488b0da96b445ea4b098b389ca4ef0943 (patch) | |
tree | d4506a68acde750c7042558669ff04fe3d7d0c68 /libavutil/mem.h | |
parent | 4b2be143cd5ab216c6a7ebd8715b732169077e5d (diff) | |
download | ffmpeg-16c2e21488b0da96b445ea4b098b389ca4ef0943.tar.gz |
Move DECLARE_ALIGNED and DECLARE_ASM_CONST back from lavu/internal.h to
lavu/mem.h.
Originally committed as revision 19384 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavutil/mem.h')
-rw-r--r-- | libavutil/mem.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/libavutil/mem.h b/libavutil/mem.h index fe18561e0e..37ba276d08 100644 --- a/libavutil/mem.h +++ b/libavutil/mem.h @@ -28,6 +28,21 @@ #include "common.h" +#if defined(__ICC) || defined(__SUNPRO_C) + #define DECLARE_ALIGNED(n,t,v) t v __attribute__ ((aligned (n))) + #define DECLARE_ASM_CONST(n,t,v) const t __attribute__ ((aligned (n))) v +#elif defined(__GNUC__) + #define DECLARE_ALIGNED(n,t,v) t v __attribute__ ((aligned (n))) + #define DECLARE_ASM_CONST(n,t,v) static const t v attribute_used __attribute__ ((aligned (n))) +#elif defined(_MSC_VER) + #define DECLARE_ALIGNED(n,t,v) __declspec(align(n)) t v + #define DECLARE_ASM_CONST(n,t,v) __declspec(align(n)) static const t v +#else + #define DECLARE_ALIGNED(n,t,v) t v + #define DECLARE_ASM_CONST(n,t,v) static const t v +#endif + + #if AV_GCC_VERSION_AT_LEAST(3,1) #define av_malloc_attrib __attribute__((__malloc__)) #else |