[GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC
authorPetar Avramovic <Petar.Avramovic@rt-rk.com>
Tue, 27 Aug 2019 14:33:05 +0000 (14:33 +0000)
committerPetar Avramovic <Petar.Avramovic@rt-rk.com>
Tue, 27 Aug 2019 14:33:05 +0000 (14:33 +0000)
commita393238422ecadf56826d4f1a3562fbf2dcab849
treece23231c057dd7f96420436c3f66f16c92029dbf
parentd568ed40e0cbb4a069f9ed693f40254e24d9379a
[GlobalISel] Factor narrowScalar for G_ASHR and G_LSHR. NFC

Main difference is in the way Hi for Long shift (HiL) is made.
G_LSHR fills HiL with zeros, while G_ASHR fills HiL with sign bit value.

Differential Revision: https://reviews.llvm.org/D66589

llvm-svn: 370064
llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp