<html>
  <head>
    <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <br>
    <div class="moz-cite-prefix">On 09/11/15 01:55 PM, Manuel Klimek via
      cfe-dev wrote:<br>
    </div>
    <blockquote
cite="mid:CAOsfVvn3c3hgXeCn=bJbq6DsuBY-AX-9H7Q5quMOK0Urmf5yQw@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div class="gmail_quote">
          <div dir="ltr">On Fri, Sep 11, 2015 at 12:46 PM Vladimir
            Voskresensky - Oracle via cfe-dev <<a
              moz-do-not-send="true"
              href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a>>
            wrote:<br>
          </div>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div text="#000000" bgcolor="#FFFFFF"> <br>
              <div>On 09/11/15 12:44 PM, Manuel Klimek via cfe-dev
                wrote:<br>
              </div>
              <blockquote type="cite">
                <div dir="ltr">
                  <div class="gmail_quote">
                    <div dir="ltr">On Fri, Sep 11, 2015 at 11:40 AM
                      Vladimir Voskresensky - Oracle <<a
                        moz-do-not-send="true"
                        href="mailto:vladimir.voskresensky@oracle.com"
                        target="_blank">vladimir.voskresensky@oracle.com</a>>

                      wrote:<br>
                    </div>
                    <blockquote class="gmail_quote" style="margin:0 0 0
                      .8ex;border-left:1px #ccc solid;padding-left:1ex">
                      <div text="#000000" bgcolor="#FFFFFF"> Hello
                        Manuel,</div>
                      <div text="#000000" bgcolor="#FFFFFF"><br>
                        <br>
                        <div>On 09/11/15 11:59 AM, Manuel Klimek wrote:<br>
                        </div>
                        <blockquote type="cite">
                          <div dir="ltr">
                            <div class="gmail_quote">
                              <div dir="ltr">On Thu, Sep 10, 2015 at
                                7:59 PM Vladimir Voskresensky - Oracle
                                via cfe-dev <<a
                                  moz-do-not-send="true"
                                  href="mailto:cfe-dev@lists.llvm.org"
                                  target="_blank">cfe-dev@lists.llvm.org</a>>

                                wrote:<br>
                              </div>
                              <blockquote class="gmail_quote"
                                style="margin:0 0 0 .8ex;border-left:1px
                                #ccc solid;padding-left:1ex">Hello
                                Keith,<br>
                                <br>
                                I'm from Oracle (previously from Sun
                                Microsystems) and use NetBeans C++ IDE
                                for<br>
                                developing Clang based tools.<br>
                              </blockquote>
                              <div><br>
                              </div>
                              <div>Oh, this is awesome :)</div>
                            </div>
                          </div>
                        </blockquote>
                      </div>
                      <div text="#000000" bgcolor="#FFFFFF"> I've demoed
                        this to Argyrios Kyrtzidis ~year ago and he was
                        impressed by it's parsing speed :-)<br>
                        NB needed just 1 minute to parse whole
                        LLVM+Clang 3.4 codebase on my laptop.<br>
                        Also I was complaining that migrating to i.e.
                        Clang's preprocessor makes us 2x slower (which
                        is still the case for upcoming NB 8.1, but we
                        trying to restore our speed)</div>
                      <div text="#000000" bgcolor="#FFFFFF"><br>
                        <blockquote type="cite">
                          <div dir="ltr">
                            <div class="gmail_quote">
                              <div> </div>
                              <blockquote class="gmail_quote"
                                style="margin:0 0 0 .8ex;border-left:1px
                                #ccc solid;padding-left:1ex"> Till 8.0
                                version Netbeans had own parser (as
                                Eclipse). Starting from upcoming<br>
                                8.1 NB is trying to use some clang
                                components in experimental mode.<br>
                              </blockquote>
                              <div><br>
                              </div>
                              <div>Will this by any chance use the
                                compilation database integration?</div>
                            </div>
                          </div>
                        </blockquote>
                      </div>
                      <div text="#000000" bgcolor="#FFFFFF"> NetBeans
                        for a long time has own "build interceptor". It
                        helps to put code bases with even really complex
                        build systems into IDE.<br>
                        When developer uses Project with Existing
                        Sources wizard and specify commands which he
                        proceed in cmd shell, then IDE executes them and
                        interpose compiler invocations to extract cwd
                        and all flags passed to compiler.<br>
                        Then all is persisted in project properties, so
                        user gain "Compile File" for free, because IDE
                        for each file knows how it was compiled.<br>
                        For CMake based codebases json database is
                        produced and used to extract flags.<br>
                        Am I answering your question? Or do you mean
                        smth different?</div>
                    </blockquote>
                    <div><br>
                    </div>
                    <div>Let me rephrase: for example, YouCompleteMe
                      supports using libclang & its compilation
                      database interface to get the necessary compile
                      flags for C++ files. Due to that support, I can
                      take an arbitrary internal build system and add
                      support for YCM by providing a libclang with a
                      special implementation of the CompilationDatabase.
                    </div>
                  </div>
                </div>
              </blockquote>
            </div>
            <div text="#000000" bgcolor="#FFFFFF"> What you describe is
              the YCM approach how to help libclang to find compile
              flags to create correct TU.<br>
              YCM should create implementation of CompilationDatabase
              and register it for libclang to see it (or generate
              compile_commands.json file) , right?<br>
            </div>
          </blockquote>
          <div><br>
          </div>
          <div>No, the trick is that YCM doesn't know about how to
            generate a compilation database - the build system
            integration knows (for example, CMake and ninja can generate
            the .json files, for our internal distributed build system
            (similar to <a moz-do-not-send="true"
              href="http://bazel.io">bazel.io</a>) we use a specific
            internal integration).</div>
        </div>
      </div>
    </blockquote>
    Then the most complex part (generate compilation db) is just
    provided for you. Great.<br>
    <br>
    <blockquote
cite="mid:CAOsfVvn3c3hgXeCn=bJbq6DsuBY-AX-9H7Q5quMOK0Urmf5yQw@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div class="gmail_quote">
          <div><br>
          </div>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div text="#000000" bgcolor="#FFFFFF"> But, from our
              experience the most difficult part here is: how to fill
              this CompilationDatabase content for arbitrary build
              system?<br>
              I.e. for projects with alone my_favorite_buld_all.sh
              script?<br>
              So, above I just shortly described how NB historically
              gets information about compiled flags.<br>
              <a moz-do-not-send="true"
href="http://netbeans.org/kb/docs/cnd/quickstart.html#existingsourcesprojects"
                target="_blank">http://netbeans.org/kb/docs/cnd/quickstart.html#existingsourcesprojects</a><br>
              It is similar to scan-build.</div>
            <div text="#000000" bgcolor="#FFFFFF"><br>
              <br>
              <blockquote type="cite">
                <div dir="ltr">
                  <div class="gmail_quote">
                    <div>Is that possible with NetBeans?</div>
                  </div>
                </div>
              </blockquote>
            </div>
            <div text="#000000" bgcolor="#FFFFFF"> Possible what? :-)<br>
              Possible to wrap flags gathered by scan-build-like
              interposer into CompilationDatabase for libclang usage?
              Yes it's possible.<br>
              But we don't use libclang or Tooling APIs.<br>
              I.e. we init Preprocessor manually, because have to
              disable all target build-ins and provide all our own
              settings for system paths, system macros and so one.<br>
              Also we provide own FileSystem impl (great add-on in
              3.6!!!), because we support Remote Development and real
              parsed files have to be treated in the environment
              emulating Remote Host.</div>
          </blockquote>
          <div><br>
          </div>
          <div>Ah, is all of this open source? Are you planning to
            contribute it back to clang to make the tooling better?</div>
        </div>
      </div>
    </blockquote>
    yes, it's in open source. There is no sense to contribute FS impl,
    because it wraps NB's FileObjects into CLang's Files.<br>
<a class="moz-txt-link-freetext" href="http://hg.netbeans.org/main/file/tip/cnd.apt/src/org/netbeans/modules/cnd/apt/impl/support/clank/ClankFileObjectBasedFileSystem.java">http://hg.netbeans.org/main/file/tip/cnd.apt/src/org/netbeans/modules/cnd/apt/impl/support/clank/ClankFileObjectBasedFileSystem.java</a><br>
    <br>
    <blockquote
cite="mid:CAOsfVvn3c3hgXeCn=bJbq6DsuBY-AX-9H7Q5quMOK0Urmf5yQw@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div class="gmail_quote">
          <div><br>
          </div>
          <div>I guess the answer to my questions is "no", </div>
        </div>
      </div>
    </blockquote>
    The answer to your original question <br>
    "Will this by any chance use the compilation database integration?"<br>
    is "no"<br>
    Because we have all this information already. We don't need clang
    for that task. <br>
    We generate compilation database for any arbitrary complex systems
    by own mechanism.<br>
    But we can read compile_commands.json format as well and use it to
    configure NetBeans (and in 8.1 we use it to init Clang classes).<br>
    <br>
    <blockquote
cite="mid:CAOsfVvn3c3hgXeCn=bJbq6DsuBY-AX-9H7Q5quMOK0Urmf5yQw@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div class="gmail_quote">
          <div>then - what I really want to do is be able to use the
            already existing integration we have for our internal build
            system with clang tools via the compilation-database to use
            NetBeans, but from what you say it seems like that's not
            possible.</div>
        </div>
      </div>
    </blockquote>
    If "existing integration you have for your internal build system"
    can dump cmake-complaint compile_commands.json, then you can use
    NetBeans.<br>
    <br>
    If you are really interested in trying NB[1] then let's exclude
    cfe-dev?<br>
    Write me personally and I will try to advise how to configure/tune
    IDE for your project.<br>
    I'm eager to do that, because we are very interested in user's
    experience on big code bases.<br>
    In fact we develop NetBeans as an IDE platform for Oracle Solaris
    Studio IDE where customers are dealing with really huge enterprise
    apps (recently I talked to customer successfully using Studio IDE
    for 50K Files/15MLoc C++ boost-intensive codebase)<br>
    <br>
    Thanks,<br>
    Vladimir.<br>
    <br>
    <blockquote
cite="mid:CAOsfVvn3c3hgXeCn=bJbq6DsuBY-AX-9H7Q5quMOK0Urmf5yQw@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div class="gmail_quote">
          <div>Cheers,</div>
          <div>/Manuel</div>
          <div> </div>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div text="#000000" bgcolor="#FFFFFF"><br>
              <br>
              Vladimir.</div>
            <div text="#000000" bgcolor="#FFFFFF"><br>
              <blockquote type="cite">
                <div dir="ltr">
                  <div class="gmail_quote">
                    <div> </div>
                    <blockquote class="gmail_quote" style="margin:0 0 0
                      .8ex;border-left:1px #ccc solid;padding-left:1ex">
                      <div text="#000000" bgcolor="#FFFFFF"><br>
                        <br>
                        Vladimir.</div>
                      <div text="#000000" bgcolor="#FFFFFF"><br>
                        <blockquote type="cite">
                          <div dir="ltr">
                            <div class="gmail_quote">
                              <div> </div>
                              <blockquote class="gmail_quote"
                                style="margin:0 0 0 .8ex;border-left:1px
                                #ccc solid;padding-left:1ex"> <br>
                                Vladimir.<br>
                                <br>
                                On 09/10/15 03:17 AM, Keith Smith via
                                cfe-dev wrote:<br>
                                > Mats, Renalto - Thanks for the
                                information<br>
                                ><br>
                                > I beg to differ that Eclipse CDT
                                hasn't caught on. The originator of<br>
                                > Eclipse CDT, QNX, and the
                                maintainers, use Eclipse CDT as their
                                IDE<br>
                                > for their OS. QNX is in many high
                                end car nav systems today.<br>
                                ><br>
                                > Eclipse CDT is the basis for many
                                embedded tool chains used by<br>
                                > firmware engineers, both in Linux
                                and Windows.<br>
                                ><br>
                                > Eclipse CDT may not have caught on
                                as a host OS, host app development<br>
                                > IDE, but it is used extensively.<br>
                                ><br>
                                > I have used it for over ten years
                                now. It has had its limitations,<br>
                                > like no 'headless' builds, but that
                                has been corrected.<br>
                                ><br>
                                > Anyway thanks for the info. I was
                                afraid that emacs and vi(m) would be<br>
                                > part of the response. :( Don't use
                                either at present.<br>
                                ><br>
                                > Keith Smith<br>
                                ><br>
                                > On Wed, Sep 9, 2015 at 10:35 AM,
                                mats petersson <<a
                                  moz-do-not-send="true"
                                  href="mailto:mats@planetcatfish.com"
                                  target="_blank">mats@planetcatfish.com</a>>

                                wrote:<br>
                                >><br>
                                >> On 9 September 2015 at 15:03,
                                Renato Golin <<a
                                  moz-do-not-send="true"
                                  href="mailto:renato.golin@linaro.org"
                                  target="_blank">renato.golin@linaro.org</a>>

                                wrote:<br>
                                >>> On 9 September 2015 at
                                14:29, mats petersson <<a
                                  moz-do-not-send="true"
                                  href="mailto:mats@planetcatfish.com"
                                  target="_blank">mats@planetcatfish.com</a>><br>
                                >>> wrote:<br>
                                >>>> Technically, I'm not an
                                LLVM or Clang developer [by which I
                                mean, I'm<br>
                                >>>> not<br>
                                >>>> contributing code to
                                LLVM or Clang, although I do have a
                                patch for clang<br>
                                >>>> that may make it in at
                                some point], but I do use Emacs with
                                cscope.<br>
                                >>> Honest question: how does
                                cscope copes with C++11 constructs? I<br>
                                >>> finally gave up emacs when
                                cscope was the only thing I could use
                                and<br>
                                >>> it wasn't enough. Maybe I
                                missed something?<br>
                                >><br>
                                >> I have not tried on big
                                projects, but I use cscope  on C++ in my
                                hobby<br>
                                >> project compiler, which uses
                                limited C++11 features, and it's not
                                failing in<br>
                                >> any obvious way for this
                                use-case. But llvm is "out of tree", and
                                I<br>
                                >> typically use google and the
                                online doxygen pages for LLVM searches.<br>
                                >><br>
                                >> My main use is in my day-job,
                                which is nearly all C, so C++11 is not a
                                big<br>
                                >> issue - but the build we use
                                has all of clang and llvm in the
                                sources, and<br>
                                >> cscope is not failing in any
                                obvious way, and I can search for
                                "getType" and<br>
                                >> it finds a load of them. But
                                I'm sure there may be more subtle things
                                that I<br>
                                >> don't notice because when I use
                                cscope in this project, I'm typically<br>
                                >> searching for C symbols, not
                                C++ things.<br>
                                >>><br>
                                >>><br>
                                >>>> I'm not trying to start
                                a war with Renato about "vi(m) vs
                                (x)emacs" -<br>
                                >>>> it's<br>
                                >>>> pointless,<br>
                                >>> That was a joke. :)<br>
                                >><br>
                                >> Sorry, my "sarcasticly pointing
                                out the pointlessness of a editor
                                flame-war"<br>
                                >> obviously didn't have the
                                (right) sarcasm font... ;)<br>
                                >>><br>
                                >>><br>
                                >>>> it's just one of those
                                choices one makes at some point in life
                                -<br>
                                >>>> once you know enough to
                                do things with ease in one, you end up
                                not<br>
                                >>>> liking<br>
                                >>>> the other.<br>
                                >>> Yup. Especially as you get
                                older... :)<br>
                                >><br>
                                >> I've been old quite some time
                                now... ;)<br>
                                >><br>
                                >> --<br>
                                >> Mats<br>
                                >>><br>
                                >>><br>
                                >>>> I'm sufficiently
                                damaged that I type ESC+w to copy text
                                in<br>
                                >>>> the browser - which of
                                course doesn't work... :(<br>
                                >>> I type :wq and "i"
                                everywhere, too. :)<br>
                                >>><br>
                                >>> cheers,<br>
                                >>> --renato<br>
                                >><br>
                                ><br>
                                ><br>
                                <br>
_______________________________________________<br>
                                cfe-dev mailing list<br>
                                <a moz-do-not-send="true"
                                  href="mailto:cfe-dev@lists.llvm.org"
                                  target="_blank">cfe-dev@lists.llvm.org</a><br>
                                <a moz-do-not-send="true"
                                  href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev"
                                  rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a><br>
                              </blockquote>
                            </div>
                          </div>
                        </blockquote>
                        <br>
                      </div>
                    </blockquote>
                  </div>
                </div>
                <br>
                <fieldset></fieldset>
                <br>
                <pre>_______________________________________________
cfe-dev mailing list
<a moz-do-not-send="true" href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a>
<a moz-do-not-send="true" href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a>
</pre>
              </blockquote>
              <br>
            </div>
            _______________________________________________<br>
            cfe-dev mailing list<br>
            <a moz-do-not-send="true"
              href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a><br>
            <a moz-do-not-send="true"
              href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev"
              rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a><br>
          </blockquote>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
cfe-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a>
<a class="moz-txt-link-freetext" href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>