Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
05-01-2014, 10:19 AM
|
#1
|
Senior Member
Registered: May 2010
Distribution: No more Linux. Done with it.
Posts: 1,238
Rep:
|
Why doesn't kdenlive load my 4 core CPU 100%?
Hi guys. When I render video in kdenlive on my Phenom X4 9650 I specify rendering for all 4 cores (selecting number of threads before hitting "Start rendering" button). But during rendering process all 4 cores are loaded about a half of their resource (as conky shows). Why does it happen? Why doesn't kdenlive use 100% of my CPU even if I make necessary configuration before processing?
|
|
|
05-01-2014, 11:48 AM
|
#2
|
Member
Registered: Aug 2009
Location: /Universe/Earth/India/Pune
Distribution: Slackware64 -Current
Posts: 890
Rep:
|
Quote:
Originally Posted by Mr. Alex
Hi guys. When I render video in kdenlive on my Phenom X4 9650 I specify rendering for all 4 cores (selecting number of threads before hitting "Start rendering" button). But during rendering process all 4 cores are loaded about a half of their resource (as conky shows). Why does it happen? Why doesn't kdenlive use 100% of my CPU even if I make necessary configuration before processing?
|
You mean you set the CPU affinity using taskset?
Regards.
|
|
|
05-01-2014, 02:11 PM
|
#3
|
Senior Member
Registered: May 2010
Distribution: No more Linux. Done with it.
Posts: 1,238
Original Poster
Rep:
|
|
|
|
05-01-2014, 02:18 PM
|
#4
|
Senior Member
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,278
|
Quick test,.. if you select 1 cpu and time it, does it take 4x the time it would with all four cpu's selected?
Also, if you select 1 cpu, does it use 100% of the cpu? if you select two does it use 50% on each? if you select 4 does it use 25% a piece?
If so, it seems like the scheduling that they are using in the program itself is causing the odd behavior. Perhaps not suited for multiprocessor usage.
|
|
|
05-02-2014, 03:34 AM
|
#5
|
Member
Registered: Aug 2009
Location: /Universe/Earth/India/Pune
Distribution: Slackware64 -Current
Posts: 890
Rep:
|
I may be wrong but I suspect this is the way Completely Fair Scheduler works in Linux. In my 4-core Intel i5, I use 2-3 VMs at the same time but not all the cores go to 100% at the same time. Most of the time they are used like 50-70% each.
Regards.
|
|
|
05-02-2014, 04:46 AM
|
#6
|
Senior Member
Registered: May 2010
Distribution: No more Linux. Done with it.
Posts: 1,238
Original Poster
Rep:
|
I use BFS. Does it behave the same way?
|
|
|
05-02-2014, 04:58 AM
|
#7
|
Member
Registered: Aug 2009
Location: /Universe/Earth/India/Pune
Distribution: Slackware64 -Current
Posts: 890
Rep:
|
I have no idea how BFS works and what it's implementation is. May be you can try reaching it's maintainer.
Regards.
|
|
|
05-02-2014, 05:19 AM
|
#8
|
Senior Member
Registered: May 2010
Distribution: No more Linux. Done with it.
Posts: 1,238
Original Poster
Rep:
|
Quote:
Originally Posted by szboardstretcher
Quick test,.. if you select 1 cpu and time it, does it take 4x the time it would with all four cpu's selected?
Also, if you select 1 cpu, does it use 100% of the cpu? if you select two does it use 50% on each? if you select 4 does it use 25% a piece?
|
If I, for example, select 2 cores in that window, it doesn't make the situation any more clear. Estimated time becomes only about 1 minute more and CPU cores are loaded chaotically.
Quote:
Originally Posted by PrinceCruise
I have no idea how BFS works and what it's implementation is. May be you can try reaching it's maintainer.
|
I guess that's about the only way to find out.
|
|
|
05-02-2014, 05:56 AM
|
#9
|
LQ Veteran
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,251
|
Very unlikely to be a scheduler issue. I regularly run multiple cores up to near 100% (CFS, not BFS).
If a multi-threaded application can't run cores to (near) 100%, it's usually because:
- it doesn't have the workload to need all those cores, or
- it isn't truly independent when threaded, some resource(s) - mutex, semaphore, shared memory, whatever - is in contention.
Better to talk to the applicaion support than scheduler - at least initially. Latencytop might help spot contention.
Last edited by syg00; 05-02-2014 at 05:57 AM.
Reason: typos
|
|
|
05-02-2014, 06:40 AM
|
#10
|
Senior Member
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,912
|
Very likely each thread is on a different CPU... But each thread must also perform I/O, and during that delay, the CPU is idle, thus the 50% load.
Try setting to 6 threads... that way more I/O will be overlapped by processing done by other threads.
PS: I think your load should go to 75+%. You don't really want it to go much higher than that as you want to monitor the system as well.
Last edited by jpollard; 05-02-2014 at 06:43 AM.
|
|
1 members found this post helpful.
|
05-02-2014, 06:48 AM
|
#11
|
Senior Member
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,505
|
Quote:
Originally Posted by jpollard
Very likely each thread is on a different CPU... But each thread must also perform I/O, and during that delay, the CPU is idle, thus the 50% load.
|
I'd tend to agree here. People tend to forget about IO requirements, also your disk, your choice of disks, your raid controller, raid level etc. will all make a difference. For example on a recent "real world" scenario we could decrease an 18+ hour import to 6 hours simply by changing from RAID5 to RAID1+0.
With any software/process it's rather simplistic to hope that using 4 threads will cause the process to run 4 times faster than 1 thread if there's any form of IO involved.
|
|
|
05-02-2014, 06:51 AM
|
#12
|
Senior Member
Registered: May 2010
Distribution: No more Linux. Done with it.
Posts: 1,238
Original Poster
Rep:
|
Quote:
Originally Posted by jpollard
Try setting to 6 threads... that way more I/O will be overlapped by processing done by other threads.
|
I can't do it. If I try to type in some number higher than 4, kdenlive doesn't allow me to do that (nothing is entered).
|
|
|
05-02-2014, 06:53 AM
|
#13
|
Senior Member
Registered: May 2010
Distribution: No more Linux. Done with it.
Posts: 1,238
Original Poster
Rep:
|
Quote:
Originally Posted by TenTenths
I'd tend to agree here. People tend to forget about IO requirements, also your disk, your choice of disks, your raid controller, raid level etc. will all make a difference. For example on a recent "real world" scenario we could decrease an 18+ hour import to 6 hours simply by changing from RAID5 to RAID1+0.
With any software/process it's rather simplistic to hope that using 4 threads will cause the process to run 4 times faster than 1 thread if there's any form of IO involved.
|
But during the rendering process my HDD led doesn't glow all the time. It blinks. Doesn't it mean HDD I/O isn't loaded 100% also?
|
|
|
05-02-2014, 02:59 PM
|
#14
|
Senior Member
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,912
|
Quote:
Originally Posted by Mr. Alex
But during the rendering process my HDD led doesn't glow all the time. It blinks. Doesn't it mean HDD I/O isn't loaded 100% also?
|
It isn't - only about 50% of the time is it actually busy. And it may actually be less as the light takes time to come on, and time to go off after the signal comes in.
|
|
1 members found this post helpful.
|
05-03-2014, 02:31 AM
|
#15
|
Senior Member
Registered: May 2010
Distribution: No more Linux. Done with it.
Posts: 1,238
Original Poster
Rep:
|
jpollard, then what part of PC is loaded 100% during this process?
|
|
|
All times are GMT -5. The time now is 11:46 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|