HomePhabricator

[SCEV] Match 'zext (trunc A to iB) to iY' as URem.

Authored by fhahn on Oct 29 2020, 2:30 AM.

Description

[SCEV] Match 'zext (trunc A to iB) to iY' as URem.

URem operations with constant power-of-2 second operands are modeled as
such. This patch on its own has very little impact (e.g. no changes in
CodeGen for MultiSource/SPEC2000/SPEC2006 on X86 -O3 -flto), but I'll
soon post follow-up patches that make use of it to more accurately
determine the trip multiple.

Reviewed By: mkazantsev

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

Details

Committed
fhahnOct 29 2020, 3:46 AM
Reviewer
mkazantsev
Differential Revision
D89821: [SCEV] Match 'zext (trunc A to iB) to iY' as URem.
Parents
rG79c5b4c546bb: [NFC] Add some new util functions to ICmpInst
Branches
Unknown
Tags
Unknown