Does altivec work on biarch compiler for gcc 3.3.3-hammer?

Segher Boessenkool segher at
Mon Apr 26 17:39:17 EST 2004

> Does altivec work with gcc 3.3.3 hammer?


> I'm building  with -maltivec and -mabi=altivec but it does not seem to
> work
> for simple programs.  For instance,
> 	printf("%vc",(vector unsigned char) {'h','e','l','l','o'});

Not valid code.  A vector initializer has either one, or exactly
the correct number of elements (i.e., for char, 16 elts).

> Will print:
>  	%vc

glibc doesn't support vector printf extensions.  Political issue.

> Here is how I am building:
> 	gcc -maltivec -mabi=altivec -mcpu=970 -mtune=970 testy.c

-mtune is redundant; looks fine otherwise.


** Sent via the linuxppc64-dev mail list. See

More information about the Linuxppc64-dev mailing list