Compile the below with gcc chelper-exploit.c -c -O -fforce-mem -msse : typedef int v4sf __attribute__ ((mode(V4SF))); void cprocess(v4sf* d_r) { v4sf force= -(*d_r); } And the compiler (cc1) will try to allocate all memory. Problem disappears with removing the '-', or by switching to 3.3.3 or to the SSA branche, by removing -O or removing -fforce-mem, by removing -msse
Confirmed, here is an example which is happens even on the tree-ssa: typedef int v4sf __attribute__ ((mode(V4SF))); v4sf cprocess(v4sf* d_r) { v4sf force= -(*d_r); return force; }
Richard -- As the IA32 maintainer, would you please look at this? Tnanks, -- Mark
Patch in progress.
Subject: Bug 15193 CVSROOT: /cvs/gcc Module name: gcc Changes by: rth@gcc.gnu.org 2004-06-07 17:21:07 Modified files: gcc : ChangeLog expmed.c gcc/config/i386: i386.md Log message: PR rtl-opt/15193 * expmed.c (extract_bit_field): Fix vector_extract return. * config/i386/i386.md (negv4sf2): New pattern. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.3861&r2=2.3862 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/expmed.c.diff?cvsroot=gcc&r1=1.160&r2=1.161 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/i386/i386.md.diff?cvsroot=gcc&r1=1.541&r2=1.542
Subject: Bug 15193 CVSROOT: /cvs/gcc Module name: gcc Branch: gcc-3_4-branch Changes by: rth@gcc.gnu.org 2004-06-07 18:09:13 Modified files: gcc : ChangeLog expmed.c Log message: PR rtl-opt/15193 * expmed.c (extract_bit_field): Fix vector_extract return. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=2.2326.2.472&r2=2.2326.2.473 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/expmed.c.diff?cvsroot=gcc&only_with_tag=gcc-3_4-branch&r1=1.148.4.1&r2=1.148.4.2
Fixed.