Zhoulai
2015-Apr-09 16:17 UTC
[LLVMdev] BasicBlock.h in the binary and in the source differ
The source is cloned from https://github.com/llvm-mirror/llvm Thanks. Zhoulai On Thu, Apr 9, 2015 at 9:15 AM, Jonathan Roelofs <jonathan at codesourcery.com> wrote:> > > On 4/9/15 9:58 AM, Zhoulai wrote: > >> Hi, I am using LLVM to develop a tool, using Mac OS 10.9. I have >> download llvm source and binary from >> >> http://llvm.org/releases/download.html >> >> I just find the BasicBlock.h file of the binary package >> >> clang+llvm-3.6.0-x86_64-apple-darwin/include/llvm/IR/ >> BasicBlock.h >> >> is slightly different from that of the source >> >> llvm/include/llvm/IR/BasicBlock.h >> > > Where specifically did you download the source from? > > >> In particular, llvm:: getModule(..) is included in the latter >> BasicBlock.h but not in the former BasicBlock.h. Am I misunderstanding >> something or is it an inconsistency LLVM developers will fix? >> >> Thanks in advance. >> >> >> Zhoulai >> >> >> _______________________________________________ >> LLVM Developers mailing list >> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu >> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >> >> > -- > Jon Roelofs > jonathan at codesourcery.com > CodeSourcery / Mentor Embedded >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150409/470153c8/attachment.html>
Jonathan Roelofs
2015-Apr-09 16:21 UTC
[LLVMdev] BasicBlock.h in the binary and in the source differ
On 4/9/15 10:17 AM, Zhoulai wrote:> The source is cloned from > https://github.com/llvm-mirror/llvmWhich branch, master or one of the release_* branches? Jon> > Thanks. > > Zhoulai > > On Thu, Apr 9, 2015 at 9:15 AM, Jonathan Roelofs > <jonathan at codesourcery.com <mailto:jonathan at codesourcery.com>> wrote: > > > > On 4/9/15 9:58 AM, Zhoulai wrote: > > Hi, I am using LLVM to develop a tool, using Mac OS 10.9. I have > download llvm source and binary from > > http://llvm.org/releases/__download.html > <http://llvm.org/releases/download.html> > > I just find the BasicBlock.h file of the binary package > > > clang+llvm-3.6.0-x86_64-apple-__darwin/include/llvm/IR/__BasicBlock.h > > is slightly different from that of the source > > llvm/include/llvm/IR/__BasicBlock.h > > > Where specifically did you download the source from? > > > In particular, llvm:: getModule(..) is included in the latter > BasicBlock.h but not in the former BasicBlock.h. Am I > misunderstanding > something or is it an inconsistency LLVM developers will fix? > > Thanks in advance. > > > Zhoulai > > > _________________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu <mailto:LLVMdev at cs.uiuc.edu> > http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/__mailman/listinfo/llvmdev > <http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev> > > > -- > Jon Roelofs > jonathan at codesourcery.com <mailto:jonathan at codesourcery.com> > CodeSourcery / Mentor Embedded > >-- Jon Roelofs jonathan at codesourcery.com CodeSourcery / Mentor Embedded
Zhoulai
2015-Apr-09 16:35 UTC
[LLVMdev] BasicBlock.h in the binary and in the source differ
Sorry. 'master' branch of most recent release. Actually I use git clone http://llvm.org/git/llvm.git. Maybe the issue comes from the binary package? At line 122 of the BasicBlock.h from <http://llvm.org/releases/download.html>const DataLayout *getDataLayout() const; vs. Line 118 of the source BasicBlock.h from the above repo: const Module *getModule() const; For information, I am concerned with the inconsistency because of this error message when building the project at https://github.com/eliben/llvm-clang-samples: --------------- g++ -fno-rtti -O0 -g `$HOME/MyLib/clang+llvm-3.6.0-x86_64-apple-darwin/bin/llvm-config --cxxflags` src_llvm/simple_bb_pass.cpp `$HOME/MyLib/clang+llvm-3.6.0-x86_64-apple-darwin/bin/llvm-config --ldflags --libs --system-libs` -o build/simple_bb_pass *src_llvm/simple_bb_pass.cpp:30:31: error: no member named 'getModule' in 'llvm::BasicBlock' const DataLayout &DL BB.getModule()->getDataLayout(); ~~ ^1 error generated.Makefile:131: recipe for target 'build/simple_bb_pass' failedmake: *** [build/simple_bb_pass] Error 1* Thanks for your ideas. Zhoulai On Thu, Apr 9, 2015 at 9:21 AM, Jonathan Roelofs <jonathan at codesourcery.com> wrote:> > > On 4/9/15 10:17 AM, Zhoulai wrote: > >> The source is cloned from >> https://github.com/llvm-mirror/llvm >> > > Which branch, master or one of the release_* branches? > > Jon > > >> Thanks. >> >> Zhoulai >> >> On Thu, Apr 9, 2015 at 9:15 AM, Jonathan Roelofs >> <jonathan at codesourcery.com <mailto:jonathan at codesourcery.com>> wrote: >> >> >> >> On 4/9/15 9:58 AM, Zhoulai wrote: >> >> Hi, I am using LLVM to develop a tool, using Mac OS 10.9. I have >> download llvm source and binary from >> >> http://llvm.org/releases/__download.html >> <http://llvm.org/releases/download.html> >> >> I just find the BasicBlock.h file of the binary package >> >> >> clang+llvm-3.6.0-x86_64-apple-__darwin/include/llvm/IR/__ >> BasicBlock.h >> >> is slightly different from that of the source >> >> llvm/include/llvm/IR/__BasicBlock.h >> >> >> Where specifically did you download the source from? >> >> >> In particular, llvm:: getModule(..) is included in the latter >> BasicBlock.h but not in the former BasicBlock.h. Am I >> misunderstanding >> something or is it an inconsistency LLVM developers will fix? >> >> Thanks in advance. >> >> >> Zhoulai >> >> >> _________________________________________________ >> LLVM Developers mailing list >> LLVMdev at cs.uiuc.edu <mailto:LLVMdev at cs.uiuc.edu> >> http://llvm.cs.uiuc.edu >> http://lists.cs.uiuc.edu/__mailman/listinfo/llvmdev >> <http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev> >> >> >> -- >> Jon Roelofs >> jonathan at codesourcery.com <mailto:jonathan at codesourcery.com> >> CodeSourcery / Mentor Embedded >> >> >> > -- > Jon Roelofs > jonathan at codesourcery.com > CodeSourcery / Mentor Embedded >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150409/63ba0f86/attachment.html>