diff options
| author | Nick Lewycky <nicholas@mxc.ca> | 2012-12-26 22:00:35 +0000 |
|---|---|---|
| committer | Nick Lewycky <nicholas@mxc.ca> | 2012-12-26 22:00:35 +0000 |
| commit | 90053a12146b5e4361e3dbabee179c16468235a7 (patch) | |
| tree | 832c4fb1d7d7f536b66926b5c003d4115b17a06f /llvm/lib/Transforms/InstCombine | |
| parent | 1b8c0750eee39b0c112da71df744d27f1e03dc7d (diff) | |
| download | bcm5719-llvm-90053a12146b5e4361e3dbabee179c16468235a7.tar.gz bcm5719-llvm-90053a12146b5e4361e3dbabee179c16468235a7.zip | |
Remove mid-optimizer warning. This situation should be handled differently,
such as by a compiler warning, a check in clang -fsanitizer=undefined, being
optimized to unreachable, or a combination of the above. PR14722.
llvm-svn: 171119
Diffstat (limited to 'llvm/lib/Transforms/InstCombine')
| -rw-r--r-- | llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp b/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp index 4849463b5a1..23306b4079b 100644 --- a/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp +++ b/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp @@ -1153,11 +1153,8 @@ bool InstCombiner::transformConstExprCastCall(CallSite CS) { // If we are removing arguments to the function, emit an obnoxious warning. if (FT->getNumParams() < NumActualArgs) { - if (!FT->isVarArg()) { - FT->getContext().emitWarning("while resolving call to function '" + - Callee->getName() + - "' arguments were dropped"); - } else { + // TODO: if (!FT->isVarArg()) this call may be unreachable. PR14722 + if (FT->isVarArg()) { // Add all of the arguments in their promoted form to the arg list. for (unsigned i = FT->getNumParams(); i != NumActualArgs; ++i, ++AI) { Type *PTy = getPromotedType((*AI)->getType()); |

