Change thread calculation to properly correct for absence of hyperthreading

Credit:  NuclearMistake

Backported from VanirAOSP, kk44 branch
http://vaniraosp.goo.im/#/c/9757/1

Change-Id: I8c08c13fcd47c6522ca21e5b70bd4043103beffd