Hi there,

I just found that recent change in the language to make all global variables thread-local by default. This makes me think of a major performance problem: every thread creation will have to copy all the thread-local variables. This makes it impossible to efficiently spawn many light-weight threads even if they do not make use of the global variables at all.

I guess I am not the first one to spot this problem? I believe that thread creation should come with as little overhead as possible. Maybe a concept of light-weight threads based on side-effect free code could complement the regular threads?

Just a quick idea to throw into discussion...

Greetings,
Norbert

Reply via email to