This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/15795] New: Strange bug / incorrect code generation with SSE
- From: "ma1flfs at bath dot ac dot uk" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Jun 2004 14:36:46 -0000
- Subject: [Bug c++/15795] New: Strange bug / incorrect code generation with SSE
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The following test program, when compiled with
g++ -O2 -march=pentium4 -msse
will segfault, at least on the machines I tried it on:
* Pentium III (Katmai)
* Intel(R) Pentium(R) 4 CPU 3.00GHz
* Intel(R) Xeon(TM) CPU 2.40GHz
When allocating fewer vectors, it sometimes works. Oh, and it also fails with
intels own compiler...
#include <xmmintrin.h>
#include <stdio.h>
class Vector4
{
public:
Vector4() { vec = _mm_setzero_ps(); }
__m128 vec;
};
int main(int argc, char **argv)
{
Vector4 *foo = new Vector4[200*200];
delete foo;
}
--
Summary: Strange bug / incorrect code generation with SSE
Product: gcc
Version: 3.3.3
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: ma1flfs at bath dot ac dot uk
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: i686-pc-linux-gnu
GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15795