X-Git-Url: http://git.sourceforge.jp/view?a=blobdiff_plain;f=include%2Fansidecl.h;h=c19955a98a677f66dc9bf5e54291ac0f3aa3efff;hb=8026444e747c8a63b393bf3f74a49f1d572efbe3;hp=a1a765d63f32b82ea8e4af411d7b89d2f1a250ad;hpb=91fc5678cae1e7421e46e1e0af32c91a41b65aa1;p=pf3gnuchains%2Fgcc-fork.git diff --git a/include/ansidecl.h b/include/ansidecl.h index a1a765d63f3..c19955a98a6 100644 --- a/include/ansidecl.h +++ b/include/ansidecl.h @@ -361,6 +361,28 @@ So instead we use the macro below and test it against specific values. */ # endif /* GNUC >= 3.0 */ #endif /* ATTRIBUTE_ALIGNED_ALIGNOF */ +/* Useful for structures whose layout must much some binary specification + regardless of the alignment and padding qualities of the compiler. */ +#ifndef ATTRIBUTE_PACKED +# define ATTRIBUTE_PACKED __attribute__ ((packed)) +#endif + +/* Attribute `hot' and `cold' was valid as of gcc 4.3. */ +#ifndef ATTRIBUTE_COLD +# if (GCC_VERSION >= 4003) +# define ATTRIBUTE_COLD __attribute__ ((__cold__)) +# else +# define ATTRIBUTE_COLD +# endif /* GNUC >= 4.3 */ +#endif /* ATTRIBUTE_COLD */ +#ifndef ATTRIBUTE_HOT +# if (GCC_VERSION >= 4003) +# define ATTRIBUTE_HOT __attribute__ ((__hot__)) +# else +# define ATTRIBUTE_HOT +# endif /* GNUC >= 4.3 */ +#endif /* ATTRIBUTE_HOT */ + /* We use __extension__ in some places to suppress -pedantic warnings about GCC extensions. This feature didn't work properly before gcc 2.8. */