[MPlayer-dev-eng] altivec patch 1/5: missing vec_splat in vec_clip

Alan Curry pacman at TheWorld.com
Thu Feb 9 08:20:02 CET 2006


Luca Barbato writes the following:
>
>Alan Curry wrote:
>>   (vector signed short)AVV_SPLAT((short)1)
>> which doesn't look like much of an advantage.
>
>use typeof in clip and we are almost done probably.

OK, vec_clip takes a vector argument, so typeof() that argument gets us
"vector signed short". We need to somehow extract just the "short" part for
use inside the AVV_SPLAT macro. How?

Also, the __builtin_* functions aren't very stable between gcc versions.
3.3 has __altivec_link_error_invalid_argument()
3.4 has __builtin_altivec_compiletime_error("func_name")

Have you seen what AVV_SPLAT(256) does? lots of warnings about that 256 being
too big for a char constant, even though those branches of the expression
aren't actually used, it still complains about them.




More information about the MPlayer-dev-eng mailing list