User-Agent: Mozilla/5.0 (BeOS; U; BeOS BePC; en-US; rv:1.8b) Gecko/20050212 Firefox/1.0+ Build Identifier: nsAppShell and nsToolkit uses a sync-semaphore to halt and wake up threads that wants to do work in the GUI-thread. This is slow and there is no guarantee the thread whose work was just processed is the one woken up. Instead I suggest we pass the thread id in the call and then suspend the thread. When the work is processed the GUI-thread wakes it up with a resume_thread. Patch in progress. Reproducible: Always
Created attachment 174144 [details] [diff] [review] Old patch, until I've made the real one. Should work though.
Created attachment 174148 [details] [diff] [review] Cleaned up patch Tried to clean it up a little.
Created attachment 174150 [details] [diff] [review] Spotted some formatting things. r?
Some of the changes are in unreachable nsToolkit-code, but I have a feeling I'm going to do some work there soon :)
Created attachment 174151 [details] [diff] [review] xpcom/threads/plevent.c did actually know about this too Fixed the types in plevent.c
Comment on attachment 174150 [details] [diff] [review] Spotted some formatting things. Works great. r=sergei_d
As there is a small change in xpcom now I'm switching to xpcom-component.
Comment on attachment 174151 [details] [diff] [review] xpcom/threads/plevent.c did actually know about this too Better put a review on the lines in xpcom as well. r?
tqh, putting plevent change in same patch will cause need for sr also for widget/src/beos changes:)
Comment on attachment 174151 [details] [diff] [review] xpcom/threads/plevent.c did actually know about this too r=sergei_d actually, same as previous. Need someone's help for sr and checkin, as now patch touches xpcom
Should I seperate them?
Created attachment 174212 [details] [diff] [review] Changes outside BeOS-folder (plevent.c) Ok, so to easier get SR we do this.
Comment on attachment 174150 [details] [diff] [review] Spotted some formatting things. We'll use this one.
Comment on attachment 174151 [details] [diff] [review] xpcom/threads/plevent.c did actually know about this too And not this one, they are identical, except for xpcom/threads/plevent.c which is in last patch now.
Comment on attachment 174212 [details] [diff] [review] Changes outside BeOS-folder (plevent.c) r=sergei_d
Comment on attachment 174212 [details] [diff] [review] Changes outside BeOS-folder (plevent.c) sr? (This is BeOS only changes in our nsAppShell / nsToolkit, but since plevent.c knows about this as well we want that fixed. So we're doing sr on that part.)
Comment on attachment 174212 [details] [diff] [review] Changes outside BeOS-folder (plevent.c) look fine. need a checkin?
Yes, it would be great if you could checkin both patches, but isn't the tree frozen for 1.8b?
last patch checked in: Checking in plevent.c; /cvsroot/mozilla/xpcom/threads/plevent.c,v <-- plevent.c new revision: 1.50; previous revision: 1.49 done
Sergei, plevent.c is checked in, so could you check in our widget changes?
Do you mean this https://bugzilla.mozilla.org/attachment.cgi?id=174150 one?
yes.
Done. Checked in 2005-02-19 11:54 'bug 282031. Use suspend/resume_thread instead syncsem for synchronous events. r=sergei_d. no sr required - BeOS-only'