Same problem for -0s/-02 version 4.1.0 etc...
[Code] typedef unsigned * ptr_t; void f (void) { ptr_t p = (ptr_t)0xFED0; p[0] = 0xDEAD; p[2] = 0xDEAD; p[4] = 0xDEAD; p[6] = 0xDEAD; } [Assembly generated by version gcc-4.3-20071005] 00000000 <f>: 0: 3404dead li a0,0xdead 4: 3402fee8 li v0,0xfee8 8: 3403fed0 li v1,0xfed0 c: ac440000 sw a0,0(v0) 10: ac640000 sw a0,0(v1) 14: 3402fed8 li v0,0xfed8 18: 3403fee0 li v1,0xfee0 1c: ac440000 sw a0,0(v0) 20: 03e00008 jr ra 24: ac640000 sw a0,0(v1) [Assembly generated by version 3.4.5 (seems better)] 00000000 <f>: 0: 3403fed0 li v1,0xfed0 4: 3402dead li v0,0xdead 8: ac620018 sw v0,24(v1) c: ac620000 sw v0,0(v1) 10: ac620008 sw v0,8(v1) 14: 03e00008 jr ra 18: ac620010 sw v0,16(v1) 1c: 00000000 nop [Version] Using built-in specs. Target: mips-elf Configured with: ../gcc-4.3-20071005/configure --enable-languages=c,c++ --prefix=/auto/mipaproj/fshvaige/apps/Linux/gcc-4.3-20071005 --target=mips-elf --program-suffix=.mips --without-headers --with-newlib Thread model: single gcc version 4.3.0 20071005 (experimental) (GCC) [Command line options] gcc.mips -c -o main.o -v -save-temps -O3 -march=mips64 -mabi=eabi -mexplicit-relocs main.c -- Summary: regression, missing optimization on const addr area store Product: gcc Version: 4.3.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: fshvaige at cisco dot com GCC build triplet: i686-pc-linux-gnu GCC host triplet: i686-pc-linux-gnu GCC target triplet: mips-elf http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33699