gcc 4.0 compiles kernel with altivec

Segher Boessenkool segher at kernel.crashing.org
Fri Feb 18 01:48:39 EST 2005

>>> I can imagine userland apps causing a severe hit on context switch 
>>> time
>>> bcs they all start using altivec and cause the kernel to have to swap
>>> 32x128bits registers... I've been thinking about using vrsave to 
>>> break
>>> the save/restore code into 2 or 4 parts and only save the ones that 
>>> need
>>> to be saved. (It's an ABI thing anyway)
>> Yes, you should definitely do this..
> Yup, will probably do when I have some time, I need to bench the whole
> stuff though.

Last time I benchmarked it (on 970), it was best to test per group of
4 to 8 registers (bigger was worse, smaller was worse).  This was an
artificial benchmark though, real usage patterns might skew the results
a bit.  Anyway, between 4 to 8 the graph was quite flat.


More information about the Linuxppc64-dev mailing list