This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] set -mabi=altivec with -ftree-vectorize
- From: Daniel Jacobowitz <drow at false dot org>
- To: Andrew Pinski <pinskia at gmail dot com>
- Cc: David Edelsohn <dje at watson dot ibm dot com>, Zdenek Dvorak <rakdver at kam dot mff dot cuni dot cz>, gcc-patches at gcc dot gnu dot org
- Date: Tue, 7 Aug 2007 13:00:28 -0400
- Subject: Re: [patch] set -mabi=altivec with -ftree-vectorize
- References: <20070731071457.GB32641@kam.mff.cuni.cz> <20070731110821.GA7127@caradoc.them.org> <200707311202.l6VC2C6U029180@makai.watson.ibm.com> <20070731132042.GA10523@caradoc.them.org> <20070807153553.GA3577@caradoc.them.org> <de8d50360708070858y5e8be32g3a53767c8a537bbf@mail.gmail.com>
On Tue, Aug 07, 2007 at 11:58:11AM -0400, Andrew Pinski wrote:
> The ABI is only difference if you actually use altivec registers or
> VMX sized vectors (except for vector long long which does not
> exist).
That's almost right, but not quite. The required stack alignment
difference is an ABI issue.
> So I think the warning is wrong and will get people confused even
> more. In most cases you only want to compile some parts of the
> program with -maltivec -mabi=altivec and then only call those parts
> when VMX exists. This is very very common in generic programs that
> people compile for PowerPC and allow to run on mutliple pieces of
> hardware. Remember not all users of GCC can provide full different
> versions of their program in an effient manor.
Then they should either use just -maltivec without -mabi=altivec, or
someone should implement support for "don't care" tagging. As things
stand now code can go horribly wrong if the stack does not happen to
be sufficiently aligned.
I wouldn't object to a linker option to suppress the warnings; that's
been suggested before and we may need it on ARM for the -fshort-wchar
tests.
--
Daniel Jacobowitz
CodeSourcery