]> granicus.if.org Git - llvm/commit
This converts a signed remainder instruction to unsigned remainder, which
authorSjoerd Meijer <sjoerd.meijer@arm.com>
Thu, 14 Jul 2016 12:23:48 +0000 (12:23 +0000)
committerSjoerd Meijer <sjoerd.meijer@arm.com>
Thu, 14 Jul 2016 12:23:48 +0000 (12:23 +0000)
commit4fab1d4f07d728d5f2d0831ceaebf4b0dbed79d7
tree17f084467f368f771789eac3d6d2cbdfcd806966
parent2bb340ccad0c871d553436e73ecde17ff78044f0
This converts a signed remainder instruction to unsigned remainder, which
enables the code size optimisation to fold a rem and div into a single
aeabi_uidivmod call. This was not happening before because sdiv was converted
but srem not, and instructions with different signedness are not combined.

Differential Revision: http://reviews.llvm.org/D22214

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@275403 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/CorrelatedValuePropagation.cpp
test/Transforms/CorrelatedValuePropagation/srem.ll [new file with mode: 0644]