Make SCEV print <nsw><nuw> for Add/MulExpr.

llvm-svn: 145364
This commit is contained in:
Andrew Trick 2011-11-29 02:06:35 +00:00
parent a033165cf9
commit 975fe6c09b

View File

@ -188,6 +188,14 @@ void SCEV::print(raw_ostream &OS) const {
OS << OpStr;
}
OS << ")";
switch (NAry->getSCEVType()) {
case scAddExpr:
case scMulExpr:
if (NAry->getNoWrapFlags(FlagNUW))
OS << "<nuw>";
if (NAry->getNoWrapFlags(FlagNSW))
OS << "<nsw>";
}
return;
}
case scUDivExpr: {