lock Serious performance issue with GTK3, no problem with GTK2

1 year 5 months ago #6276 by cluxter

My environment:

OS: ArchLinux
Modelio version: 4.1.0
Desktop environment: XFCE and Gnome
CPU: AMD Ryzen 9 3950X (16 cores/32 threads)
RAM: 64 Gb DDR4 @3200 GHz
GPU: Nvidia GeForce GTX 670
GPU driver: nvidia (proprietary)
Motherboard: ASUS ROG Crosshair IV Formula

I experience very very poor performance when running Modelio with GTK3 (which is the default setting).
When I use GTK2 instead like this:

SWT_GTK3=0 /opt/modelio/modelio

performance goes back to normal. It's night and day.
Actually, GTK3 performance is so bad that it comes to a point where Modelio is just unusable.
I experience this on 3 different machines (all of them using ArchLinux).

I attached

File Attachment:

File Name: Example1.zip
File Size:821 KB

a State Diagram which is composed of 16 states and ~30 transitions. It takes about 3 seconds on my high end PC (description above) to update the diagram when I move around one state, for example the sub-state State 3. It takes up to 8 seconds on my laptop with the same diagram, just for one move! Every time I move something around, 1 core of the CPU reaches 100% for several seconds until it refreshes the display, and meanwhile the whole application gets stuck. So even if Modelio can be run, it just can't be used using GTK3, I've got to force using GTK2 if I want to be able to use it in Linux.

Some other projects also experience a similar problem:

GTK3 should obviously be used over GTK2 since it supports HiDPI scaling and is supposed to be future proof with the support of Wayland, so I think we should really address this issue.

I tried changing the display backend using GDK_BACKEND=wayland in Gnome but Modelio wouldn't run, it wants x11.
I tried switching to different GTK3 themes like Arc, Breeze, Adwaita:dark, it didn't change anything.
I tried turning off font anti-aliasing by putting these options in modelio.ini:


but it didn't change anything (except that it was more ugly).
I tried using the default Modelio diagramming theme instead of my custom "Black and white" theme, it didn't change anything.

From other projects experiencing similar issues, it looks like it comes from the way GTK3 is handled in the Modelio source code. Or maybe it's just that GTK3 is really poorly designed, I don't know.

Could you please at least confirm or deny this behavior?

I will be glad to help in the debugging process and provide as many data as needed to fix this issue.

Thank you very much and thanks a lot for Modelio, it really is a great tool :)

P.S.: I also opened a GitHub issue about this: github.com/ModelioOpenSource/Modelio/issues/11
The topic has been locked.
1 year 4 months ago #6318 by phv
Hi Cluxter,

Thank you for your contribution to Modelio and to help fixing this annoying issue.
We are glad to hear that you think Modelio is a great tool, thank for that.
We noticed your post in GitHub about the same GTK issue and we propose to continue the discussion about this particular issue only in GitHub. Therefore we lock this thread and invite the followers to move to GitHub about it.

Modelio Team.
The topic has been locked.
Moderators: tmaaabcde
Time to create page: 0.040 seconds
^ Back to Top