xiaoyifang / goldendict-ng

The Next Generation GoldenDict
https://xiaoyifang.github.io/goldendict-ng/
Other
1.68k stars 93 forks source link

Very high CPU usage in both 5.15.2 and 6.4.2 versions. #333

Closed thenicegirl closed 1 year ago

thenicegirl commented 1 year ago

I tried both versions, they make my fan rampage. the CPU usage surpasses 60% easily and sometimes above 80%. This app means too much to me, please fix it. @xiaoyifang 5.15.2-GoldenDict.exe_windows-2019_20230205.zip 6.4.2-GoldenDict.exe_windows-2019_20230205.zip Snipaste_2023-02-07_03-08-28

xiaoyifang commented 1 year ago

can you enable log and upload the log file goldendict.exe --log-to-file --show-error-file

and what's the operation you are doing when this occured. the os platform ,Windows 11?

xiaoyifang commented 1 year ago

any fulltext index has been in progress? try to disable fulltext and have a try.

thenicegirl commented 1 year ago

can you enable log and upload the log file goldendict.exe --log-to-file --show-error-file

and what's the operation you are doing when this occured. the os platform ,Windows 11?

I executed the command you indicates, but I don't know where the log file is. this is my os platform:

Edition Windows 11 Pro
Version 22H2
Installed on    ‎11/‎23/‎2022
OS build    22621.1105
Experience  Windows Feature Experience Pack 1000.22638.1000.0
thenicegirl commented 1 year ago

any fulltext index has been in progress? try to disable fulltext and have a try.

I disabled it as you indicate, it performs a bit better but still makes my fan rampage. CPU usage is still about 30% to 50%.

It contrasts with Goldendict++ which I used before, I have never seen it make my fan rampage, and its CPU usage rarely exceeds 10%. It is considered malware now and I dare not use it anymore.

BEST8OY commented 1 year ago

but I don't know where the log file is.

It's here.

"C:\Users\XXXX\AppData\Roaming\GoldenDict\gd_log.txt"

thenicegirl commented 1 year ago

but I don't know where the log file is.

It's here.

"C:\Users\XXXX\AppData\Roaming\GoldenDict\gd_log.txt"

Thanks for telling me. 🙂

gd_log.txt Now I upload it, hope it will help you @xiaoyifang improve.

xiaoyifang commented 1 year ago

I checked the log file,it looked ok,nothing valuable in the log file.

yg-h commented 1 year ago

I can confirm this also, but I'm on Win10.

However, this problem doesn't seem to specific to this fork. On my machine whenever I try to use GD built with qt5 or qt6 to access wikipedia, the fan goes rampage. The problem exists both in main branch and in this fork.

The qt4 user wikipedia experience is so much better (smoother scrolling, page rendering much faster, no noisy fans) that I really wish this fork supports qt4 as well

xiaoyifang commented 1 year ago

The qt4 user wikipedia experience is so much better (smoother scrolling, page rendering much faster, no noisy fans)

maybe the difference between webengine and webkit . But webengine is evolving and webkit is dead. qt4 will not be supported , It's not in plan.

thenicegirl commented 1 year ago

It works better and returns to normal in my recent use, maybe it's because indexing causes high CPU usage issues when adding new dictionaries. I'll observe it for several days to oversee whether it's okay or not. @xiaoyifang

By the way, in my Windows 10 device, the Dark Reader Mode works properly #332, I dunno if it's due to Windows 11, but I expect you to fix it.

Edited: The sound issue has been solved after manually installing FFmpeg and invoking it as an external program. below is what I met previously, have a look as you wish. You had known the FFmpeg not working at 6.4.2 #331, so I changed to Qt Multimedia, it's audible, but only repeatedly plays the first word I searched, the other ones after the first one play the same sound, whatever I click every speaker icons on the page, it always plays the same.

xiaoyifang commented 1 year ago

it's audible, but only repeatedly plays the first word I searched, the other ones after the first one play the same sound, whatever I click every speaker icons on the page, it always plays the same.

seems a bug ,only happened when using qtmultimedia .,can you open a new issue to track this .

xiaoyifang commented 1 year ago

You had known the FFmpeg not working at 6.4.2 #331,

fixed with qt 6.4.3