Don't upgrade functions that look like a bswap intrinsic but aren't.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35570 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Reid Spencer 2007-04-02 01:13:36 +00:00
parent 9277e3bbd3
commit de704f36c6

View File

@ -1457,7 +1457,7 @@ upgradeIntrinsicCall(const Type* RetTy, const ValID &ID,
}
break;
case 'b':
if (Name.length() > 10 && !memcmp(&Name[5], "bswap.", 6)) {
if (Name.length() == 14 && !memcmp(&Name[5], "bswap.i", 7)) {
const Type* ArgTy = Args[0]->getType();
Name += ".i" + utostr(cast<IntegerType>(ArgTy)->getBitWidth());
Function *F = cast<Function>(