This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug optimization/14063] New: conditional around vec_dss() call disappears at -O2
- From: "leblanc at skycomputers dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Feb 2004 15:38:59 -0000
- Subject: [Bug optimization/14063] New: conditional around vec_dss() call disappears at -O2
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The problem does NOT occur at lower optimization levels.
Configured with:
../gnu-tool-chain/gcc/configure
--with-cpu=7450
--enable-altivec
--enable-shared
--enable-threads=posix
--enable-languages=c,c++
--disable-checking
--with-system-zlib
--enable-__cxa_atexit
--host=ppc-sky-linux
--target=ppc-sky-linux
--prefix=/usr/local
Thread model: posix
Source mike.c:
#include <altivec.h>
void dstt_bug(int i, int j, char *mem)
{
if (i == 0)
vec_dss(1);
}
Command line:
gcc mike.c -S -O2 -maltivec
No messages; mike.s shows bug:
.file "mike.c"
.section ".text"
.align 2
.globl dstt_bug
.type dstt_bug, @function
dstt_bug:
stwu 1,-16(1)
dss 1
addi 1,1,16
blr
.size dstt_bug, .-dstt_bug
.ident "GCC: (GNU) 3.3"
mike.i:
# 1 "mike.c"
# 1 "<built-in>"
# 1 "<command line>"
# 1 "mike.c"
# 1 "/usr/local/lib/gcc-lib/ppc-sky-linux/3.3/include/altivec.h" 1 3 4
# 52 "/usr/local/lib/gcc-lib/ppc-sky-linux/3.3/include/altivec.h" 3 4
extern int __altivec_link_error_invalid_argument ();
# 2 "mike.c" 2
void dstt_bug(int i, int j, char *mem)
{
if (i == 0)
__builtin_altivec_dss ((1));
}
--
Summary: conditional around vec_dss() call disappears at -O2
Product: gcc
Version: 3.3
Status: UNCONFIRMED
Severity: critical
Priority: P2
Component: optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: leblanc at skycomputers dot com
CC: gcc-bugs at gcc dot gnu dot org
GCC host triplet: ppc-sky-linux
GCC target triplet: ppc-sky-linux
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14063