Re: AES assembler optimizations

From: Bill Davidsen
Date: Thu Aug 12 2004 - 15:18:12 EST


David S. Miller wrote:

On sparc64, we:

1) Always save the full FPU state at context switch time if it
is active.

2) On entry to a FPU-using kernel routine, we save the FPU if
it is active.

3) On exit from a FPU-using kernel routine, we do nothing
except mark the FPU as inactive.

4) FPU-disabled traps by the user restore the state saved
by #1 or #2

Depending on the cost saving of not saving the registers if they haven't changed, vs. the time to take the trap and set the FPU active again, it might be a win overall, even if you never used FPU in the kernel. Wasn't there a change between saving everything and saving FPU only when used "back when?" I seem to remember something about that, and the cost of the test vs. the cost of just doing the save.

--
-bill davidsen (davidsen@xxxxxxx)
"The secret to procrastination is to put things off until the
last possible moment - but no longer" -me
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/