From cd9ef18564af6cdbd2ab65bb16e184e17aa43702 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Mon, 25 Jan 2016 10:20:14 +0100 Subject: score: Add RTEMS_ALIGNED() --- cpukit/score/include/rtems/score/basedefs.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/cpukit/score/include/rtems/score/basedefs.h b/cpukit/score/include/rtems/score/basedefs.h index 7e282c1883..25f505897d 100644 --- a/cpukit/score/include/rtems/score/basedefs.h +++ b/cpukit/score/include/rtems/score/basedefs.h @@ -235,6 +235,15 @@ #define RTEMS_PACKED #endif +/** + * @brief Instructs the compiler to enforce the specified alignment. + */ +#if defined(__GNUC__) + #define RTEMS_ALIGNED( _alignment ) __attribute__((__aligned__(_alignment))) +#else + #define RTEMS_ALIGNED( _alignment ) +#endif + /* Provided for backward compatibility */ #define RTEMS_COMPILER_PACKED_ATTRIBUTE RTEMS_PACKED -- cgit v1.2.3