Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

qBittorrent requests file icons too frequently casing performance issues #10897

morpheby opened this issue Jul 7, 2019 · 0 comments


None yet
1 participant
Copy link

commented Jul 7, 2019

qBittorrent version and Operating System

qBittorrent 4.1.6 64-bit, macOS 10.15 Beta (19A501i)

What is the problem

macOS 10.15 (presumably some issue on the beta) has iconserviceagent compiled with malloc scribble is causing severe performance downgrade on icon requests through Cocoa APIs.

qBittorrent apparently requests icons so often, that this causes iconserviceagent to use up the whole CPU core of the system. No other application was observed to elicit the same behavior.

While this isn't a bug per se, this highlights inefficient resource use in the qBittorrent, that can be fixed with some caching.

What is the expected behavior

No significant performance degradation caused by qBittorrent's use of file icons.

Steps to reproduce

  1. Install macOS 10.15 Developer Beta
  2. Start qBittorrent
  3. Open and select any torrent file with a list of files > 20 (depends on the performance of the system, tested on MacBook 12" Early 2015)
  4. Select "Contents"
  5. Observe high CPU load in Activity Monitor coming from iconserviceagent
  6. Observe terribly slow responsiveness from qBittorrent

Extra info(if any)

After investigating the code of qBittorrent, it seems like something is wrong with caching. Either the CGImage is fully bridged down to XPC and Qt simply wraps it away into one more proxy layer (then to resolve the issue one would just need to copy CGImage bytes before creating pixmap); or it could be that there is an actual issue with qBittorrent's CachingFileIconProvider

I am free to investigate this further if needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.