Reapply fix PR23384 (part 3 of 3) r304824 (was reverted in r305720).
The root cause of reverting was fixed - PR33514.
The patch makes instruction count the highest priority for
LSR solution for X86 (previously registers had highest priority).
Differential Revision: http://reviews.llvm.org/D30562
From: Evgeny Stupachenko <email@example.com>