Fix -Wpessimizing-move warnings by removing std::move calls.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236278 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Richard Trieu 2015-04-30 23:07:00 +00:00
parent b6b3a92b97
commit 509e9d9471
3 changed files with 7 additions and 7 deletions

View File

@ -680,7 +680,7 @@ LoopInfo LoopAnalysis::run(Function &F, AnalysisManager<Function> *AM) {
// the problem is better understood.
LoopInfo LI;
LI.Analyze(AM->getResult<DominatorTreeAnalysis>(F));
return std::move(LI);
return LI;
}
PreservedAnalyses LoopPrinterPass::run(Function &F,

View File

@ -3920,7 +3920,7 @@ APFloat::makeZero(bool Negative) {
APFloat llvm::scalbn(APFloat X, int Exp) {
if (X.isInfinity() || X.isZero() || X.isNaN())
return std::move(X);
return X;
auto MaxExp = X.getSemantics().maxExponent;
auto MinExp = X.getSemantics().minExponent;
@ -3932,5 +3932,5 @@ APFloat llvm::scalbn(APFloat X, int Exp) {
return APFloat::getZero(X.getSemantics(), X.isNegative());
X.exponent += Exp;
return std::move(X);
return X;
}

View File

@ -62,7 +62,7 @@ OrcLazyJIT::TransformFtor OrcLazyJIT::createDebugDumper() {
switch (OrcDumpKind) {
case DumpKind::NoDump:
return [](std::unique_ptr<Module> M) { return std::move(M); };
return [](std::unique_ptr<Module> M) { return M; };
case DumpKind::DumpFuncsToStdOut:
return [](std::unique_ptr<Module> M) {
@ -80,7 +80,7 @@ OrcLazyJIT::TransformFtor OrcLazyJIT::createDebugDumper() {
}
printf("]\n");
return std::move(M);
return M;
};
case DumpKind::DumpModsToStdErr:
@ -88,7 +88,7 @@ OrcLazyJIT::TransformFtor OrcLazyJIT::createDebugDumper() {
dbgs() << "----- Module Start -----\n" << *M
<< "----- Module End -----\n";
return std::move(M);
return M;
};
case DumpKind::DumpModsToDisk:
@ -102,7 +102,7 @@ OrcLazyJIT::TransformFtor OrcLazyJIT::createDebugDumper() {
exit(1);
}
Out << *M;
return std::move(M);
return M;
};
}
llvm_unreachable("Unknown DumpKind");