Fix PR6910.

Limit alignment in SmallVector 8, otherwise GCC assumes 16 byte alignment.
opetaror new, and malloc only return 8-byte aligned memory on 32-bit Linux,
which cause a crash if code is compiled with -O3 (or -ftree-vectorize) and some
SmallVector code is vectorized.

llvm-svn: 102604
This commit is contained in:
Torok Edwin 2010-04-29 06:43:12 +00:00
parent 923679f929
commit 63dd86352e
1 changed files with 1 additions and 1 deletions

View File

@ -59,7 +59,7 @@ protected:
// number of union instances for the space, which guarantee maximal alignment.
struct U {
#ifdef __GNUC__
char X __attribute__((aligned));
char X __attribute__((aligned(8)));
#else
union {
double D;