Re: Linux Jobs as of 2.3.99pre6-5

From: Richard B. Johnson (
Date: Tue Apr 25 2000 - 07:25:17 EST

On 24 Apr 2000, Ulrich Drepper wrote:

> Alan Cox <> writes:
> > To Do
> > -----
> Do you want to add:
> fix kernel handling of %fs and %gs registers on x86
> ?? It's preventing major optimizations in the thread library.

Previously, no kernel code I've seen used these registers so they are
never touched during a context-switch. If these are now used by the C
compiler, it is the responsibility of that compiler to preserve the
segment registers in its code generation so a potential problem has
been overlooked.

If a kernel procedure sleeps after the 'C' code has modified these
registers, but before they are restored, the task(s) that get the CPU will
have invalid registers. So I think the time has come to eat the few
machine cycles necessary to save and restore these registers.

Dick Johnson

Penguin : Linux version 2.3.41 on an i686 machine (800.63 BogoMips).

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

This archive was generated by hypermail 2b29 : Sun Apr 30 2000 - 21:00:09 EST