Opened 6 years ago

Closed 6 years ago

#5247 closed defect (fixed)

Opening OMSimulator projects makes OMEdit slower and unstable

Reported by: Francesco Casella Owned by: Adeel Asghar
Priority: blocker Milestone: 1.14.0
Component: OMEdit Version: v1.13.0-dev.beta1
Keywords: Cc: Andrea Bartolini, Alachew Mengist, Lennart Ochel

Description

Steps to reproduce:

Case A

  • Start OMEdit
  • Load ThermoPower
  • Open ThermoPower.PowerPlants.Simulators.SteamPlant_Sim1
  • Create a new OMSimulator project
  • Close the OMSimulator diagram with the red cross button
  • Now interacting with the library browser and other Modelica models is much slower

Case B

  • Start OMEdit
  • Open Modelica.Mechanics.MultiBody.Examples.Systems.RobotR3.fullRobot
  • Create a new OMSimulator object
  • Close the OMSimulator diagram with the red cross button
  • OMEdit closes abruptly

The problem shows up in Linux Ubuntu 16.04 LTR. On Windows 10 64-bit everything seems ok. Possibly an issue with the QT libraries? The Linux Ubuntu system where this problem shows up has QT 4 and 5 installed, as well as compatibility for QT 3.

Change History (13)

comment:1 by Francesco Casella, 6 years ago

Cc: Andrea Bartolini added

comment:2 by Adeel Asghar, 6 years ago

So both cases works fine in Windows, right? They should work fine in Linux as well but I will see if I can reproduce the issue. Which Qt version you are actually using?

in reply to:  2 comment:3 by Andrea Bartolini, 6 years ago

Replying to adeas31:

So both cases works fine in Windows, right? They should work fine in Linux as well but I will see if I can reproduce the issue. Which Qt version you are actually using?

My Linux Ubuntu system is 16.04 and has Qt4 and Qt5 installed, as well as compatibility for Qt3.

comment:4 by Adeel Asghar, 6 years ago

Yeah but you can't use all versions of Qt so do you know which one is used?

in reply to:  4 comment:5 by Andrea Bartolini, 6 years ago

Replying to adeas31:

Yeah but you can't use all versions of Qt so do you know which one is used?

Followin the output of the command qtdiag

Qt 5.5.1 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 5.4.0 20160609) on "xcb"
OS: Ubuntu 16.04.5 LTS [linux version 4.15.0-42-generic]

Architecture: x86_64; features: SSE2 SSE3 SSSE3 SSE4.1 SSE4.2 AVX AVX2 RTM HLE

It seems to be Qt5...

comment:6 by anatoly.trosinenko@…, 6 years ago

So both cases works fine in Windows, right? They should work fine in Linux as well but I will see if I can reproduce the issue.

Just as a note: slowdown of OMEdit operation on Linux is not a surprise to me, I have observed ~3x startup slowdown of Linux version of OMEdit due to parsing /proc/PID/maps on every component tree node query (or maybe on every non-leaf node...) to determine the stack boundaries before entering the backend. I had a solution for it: https://github.com/OpenModelica/OMEdit/pull/173 -- it is highly kludgy and should probably be rewritten, but can be used for the testing purposes to try to align Windows-Linux performance.

PS: I have absolutely no clue on unstabilities and performance degradation, but can't the degradation be observed on Windows too would its performance scaled 3x both before and after OMSimulator initialization? :)

comment:7 by Francesco Casella, 6 years ago

Milestone: 1.13.01.14.0

Will be further investigated for 1.14.0

comment:8 by anatoly.trosinenko@…, 6 years ago

In some cases, OMEdit seems to be deadlocked by GitCommands sometimes (30s timeout). When applied https://github.com/OpenModelica/OMEdit/pull/203, it looks like TLMErrorLog just receives some fatal error and closes the application (set breakpoints on exit and _exit).

comment:9 by Adeel Asghar, 6 years ago

Cc: Alachew Mengist added

AFAIK GitCommands is not used at all.
Since I haven't implemented it so I can't be sure. I let Alachew comment on it.

comment:10 by Adeel Asghar, 6 years ago

Cc: Lennart Ochel added

@lochel do you encounter any of the issues described in the description of the ticket?

comment:11 by Adeel Asghar, 6 years ago

@Andrea.Bartolini and @casella is this issue still valid? I still can't reproduce it.

comment:12 by Andrea Bartolini, 6 years ago

With the version

OMEdit 1.11.0~1-gf048cec
Connected to OpenModelica 1.14.0~dev-5914-g99eb5ee
Connected to OMSimulator unknown-linux

installed om my PC (sysop: Linux Ubuntu 16.04) the issue is fixed.

comment:13 by Adeel Asghar, 6 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.