<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><br><div><div>Le 11 nov. 2013 à 22:17, Sean Silva <<a href="mailto:silvas@purdue.edu">silvas@purdue.edu</a>> a écrit :</div><br class="Apple-interchange-newline"><blockquote type="cite"><div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Nov 11, 2013 at 3:30 PM, Devin Crumb <span dir="ltr"><<a href="mailto:bitogre@gmail.com" target="_blank">bitogre@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">I am definitely interested in contributing to such an effort and fully support the idea of trying to make an LLVM libc as cross platform as possible (and have some experience in this area). However, I want to understand what is going to be expected of me if I am the one to actually start the effort before taking on such a commitment.</div>
</blockquote><div><br></div><div>Any significant new block of code will generally require a long-term maintenance commitment. However, for a libc I'm sure there are a bunch of things to do that don't require as much of a commitment. In particular, I think it would be useful to pin down the following:</div>
<div><br></div><div>* Try to explore the realistic benefits of having our own libc. I'm not entirely convinced that having our own libc will be a huge win, or at least not enough to justify the huge amount of work it would entail. We seem to get along just fine (?; at least in my experience) without having to "own" the libc. What are the "pain points" that would be soothed by having our own libc, and on what platforms?<br>
</div><div><br></div><div>* Survey existing libc's and write-up their current portability situation, licensing, implementation quality, etc. Off the top of my head, some libc's that I know about: musl, uclibc, bionic, glibc, {Free,Open,Net,...}BSD's libc, OpenSolaris (illumos) libc. Is it really necessary to roll our own, or can one of these existing ones be adapted to soothe the biggest "pain points"?</div>
<div><br></div><div>* How realistic is it to implement a windows libc? A couple things that come to mind are:</div><div> - What is the "lowest level" interface that the libc is going to be built on top of (I'm clueless about windows, but for example Linux has a documented and stable syscall ABI, which is trivial to interoperate with; is there an equivalent of that on Windows? or Mac?)</div>
<div> - Are those interfaces stable and documented?</div></div></div></div></blockquote><div><br></div>At least on Darwin, I never saw any guarantee that the syscall will not change from one release to an other (IIRC, they already did it in the past). And I'm not even mentioning the mach syscalls.</div><div>Moreover, having an alternative c library is pointless as any executable is forced to link on libSystem which not only provide libc functions, but also include many other services (cache, crypto, dispatch, dyld, launchd, asl, sandbox, xpc, …).</div><div><br></div><div>What could be useful though is a library to provide the C11 specifics parts which are not available yet.</div><div><br><blockquote type="cite"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><br></div><div>* What are the goals of our own libc? Is it a goal to eventually be able to build Debian with our libc? What is the end-goal for this library on Apple platforms? On Windows? etc.</div>
<div><br></div><div>* As Chandler mentioned, really any such project will have to be cross-platform to be of any interest. What are the use cases on each platform? E.g. is this something that Apple is willing to get behind on Darwin? I don't think we expect any involvement from Microsoft, but what Windows users would be interested in this? (also, how many "hacks" are there in the regular Windows libc that we would have to emulate in order to build nontrivial existing apps?). On Linux there are already a number of good libc's that can be built from source and/or modified to your heart's desire so I'm not sure how much we would gain there. I'm not sure any of the BSD's are going to be interested in replacing their libc with something "foreign". Trying to be "cross-platform" would be mostly for show if most of the platforms are not interested in being supported and/or the library really only brings significant "benefits" on a single platform.</div>
<div><br></div><div>-- Sean Silva</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><span class=""><font color="#888888">
</font></span><div class="gmail_extra"><span class=""><font color="#888888"><br clear="all"><div>Devin Crumb</div></font></span><div><div class="h5">
<br><br><div class="gmail_quote">On Mon, Nov 11, 2013 at 2:55 PM, Chandler Carruth <span dir="ltr"><<a href="mailto:chandlerc@google.com" target="_blank">chandlerc@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div dir="ltr"><div class="gmail_extra"><div><br><div class="gmail_quote">On Mon, Nov 11, 2013 at 11:53 AM, Marshall Clow <span dir="ltr"><<a href="mailto:mclow.lists@gmail.com" target="_blank">mclow.lists@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div>On Nov 11, 2013, at 11:24 AM, Chandler Carruth <<a href="mailto:chandlerc@google.com" target="_blank">chandlerc@google.com</a>> wrote:</div>
<br><blockquote type="cite"><div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Nov 11, 2013 at 11:20 AM, Devin Crumb <span dir="ltr"><<a href="mailto:bitogre@gmail.com" target="_blank">bitogre@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Does Clang have C headers and C libraries for Unix that I can port to Windows or do I need to start from scratch?</blockquote>
</div><br>No, Clang does not include any thing from libc at this point.</div><div class="gmail_extra"><br></div><div class="gmail_extra">If you are seriously interested in starting one, there might be serious interest in it being a designated LLVM project. I would start a separate email thread on that subject if you want to pursue it as part of the LLVM project. I'm happy to point you at some of the folks that should be part of such a discussion.</div>
</div></blockquote><br></div><div>I'd like to encourage you to do this.</div><div>It's not a small undertaking, though.</div></blockquote></div><br></div>FWIW, I too would like to see a libc as part of the LLVM project. =] That's why I offered to help connect interested parties. I think there is a lot of interest in this, but it would be a massive undertaking. I'm also only really interested if it sets out from the beginning to be nicely cross platform.</div>
</div>
</blockquote></div><br></div></div></div>
<br>_______________________________________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@cs.uiuc.edu">cfe-dev@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev</a><br>
<br></blockquote></div><br></div></div>
_______________________________________________<br>cfe-dev mailing list<br><a href="mailto:cfe-dev@cs.uiuc.edu">cfe-dev@cs.uiuc.edu</a><br>http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev<br></blockquote></div><br><div>
<span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div>-- Jean-Daniel</div><div><br></div><div><br></div></span><br class="Apple-interchange-newline">
</div>
<br></body></html>