[llvm-commits] CVS: llvm/utils/TableGen/IntrinsicEmitter.cpp

Chris Lattner sabre at nondot.org
Thu Feb 15 11:26:34 PST 2007



Changes in directory llvm/utils/TableGen:

IntrinsicEmitter.cpp updated: 1.28 -> 1.29
---
Log message:

the lengths of the strings are known, just use memcmp


---
Diffs of the changes:  (+1 -1)

 IntrinsicEmitter.cpp |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)


Index: llvm/utils/TableGen/IntrinsicEmitter.cpp
diff -u llvm/utils/TableGen/IntrinsicEmitter.cpp:1.28 llvm/utils/TableGen/IntrinsicEmitter.cpp:1.29
--- llvm/utils/TableGen/IntrinsicEmitter.cpp:1.28	Thu Feb 15 13:17:16 2007
+++ llvm/utils/TableGen/IntrinsicEmitter.cpp	Thu Feb 15 13:26:16 2007
@@ -93,7 +93,7 @@
     }
     
     OS << "    if (Len == " << I->first.size()
-       << " && !strcmp(Name, \"" << I->first << "\")) return Intrinsic::"
+       << " && !memcmp(Name, \"" << I->first << "\", Len)) return Intrinsic::"
        << I->second << ";\n";
   }
   OS << "  }\n";






More information about the llvm-commits mailing list