This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Segfault with SSE builtins
- From: Jan Hubicka <jh at suse dot cz>
- To: Ross Smith <r-smith at ihug dot co dot nz>
- Cc: gcc at gcc dot gnu dot org
- Date: Wed, 10 Jul 2002 18:16:13 +0200
- Subject: Re: Segfault with SSE builtins
- References: <200207110353.04917.r-smith@ihug.co.nz>
> I've been trying to get the builtin functions corresponding to SSE
> instructions to work, and I keep getting segfaults on any code that
> uses them. Example:
>
> typedef float v4sf __attribute__ ((mode(V4SF)));
> int main() {
> v4sf u, v, w;
> w = __builtin_ia32_addps(u, v);
> return 0;
> }
Most likely your runtime is broken and misaligns the entry stack for
main.
GCC aligns the outgoing stacks, but does not align the frame of main, so
you need to use the vector types only in other functions.
Honza