intel / intel/opencl-clang

Compilation error opencl-clang/common_clang.cpp

Open
#85 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
C
Stars
140
Forks
92
Avg merge
8h 2m
Merged PRs (30d)
7

Description

Quite new to github, if this isn't the proper way to report, or even worse: the answer is already available elsewhere: please let me know!

I'm following the in-tree 4-in-1-build of llvm, clang, spir-v and open-clang. Branches used are release_80 .

I get this error when compiling opencl-clang/common_clang.cpp :

`ws/llvm/projects/opencl-clang/common_clang.cpp: In function ‘int Compile(const char*, const char**, unsigned int, const char**, const char*, size_t, const char*, const char*, const char*, Intel::OpenCL::ClangFE::IOCLFEBinaryResult**)’:
ws/llvm/projects/opencl-clang/common_clang.cpp:305:50: **error**: invalid initialization of reference of type ‘std::ostream& {aka std::basic_ostream&}’ from expression of type ‘llvm::raw_svector_ostream’
success = llvm::writeSpirv(M.get(), OS, Err);
^
In file included from ws/llvm/projects/opencl-clang/common_clang.cpp:56:0:
ws/llvm/projects/llvm-spirv/include/LLVMSPIRVLib.h:103:6: note: in passing argument 2 of ‘bool llvm::writeSpirv(llvm::Module*, std::ostream&, std::__cxx11::string&)’
bool writeSpirv(Module *M, std::ostream &OS, std::string &ErrMsg);`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.