diff options
author | Ramiro Polla <ramiro.polla@gmail.com> | 2007-08-13 15:28:29 +0000 |
---|---|---|
committer | Ramiro Polla <ramiro.polla@gmail.com> | 2007-08-13 15:28:29 +0000 |
commit | 5e4c7ca224417902dd714f4f50500b36b8c89148 (patch) | |
tree | c9fdb0713c75ea36467a645f9cafc67549e1b754 /libavutil/internal.h | |
parent | 345bb2ad90f845e004ccef49dec8fa183576eeaa (diff) | |
download | ffmpeg-5e4c7ca224417902dd714f4f50500b36b8c89148.tar.gz |
Add attribute that forces alignment of stack to functions that need it.
Necessary for systems that don't align by default to 16 bytes, required by some
SSE instructions.
Requires GCC >= 4.2.
Based on patch by Gaƫl Chardon.
Originally committed as revision 10106 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavutil/internal.h')
-rw-r--r-- | libavutil/internal.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libavutil/internal.h b/libavutil/internal.h index e8dc72ef85..337f297083 100644 --- a/libavutil/internal.h +++ b/libavutil/internal.h @@ -34,6 +34,14 @@ #include <stddef.h> #include <assert.h> +#ifndef attribute_align_arg +#if defined(__GNUC__) && (__GNUC__ > 4 || __GNUC__ == 4 && __GNUC_MINOR__>1) +# define attribute_align_arg __attribute__((force_align_arg_pointer)) +#else +# define attribute_align_arg +#endif +#endif + #ifndef attribute_used #if defined(__GNUC__) && (__GNUC__ > 3 || __GNUC__ == 3 && __GNUC_MINOR__ > 0) # define attribute_used __attribute__((used)) |