Mikael Lyngvig
2013-Nov-14 02:36 UTC
[LLVMdev] Quad-Core ARMv7 Build Slave Seeks Noble Purpose
A quick question while I am adding a tiny section on ccache to the HowToAddABuilder document: Why do you set CCACHE_CPP2 to yes? From reading the manual, I get the impression that this is much slower than the default and that it should only be used with tricky compilers or when debugging. Is Clang such a tricky compiler? If so, I suppose Clang should be fixed, not the ccache configuration. -- Mikael 2013/11/14 Dmitri Gribenko <gribozavr at gmail.com>> On Wed, Nov 13, 2013 at 5:28 PM, Mikael Lyngvig <mikael at lyngvig.org> > wrote: > > Hi Dmitri, > > > > I am not using any kind of cache (didn't even know of ccache). I have > now > > installed ccache. Perhaps ccache should be mentioned in the buildbot > > document so that every buildbot owner knows about it? > > Possibly. > > > It is currently running Arch Linux ARM. if there are good reasons to > switch > > to something else, I'll be happy to do that, although I am generally very > > happy about Arch Linux. > > > > What do you want me to build? LLVM? Clang? Both plus test suite? > > Personally, I see more value in building LLVM, Clang, possibly lld, > without test suite. This is the way that most build bots operate. > Test suite takes a long time to run, and this increases the iteration > time. > > As an example, you could look at the configuration in zorg repository > that corresponds to this buildbot: > > http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-debian-fast > > It uses CMake/ninja, which will give you the best possible iteration time. > > In order to use ccache, you need ensure that these environment > variables are set: > > CC="ccache clang" > CXX="ccache clang++" > CCACHE_CPP2=yes > export CC CXX CCACHE_CPP2 > > (Of course, you can use gcc/g++ as compilers.) > > Dmitri > > -- > main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if > (j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr at gmail.com>*/ >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20131114/63c88442/attachment.html>
Dmitri Gribenko
2013-Nov-14 02:48 UTC
[LLVMdev] Quad-Core ARMv7 Build Slave Seeks Noble Purpose
On Wed, Nov 13, 2013 at 6:36 PM, Mikael Lyngvig <mikael at lyngvig.org> wrote:> A quick question while I am adding a tiny section on ccache to the > HowToAddABuilder document: Why do you set CCACHE_CPP2 to yes? From reading > the manual, I get the impression that this is much slower than the default > and that it should only be used with tricky compilers or when debugging. Is > Clang such a tricky compiler? If so, I suppose Clang should be fixed, not > the ccache configuration.I don't remember exactly why I used this option, but it seems like I was getting diagnostics from system headers, that would otherwise be suppressed, because the header was found in a system include directory. Dmitri -- main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if (j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr at gmail.com>*/
Mikael Lyngvig
2013-Nov-14 04:55 UTC
[LLVMdev] Quad-Core ARMv7 Build Slave Seeks Noble Purpose
I ran into the very same problem, so it is definitely required. I'll add it to the proposed change to the LLVM buildbot documentation. LOL, a full build with an empty ccache cache took 36 minutes. A full build with all the files in ccache's cache took about eleven and a half minute, most of it spent linking. -- Mikael 2013/11/14 Dmitri Gribenko <gribozavr at gmail.com>> On Wed, Nov 13, 2013 at 6:36 PM, Mikael Lyngvig <mikael at lyngvig.org> > wrote: > > A quick question while I am adding a tiny section on ccache to the > > HowToAddABuilder document: Why do you set CCACHE_CPP2 to yes? From > reading > > the manual, I get the impression that this is much slower than the > default > > and that it should only be used with tricky compilers or when debugging. > Is > > Clang such a tricky compiler? If so, I suppose Clang should be fixed, > not > > the ccache configuration. > > I don't remember exactly why I used this option, but it seems like I > was getting diagnostics from system headers, that would otherwise be > suppressed, because the header was found in a system include > directory. > > Dmitri > > -- > main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if > (j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr at gmail.com>*/ >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20131114/808db476/attachment.html>
On 14/11/13 10:36, Mikael Lyngvig wrote:> A quick question while I am adding a tiny section on ccache to the > HowToAddABuilder document: Why do you set CCACHE_CPP2 to yes? From reading > the manual, I get the impression that this is much slower than the default > and that it should only be used with tricky compilers or when debugging. > Is Clang such a tricky compiler? If so, I suppose Clang should be fixed, > not the ccache configuration.Because ccache splits the compilation step up into components (preprocess, compile, link, etc.), but passes all the options to each stage, clang complains about unused build flags. There might be other reasons that are not down to diagnostic noise, and certainly ccache has had some of these issues fixed (it better knows which options are suitable for which stage) since the recommendation (I'm assuming they exist because it was tested with gcc which does not complain so much). Ben
Seemingly Similar Threads
- [LLVMdev] Quad-Core ARMv7 Build Slave Seeks Noble Purpose
- [LLVMdev] Quad-Core ARMv7 Build Slave Seeks Noble Purpose
- [LLVMdev] Quad-Core ARMv7 Build Slave Seeks Noble Purpose
- [LLVMdev] Quad-Core ARMv7 Build Slave Seeks Noble Purpose
- [LLVMdev] Quad-Core ARMv7 Build Slave Seeks Noble Purpose