search for: flagnuw

Displaying 4 results from an estimated 4 matches for "flagnuw".

2013 Oct 01
3
[LLVMdev] ScalarEvolution::createNodeForPHI
...alueV (ScalarEvoluton.cpp:3099-3113), but only Add and GEP operators are checked. //-------------------------------------------------------------------------// if (const AddOperator *OBO = dyn_cast<AddOperator>(BEValueV)) { if (OBO->hasNoUnsignedWrap()) Flags = setFlags(Flags, SCEV::FlagNUW); if (OBO->hasNoSignedWrap()) Flags = setFlags(Flags, SCEV::FlagNSW); } else if (const GEPOperator *GEP = dyn_cast<GEPOperator>(BEValueV)) { // If the increment is an inbounds GEP, then we know the address // space cannot be wrapped around. We cannot make any guarant...
2015 Jan 15
4
[LLVMdev] confusion w.r.t. scalar evolution and nuw
...onstant ranges) in ScalarEvolution::getUnsignedRange, the following code could fire: if (const SCEVAddRecExpr *AddRec = dyn_cast<SCEVAddRecExpr>(S)) { // If there's no unsigned wrap, the value will never be less than its // initial value. if (AddRec->getNoWrapFlags(SCEV::FlagNUW)) if (const SCEVConstant *C = dyn_cast<SCEVConstant>(AddRec->getStart())) if (!C->getValue()->isZero()) ConservativeResult = ConservativeResult.intersectWith( ConstantRange(C->getValue()->getValue(), APInt(BitWidth, 0))); and c...
2013 Oct 02
0
[LLVMdev] ScalarEvolution::createNodeForPHI
...pp:3099-3113), but only Add and GEP operators are checked. > > //-------------------------------------------------------------------------// > if (const AddOperator *OBO = dyn_cast<AddOperator>(BEValueV)) { > if (OBO->hasNoUnsignedWrap()) > Flags = setFlags(Flags, SCEV::FlagNUW); > if (OBO->hasNoSignedWrap()) > Flags = setFlags(Flags, SCEV::FlagNSW); > } else if (const GEPOperator *GEP = > dyn_cast<GEPOperator>(BEValueV)) { > // If the increment is an inbounds GEP, then we know the address > // space cannot be wrapped around. W...
2013 Oct 02
1
[LLVMdev] ScalarEvolution::createNodeForPHI
...operators are > > checked. > > > > //-------------------------------------------------------------------------// > > if (const AddOperator *OBO = dyn_cast<AddOperator>(BEValueV)) { > > if (OBO->hasNoUnsignedWrap()) > > Flags = setFlags(Flags, SCEV::FlagNUW); > > if (OBO->hasNoSignedWrap()) > > Flags = setFlags(Flags, SCEV::FlagNSW); > > } else if (const GEPOperator *GEP = > > dyn_cast<GEPOperator>(BEValueV)) { > > // If the increment is an inbounds GEP, then we know the address > > // spa...