[llvm] r222093 - ScalarEvolution: HowFarToZero was wrongly using signed division
Tobias Grosser
tobias at grosser.es
Sun Nov 16 02:19:46 PST 2014
On 16.11.2014 08:30, David Majnemer wrote:
> Author: majnemer
> Date: Sun Nov 16 01:30:35 2014
> New Revision: 222093
>
> URL: http://llvm.org/viewvc/llvm-project?rev=222093&view=rev
> Log:
> ScalarEvolution: HowFarToZero was wrongly using signed division
>
> HowFarToZero was supposed to use unsigned division in order to calculate
> the backedge taken count. However, SCEVDivision::divide performs signed
> division. Unless I am mistaken, no users of SCEVDivision actually want
> signed arithmetic: switch to udiv and urem.
>
> This fixes PR21578.
This commit breaks a delinearization test case in polly.
I copied Sebastian who originally wrote the divide operation exactly as
part of our delinearization analysis. He is possibly the best person to
comment on this.
Cheers,
Tobias
More information about the llvm-commits
mailing list