Does more CPU cores make HB use more RAM?

General questions or discussion about HandBrake, Video and/or audio transcoding, trends etc.
Post Reply
Sprinterdriver
Posts: 36
Joined: Wed Jun 05, 2013 9:43 pm

Does more CPU cores make HB use more RAM?

Post by Sprinterdriver »

Hi.

Simple question, but I feel the need to know this.

Will Handbrake use more ram if the number of CPU cores increases? Would an CPU upgrade from dual core to quad-core make Handbrake use twice as much RAM.

I have a computer with 4 cores, and 4 Gb RAM. I sometimes experience that HB get out of RAM. Why isn't there an option to use page file, even that I know it would kill the speed (can afford the computer to run for days anyways)?


Thanks in advance :D
Deleted User 11865

Re: Does more CPU cores make HB use more RAM?

Post by Deleted User 11865 »

No. It used to be that we had larger FIFOs depending on the CPU count, but this is no longer the case.

One way to decrease memory usage would be to reduce the size of the lookahead (e.g. add rc-lookahead=20 to the additional options string - default is 40).

Also, are you using the 64-bit build or the 32-bit one?
Sprinterdriver
Posts: 36
Joined: Wed Jun 05, 2013 9:43 pm

Re: Does more CPU cores make HB use more RAM?

Post by Sprinterdriver »

Hi. Thanks for answering.

I'm currently using 32 bit, but I'm planning to upgrade OS to 64 bit Windows 7. However, the computer have "only" 4 Gb ram, so I'm concern that I need to upgrade the ram as well in order to being able to convert the video clips I've recorded.
mduell
Veteran User
Posts: 8187
Joined: Sat Apr 21, 2007 8:54 pm

Re: Does more CPU cores make HB use more RAM?

Post by mduell »

32-bit is probably your real problem, with 64-bit you could use swap (as slow as it would be).
Deleted User 11865

Re: Does more CPU cores make HB use more RAM?

Post by Deleted User 11865 »

If you don't mind losing some compression efficiency, you could always try these advanced settings to reduce memory usage in the meantime:

Code: Select all

rc-lookahead=0:no-mbtree=1
Wetnap
Posts: 29
Joined: Thu Jun 05, 2008 8:31 am

Re: Does more CPU cores make HB use more RAM?

Post by Wetnap »

Sprinterdriver wrote:Hi. Thanks for answering.

I'm currently using 32 bit, but I'm planning to upgrade OS to 64 bit Windows 7. However, the computer have "only" 4 Gb ram, so I'm concern that I need to upgrade the ram as well in order to being able to convert the video clips I've recorded.
Its not a concern, handbrake only uses a couple hundred mb at most from what I've seen it do, after all its compressing video, its mostly the processor crunching through a series of frames..

Just don't worry about it, 4Gb is more than enough for just encoding video.
Deleted User 11865

Re: Does more CPU cores make HB use more RAM?

Post by Deleted User 11865 »

For 1080p with the lookahead, if we include audio and a bit of buffering in the muxers, we sometimes hit the 2 GB per-process limit under Windows.
Sprinterdriver
Posts: 36
Joined: Wed Jun 05, 2013 9:43 pm

Re: Does more CPU cores make HB use more RAM?

Post by Sprinterdriver »

You know what feature I think have been great? To let HB monitoring it's amount of used memory, and when it reaches close to the limit of avaiable RAM, HB adjust the rc-lookahead and no-mbtree to use less RAM :D
User avatar
s55
HandBrake Team
Posts: 10350
Joined: Sun Dec 24, 2006 1:05 pm

Re: Does more CPU cores make HB use more RAM?

Post by s55 »

It's not as simple as that.

The more likely scenario is we simply drop 32bit builds altogether. (we already did so for Mac almost 2 years ago now)
Unfortunately, Microsoft was slower at pushing 64bit and the prevalence of XP has meant we've had to continue longer than we would have liked on the Windows side.
drefk2000
Posts: 3
Joined: Thu Dec 05, 2013 5:39 pm

Re: Does more CPU cores make HB use more RAM?

Post by drefk2000 »

I don't know about ram but you want as many cores as posible, When I started ripping my collection I had an old dual core processor and a bit in I changed to a hexacore. The time it took to rip was dramaticly changed.
Post Reply