This is an archive of the discontinued LLVM Phabricator instance.

Removing redundant-move warnings generated by gcc9x.
Needs RevisionPublic

Authored by zahiraam on Aug 5 2019, 1:39 PM.

Diff Detail

Event Timeline

zahiraam created this revision.Aug 5 2019, 1:39 PM
thopre added inline comments.Aug 5 2019, 1:48 PM
llvm/lib/Support/FileCheck.cpp
345

I fixed a build failure with -Werror where GCC was the host compiler by doing the reverse change. So this change would most likely result on build failure when host compiler is GCC <9.x

llvm/tools/llvm-objcopy/CopyConfig.cpp
573

khm, wouldn't it break the builds using MSVC ? https://gcc.godbolt.org/z/esJH6J

Isn't clang warning in the other direction? (incompatible with GCC)

Isn't clang warning in the other direction? (incompatible with GCC)

Some past reference: http://lists.llvm.org/pipermail/llvm-dev/2018-September/126471.html

rupprecht requested changes to this revision.Aug 7 2019, 12:02 PM

Agree with all these comments -- I'm no expert on when and when not to std::move, but this is undoing changes I've made to fix buildbots on different compilers.

This revision now requires changes to proceed.Aug 7 2019, 12:02 PM

Agree with all these comments -- I'm no expert on when and when not to std::move, but this is undoing changes I've made to fix buildbots on different compilers.

I agree. This is probably more aggressive than I anticipated. I am looking at them and trying to figure out which and if some of them can stay.