<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/14/15 09:08 PM, Manuel Klimek via
cfe-dev wrote:</div>
<blockquote
cite="mid:CAOsfVvm6x_TiOaO9zy3nTX7bqUmnawHA+4QFH6LUCxSqxi=KDA@mail.gmail.com"
type="cite">
<div dir="ltr">
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div text="#000000" bgcolor="#FFFFFF">
<blockquote 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>
</div>
<div text="#000000" bgcolor="#FFFFFF"> The answer to your
original question <br>
</div>
<div text="#000000" bgcolor="#FFFFFF"> "Will this by any
chance use the compilation database integration?"<br>
</div>
<div text="#000000" bgcolor="#FFFFFF"> 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>
</div>
</blockquote>
<div><br>
</div>
<div>Well, the problem is once you hit a single highly
integrated codebase of > 100MLOC on networked file
systems (meaning latency at least 1 order of magnitude
higher than local disk) most of the IDEs I've tried fail
miserably.</div>
</div>
</div>
</blockquote>
That's why I'm also very interested in the try.<br>
<blockquote
cite="mid:CAOsfVvm6x_TiOaO9zy3nTX7bqUmnawHA+4QFH6LUCxSqxi=KDA@mail.gmail.com"
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"> 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).</div>
</blockquote>
<div><br>
</div>
<div>If I put O(500k) files into it, many of which take 20-60
seconds to parse, what will happen?</div>
</div>
</div>
</blockquote>
I think it would be O(TIME): where TIME is<br>
#time find $SOURCE_ROOT -name "*.h" -o -name "*.cpp" -o -name "*.c"
| xargs cat | wc -l<br>
<br>
Btw, where have you got 20-60 seconds timing per compilation unit?
From clang++?<br>
<br>
This is example for Mozilla code base:<br>
#export SOURCE_ROOT=/export/devarea/osprojects/mozilla-central<br>
#time find $SOURCE_ROOT -name "*.h" -o -name "*.cpp" -o -name "*.c"
| xargs cat | wc -l<br>
8 050 831<br>
real <b>1m22.518s</b><br>
user 0m1.978s<br>
sys 0m4.635s<br>
<br>
This is the internal statistics printed by NetBeans:<br>
Compilation Units: 5587<br>
=== Stopping parser queue stopwatch mozilla-central (14745 files):
127953 ms<br>
Parsed 6521 KLines, Time <b>128</b> seconds, Speed 50
KLines/second, Max Memory 5064 Mb<br>
<br>
This is on Solaris with 4cores x 4Gz machine with<br>
#netbeans -J-Xmx6G<br>
<br>
<blockquote
cite="mid:CAOsfVvm6x_TiOaO9zy3nTX7bqUmnawHA+4QFH6LUCxSqxi=KDA@mail.gmail.com"
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">
<blockquote 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>
</div>
<div text="#000000" bgcolor="#FFFFFF"> If "existing
integration you have for your internal build system" can
dump cmake-complaint compile_commands.json, then you can
use NetBeans.<br>
</div>
</blockquote>
<div><br>
</div>
<div>See questions above.</div>
<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"> If you are really
interested in trying NB[1] then let's exclude cfe-dev?<br>
</div>
</blockquote>
<div><br>
</div>
<div>I'm interested in using NB, but I'd also first like to
understand some of the engineering trade-offs you made - as
the maintainer for our tooling infrastructure in clang, I'd
like to get to a point where we get a lot of integration for
free, instead of everybody needing to re-invent the wheel
because we don't meet the requirements.</div>
</div>
</div>
</blockquote>
What we had to made as tradeoff: Parse headers "minimal amount of
times"<br>
So, we have introduced smth like "chained PCHs" long time ago.<br>
It allows to reuse what was parsed in the context of one translation
unit for parsing other translation units if "controling macro" for
header check says "ok" to reuse (so, one header sometimes has
several versions of PCH states)<br>
<br>
Of course I would recommend to run NB (being Java app) to allow big
heap allocation, i.e. <br>
#netbeans -J-Xmx6G<br>
<br>
Thanks,<br>
Vladimir.<br>
<br>
</body>
</html>