Re: MMX stuff..

Zach (
Sun, 2 Feb 1997 15:47:08 -0800 (PST)

On Sun, 2 Feb 1997, Illuminati Primus wrote:

> I wonder.. how fast would linux be if it was optimized for MMX? Will GCC
> support MMX optimizations sometime? I have been thinking it could
> probably speed up checksumming and other repetitive calculations.. Or
> maybe I'm misinformed?

as far as the ip checksum routine goes, it seems pretty useless. the mmx
can do a boatload byte/word sized adds, but it just discards the carry so
lots of trickery would be done to get it to work. then there is the
overhead of actually loading the data to be checksummed into the
registers.. has anyone come up with some neat tricks for this?

On Sun, 2 Feb 1997, Phillip G Ezolt wrote:

> What kind of performance hit will linux take using MMX?
> >From what I understand, everytime you switch between MMX mode and regular
> FP mode, 100 or so cycles are burned. If you are context switching
> alot (any multitasking enviornment), this would seem to add up. Or is
> it insignifcant to the amount time required for a context switch?

i might be understanding things wrong, but i thought it only did a fpu
load/restore when a task tried to use the fpu and someone else had used it
more recently. isn't there a specific exception for using the floating
point when it wasn't your turn so you don't have to do it with every
context switch?

but you're right on some level.. if you had a process doing mmx and fpu
things at the same time, things get real ugly. i think having two
different processes, one doing fpu and one doing mmx would be the same as
having two doing fpu.

someone feel free to correct me if i'm totally confused..

-- zach