From: Alan W. I. <ir...@be...> - 2016-11-14 09:01:50
|
On 2016-11-14 08:28+0100 Laurent Berger wrote: > Hi, > > I have just made a git pull git.code.sf.net/p/plplot/plplot. Using cmake > 3.7.0.rc2 and wxwidgets 3.1.0 and VS 2015. After pressing OK every where, all > is fine. thanks for this new version! Hi Laurent: I am glad to hear our wxwidgets device driver works for you so well on Windows (which is the primary development platform used by Phil Rosenberg for this new wxwidgets device driver). However, I am having real trouble with how slow this device is on my Linux platform (Debian Jessie), and gave a detailed example (last January on this list that included screen shots of my cpu meter) of the issue which was the cpu is idle most of the time when communicating data both ways between the wxwidgets device driver and wxPLViewer application. However, I don't know whether this excessivee idle time (compared to all our other interactive devices available on Linux) is specific to Debian Jessie or a general issue that needs to be addressed for the Linux interprocess communication protocol that is being used to communicate between wxwidgets device driver and wxPLViewer application. So if you (or anyone else here) has access to a Linux box, some confirmation (or not) of my (extremely) slow speed results for wxwidgets device driver and wxPLViewer application would be much appreciated. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); the Time Ephemerides project (timeephem.sf.net); PLplot scientific plotting software package (plplot.sf.net); the libLASi project (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ |
From: Alan W. I. <ir...@be...> - 2016-11-14 21:19:38
|
Hi Laurent: I have put my reply to you on list for obvious reasons. On 2016-11-14 14:26+0100 Laurent Berger wrote: > Hi Alan, > > I would try to help you Thanks in advance for that. > but I'm not familiar on linux (see attached file for > version). >From what you included, your Linux platform has access to wxwidgets version 3.0 (as do I). But the rest of your platform (old Linux Mint distribution using a relatively old kernel version 3.2.0-2-amd64 compared to my much more modern Debian Jessie using a fairly up-to-date kernel version 3.16.0-4-amd64) provides an extremely useful testing contrast in case the issue is some lameness in the IPC implementation for my particular Linux kernel. (IPC, i.e., interprocess communication is used to communicate between -dev wxwidgets and the wxPLViewer application that displays the results.) > I think it is this message > (https://sourceforge.net/p/plplot/mailman/message/34744869/) Yes, that message and the following one that provided the screenshots referred to in that message are the relevant ones. > > I have build plplot on linux using cmake 3.0.2 using "Unix Makefiles" > Then sudo make install. I have attached git log result and cmakecache > Then I run in folder examples/c++ > ./x01c -dev wxdrivers > > I can see a window with 4 curves. Windows title is wxPLviewer. No problem > Now what do you want to test ? Speed. You measure speed on linux using, e.g., software@raven> time examples/c/x01c -dev wxwidgets -np PLplot library version: 5.11.1 real 0m0.652s user 0m0.064s sys 0m0.016s software@raven> software@raven> time examples/c/x01c -dev wxwidgets -np PLplot library version: 5.11.1 real 0m9.327s user 0m0.072s sys 0m0.008s That -np option stands for "no pause" and allows you to measure time without waiting for the human reaction of clicking on the GUI to finish the display. Those two measurements obviously have a huge difference in the real time used. The first timing is not too bad, but (by chance) the second timed run shows the problem which is quite often there is a random drop of at least an order of magnitude and sometimes two orders of magnitude in speed of communications between -dev wxwidgets and wxPLviewer due to excessive times when my cpus sit absolutely idle (as proved above by comparison of the sum of the user + sys times and the real time required to finish the example in the second time run). (This excessive idle time is also proved by my screenshots of my cpu meter that are referred to above.) The above results are for the current master branch tip. By way of comparison here are the consistent timing results I get for -dev xwin, -dev qtwidget (for Qt5), and -dev xcairo on my platform. software@raven> time examples/c/x01c -dev xwin -np PLplot library version: 5.11.1 real 0m0.482s user 0m0.008s sys 0m0.008s software@raven> time examples/c/x01c -dev xwin -np PLplot library version: 5.11.1 real 0m0.472s user 0m0.012s sys 0m0.004s software@raven> time examples/c/x01c -dev qtwidget -np PLplot library version: 5.11.1 libGL error: failed to authenticate magic 759 libGL error: failed to load driver: nouveau real 0m0.472s user 0m0.088s sys 0m0.012s software@raven> software@raven> time examples/c/x01c -dev qtwidget -np PLplot library version: 5.11.1 real 0m0.452s user 0m0.076s sys 0m0.020s software@raven> time examples/c/x01c -dev xcairo -np PLplot library version: 5.11.1 real 0m0.239s user 0m0.048s sys 0m0.012s software@raven> time examples/c/x01c -dev xcairo -np PLplot library version: 5.11.1 real 0m0.229s user 0m0.044s sys 0m0.012s If you get consistent timing results for -dev wxwidgets no matter how often you repeat the experiment and those timing results are within a factor of two of the timing results for one or more of the above interactive devices, then it is clear the IPC problem is likely due to some kernel issue on my Debian Jessie platform, and we can write off my timing results above to that cause. But if you also get wildly inconsistent and often extremely slow wxwidgets results for a completely different Linux kernel, then either IPC kernel implementations on Linux are uniformly bad regardless of kernel version (a conclusion which I doubt) or the way that -dev wxwidgets and wxPLviewer currently use IPC to communicate between them is set up in a bad way for the Linux case, that randomly causes excessive idle times, and that is an issue that the PLplot development team needs to urgently address if we ever want the wxwidgets device to be popular on Linux. I am looking forward to your reply with similar time experiments on your own Linux platform. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); the Time Ephemerides project (timeephem.sf.net); PLplot scientific plotting software package (plplot.sf.net); the libLASi project (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ |
From: Laurent B. <lau...@un...> - 2016-11-15 13:58:32
|
Hi Alan, I haven't got qt installed. My results looks like yours results : lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev wxwidgets -np PLplot library version: 5.11.1 Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: Having multiple values in <test> isn't supported and may not work as expected Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: Having multiple values in <test> isn't supported and may not work as expected Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: Having multiple values in <test> isn't supported and may not work as expected Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: Having multiple values in <test> isn't supported and may not work as expected real 0m0.407s user 0m0.108s sys 0m0.016s lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev wxwidgets -np PLplot library version: 5.11.1 Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: Having multiple values in <test> isn't supported and may not work as expected Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: Having multiple values in <test> isn't supported and may not work as expected Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: Having multiple values in <test> isn't supported and may not work as expected Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: Having multiple values in <test> isn't supported and may not work as expected real 0m10.997s user 0m0.064s sys 0m0.040s lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xwin -np PLplot library version: 5.11.1 real 0m0.122s user 0m0.056s sys 0m0.020s lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xwin -np PLplot library version: 5.11.1 real 0m0.122s user 0m0.060s sys 0m0.016s lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xcairo -np PLplot library version: 5.11.1 Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: Having multiple values in <test> isn't supported and may not work as expected Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: Having multiple values in <test> isn't supported and may not work as expected real 0m0.125s user 0m0.088s sys 0m0.016s lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xcairo -np PLplot library version: 5.11.1 Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: Having multiple values in <test> isn't supported and may not work as expected Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: Having multiple values in <test> isn't supported and may not work as expected real 0m0.128s user 0m0.084s sys 0m0.020s lb@mp12-lb:~/plplot.git/examples/c++$ Le 14/11/2016 à 22:19, Alan W. Irwin a écrit : > Hi Laurent: > > I have put my reply to you on list for obvious reasons. > > On 2016-11-14 14:26+0100 Laurent Berger wrote: > >> Hi Alan, >> >> I would try to help you > > Thanks in advance for that. > >> but I'm not familiar on linux (see attached file for version). > > From what you included, your Linux platform has access to wxwidgets > version 3.0 (as do I). But the rest of your platform (old Linux Mint > distribution using a relatively old kernel version 3.2.0-2-amd64 > compared to my much more modern Debian Jessie using a fairly > up-to-date kernel version 3.16.0-4-amd64) provides an extremely useful > testing contrast in case the issue is some lameness in the IPC > implementation for my particular Linux kernel. (IPC, i.e., > interprocess communication is used to communicate between -dev > wxwidgets and the wxPLViewer application that displays the results.) > >> I think it is this message >> (https://sourceforge.net/p/plplot/mailman/message/34744869/) > > Yes, that message and the following one that provided the screenshots > referred to > in that message are the relevant ones. > >> >> I have build plplot on linux using cmake 3.0.2 using "Unix Makefiles" >> Then sudo make install. I have attached git log result and cmakecache >> Then I run in folder examples/c++ >> ./x01c -dev wxdrivers >> >> I can see a window with 4 curves. Windows title is wxPLviewer. No >> problem >> Now what do you want to test ? > > Speed. > > You measure speed on linux using, e.g., > > software@raven> time examples/c/x01c -dev wxwidgets -np > PLplot library version: 5.11.1 > > real 0m0.652s > user 0m0.064s > sys 0m0.016s > software@raven> software@raven> time examples/c/x01c -dev wxwidgets -np > PLplot library version: 5.11.1 > > real 0m9.327s > user 0m0.072s > sys 0m0.008s > > That -np option stands for "no pause" and allows you to measure time > without waiting for the human reaction of clicking on the GUI to > finish the display. > > Those two measurements obviously have a huge difference in the real > time used. The first timing is not too bad, but (by chance) the second > timed run shows the problem which is quite often there is a random > drop of at least an order of magnitude and sometimes two orders of > magnitude in speed of communications between -dev wxwidgets and > wxPLviewer due to excessive times when my cpus sit absolutely idle (as > proved above by comparison of the sum of the user + sys times and the > real time required to finish the example in the second time run). > (This excessive idle time is also proved by my screenshots of my cpu > meter that are referred to above.) The above results are for the > current master branch tip. By way of comparison here are the > consistent timing results I get for -dev xwin, -dev qtwidget (for > Qt5), and -dev xcairo on my platform. > > software@raven> time examples/c/x01c -dev xwin -np > PLplot library version: 5.11.1 > > real 0m0.482s > user 0m0.008s > sys 0m0.008s > software@raven> time examples/c/x01c -dev xwin -np > PLplot library version: 5.11.1 > > real 0m0.472s > user 0m0.012s > sys 0m0.004s > software@raven> time examples/c/x01c -dev qtwidget -np > PLplot library version: 5.11.1 > libGL error: failed to authenticate magic 759 > libGL error: failed to load driver: nouveau > > real 0m0.472s > user 0m0.088s > sys 0m0.012s > software@raven> software@raven> time examples/c/x01c -dev qtwidget -np > PLplot library version: 5.11.1 > > real 0m0.452s > user 0m0.076s > sys 0m0.020s > software@raven> time examples/c/x01c -dev xcairo -np > PLplot library version: 5.11.1 > > real 0m0.239s > user 0m0.048s > sys 0m0.012s > software@raven> time examples/c/x01c -dev xcairo -np > PLplot library version: 5.11.1 > > real 0m0.229s > user 0m0.044s > sys 0m0.012s > > If you get consistent timing results for -dev wxwidgets no matter how > often you repeat the experiment and those timing results are within a > factor of two of the timing results for one or more of the above > interactive devices, then it is clear the IPC problem is likely due to > some kernel issue on my Debian Jessie platform, and we can write off > my timing results above to that cause. But if you also get wildly > inconsistent and often extremely slow wxwidgets results for a > completely different Linux kernel, then either IPC kernel > implementations on Linux are uniformly bad regardless of kernel > version (a conclusion which I doubt) or the way that -dev wxwidgets > and wxPLviewer currently use IPC to communicate between them is set up > in a bad way for the Linux case, that randomly causes excessive idle > times, and that is an issue that the PLplot development team needs to > urgently address if we ever want the wxwidgets device to be popular on > Linux. > > I am looking forward to your reply with similar time experiments > on your own Linux platform. > > Alan > __________________________ > Alan W. Irwin > > Astronomical research affiliation with Department of Physics and > Astronomy, > University of Victoria (astrowww.phys.uvic.ca). > > Programming affiliations with the FreeEOS equation-of-state > implementation for stellar interiors (freeeos.sf.net); the Time > Ephemerides project (timeephem.sf.net); PLplot scientific plotting > software package (plplot.sf.net); the libLASi project > (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); > and the Linux Brochure Project (lbproject.sf.net). > __________________________ > > Linux-powered Science > __________________________ -- Laurent Berger Enseignant-chercheur I.U.T. du Mans Département Gestion des Entreprises et des Administrations Département Mesures Physiques Tél 02 43 83 37 09 |
From: Alan W. I. <ir...@be...> - 2016-11-15 21:22:16
|
On 2016-11-15 14:59+0100 Laurent Berger wrote: > Hi Alan, > > I haven't got qt installed. > My results looks like yours results : > > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev wxwidgets -np > PLplot library version: 5.11.1 > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > > real 0m0.407s > user 0m0.108s > sys 0m0.016s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev wxwidgets -np > PLplot library version: 5.11.1 > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > > real 0m10.997s > user 0m0.064s > sys 0m0.040s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xwin -np > PLplot library version: 5.11.1 > > real 0m0.122s > user 0m0.056s > sys 0m0.020s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xwin -np > PLplot library version: 5.11.1 > > real 0m0.122s > user 0m0.060s > sys 0m0.016s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xcairo -np > PLplot library version: 5.11.1 > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > > real 0m0.125s > user 0m0.088s > sys 0m0.016s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xcairo -np > PLplot library version: 5.11.1 > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > > real 0m0.128s > user 0m0.084s > sys 0m0.020s > lb@mp12-lb:~/plplot.git/examples/c++$ Hi Laurent: Thanks very much for the above report. Your timing results verify mine and show that -dev wxwidgets sometimes has very poor "real" timing results even though the actual cpu times indicated by the sum of "user" + "sys" are quite fast and consistent. For this case > real 0m10.997s > user 0m0.064s > sys 0m0.040s the sum of user + sys is 0.104 seconds so that means for this test the cpu was idle for 10.893 seconds out of the 10.997 seconds or 99.05 per cent of the time which is equivalent to two (!) orders of magnitude slowdown. Since your results and mine confirm the problem for a wide range of Linux kernel versions, my working hypothesis is these excessive idle times/slowdowns are due to the inefficient way that Linux kernel IPC is being used to implement the necessary two-way communication between -dev wxwidgets and the wxPLviewer application on Linux. Gaining two orders of magnitude in speed is certainly an attractive goal for the wxwidgets device/wxPLviewer combination so I am tempted to immediately start reviewing the Linux kernel IPC use between -dev wxwidgets and wxPLviewer. However, my current knowledge of Linux kernel IPC is small, and I have many other PLplot issues on my plate at the moment so I will have to delay this for quite a while. Thus, there is an opportunity for someone else to contribute substantially here if they have some knowledge about the most efficient way to use Linux kernel IPC or want to learn more about that interesting topic. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); the Time Ephemerides project (timeephem.sf.net); PLplot scientific plotting software package (plplot.sf.net); the libLASi project (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ |
From: <p.d...@gm...> - 2016-11-15 22:52:55
|
Hi Alan, Laurent I can't say I have much to add. It wasn't obvious to me where the lag was last time i looked, but I agree it is an issue I haven't done much plplot work for some time, but when I can i will look at this. If anyone has any suggestions I would be keen to hear. Phil Sent from my Windows 10 phone From: Alan W. Irwin Sent: 15 November 2016 21:22 To: Laurent Berger Cc: PLplot development list Subject: Re: [Plplot-devel] The wxwidgets device driver speed/idle time On 2016-11-15 14:59+0100 Laurent Berger wrote: > Hi Alan, > > I haven't got qt installed. > My results looks like yours results : > > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev wxwidgets -np > PLplot library version: 5.11.1 > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > > real 0m0.407s > user 0m0.108s > sys 0m0.016s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev wxwidgets -np > PLplot library version: 5.11.1 > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > > real 0m10.997s > user 0m0.064s > sys 0m0.040s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xwin -np > PLplot library version: 5.11.1 > > real 0m0.122s > user 0m0.056s > sys 0m0.020s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xwin -np > PLplot library version: 5.11.1 > > real 0m0.122s > user 0m0.060s > sys 0m0.016s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xcairo -np > PLplot library version: 5.11.1 > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > > real 0m0.125s > user 0m0.088s > sys 0m0.016s > lb@mp12-lb:~/plplot.git/examples/c++$ time ./x01 -dev xcairo -np > PLplot library version: 5.11.1 > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 103: > Having multiple values in <test> isn't supported and may not work as expected > Fontconfig warning: "/etc/fonts/conf.d/65-droid-sans-fonts.conf", line 138: > Having multiple values in <test> isn't supported and may not work as expected > > real 0m0.128s > user 0m0.084s > sys 0m0.020s > lb@mp12-lb:~/plplot.git/examples/c++$ Hi Laurent: Thanks very much for the above report. Your timing results verify mine and show that -dev wxwidgets sometimes has very poor "real" timing results even though the actual cpu times indicated by the sum of "user" + "sys" are quite fast and consistent. For this case > real 0m10.997s > user 0m0.064s > sys 0m0.040s the sum of user + sys is 0.104 seconds so that means for this test the cpu was idle for 10.893 seconds out of the 10.997 seconds or 99.05 per cent of the time which is equivalent to two (!) orders of magnitude slowdown. Since your results and mine confirm the problem for a wide range of Linux kernel versions, my working hypothesis is these excessive idle times/slowdowns are due to the inefficient way that Linux kernel IPC is being used to implement the necessary two-way communication between -dev wxwidgets and the wxPLviewer application on Linux. Gaining two orders of magnitude in speed is certainly an attractive goal for the wxwidgets device/wxPLviewer combination so I am tempted to immediately start reviewing the Linux kernel IPC use between -dev wxwidgets and wxPLviewer. However, my current knowledge of Linux kernel IPC is small, and I have many other PLplot issues on my plate at the moment so I will have to delay this for quite a while. Thus, there is an opportunity for someone else to contribute substantially here if they have some knowledge about the most efficient way to use Linux kernel IPC or want to learn more about that interesting topic. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); the Time Ephemerides project (timeephem.sf.net); PLplot scientific plotting software package (plplot.sf.net); the libLASi project (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ ------------------------------------------------------------------------------ _______________________________________________ Plplot-devel mailing list Plp...@li... https://lists.sourceforge.net/lists/listinfo/plplot-devel |
From: Alan W. I. <ir...@be...> - 2016-11-16 01:21:33
|
On 2016-11-15 22:52-0000 p.d...@gm... wrote: > Hi Alan, Laurent > I can't say I have much to add. It wasn't obvious to me where the lag was last time i looked, but I agree it is an issue > > I haven't done much plplot work for some time, but when I can i will look at this. If anyone has any suggestions I would be keen to hear. Hi Phil: >From what you say above it sounds like any serious time you can spend on this would be pretty limited and not immediate. Given those conditions, I think that likely the most valuable thing you can do for us immediately is to write up a paragraph or so describing how you are currently using IPC to communicate between -dev wxwidgets and wxPLViewer including a summary of where waits might be occurring. I suggest you commit that overview in the new file drivers/README.wxwidgets_IPC (or I will do that if you just want to send your overview by e-mail). That IPC overview would be a big help in getting up to speed for anyone else wanting to figure out what is going on with these weird idle times that we are encountering on the Linux platform. Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); the Time Ephemerides project (timeephem.sf.net); PLplot scientific plotting software package (plplot.sf.net); the libLASi project (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ |
From: Alan W. I. <ir...@be...> - 2016-11-19 07:39:53
|
Hi Phil: I got tired of speculating about more efficient Linux IPC methods so I implemented (as of commit e166866) the "Unnamed semaphores example" paradigm outlined starting on page 73 of <http://man7.org/conf/lca2013/IPC_Overview-LCA-2013-printable.pdf>. (I discussed this possibility in earlier versions of this thread.) This test project is described in cmake/test_linux_ipc/README. Follow the directions there to test it on your own Linux systems. My tests show this method is quite efficient for transferring data between processes on POSIX-compliant systems. The transfer process is under complete control of unnamed semaphores that reside in the shared memory so coordinating required data transfer between two applications is completely straightforward, and there is very little idle time required during these transfers. The IPC-relevant routines that are called in this test project are shm_open, ftruncate, mmap, sem_init, sem_wait, sem_post, and shm_unlink, and according to the Linux man pages, all of these functions are provided by platforms that are compliant with POSIX.1-2001. So on the present evidence from this test project I think this method looks extremely promising for efficiently transferring data both ways between -dev wxwidgets and wxPLViewer for POSIX-compliant systems. If after trying the test of the method documented in cmake/test_linux_ipc/README you agree with this assessment, would you be willing to have a go at the required wxwidgets and wxPLViewer source code changes to see if that essentially eliminates the large idle times we have now on Linux? Alan __________________________ Alan W. Irwin Astronomical research affiliation with Department of Physics and Astronomy, University of Victoria (astrowww.phys.uvic.ca). Programming affiliations with the FreeEOS equation-of-state implementation for stellar interiors (freeeos.sf.net); the Time Ephemerides project (timeephem.sf.net); PLplot scientific plotting software package (plplot.sf.net); the libLASi project (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); and the Linux Brochure Project (lbproject.sf.net). __________________________ Linux-powered Science __________________________ |
From: Phil R. <p.d...@gm...> - 2016-11-22 14:18:00
|
Hi Alan It's on my list - I will do it as soon as I can :-). I actually think I had a similar system like this set up - although I think I used named semaphores. I would have to go back to the code to check. Phil On 19 November 2016 at 07:39, Alan W. Irwin <ir...@be...> wrote: > Hi Phil: > > I got tired of speculating about more efficient Linux IPC methods so I > implemented (as of commit e166866) the "Unnamed semaphores example" > paradigm outlined starting on page 73 of > <http://man7.org/conf/lca2013/IPC_Overview-LCA-2013-printable.pdf>. (I > discussed this possibility in earlier versions of this thread.) > This test project is described in cmake/test_linux_ipc/README. Follow > the directions there to test it on your own Linux systems. > > My tests show this method is quite efficient for transferring data > between processes on POSIX-compliant systems. The transfer process is > under complete control of unnamed semaphores that reside in the shared > memory so coordinating required data transfer between two applications > is completely straightforward, and there is very little idle time > required during these transfers. > > The IPC-relevant routines that are called in this test project are > shm_open, ftruncate, mmap, sem_init, sem_wait, sem_post, and > shm_unlink, and according to the Linux man pages, all of these > functions are provided by platforms that are compliant with POSIX.1-2001. > > So on the present evidence from this test project I think this method > looks extremely promising for efficiently transferring data both ways > between -dev wxwidgets and wxPLViewer for POSIX-compliant systems. > > If after trying the test of the method documented in > cmake/test_linux_ipc/README you agree with this assessment, would you > be willing to have a go at the required wxwidgets and wxPLViewer > source code changes to see if that essentially eliminates the > large idle times we have now on Linux? > > > Alan > __________________________ > Alan W. Irwin > > Astronomical research affiliation with Department of Physics and Astronomy, > University of Victoria (astrowww.phys.uvic.ca). > > Programming affiliations with the FreeEOS equation-of-state > implementation for stellar interiors (freeeos.sf.net); the Time > Ephemerides project (timeephem.sf.net); PLplot scientific plotting > software package (plplot.sf.net); the libLASi project > (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); > and the Linux Brochure Project (lbproject.sf.net). > __________________________ > > Linux-powered Science > __________________________ |