Unverified Commit 54a9f000 authored by annamthomas's avatar annamthomas Committed by GitHub
Browse files

[SCEV] Fix BinomialCoefficient Iteration to fit in W bits (#88010)

BinomialCoefficient computes the value of W-bit IV at iteration It of a loop. When W is 1, we can call multiplicative inverse on 0 which triggers an assert since 1b761205.
    
Since the arithmetic is supposed to wrap if It or K does not fit in W bits, do the truncation into W bits after we do the shift.
    
 Fixes #87798
parent 49ef12a0
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment