Green threads - some experience

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

 



Ian Rogers wrote:

> The AWT peer problems were caused primarily by pthread mechanisms being 
> used by GTK. These are wrapped in a library called gthreads. A Java 
> thread would:
> 1) enter some native code that acquired a pthread mutex
> 2) call back into the JVM
> 3) the JVM would switch Java thread
> 4) the Java thread would call code that required the original mutex and 
> block in native code not allowing other threads to get scheduled

Hi, why didn't you modify GTK instead? Calling back into the JVM (with 
unpredictable consequences) whilst holding a pthread mutex is a bad idea.

Cheers,

Dave



[Index of Archives]     [Linux Kernel]     [Linux Cryptography]     [Fedora]     [Fedora Directory]     [Red Hat Development]

  Powered by Linux