Hi CPU Usage even at rest - Printable Version +- QB64 Phoenix Edition (https://staging.qb64phoenix.com) +-- Forum: Chatting and Socializing (https://staging.qb64phoenix.com/forumdisplay.php?fid=11) +--- Forum: General Discussion (https://staging.qb64phoenix.com/forumdisplay.php?fid=2) +--- Thread: Hi CPU Usage even at rest (/showthread.php?tid=1402) Pages:
1
2
|
Hi CPU Usage even at rest - daivdW2 - 01-16-2023 Hello. First, I would like to say how much I am enjoying using QB64PE - This is my first post. I have installed QB64PE it on a Linux VM but I have noticed that it takes my CPU up beyond 90% even when only the IDE is open and no code is running (the fan screaming lets me know!) I have included two graphs below. The first with the larger area is QB64PE running a small program and then sitting in the IDE only. The second with the smaller area, is the same small program in QB64. Is there a known issue I should be aware of? RE: Hi CPU Usage even at rest - SMcNeill - 01-16-2023 I tried to reproduce this type of behavior with a version of Linux Mint, run via a VMware virtual machine, but I couldn't get it to idle with any real CPU usage. Is there something specific in the code you're running, which might contribute to the difference? Does it have several $INCLUDE files? Rely on several DECLARE LIBRARY calls? Is it a long set of code, such as the qb64pe.bas file itself? Usually such issues are nothing more than an endless loop without any sort of limit or delay in them. They run over and over and over, without pausing to let the CPU share resources with other processes like it should. The only issue is figuring out *where* in the vast sea of code that is qb64pe, one of these endless loops might be hiding. Any further details, or test code, which you can share, will help us try to pinpoint exactly what to be digging into for the issue. RE: Hi CPU Usage even at rest - daivdW2 - 01-16-2023 (01-16-2023, 12:58 PM)SMcNeill Wrote: I tried to reproduce this type of behavior with a version of Linux Mint, run via a VMware virtual machine, but I couldn't get it to idle with any real CPU usage. Is there something specific in the code you're running, which might contribute to the difference? Does it have several $INCLUDE files? Rely on several DECLARE LIBRARY calls? Is it a long set of code, such as the qb64pe.bas file itself? I am using Mint 21.1 with Cinnamon on a Proxmox Server. The VM has 4GB Ram, 64GB SDD, 4 Cores Just starting QB64PE takes the CPU up to 70% before loading the .bas file The code is below. I will try another VM and report back. Thx! Code: (Select All) Input "Day : "; d$ RE: Hi CPU Usage even at rest - mnrvovrfc - 01-16-2023 Welcome to the forums. Mis dos centavos. Virtualization is a really complex business, so much that the Oracle product refused to run on my 10-year-old PC. It doesn't seem to care neither how much RAM is installed. It's recommended to really install Linux Mint or whichever penguin and try again. Is your processor AMD? Because it seems there are difficulties trying to keep stuff up to date equal to Intel. It might have to do with Linux kernel as well and other factors. If you insist on virtualization I strongly recommend Fedora or Arch-based OS to test in. IJS, with the equipment you have which could well support a rolling-release distribution. Quote:I have included two graphs below. The first with the larger area is QB64PE running a small program and then sitting in the IDE only. Did you take the screenshots while one of the "INPUT" statements was being executed in your program? Which is this "QB64" that you mean, the "official" one (v2.1) or the "dot-org" one (last was v2.0.2)? RE: Hi CPU Usage even at rest - daivdW2 - 01-17-2023 (01-16-2023, 03:12 PM)mnrvovrfc Wrote: Welcome to the forums. Mis dos centavos. It was the QB64.com version - 2.1 it states on the download page. I took the graphs while the IDE was doing nothing other than sitting there with the code in edit mode. It had been run, a few times in fact. But was do nothing in particular at the time. I repeated the test on an Ubuntu 22.10 and got the following results - this time I also paid attention to the memory. On this occasion the CPU ran to about 60% but almost the entire 4GB of ram was used. I will try to find the time today to repeat this test on 'real' computers running the same OS's RE: Hi CPU Usage even at rest - SMcNeill - 01-17-2023 And test it out with our latest PE version as well, if you don't mind. See if we produce the same issue, or if it might be a change or such which they made to their version which doesn't apply with us. RE: Hi CPU Usage even at rest - daivdW2 - 01-17-2023 So, I thought I would try a Windows VM first. I downloaded the pre-compiled QB64PE 3.5.07 and performed the same test on Windows 10 VM with 4GB Ram, 2 Cores, 64GB SDD. It held a steady 15% CPU and just over 3.2 GB Ram. When executing the program (Running the bas file) , the CPU would go to 60% and drop back down again as soon as the program exited. The version on the Linux VMs is 3.5.0 (according to the about) and was built from source on the VMs using the setup_lnx.sh script. RE: Hi CPU Usage even at rest - mnrvovrfc - 01-17-2023 (01-17-2023, 12:20 PM)daivdW2 Wrote: It held a steady 15% CPU and just over 3.2 GB Ram. When executing the program (Running the bas file) , the CPU would go to 60% and drop back down again as soon as the program exited. This is entirely expected from any program entering and exiting, but only that. The fault might be with the task manager trying to measure things while another program is trying to set up (race conditions and other high-technical working stuff). The problem seems to be that you're also running the web browser, that is a big culprit of performance. If not then why do the filenames of the screenshots begin with "msedge"? If it's possible make sure no other programs are running except QB64PE and the task manager, then try these tests again. RE: Hi CPU Usage even at rest - daivdW2 - 01-19-2023 (01-17-2023, 05:43 PM)mnrvovrfc Wrote:(01-17-2023, 12:20 PM)daivdW2 Wrote: It held a steady 15% CPU and just over 3.2 GB Ram. When executing the program (Running the bas file) , the CPU would go to 60% and drop back down again as soon as the program exited. There were no web browsers running on the VMs. Only the OS, QB64PE and the RDP Service for remote access to the VM. The screenshots are labelled by the capture program which is called ShareX. ShareX is a tool on my Windows 11 laptop that I use to RDP into the VMs. ProxMox is a Hypervisor. It runs on my mini server and is the tool used to manage the VMs. It has a Web based admin panel and this is the source of the graphs. I have multiple screens so I can work on the VM using RDP to load QB64PE while watching the ProxMox stats. I hope that makes sense? RE: Hi CPU Usage even at rest - Fifi - 01-21-2023 (01-19-2023, 09:45 PM)daivdW2 Wrote: There were no web browsers running on the VMs. Only the OS, QB64PE and the RDP Service for remote access to the VM. The screenshots are labelled by the capture program which is called ShareX. Hi davidW2 May I suggest you try VMware Workstation Player as the VM tool Vs ShareX. It's free whatever your OS is and would eliminate the load of ProxMox and its connection to your mini server. You can get it here:VMware Player Just my two cents. Cheers. Fifi |