Qt, GCC, SSE and stack alignment
问题 I'm trying to make a program compiled with GCC and using Qt and SSE intrinsics. It seems that when one of my functions is called by Qt, the stack alignment is not preserved. Here's a short example to illustrate what I mean : #include <cstdio> #include <emmintrin.h> #include <QtGui/QApplication.h> #include <QtGui/QWidget.h> class Widget: public QWidget { public: void paintEvent(QPaintEvent *) { __m128 a; printf("a: 0x%08x\n", ((void *) &a)); } }; int main(int argc, char** argv) { QApplication