[llvm-commits] CVS: llvm/tools/llvm-upgrade/UpgradeParser.y
Reid Spencer
reid at x10sys.com
Sat Dec 9 11:40:56 PST 2006
Changes in directory llvm/tools/llvm-upgrade:
UpgradeParser.y updated: 1.23 -> 1.24
---
Log message:
Fix test/Regression/Assembler/2006-12-09-Cast-To-Bool.ll
Do not upgrade casts of bool to bool.
---
Diffs of the changes: (+1 -1)
UpgradeParser.y | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)
Index: llvm/tools/llvm-upgrade/UpgradeParser.y
diff -u llvm/tools/llvm-upgrade/UpgradeParser.y:1.23 llvm/tools/llvm-upgrade/UpgradeParser.y:1.24
--- llvm/tools/llvm-upgrade/UpgradeParser.y:1.23 Sat Dec 9 10:56:55 2006
+++ llvm/tools/llvm-upgrade/UpgradeParser.y Sat Dec 9 13:40:41 2006
@@ -188,7 +188,7 @@
SrcTy.destroy();
SrcTy.newTy = new std::string("ulong");
SrcTy.oldTy = ULongTy;
- } else if (DstTy.oldTy == BoolTy) {
+ } else if (DstTy.oldTy == BoolTy && SrcTy.oldTy != BoolTy) {
// cast ptr %x to bool was previously defined as setne ptr %x, null
// The ptrtoint semantic is to truncate, not compare so we must retain
// the original intent by replace the cast with a setne
More information about the llvm-commits
mailing list