<div dir="ltr"><div><div><div><div><div><div>Sorry. 'master' branch of  most recent release. Actually I use<br>git clone <a href="http://llvm.org/git/llvm.git">http://llvm.org/git/llvm.git</a>.<br><br>Maybe the issue comes from the binary package<span class="im"></span>?<br></div><br></div>At line 122 of the BasicBlock.h from <span class="im"><<a href="http://llvm.org/releases/download.html" target="_blank">http://llvm.org/releases/download.html</a>></span><br>  const DataLayout *getDataLayout() const;<br><br></div>vs.<br><br>Line 118 of the source BasicBlock.h from the above repo:<br>  const Module *getModule() const;<br><br></div>For information, I am concerned with the inconsistency because of this error message when building the project at <a href="https://github.com/eliben/llvm-clang-samples">https://github.com/eliben/llvm-clang-samples</a>:<br><br>---------------<br>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<br><br><b>src_llvm/simple_bb_pass.cpp:30:31: error: no member named 'getModule' in<br>      'llvm::BasicBlock'<br>    const DataLayout &DL = BB.getModule()->getDataLayout();<br>                           ~~ ^<br>1 error generated.<br>Makefile:131: recipe for target 'build/simple_bb_pass' failed<br>make: *** [build/simple_bb_pass] Error 1<br><br></b></div>Thanks for your ideas.<br></div><br><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature">Zhoulai</div></div>
<br><div class="gmail_quote">On Thu, Apr 9, 2015 at 9:21 AM, Jonathan Roelofs <span dir="ltr"><<a href="mailto:jonathan@codesourcery.com" target="_blank">jonathan@codesourcery.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
<br>
On 4/9/15 10:17 AM, Zhoulai wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
The source is cloned from<br>
<a href="https://github.com/llvm-mirror/llvm" target="_blank">https://github.com/llvm-<u></u>mirror/llvm</a><br>
</blockquote>
<br></span>
Which branch, master or one of the release_* branches?<br>
<br>
Jon<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">
<br>
Thanks.<br>
<br>
Zhoulai<br>
<br>
On Thu, Apr 9, 2015 at 9:15 AM, Jonathan Roelofs<br></span><span class="">
<<a href="mailto:jonathan@codesourcery.com" target="_blank">jonathan@codesourcery.com</a> <mailto:<a href="mailto:jonathan@codesourcery.com" target="_blank">jonathan@codesourcery.<u></u>com</a>>> wrote:<br>
<br>
<br>
<br>
    On 4/9/15 9:58 AM, Zhoulai wrote:<br>
<br>
        Hi, I am using LLVM to develop a tool, using Mac OS 10.9. I have<br>
        download llvm source and binary from<br>
<br></span>
        <a href="http://llvm.org/releases/__download.html" target="_blank">http://llvm.org/releases/__<u></u>download.html</a><span class=""><br>
        <<a href="http://llvm.org/releases/download.html" target="_blank">http://llvm.org/releases/<u></u>download.html</a>><br>
<br>
        I just find the BasicBlock.h file of the binary package<br>
<br>
<br></span>
          clang+llvm-3.6.0-x86_64-apple-<u></u>__darwin/include/llvm/IR/__<u></u>BasicBlock.h<span class=""><br>
<br>
        is slightly different from that of the source<br>
<br></span>
                 llvm/include/llvm/IR/__<u></u>BasicBlock.h<span class=""><br>
<br>
<br>
    Where specifically did you download the source from?<br>
<br>
<br>
        In particular, llvm:: getModule(..) is included in the latter<br>
        BasicBlock.h but not in the former BasicBlock.h.  Am I<br>
        misunderstanding<br>
        something or is it an inconsistency LLVM developers will fix?<br>
<br>
        Thanks in advance.<br>
<br>
<br>
        Zhoulai<br>
<br>
<br></span>
        ______________________________<u></u>___________________<br>
        LLVM Developers mailing list<br>
        <a href="mailto:LLVMdev@cs.uiuc.edu" target="_blank">LLVMdev@cs.uiuc.edu</a> <mailto:<a href="mailto:LLVMdev@cs.uiuc.edu" target="_blank">LLVMdev@cs.uiuc.edu</a>><br>
        <a href="http://llvm.cs.uiuc.edu" target="_blank">http://llvm.cs.uiuc.edu</a><br>
        <a href="http://lists.cs.uiuc.edu/__mailman/listinfo/llvmdev" target="_blank">http://lists.cs.uiuc.edu/__<u></u>mailman/listinfo/llvmdev</a><span class=""><br>
        <<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev" target="_blank">http://lists.cs.uiuc.edu/<u></u>mailman/listinfo/llvmdev</a>><br>
<br>
<br>
    --<br>
    Jon Roelofs<br></span>
    <a href="mailto:jonathan@codesourcery.com" target="_blank">jonathan@codesourcery.com</a> <mailto:<a href="mailto:jonathan@codesourcery.com" target="_blank">jonathan@codesourcery.<u></u>com</a>><br>
    CodeSourcery / Mentor Embedded<br>
<br>
<br>
</blockquote><div class="HOEnZb"><div class="h5">
<br>
-- <br>
Jon Roelofs<br>
<a href="mailto:jonathan@codesourcery.com" target="_blank">jonathan@codesourcery.com</a><br>
CodeSourcery / Mentor Embedded<br>
</div></div></blockquote></div><br></div></div>