1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 <2015> 2016 2017 2018 2019 2020 2021 2022 2023 2024 | Index | 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 <2015> 2016 2017 2018 2019 2020 2021 2022 2023 2024 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: CSS performance |
From: | Benoit <[email protected]> |
To: | "Kasemir, Kay" <[email protected]> |
Cc: | Marcio Alexandre Barbosa <[email protected]>, EPICS mailing list <[email protected]> |
Date: | Mon, 29 Jun 2015 18:02:23 +0200 |
Hi:
_javascript_ tends to initialize faster, while it takes a little longer to load the Jython interpreter.At runtime, I doubt that there's a huge difference, and I would personally prefer python over _javascript_ because of its syntax.
The use of scripts in BOY should, however, be limited to very special cases.Don't add a script to a circle to change its color, but use an LED widget.Don't add a script to some widget to change the text, instead create a text (or enum) PV and use a Textupdate widget.Don't use a script to somehow indicate an alarm state, but instead use the "alarm sensitive border" of the widget.Don't use a script to do anything that should really be done on an IOC.In short, many of the "BOY Examples" included in CSS that include script examples tend to show gimmicky things that you shouldn't really do in a production environment.
The current implementation of scripts is such that they execute on the user interface thread, because that's currently necessary to update widget properties.Because of this, each script not just uses CPU, but uses CPU on the UI thread. Even if you have a 128 core computer, when you use many scripts 127 of your cores will be idle while CSS becomes unresponsive because the user interface thread gets bogged down.
Thanks,Kay
On Jun 29, 2015, at 10:12 AM, Benoit <[email protected]>wrote:Hi Kunal,
I am using v3.2.16 but I am not "authorized" to change the version so easily. Anyway I will try to install v4.x just to see if we don't have anymore these freezes.I will also try to add more VM RAM and told you if my problems appear again!
I am using Python script instead of JS (more used to write python code), do they consume more CPU/RAM?
Then do you know a way to get the script usage (CPU/RAM) to see if I have one script more thirsty than the others because they are actually quite simple.
Regards,
On Thu, Jun 25, 2015 at 6:48 PM, Shroff, Kunal <[email protected]> wrote:
Hello Marcio and Benoit,
What version of cs-studio are you using?
Also could you give provide some details about the opi screens which result in the freeze. Are there any scripts or rules associated with those screens.
With cs-studio 3.2.x and 3.3.x make sure you have allocated enough perm memory (especially if you are using a lot of scripts)
You can set it with the following VM argument in your config.ini file -XX:MaxPermSize=256M
With the 4.1.x (latest release), cs-studio moved to a newer version of pvmanager with improvements intended to reduce cpu and memory load
You could try one of the 4.1.x products and see if that resolves your problems
http://controlsystemstudio.org/download.html
Cheers,
Kunal
From: [email protected] [mailto:[email protected]] On Behalf Of Benoit
Sent: Monday, June 15, 2015 3:28 AM
To: Marcio Alexandre Barbosa
Cc: EPICS mailing list
Subject: Re: CSS performance
Hi Marcio,
I have also similar bottlenecks and screen freezes when using CSS/BOY under windows 7. Never saw these problems with ubuntu 14.04.
In my case the problem seems to come from RAM usage: at some point the RAM consumption is going really high and then CSS/BOY freezes.
If someone has some suggestions it would be nice.
Cheers,
Benoit
On Tue, Jun 9, 2015 at 4:27 PM, Marcio Alexandre Barbosa <[email protected]> wrote:
How can I configure the .ini file to improve performance of CSS? I'm
having some bottlenecks and screen freezes.
Thank you,
Marcio