GUI incredibly slow Performance (1 Viewer)

Trigg3r

MP Donator
  • Premium Supporter
  • December 14, 2019
    14
    27
    UK
    Home Country
    Great Britain (UK) Great Britain (UK)
    Right so had a change to have a mess with this.

    Firstly, I commented out the change as requested and re-ran with 1000hz mouse setting, it caused absolutely no change – weird.

    Just for the sake of it, also ran without the change and back at 125hz – still very smooth and not particularly high CPU usage, all good (so the change I removed seems to make little difference to me in either situation).

    The thing I was not quite understanding is, if we are saying we are swamping the program with events, why was the CPU not jumping to 100% (one core at least) while the events where processed... there are spikes, but only 1-2% over the whole CPU.

    So I figured I would chuck in a Debug.WriteLine(), right on the MainForm_MouseMove so I could visually see the X and Y events being processed – this is where it gets interesting.

    With the mouse set to 125hz, I move the mouse across the screen (left to tight) and see roughly 40 events... ok, cool.

    Now bump it to 500hz and preform the left to right test again, this time, maybe 20 or so events – what the!

    Ok so now try at the 1000hz setting, left to right test again... 4, 4 Events! What the hell!

    So increasing the report rate is actually reducing the events raised by, well, quite a lot. This explains why there is no CPU spike, it’s not that there are too many events, there are substantially LESS.

    This is what causes the huge “delay” on dragging the window, at 1000hz if you are lucky enough, an event will get raised “at some point” and the screen will jump to the new events position.

    This is not a Media Portal issue; this is a Windows 10 issue

    So with a little google, there are actually posts all over R.E 1000hz mice, it seems to have been noticed since Windows 10 1903, and not much interest from Microsoft thus far.

    I did also come across someone mentioning enabling HPET (High precision timers) in the BIOS fixed the issue, but caused more CPU usage (as you would expect) - I did have that option (and enabled) on my previous Intel board, but I can’t see anything similar in my current (AMD) X570 setup.

    There was also some mention of DPI & Report rates linked to windows mouse pointer speed – I did knock the mouse speed down to almost minimum while at 1000hz, it did improve a little but far from lag free, so at this point I don’t think there is anything that can be tweaked in Windows.

    I wonder if this would improve if the main form was WPF, rather than WinForms? not a trivial upgrade I know.

    Running the mouse at 125hz and the difference is substantial, Media Portal feels very quick – so glad to have got to the bottom after struggling with it for over a year now! Would you believe it’s even had an impact in games, the whole system just feels... better.
     

    Trigg3r

    MP Donator
  • Premium Supporter
  • December 14, 2019
    14
    27
    UK
    Home Country
    Great Britain (UK) Great Britain (UK)
    Another small update (HPET setting was bugging me),

    I have a ROG Strix X570-F and no where in the manual is any mention of HPET setting. I found mention that it's disabled by Windows by default now and can be toggle from an elevated command prompt using (apparently, yes I just ran these commands blindly ;));

    Enable;
    bcdedit /set useplatformclock true

    Disable;
    bcdedit /deletevalue useplatformclock

    Tried that with no difference at all, so I can't think of any other settings in Windows that could be tweaked to solve it. Annoyingly the default value on the Logitech software is 500hz (for my mouse anyway) and that's pretty bad lag wise.

    There seems to be a few projects kocking around that show the mouse DPI and input rate - I wonder if you could check that info (however they are doing it, maybe a Nuget Package for advanced input info :p) and then show a warning in the logs or similar? I don't think there is anything else you could do in this instance...
     

    morpheus_xx

    Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,073
    7,459
    Home Country
    Germany Germany
    Very interesting finding (y). Thank you very much for your analysis, it's very welcome :)
     

    Matt84

    Portal Member
    November 25, 2017
    5
    1
    39
    Home Country
    Australia Australia
    I know this is an old thread, however I just experienced this issue. Previously I had the following system where Media Portal 2.X client install only has been working without any issues for years:

    • Intel i7 4770K
    • 32 GB DDR3 2133 RAM
    • ASUS Maximus VI Hero (Z87)
    • Gigabyte Aorus Xtreme 1080Ti
    • 2x Samsung 860 EVO 500GB in RAID0 (No NVMe support on Z87 as a boot drive)

    Last week I switched it out for the following:

    • AMD Ryzen 7 5800X
    • 32GB DDR4 3600 RAM
    • Gigabyte Aorus X570 Master
    • Gigabyte Aorus Xtreme 1080Ti (same card)
    • Samsung 980 Pro 1TB NVMe

    The other common component is a Cooler Master Inferno mouse which is a carry over from my old Core2Quad Q9550 from years ago.

    After installing the latest Media Portal 2.3.1 client only, is upon launch the UI is responsive for a few seconds and then it is almost completely unresponsive. If you are patient the UI does respond after 30 seconds or so, but it is totally unusable.

    After finding this thread I dug out the old Cooler Master Inferno app that I hadn't used on either of my last two systems; lucky it worked on Windows 10 and found that the USB polling rate was set to 1000hz. I then backed it down to 125 as described in this thread above, and the UI is completely responsive again.

    Is this an AMD issue as my previous two Intel systems would have had the mouse set to 1000hz and I experienced no UI issue. The original poster in this thread mentions they have a Ryzen system as well so I'm wondering if that is a commonality here. I'm happy to provide any further information if required.
     

    Attachments

    • Capture.PNG
      Capture.PNG
      663.1 KB

    Boehamian

    Portal Member
    April 21, 2013
    7
    1
    32
    Home Country
    Australia Australia
    thanks guys, interesting reading, having this same issue. Might have to try when I get back home from work. Will be interesting.
     

    Users who are viewing this thread

    Top Bottom