[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[platform-ui-dev] Too much too many
|
Hi,
In the past few weeks I had the fun to investigate performance problems
in an 3.x RCP application currently ported to e4 and the compat layer [1].
I'd say the figures are shocking and amazing at the same moment!
I've attached a gerrit-review with a strategy to queue updates (instead
of recalculating the same information in the same UI-Pass) by scheduling
them on an Display#asyncExec. I'm not totally happy with this strategy
but I could not come up with a better one.
You can play around yourself with turning on/off certain parts of the
fix using system-properites certainly the biggest impact has the
enabledWhen queueing.
The enabledWhen-Queueing is getting even better if you make the
EvaluationService sending the reevaluation command synchronously. I
don't know why this was done that way but it makes totally no sense to
post the event just to make the event-system to schedule an asyncExec
polluting the event-loop with runnables.
While looking into this part I looked at EventBroker and what I think
has not been a very good idea there was that all subscriptions are
forced back to the UI-Thread and the user of the API has no chance to
overrule that :-(
As of today @EventTopic is the only way to receive events outside the
UI-Thread which is very unfortunate (you all probably know that I think
@EventTopic and @UIEventTopic have been a bad bad idea) but it is not
used in the (platform) codebase.
I think Platform-Developers should keep that in mind when deciding
whether IEventBroker post/send should be used (99% I think you should
opt for send, if some handler is doing bad things the event-loop would
be stuck anyway by EventBroker and/or @UIEventTopic).
The root cause of all those problems is that we are
activating/reactivating too many IEclipseContext branches leading to a
flush of RAT-Recalcuations but addressing these problems is a full-time
job for the next months or so and nothing I can allocate funding for.
I'm writing down those findings because I'm 100% certain that there are
probably other code parts get triggered without a need.
Tom
[1]https://bugs.eclipse.org/bugs/show_bug.cgi?id=514277
--
Thomas Schindl, CTO
BestSolution.at EDV Systemhaus GmbH
Eduard-Bodem-Gasse 5-7, A-6020 Innsbruck
http://www.bestsolution.at/
Reg. Nr. FN 222302s am Firmenbuchgericht Innsbruck