xlc supports __attribute__((aligned(x))), use it.
authorRafael Espindola <rafael.espindola@gmail.com>
Wed, 31 Oct 2012 00:54:26 +0000 (00:54 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Wed, 31 Oct 2012 00:54:26 +0000 (00:54 +0000)
Patch by Kai.

llvm-svn: 167087

llvm/include/llvm/Support/AlignOf.h

index 22c07d0..d6b0ab8 100644 (file)
@@ -78,7 +78,7 @@ template <size_t Alignment> struct AlignedCharArrayImpl;
   template <> struct AlignedCharArrayImpl<x> { \
     char alignas(x) aligned; \
   }
-#elif defined(__GNUC__)
+#elif defined(__GNUC__) || defined(__IBM_ATTRIBUTES)
 #define LLVM_ALIGNEDCHARARRAY_TEMPLATE_ALIGNMENT(x) \
   template <> struct AlignedCharArrayImpl<x> { \
     char aligned __attribute__((aligned(x))); \