View Single Post
Old 2nd October 2013, 04:07   #7  |  Link
Gregleto
Registered User
 
Join Date: Sep 2013
Posts: 38
So based on the feedback here, below is the formula for properly setting threads that seems to make sense to me.

Threads should be equal to the lesser result of the following two calculations…
1. The number of logical processors multiplied by 1.5
2. The number of vertical pixels of video divided by 40

Examples
A. Video encoded to 640x360 on a machine with a total of 8-cores and hyperthreading enabled.
(8 cores with hyperthreading equals 16 logical processors)
1. 16*1.5 = 24
2. 360/40 = 9
Set threads to 9 (the lower result)

B. Video encoded to 1280x720 on a machine with a total of 4-cores and hyperthreading enabled.
(4 cores with hyperthreading equals 8 logical processors)
1. 8*1.5 = 12
2. 720/40 = 18
Set threads to 12 (the lower result)

C. Video encoded to 1920x1080 on a machine with a total of 12-cores and hyperthreading enabled.
(12 cores with hyperthreading equals 24 logical processors)
1. 24*1.5 = 36
2. 1080/40 = 27
Set threads to 27 (the lower result)

Based on recent feedback and my (limited) understanding, with threads set to “auto” in x264, examples A and C would both result in an excessively high number of threads that could/may hinder performance and/or negatively affect quality.

If anyone sees any problems with this approach please let me know.

Thanks,

Gregleto
Gregleto is offline   Reply With Quote