[Mesa-dev] [PATCH] st/clover: Fix build against LLVM 3.8 SVN r244928

Francisco Jerez currojerez at riseup.net
Fri Aug 14 02:25:29 PDT 2015


Michel Dänzer <michel at daenzer.net> writes:

> From: Michel Dänzer <michel.daenzer at amd.com>
>
> raw_svector_ostream::flush() is now unnecessary and forbidden:
>
>   CXX      llvm/libclllvm_la-invocation.lo
> ../../../../../src/gallium/state_trackers/clover/llvm/invocation.cpp: In function 'clover::module {anonymous}::build_module_llvm(llvm::Module*, unsigned int (&)[7])':
> ../../../../../src/gallium/state_trackers/clover/llvm/invocation.cpp:574:29: error: use of deleted function 'void llvm::raw_svector_ostream::flush()'
>        bitcode_ostream.flush();
>                              ^
> In file included from /home/daenzer/src/llvm-git/llvm/include/clang/Basic/VirtualFileSystem.h:22:0,
>                  from /home/daenzer/src/llvm-git/llvm/include/clang/Basic/FileManager.h:20,
>                  from /home/daenzer/src/llvm-git/llvm/include/clang/Basic/SourceManager.h:38,
>                  from /home/daenzer/src/llvm-git/llvm/include/clang/Frontend/CompilerInstance.h:16,
>                  from ../../../../../src/gallium/state_trackers/clover/llvm/invocation.cpp:25:
> /home/daenzer/src/llvm-git/llvm/include/llvm/Support/raw_ostream.h:512:8: note: declared here
>    void flush() = delete;
>         ^
> Makefile:862: recipe for target 'llvm/libclllvm_la-invocation.lo' failed
>
> Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>

Thanks,

Reviewed-by: Francisco Jerez <currojerez at riseup.net>

> ---
>  src/gallium/state_trackers/clover/llvm/invocation.cpp | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/src/gallium/state_trackers/clover/llvm/invocation.cpp b/src/gallium/state_trackers/clover/llvm/invocation.cpp
> index 86859af..63c3f8e 100644
> --- a/src/gallium/state_trackers/clover/llvm/invocation.cpp
> +++ b/src/gallium/state_trackers/clover/llvm/invocation.cpp
> @@ -571,7 +571,9 @@ namespace {
>        llvm::raw_svector_ostream bitcode_ostream(llvm_bitcode);
>        llvm::BitstreamWriter writer(llvm_bitcode);
>        llvm::WriteBitcodeToFile(mod, bitcode_ostream);
> +#if HAVE_LLVM < 0x0308
>        bitcode_ostream.flush();
> +#endif
>  
>        const std::vector<llvm::Function *> kernels = find_kernels(mod);
>        for (unsigned i = 0; i < kernels.size(); ++i) {
> -- 
> 2.5.0
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 212 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20150814/795a8bd6/attachment.sig>


More information about the mesa-dev mailing list