https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65122
Bug ID: 65122
Summary: std::vector doesn't honor element alignment
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: jacob.benoit.1 at gmail dot com
Created attachment 34807
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=34807&action=edit
testcase
Even in C++11 mode, even with the C++11 alignas keyword, element alignment
isn't honored by std::vector.
$ g++ vectoralign.cpp -o a --std=c++11 && ./a
ctor 0x2422010
ctor 0x2422050
Tested with a freshly built GCC 4.9.2 on Ubuntu x86-64.
Attaching testcase.
Note: this is morphing bug 53900.