[PATCH] D18718: [DependenceAnalysis] Check if result of getConstantPart is null
Sanjoy Das via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 1 17:04:30 PDT 2016
sanjoy accepted this revision.
sanjoy added a comment.
This revision is now accepted and ready to land.
Hi Brendan,
I'm not familiar with this code, but this change looks innocent enough that I LGTM'ed it.
However, I have a design nit: it looks like `getConstantPart` should be defined to take a `const SCEV *` and if it is a `SCEVConstant`, return that, else if it is `SCEVMulExpr` do what it does today and otherwise return `nullptr` -- it looks like that will fit in better with how `getConstantPart` is used. Moreover, a `SCEVConstantExpr` is really a degenerate `SCEVMulExpr` :) Do you mind doing that refactoring in a later change?
http://reviews.llvm.org/D18718
More information about the llvm-commits
mailing list