[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: TLS support [was Re: Unidentified subject!]



Hi,

On Mon, 21 May 2007, Brad Boyer wrote:

> I'd like to avoid following in the footsteps of the i386 style support
> particularly because it does require more extensive kernel support than
> most of the other architectures. I'm still looking over the documentation
> and the implementation details of the other architectures, but I'll put
> something together as a proposal before I write any code.

I think there are two possible approaches. As you know we need per thread 
data. This can either be in a register, which would be the fastest option, 
but our current ABI doesn't define one, so it basically means an ABI 
change to reserve a register for it so it doesn't get clobbered.
The other possibility is to use a memory location, this requires kernel 
support to update the memory pointer at every task switch (we don't have 
SMP, so it's a lot easier), but it has the advantage that it's otherwise 
backwards compatible.
IMO the simpler option in the short term is via a memory pointer, an ABI 
change needs a lot more preparation (although it's desirable in the long 
term to also fix other things).

bye, Roman



Reply to: