I've made a patch along these lines (enclosed). Change log: * gcc/config/i386/i386.c: Use DEFAULT_TLS_SEG_REG to access TLS * gcc/config/i386/i386.h: Define default segment register for TLS * gcc/config/i386/rdos.h: Added TLS configuration for RDOS
Regards, Leif Ekblad----- Original Message ----- From: "Uros Bizjak" <[email protected]>
To: "Michael Matz" <[email protected]> Cc: <[email protected]>; "Leif Ekblad" <[email protected]> Sent: Tuesday, May 14, 2013 11:35 AM Subject: Re: Using GS for TLS on x86-64 for target RDOS
On Tue, May 14, 2013 at 11:13 AM, Michael Matz <[email protected]> wrote:On Tue, 14 May 2013, Uros Bizjak wrote:I'd propose to introduce: a) #define DEFAULT_TLS_SEG_REG in i386.h to SEG_GS b) #undef and #define DEFAULT_TLS_SEG_REG in x86-64.h to SEG_FSThis would break -m32.Uh, yes. So instead of a) and b), there should be: #define DEFAULT_TLS_SEG_REG TARGET_64BIT ? SEG_FS : SEG_GS in i386.h. Uros.
gcc-tls.diff
Description: Binary data
