jhuber6 added a comment. In D139287#4031503 <https://reviews.llvm.org/D139287#4031503>, @hbae wrote:
> In D139287#4031473 <https://reviews.llvm.org/D139287#4031473>, @jhuber6 wrote: > >> In D139287#4031469 <https://reviews.llvm.org/D139287#4031469>, @hbae wrote: >> >>> Looks like GCC 7.5 cannot build LLVM after this change. Could you please >>> take a look? >>> >>> In file included from >>> /localdisk/hbae/LLVM/llvm-base/openmp/libomptarget/plugins-nextgen/common/PluginInterface/PluginInterface.cpp:11:0: >>> >>> /localdisk/hbae/LLVM/llvm-base/openmp/libomptarget/plugins-nextgen/common/PluginInterface/PluginInterface.h: >>> In member function ‘virtual >>> llvm::Expected<std::unique_ptr<llvm::MemoryBuffer> > >>> llvm::omp::target::plugin::GenericDeviceTy::doJITPostProcessing(std::unique_ptr<llvm::MemoryBuffer>) >>> const’: >>> >>> /localdisk/hbae/LLVM/llvm-base/openmp/libomptarget/plugins-nextgen/common/PluginInterface/PluginInterface.h:389:12: >>> error: could not convert ‘MB’ from ‘std::unique_ptr<llvm::MemoryBuffer>’ >>> to ‘llvm::Expected<std::unique_ptr<llvm::MemoryBuffer> >’ >>> return MB; >>> ^~ >> >> Some older GCC's have problem with the implicit move on copy elision AFAIK. >> I'll add a `std::move` and let me know if that fixes it. > > Yes, that fixes it. We have two more places in JIT.cpp (line 126, 185). Thanks for pointing them out, I'll fix them right away. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139287/new/ https://reviews.llvm.org/D139287 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits