[GlobalISel] ComputeKnownBits - use common KnownBits shift handling (PR44526)
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 5 Nov 2020 11:52:07 +0000 (11:52 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 5 Nov 2020 11:52:26 +0000 (11:52 +0000)
commit546d002d7a5d0915ab449a3134b9737edc059378
tree4abb70dafefd70164798c4f4fab5bf0db9e97181
parentd025df3c1decf125c73c488b62bafc78a500a5c5
[GlobalISel] ComputeKnownBits - use common KnownBits shift handling (PR44526)

Convert GISelKnownBits.computeKnownBitsImpl shift handling to use the common KnownBits implementations, which makes use of the known leading/trailing bits for shifted values in cases where we don't know the shift amount value, as detailed in https://blog.regehr.org/archives/1709

Differential Revision: https://reviews.llvm.org/D90527
llvm/lib/CodeGen/GlobalISel/GISelKnownBits.cpp
llvm/test/CodeGen/AMDGPU/GlobalISel/lshr.ll