(original) (raw)
Hi,
I have a SCEV like this: {16,+,8}. Say that this came from a loop like:
int64\_t \*p;
for (int64\_t i = 0; i < ...; ++i)
I have a SCEV like this: {16,+,8}. Say that this came from a loop like:
int64\_t \*p;
for (int64\_t i = 0; i < ...; ++i)
p\[i+2\]...
And assuming that I'm on a 64-bit machine. What I would like to do is normalize it
like that, basically this: {2,+,1} i.e. map it to the index.
Now, I tried to get the underlying element size of the pointer, then getUDivExpr(OriginalSCEV, ElementSize); But I don't get the desired SCEV back. Instead I'm getting:
{16,+,8} \\u 8, i.e. just adding udiv in the original expression.
Why is this not simplified?
Why is this not simplified?
Thanks,
Stefanos Baziotis
Stefanos Baziotis