<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jun 9, 2016 at 12:06 PM, Renato Golin <span dir="ltr"><<a href="mailto:renato.golin@linaro.org" target="_blank" class="cremed">renato.golin@linaro.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 9 June 2016 at 19:13, Chris Bieneman <<a href="mailto:beanz@apple.com" class="cremed">beanz@apple.com</a>> wrote:<br>
>> On 9 June 2016 at 18:49, Justin Bogner via llvm-dev<br>
>> <<a href="mailto:llvm-dev@lists.llvm.org" class="cremed">llvm-dev@lists.llvm.org</a>> wrote:<br>
>>> This all seems pretty sensible. Should we also use the opportunity to<br>
>>> split compiler-rt's builtins and profiling/sanitizer/etc runtimes, since<br>
>>> we'll be moving things around anyway?<br>
>><br>
>> Also be good to make Compiler-RT and libc++ cross-compile for multiple<br>
>> targets... :/<br>
><br>
> Yes, that is part of the eventual goal for this. I *really* want to be able to build a full cross-compiler and runtime stack from a single CMake invocation. Ideally supporting /n/ targets.<br>
><br>
> I have lots of ideas in this area, but it is being kept in mind.<br>
<br>
</span>Thanks Chris,<br>
<br>
A big odd user of RT is Android, and they're having a lot of trouble<br>
cross-compiling, so they ended up creating their own build system.<br></blockquote><div><br></div><div>Eh, the build system for Android existed before people were using cmake in LLVM (i.e. it was based on the old autotools version for LLVM builds). At the time, nearly all the LLVM components that Android was using were trivially cross-compiled (well, except for TableGen, but even that isn't hard to write make rules for). Now that LLVM is a more important chunk of Android (and growing increasingly more complex), I agree that it isn't the best to have to maintain a parallel build system that isn't even in upstream.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
I'm copying Steve that has had more than his share of problems, maybe<br>
a sync on how we both want to compile RT wouldn't hurt.<br></blockquote><div><br></div><div>I actually am not sure how we want to compile RT. I am going to have to hack around the existing state of things for quite some time before converging on what upstream is doing because Android can't really afford to not make progress (and we have more than our share of other problems/deadlines to make this lower priority). I also still don't know enough about cmake to really understand why cross-compiling is so difficult, but I can see where the builtins combined with the sanitizers cause problems (due to different true dependencies on libcxx, etc.). I think splitting them apart is a great first step, as I already have to essentially do that for my new builds today (i.e. configure/build runtime, then configure/build sanitizers later on). Other than that, I am not sure I have any idea what to do after that.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
My goal is to get Android compiling RT together with Clang in the<br>
exact same way we do, so we only need to maintain one toolchain.<br></blockquote><div><br></div><div>Do you have a pointer to how you build these things today? I have searched for other users of compiler-rt for non-x86 platforms and nearly every configuration I saw was relying on terrible hacks (i.e. Chromium doesn't bother to use their new cross-compiler, they just rely on a pre-existing Android NDK to cross-compile compiler-rt because it is too hard to configure otherwise). I concluded that because everyone else is mostly cross-compiling Android targets incorrectly, that I don't particularly feel compelled to conform to a truly clean upstream build for compiler-rt right now.</div><div><br></div><div>Thanks,</div><div>Steve</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
cheers,<br>
--renato<br>
</blockquote></div><br></div></div>