diff options
author | Owen Anderson <resistor@mac.com> | 2008-08-26 18:50:00 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2008-08-26 18:50:00 +0000 |
commit | 3ea3efec44f4e756b4f2e7feb0bc48d114ae3224 (patch) | |
tree | 8c0f36bd1cecfadbc8188f6f692db92e064dea9c /llvm/utils/TableGen/FastISelEmitter.cpp | |
parent | 27fb3dcbc738451856f641c70c94ed44a6b44ffd (diff) | |
download | bcm5719-llvm-3ea3efec44f4e756b4f2e7feb0bc48d114ae3224.tar.gz bcm5719-llvm-3ea3efec44f4e756b4f2e7feb0bc48d114ae3224.zip |
We need to check that the return type is correct, even in cases where we don't
have a return type that differs from the operand types.
llvm-svn: 55376
Diffstat (limited to 'llvm/utils/TableGen/FastISelEmitter.cpp')
-rw-r--r-- | llvm/utils/TableGen/FastISelEmitter.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/utils/TableGen/FastISelEmitter.cpp b/llvm/utils/TableGen/FastISelEmitter.cpp index c9978e5311c..20b39c6089f 100644 --- a/llvm/utils/TableGen/FastISelEmitter.cpp +++ b/llvm/utils/TableGen/FastISelEmitter.cpp @@ -437,6 +437,9 @@ void FastISelEmitter::run(std::ostream &OS) { Operands.PrintParameters(OS); OS << ") {\n"; + OS << " if (RetVT != " << getName(RM.begin()->first) + << ")\n return 0;\n"; + const PredMap &PM = RM.begin()->second; bool HasPred = false; |