is this an appropriate use of the "target-specific builtin #defines"?

Jonathan Wilson jonwil@tpgi.com.au
Tue Oct 21 06:38:00 GMT 2003


Basicly, on win32, __declspec(thread) says "this variable is Thread Specific".
GCC uses __thread in exactly the same way.

Now I have been informed that making __declspec(thread) do the right thing 
inside the parser (so that it works as expected) is difficult.

What I want to do (to make things easy) is to add a builtin #define like this:
#define __declspec(thread) __thread
That way, we avoid all the messy stuff in the parser (which is not a good 
idea so close to branch for 1.4 (I am trying to avoid changes to non-i386 
bits in the hope that the changes are "small enough" to get into 3.4)




More information about the Gcc mailing list