-
Notifications
You must be signed in to change notification settings - Fork 3.9k
ARROW-2238: [C++] Detect and use clcache in cmake configuration #1684
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Example AppVeyor build at https://ci.appveyor.com/project/pitrou/arrow/build/1.0.155 |
|
The failure at https://ci.appveyor.com/project/pitrou/arrow/build/1.0.155/job/q31movster4v84d9 shows this can lead to inconsistencies or errors: cmake first tries to detect the compller from user-supplied information (generator, environment variables), then the clcache setting overrides that detection. Either we add logic to try and avoid such errors, or we simply let people override CC/CXX if they want to use clcache (statu quo). |
|
Also I'm not sure whether we have a Windows developer on board; I'm merely launching a VM from time to time but otherwise work on Ubuntu :-) |
|
@Maxris can take a look. How does the error you linked to arise? |
|
I think that's because So it's possible that calling |
|
@pitrou I will check, thanks |
|
@pitrou it seems that we already try to use |
Last I tried it seemed it didn't work. I might give it a try again... |
|
I will try on my end as well |
|
@pitrou, do you have an idea how to verify that clcache.exe was really used during compilation? I've tried with it and without, but I can't find any difference in output/produced results. |
|
@Maxris running |
|
@pitrou thanks! |
|
update: it seems that current solution |
|
clcache works best with Ninja or NMake (*). My suggestion here would be to recommend Ninja + clcache for best build performance. The other concern, though, is to avoid breaking existing builds for those who prefer other generators (e.g. Visual Studio). (*) See the following links: |
|
@pitrou it should be fine to set |
|
@Maxris that sounds ok to me. |
|
@pitrou I will check if that resolves Appveyor build failure and let you know, thanks |
|
@pitrou here it's changes to solve Jenkins failure as discussed P.S. I've tried to create PR into your pitrou:ARROW-2238-cmake-clcache remote branch, but for some reasons it's not listed in targets during PR creation. |
|
@Maxris thanks! I'll integrate it in my PR. |
673a82e to
8539a0e
Compare
|
Actually, it doesn't look right. Here you see that the cache wasn't looked up at all: |
|
@pitrou sorry, haven't checked in such manner. I have checked only that |
|
Hey @pitrou , could you please check logs of last passed build ( https://ci.appveyor.com/project/ApacheSoftwareFoundation/arrow/build/1.0.5601 ). For some reasons |
|
@Maxris, yes, it looks fine... And the build times are ok too (without cache, the total duration would probably be much more than 45 minutes). |
|
Great! Should be fine to go with these changes, thanks! |
|
@xhochy, yes, it's ready for merging. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1
No description provided.