{"action":"created","issue":{"url":"https://api.github.com/repos/Keno/Cxx.jl/issues/159","labels_url":"https://api.github.com/repos/Keno/Cxx.jl/issues/159/labels{/name}","comments_url":"https://api.github.com/repos/Keno/Cxx.jl/issues/159/comments","events_url":"https://api.github.com/repos/Keno/Cxx.jl/issues/159/events","html_url":"https://github.com/Keno/Cxx.jl/issues/159","id":106947311,"number":159,"title":"Cxx compiling error with julia-4.0 and LLVM-3.8  ","user":{"login":"ibadami","id":4718068,"avatar_url":"https://avatars.githubusercontent.com/u/4718068?v=3","gravatar_id":"","url":"https://api.github.com/users/ibadami","html_url":"https://github.com/ibadami","followers_url":"https://api.github.com/users/ibadami/followers","following_url":"https://api.github.com/users/ibadami/following{/other_user}","gists_url":"https://api.github.com/users/ibadami/gists{/gist_id}","starred_url":"https://api.github.com/users/ibadami/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ibadami/subscriptions","organizations_url":"https://api.github.com/users/ibadami/orgs","repos_url":"https://api.github.com/users/ibadami/repos","events_url":"https://api.github.com/users/ibadami/events{/privacy}","received_events_url":"https://api.github.com/users/ibadami/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-09-17T09:41:15Z","updated_at":"2015-09-23T10:05:25Z","closed_at":"2015-09-19T00:51:22Z","body":"I am creating a new issue for this error.\r\nI have installed julia-0.4 with the fix you provided https://github.com/JuliaLang/julia/pull/13150 for LLVM-3.8 in files cgutils.cpp and codegen.cpp. The installation is done successfully. But when I try to build Cxx package with that. I get the following errors.\r\n\r\n```\r\njulia> ENV[\"VERBOSE\"]=1\r\n1\r\n\r\njulia> Pkg.build(\"Cxx\")\r\nINFO: Building Cxx\r\nTuning for julia installation at: /home/badami/Library/julia/usr/bin\r\n g++ -m64 -fno-rtti -DLIBRARY_EXPORTS -fPIC -O0 -g -std=c++11   -I/home/badami/Library/julia/usr/bin/../../usr/include -I/home/badami/Library/julia/usr/bin/../../src/support -I/home/badami/Library/julia/usr/include -I/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib -c ../src/bootstrap.cpp -o build/bootstrap.o\r\n../src/bootstrap.cpp: In function ‘void ReplaceFunctionForDecl(CxxInstance*, clang::FunctionDecl*, llvm::Function*)’:\r\n../src/bootstrap.cpp:433:61: error: no matching function for call to ‘InlineFunction(llvm::cast_retty<llvm::CallInst, llvm::User*>::ret_type, llvm::InlineFunctionInfo&, bool)’\r\n       llvm::InlineFunction(cast<llvm::CallInst>(*I),IFI,true);\r\n                                                             ^\r\n../src/bootstrap.cpp:433:61: note: candidates are:\r\nIn file included from ../src/bootstrap.cpp:15:0:\r\n/home/badami/Library/julia/usr/bin/../../usr/include/llvm/Transforms/Utils/Cloning.h:237:6: note: bool llvm::InlineFunction(llvm::CallInst*, llvm::InlineFunctionInfo&, llvm::AAResults*, bool)\r\n bool InlineFunction(CallInst *C, InlineFunctionInfo &IFI,\r\n      ^\r\n/home/badami/Library/julia/usr/bin/../../usr/include/llvm/Transforms/Utils/Cloning.h:237:6: note:   no known conversion for argument 3 from ‘bool’ to ‘llvm::AAResults*’\r\n/home/badami/Library/julia/usr/bin/../../usr/include/llvm/Transforms/Utils/Cloning.h:239:6: note: bool llvm::InlineFunction(llvm::InvokeInst*, llvm::InlineFunctionInfo&, llvm::AAResults*, bool)\r\n bool InlineFunction(InvokeInst *II, InlineFunctionInfo &IFI,\r\n      ^\r\n/home/badami/Library/julia/usr/bin/../../usr/include/llvm/Transforms/Utils/Cloning.h:239:6: note:   no known conversion for argument 1 from ‘llvm::cast_retty<llvm::CallInst, llvm::User*>::ret_type {aka llvm::CallInst*}’ to ‘llvm::InvokeInst*’\r\n/home/badami/Library/julia/usr/bin/../../usr/include/llvm/Transforms/Utils/Cloning.h:241:6: note: bool llvm::InlineFunction(llvm::CallSite, llvm::InlineFunctionInfo&, llvm::AAResults*, bool)\r\n bool InlineFunction(CallSite CS, InlineFunctionInfo &IFI,\r\n      ^\r\n/home/badami/Library/julia/usr/bin/../../usr/include/llvm/Transforms/Utils/Cloning.h:241:6: note:   no known conversion for argument 3 from ‘bool’ to ‘llvm::AAResults*’\r\n../src/bootstrap.cpp: In function ‘void cleanup_cpp_env(CxxInstance*, cppcall_state_t*)’:\r\n../src/bootstrap.cpp:986:27: error: no match for ‘operator=’ (operand types are ‘clang::CodeGen::Address’ and ‘std::nullptr_t’)\r\n     Cxx->CGF->ReturnValue = nullptr;\r\n                           ^\r\n../src/bootstrap.cpp:986:27: note: candidates are:\r\nIn file included from /home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGValue.h:22:0,\r\n                 from /home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:18,\r\n                 from /home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenTypes.h:17,\r\n                 from /home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenModule.h:19,\r\n                 from ../src/bootstrap.cpp:54:\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/Address.h:25:7: note: clang::CodeGen::Address& clang::CodeGen::Address::operator=(const clang::CodeGen::Address&)\r\n class Address {\r\n       ^\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/Address.h:25:7: note:   no known conversion for argument 1 from ‘std::nullptr_t’ to ‘const clang::CodeGen::Address&’\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/Address.h:25:7: note: clang::CodeGen::Address& clang::CodeGen::Address::operator=(clang::CodeGen::Address&&)\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/Address.h:25:7: note:   no known conversion for argument 1 from ‘std::nullptr_t’ to ‘clang::CodeGen::Address&&’\r\n../src/bootstrap.cpp: In function ‘void AssociateValue(CxxInstance*, clang::Decl*, void*, llvm::Value*)’:\r\n../src/bootstrap.cpp:1109:81: error: no matching function for call to ‘clang::CodeGen::CodeGenFunction::EmitParmDecl(clang::VarDecl&, llvm::Value*, bool, int)’\r\n     Cxx->CGF->EmitParmDecl(*vd, Cxx->CGF->Builder.CreateBitCast(V, Ty), false, 0);\r\n                                                                                 ^\r\n../src/bootstrap.cpp:1109:81: note: candidate is:\r\nIn file included from ../src/bootstrap.cpp:57:0:\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenFunction.h:2088:8: note: void clang::CodeGen::CodeGenFunction::EmitParmDecl(const clang::VarDecl&, clang::CodeGen::CodeGenFunction::ParamValue, unsigned int)\r\n   void EmitParmDecl(const VarDecl &D, ParamValue Arg, unsigned ArgNo);\r\n        ^\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenFunction.h:2088:8: note:   candidate expects 3 arguments, 4 provided\r\n../src/bootstrap.cpp: In function ‘void* emitcallexpr(CxxInstance*, clang::Expr*, llvm::Value*)’:\r\n../src/bootstrap.cpp:1166:103: error: no matching function for call to ‘clang::CodeGen::ReturnValueSlot::ReturnValueSlot(llvm::Value*&, bool)’\r\n     clang::CodeGen::RValue ret = Cxx->CGF->EmitCallExpr(CE,clang::CodeGen::ReturnValueSlot(rslot,false));\r\n                                                                                                       ^\r\n../src/bootstrap.cpp:1166:103: note: candidates are:\r\nIn file included from /home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenTypes.h:17:0,\r\n                 from /home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenModule.h:19,\r\n                 from ../src/bootstrap.cpp:54:\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:166:5: note: clang::CodeGen::ReturnValueSlot::ReturnValueSlot(clang::CodeGen::Address, bool, bool)\r\n     ReturnValueSlot(Address Addr, bool IsVolatile, bool IsUnused = false)\r\n     ^\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:166:5: note:   no known conversion for argument 1 from ‘llvm::Value*’ to ‘clang::CodeGen::Address’\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:165:5: note: clang::CodeGen::ReturnValueSlot::ReturnValueSlot()\r\n     ReturnValueSlot() {}\r\n     ^\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:165:5: note:   candidate expects 0 arguments, 2 provided\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:154:9: note: constexpr clang::CodeGen::ReturnValueSlot::ReturnValueSlot(const clang::CodeGen::ReturnValueSlot&)\r\n   class ReturnValueSlot {\r\n         ^\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:154:9: note:   candidate expects 1 argument, 2 provided\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:154:9: note: constexpr clang::CodeGen::ReturnValueSlot::ReturnValueSlot(clang::CodeGen::ReturnValueSlot&&)\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CGCall.h:154:9: note:   candidate expects 1 argument, 2 provided\r\n../src/bootstrap.cpp:1170:18: error: ‘class clang::CodeGen::RValue’ has no member named ‘getAggregateAddr’\r\n       return ret.getAggregateAddr();\r\n                  ^\r\n../src/bootstrap.cpp: In function ‘void emitexprtomem(CxxInstance*, clang::Expr*, llvm::Value*, int)’:\r\n../src/bootstrap.cpp:1175:68: error: no matching function for call to ‘clang::CodeGen::CodeGenFunction::EmitAnyExprToMem(clang::Expr*&, llvm::Value*&, clang::Qualifiers, int&)’\r\n     Cxx->CGF->EmitAnyExprToMem(E, addr, clang::Qualifiers(), isInit);\r\n                                                                    ^\r\n../src/bootstrap.cpp:1175:68: note: candidate is:\r\nIn file included from ../src/bootstrap.cpp:57:0:\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenFunction.h:1664:8: note: void clang::CodeGen::CodeGenFunction::EmitAnyExprToMem(const clang::Expr*, clang::CodeGen::Address, clang::Qualifiers, bool)\r\n   void EmitAnyExprToMem(const Expr *E, Address Location,\r\n        ^\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenFunction.h:1664:8: note:   no known conversion for argument 2 from ‘llvm::Value*’ to ‘clang::CodeGen::Address’\r\n../src/bootstrap.cpp: In function ‘void* EmitAnyExpr(CxxInstance*, clang::Expr*, llvm::Value*)’:\r\n../src/bootstrap.cpp:1184:18: error: ‘class clang::CodeGen::RValue’ has no member named ‘getAggregateAddr’\r\n       return ret.getAggregateAddr();\r\n                  ^\r\n../src/bootstrap.cpp: In function ‘void emitDestroyCXXObject(CxxInstance*, llvm::Value*, clang::Type*)’:\r\n../src/bootstrap.cpp:1980:64: error: no matching function for call to ‘clang::CodeGen::CodeGenFunction::destroyCXXObject(clang::CodeGen::CodeGenFunction&, llvm::Value*&, clang::QualType)’\r\n   Cxx->CGF->destroyCXXObject(*Cxx->CGF, x, clang::QualType(T,0));\r\n                                                                ^\r\n../src/bootstrap.cpp:1980:64: note: candidate is:\r\nIn file included from ../src/bootstrap.cpp:57:0:\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenFunction.h:1874:20: note: static void clang::CodeGen::CodeGenFunction::destroyCXXObject(clang::CodeGen::CodeGenFunction&, clang::CodeGen::Address, clang::QualType)\r\n   static Destroyer destroyCXXObject;\r\n                    ^\r\n/home/badami/Library/julia/usr/bin/../../deps/llvm-svn/tools/clang/lib/CodeGen/CodeGenFunction.h:1874:20: note:   no known conversion for argument 2 from ‘llvm::Value*’ to ‘clang::CodeGen::Address’\r\nmake: *** [build/bootstrap.o] Error 1\r\n\r\n[ ERROR: Cxx ]\r\n\r\nLoadError: failed process: Process(`make -f BuildBootstrap.Makefile JULIA_HOME=/home/badami/Library/julia/usr/bin`, ProcessExited(2)) [2]\r\nwhile loading /home/badami/.julia/v0.4/Cxx/deps/build.jl, in expression starting on line 16\r\n\r\n[ BUILD ERRORS ]\r\n\r\nWARNING: Cxx had build errors.\r\n\r\n - packages with build errors remain installed in /home/badami/.julia/v0.4\r\n - build the package(s) and all dependencies with `Pkg.build(\"Cxx\")`\r\n - build a single package by running its `deps/build.jl` script\r\n```"},"comment":{"url":"https://api.github.com/repos/Keno/Cxx.jl/issues/comments/142553057","html_url":"https://github.com/Keno/Cxx.jl/issues/159#issuecomment-142553057","issue_url":"https://api.github.com/repos/Keno/Cxx.jl/issues/159","id":142553057,"user":{"login":"ibadami","id":4718068,"avatar_url":"https://avatars.githubusercontent.com/u/4718068?v=3","gravatar_id":"","url":"https://api.github.com/users/ibadami","html_url":"https://github.com/ibadami","followers_url":"https://api.github.com/users/ibadami/followers","following_url":"https://api.github.com/users/ibadami/following{/other_user}","gists_url":"https://api.github.com/users/ibadami/gists{/gist_id}","starred_url":"https://api.github.com/users/ibadami/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ibadami/subscriptions","organizations_url":"https://api.github.com/users/ibadami/orgs","repos_url":"https://api.github.com/users/ibadami/repos","events_url":"https://api.github.com/users/ibadami/events{/privacy}","received_events_url":"https://api.github.com/users/ibadami/received_events","type":"User","site_admin":false},"created_at":"2015-09-23T10:05:25Z","updated_at":"2015-09-23T10:05:25Z","body":"I tried compiling Julia master with LLVM master and I do not get any\ncompilation error anymore. I didn't check julia-0.4 with LLVM master yet.\n\nOn Wed, Sep 23, 2015 at 11:37 AM, Carlos Becker <notifications@github.com>\nwrote:\n\n> @Keno <https://github.com/Keno> do you think Cxx.jl will be working with\n> Julia v0.4 by default? I am planning to switch to v0.4 by checking out\n> release-0.4, but it is not meant to be compatible with the latest LLVM\n> master. Do you have a suggestion of an alternative branch or commit to pull\n> from to specify in Make.user? Thanks.\n>\n> —\n> Reply to this email directly or view it on GitHub\n> <https://github.com/Keno/Cxx.jl/issues/159#issuecomment-142546075>.\n>\n\n\n\n-- \n\nIshrat Badami\nPh.D. Student\nComputer Vision Group\nUMIC Research Centre\nRWTH Aachen University\nRoom No 129\nMies-van-der-Rohe Strasse 15\nD-52074 Aachen\nGermany\n------------------------------------\nTel: +49 241 80 20775\nFax: +49 241 80 22731\n\ne-mail: badami@vision.rwth-aachen.de\nURL: http://www.vision.rwth-aachen.de/people/ishrat-badami\n-----------------------------------------------------------------\n"}}