diff options
| author | Dan Gohman <gohman@apple.com> | 2007-08-16 21:57:19 +0000 |
|---|---|---|
| committer | Dan Gohman <gohman@apple.com> | 2007-08-16 21:57:19 +0000 |
| commit | febf946ea7591f01417c8dc735a96039dea4401c (patch) | |
| tree | cc6eb2d545221e322b4de9cf1953d8a970d8f3f6 /llvm/lib/VMCore/Verifier.cpp | |
| parent | cdee44c12a3f5a381eeb06e5ac0c65f1dfe273aa (diff) | |
| download | bcm5719-llvm-febf946ea7591f01417c8dc735a96039dea4401c.tar.gz bcm5719-llvm-febf946ea7591f01417c8dc735a96039dea4401c.zip | |
Add MVT::fAny for overloading intrinsics on floating-point types.
llvm-svn: 41128
Diffstat (limited to 'llvm/lib/VMCore/Verifier.cpp')
| -rw-r--r-- | llvm/lib/VMCore/Verifier.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/lib/VMCore/Verifier.cpp b/llvm/lib/VMCore/Verifier.cpp index c01f0fe9cc1..0c4ca642098 100644 --- a/llvm/lib/VMCore/Verifier.cpp +++ b/llvm/lib/VMCore/Verifier.cpp @@ -1157,6 +1157,20 @@ void Verifier::VerifyIntrinsicPrototype(Intrinsic::ID ID, CheckFailed("Intrinsic requires even byte width argument", F); break; } + } else if (VT == MVT::fAny) { + Suffix += "."; + if (EltTy != Ty) + Suffix += "v" + utostr(NumElts); + Suffix += MVT::getValueTypeString(MVT::getValueType(EltTy)); + if (!EltTy->isFloatingPoint()) { + if (ArgNo == 0) + CheckFailed("Intrinsic result type is not " + "a floating-point type.", F); + else + CheckFailed("Intrinsic parameter #" + utostr(ArgNo-1) + " is not " + "a floating-point type.", F); + break; + } } else if (VT == MVT::iPTR) { if (!isa<PointerType>(Ty)) { CheckFailed("Intrinsic parameter #" + utostr(ArgNo-1) + " is not a " |

