electrickery / pd-tof

Collection of control and signal objects by Thomas Ouellet Fredericks, previously part of Pd-extended
Other
5 stars 0 forks source link

[pmenu] and [menubutton] eating all cpu #1

Open 60-hz opened 7 years ago

60-hz commented 7 years ago

With OSX, banging the pmenu objet and displaying the menu eat all the CPU (>100%).

When the menu is gone everything come back to normal. The same happend with [menubutton] object.

Tested on OSX 10.9.5 and more recent, tof 0.2.0, pd-extended and also pd 0.47.1

electrickery commented 7 years ago

Thank you for the report. I couldn't reproduce the 100% CPU load on Linux 64 bit, will test it later with various MacOSX versions. I did notice different behaviour between pmenu pop-ups with no element selected (at least the first) and with an element selected. In the latter case the menu disappears when the mouse button goes up. In the first case, the menu remains visible until an element is selected or a click elsewhere happens.

electrickery commented 7 years ago

Uploaded version 0.2.1 to puredata.info (accessible via deken-plugin). There were 64-bit issues in the GUI objects, that only appeared in MacOSX-64 bit systems.

60-hz commented 7 years ago

I have the same issue with the last deken version. I noticed that the first time I display the menu everything is ok. The followings are very cpu hungry.

Tested on OSX 10.9.5, tof 0.2.1, pd-extended and also pd 0.47.1

electrickery commented 7 years ago

Hi mrpropre,

I tested with MacOSX 10.5 (32-bit), 10.8 (32 & 64-bit) and 10.11 (32 & 64-bit), all with pd-0.47-1. Pd-extended is outdated by now.

Below are the numbers for the machines I tested with. Second time display of [tof/pmenu] is heavier than first time, but not by much. It is something worth investigating, but not what I consider 'very cpu hungry'. For all tests the pmenu-help patch is used.

Mac OS X 10.11.6, 2.26 GHz Intel Core 2 Duo, 4 GByte 1067 MHz DDR3, 'Pd' process: Pd-0.47-1 (-32bit): 1st; 3.3%, 2nd; 4.7% Pd-0.47-1-64bit: 1st; 3.3%, 2nd; 4.8%

Mac OS X 10.8.5, 2 GHz Intel Core 2 Duo, 8 GByte 1067 MHz DDR3, 'Pd' process: Pd-0.47-1 (-32bit): 1st; 1.7%, 2nd; 2.8% Pd-0.47-1-64bit: 1st; 1.9%, 2nd; 2.8%

If you get wildly different numbers on a similar machine, I would think there is to be another factor influencing the results.

Fred Jan

60-hz commented 7 years ago

I tried again with the last deken version of tof (0.2.1) and I still have more than 100% cpu load in OSX (vanilla 0.47.1 and extended) while displaying the menu. Cpu come back at 5% when the menu disappear.

I am doing some workshop and I see most apple computer have the same issue than me, strange.

electrickery commented 7 years ago

Hi,

As you have pd-extended installed too, these objects could be loaded instead of the deken variant, even with pd-vanilla. It can't be the 0.2.1 version behaves the same as the pd-extended version.

The latest version logs this text in the cpd-console: "menubutton v0.12 tof, based on popup by Ben Bogart and button by ggee".

Greetings,

Fred Jan

On 25-04-17 17:31, mrpropre wrote:

I tried again with the last deken version of tof (0.2.1) and I still have more than 100% cpu load in OSX (vanilla 0.47.1 and extended) while displaying the menu. Cpu come back at 5% when the menu disappear.

I am doing some workshop and I see most apple computer have the same issue than me, strange.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/electrickery/pd-tof/issues/1#issuecomment-297069163, or mute the thread https://github.com/notifications/unsubscribe-auth/AAV8Qxa37v9iv6l08vMapOxFkBBjUcOsks5rzhHWgaJpZM4KVCez.

60-hz commented 7 years ago

Hi,

I put the last tof version in both vanilla and extended. So,

under vanilla and extended for menubutton: "menubutton v0.12 tof, based on popup by Ben Bogart and button by ggee"

under vanilla and extended for pmenu: "pmenu v0.31 by tof"

What is strange is now I only have a normal CPU in vanilla with menubutton...

All test done with the help file example.

Best

60-hz commented 7 years ago

Also I see that background color doesn't work in extended, and default color on vanilla makes only highlighted color visible (other looks empty)

screen shot 2017-04-25 at 20 42 25

Best

60-hz commented 4 years ago

I see that I have the same problem (>100 cpu while displaying the menu) with the last version of tof and now, OSX 10.15.4 with pd-0.51-1

menubutton v0.13 tof, based on popup by Ben Bogart and button by ggee
pmenu v0.32 by tof

Capture d’écran 2020-09-14 à 21 46 28

electrickery commented 4 years ago

Hi 60-hz,

On my old Mac (10.11.6) with Pd 0.50-2 and the latest 0.51.2 (Tk 8.6.10), I see the load going up to 100% when the menu is shown, and down when it is not shown. With Pd 0.47.1 this doesn't happen. This old version very likely uses an older Tcl/Tk version. I will try to find out what happens with newer Tk versions.

The visual behaviour on this mac is different from Linux; the column segmentation is ignored and an an up and down button is added to navigate a list too big to fit. As the code send to Tcl/Tk is identical, it is presumably an implementation difference of Tcl/Tk.

Greetings,

Fred Jan

I see that I have the same problem with the last version of tof and now, OSX 10.15.4 with pd-0.51-1

|menubutton v0.13 tof, based on popup by Ben Bogart and button by ggee pmenu v0.32 by tof |

Capture d’écran 2020-09-14 à 21 46 28 https://user-images.githubusercontent.com/5449719/93131471-6965cb80-f6d4-11ea-8f26-ed3a16abcdb9.jpg

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/electrickery/pd-tof/issues/1#issuecomment-692277000, or unsubscribe https://github.com/notifications/unsubscribe-auth/AACXYQ7QYT5IZ54SEKBIBVDSFZX67ANCNFSM4CSUE6ZQ.

electrickery commented 4 years ago

On the MacOSX ignored background color issue:

https://core.tcl-lang.org/tk/tktview?name=51054929f0 / https://core.tcl-lang.org/tk/info/3588636

On 14/09/2020 21.52, 60-hz wrote:

I see that I have the same problem with the last version of tof and now, OSX 10.15.4 with pd-0.51-1

|menubutton v0.13 tof, based on popup by Ben Bogart and button by ggee pmenu v0.32 by tof |

Capture d’écran 2020-09-14 à 21 46 28 https://user-images.githubusercontent.com/5449719/93131471-6965cb80-f6d4-11ea-8f26-ed3a16abcdb9.jpg

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/electrickery/pd-tof/issues/1#issuecomment-692277000, or unsubscribe https://github.com/notifications/unsubscribe-auth/AACXYQ7QYT5IZ54SEKBIBVDSFZX67ANCNFSM4CSUE6ZQ.

electrickery commented 4 years ago

This might be related to the 100% CPU, but the code sample doesn't work on my Mac. https://core.tcl-lang.org/tk/tktview?name=3573447fff