Skip to content
Commit 71b70841 authored by Hal Finkel's avatar Hal Finkel
Browse files

[AlignmentFromAssumptions] Don't divide by zero for unknown starting alignment

The routine that determines an alignment given some SCEV returns zero if the
answer is unknown. In a case where we could determine the increment of an
AddRec but not the starting alignment, we would compute the integer modulus by
zero (which is illegal and traps). Prevent this by returning early if either
the start or increment alignment is unknown (zero).

llvm-svn: 217544
parent d13951ff
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment