<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jun 30, 2020 at 10:11 AM Nicolai Hähnle <<a href="mailto:nhaehnle@gmail.com">nhaehnle@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Tue, Jun 30, 2020 at 7:15 AM Chandler Carruth via llvm-dev<br>
<<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" class="cremed">llvm-dev@lists.llvm.org</a>> wrote:<br>
><br>
> On Mon, Jun 29, 2020 at 9:43 PM Mehdi AMINI via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" class="cremed">llvm-dev@lists.llvm.org</a>> wrote:<br>
>><br>
>> Hey Duncan,<br>
>><br>
>> On Mon, Jun 29, 2020 at 8:28 PM Duncan Exon Smith via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" class="cremed">llvm-dev@lists.llvm.org</a>> wrote:<br>
>>><br>
>>> To facilitate collaboration on an upstreaming effort (see "More context" below), we'd like to push a branch (with history) called "staging/apple" to <a href="http://github.com/llvm/llvm-project" rel="noreferrer" target="_blank" class="cremed">github.com/llvm/llvm-project</a> to serve as an official contribution to the LLVM project. This enables motivated parties to work with us to craft incremental patches for review on Phabricator. This branch would live during the effort and then be deleted after. It would not be merged.<br>
>>><br>
>>> Does this seem fine? If you have a strong objection, please share your concern.<br>
>>><br>
>>> For reference, I ran some experiments:<br>
>>><br>
>>> A `--bare` clone (just the Git database) I have of <a href="http://github.com/llvm/llvm-project" rel="noreferrer" target="_blank" class="cremed">github.com/llvm/llvm-project</a> was around ~1GB. Fetching this branch from <a href="http://github.com/apple/llvm-project" rel="noreferrer" target="_blank" class="cremed">github.com/apple/llvm-project</a> increased it to ~1.2GB. Running `git gc --aggressive` brought it down to ~850MB.<br>
>>> The worktree of the "master" branch is ~1GB. Adding the Git database gives ~2GB, ~2.2GB, and ~1.9GB.<br>
>>> The diff of the proposed staging/apple branch is 3.1MB at `-U0`, 4.1MB at `-U3`, and 32MB at `-U999999` (Phabricator settings).<br>
>>><br>
>>><br>
>>><br>
>>> More context<br>
>>><br>
>>> We're making a major push over the next few months to upstream changes that have accumulated over time in the branch called "apple/master" at <a href="http://github.com/apple/llvm-project" rel="noreferrer" target="_blank" class="cremed">github.com/apple/llvm-project</a>. It has always been a non-goal for us to have changes, but over the years we've accumulated a non-trivial diff vs. <a href="http://github.com/llvm/llvm-project" rel="noreferrer" target="_blank" class="cremed">github.com/llvm/llvm-project</a>. This includes (but is not limited to) tweaks/features related to tuple hashing, modules hashing, source attributes, API notes, pointer authentication, indexing-while-building, and local refactoring.<br>
>>><br>
>>> Our goal is to eliminate this difference. Besides paying off some debt, this upstreaming effort unblocks the Swift compiler (<a href="http://github.com/apple/swift" rel="noreferrer" target="_blank" class="cremed">github.com/apple/swift</a>) from building directly against an upstream checkout of LLVM. That's why non-Apple contributors are motivated to help craft incremental patches.<br>
>>><br>
>>><br>
>>> Alternatives considered<br>
>>><br>
>>> As an alternative, we could post a GitHub pull request and close it without merging. From our perspective this would serve the same purpose. However, pull requests are contentious in LLVM.<br>
>>><br>
>>> Another alternative is to post a bulk Phabricator review and then "abandon" it. However, this has the disadvantage of not contributing the history (~30k commits).<br>
>><br>
>><br>
>> Seeing the alternatives, if a closed pull-request would fit your use-case, then I'm not sure why you need the branch to actually live in the monorepo instead of in any fork (<a href="http://github.com/apple/llvm-project" rel="noreferrer" target="_blank" class="cremed">github.com/apple/llvm-project</a> or another)? It seems publicly accessible the same way?<br>
><br>
><br>
> As I understand it, a key need is to explicitly contribute this to the LLVM project to make it unambiguous that it has been contributed and is completely available for folks not at Apple to iterate on the code and turn it into code-reviewable chunks.<br>
<br>
How do you envision this working? Has anybody outside of Apple<br>
_actually_ expressed interest in working on it in this way?<br></blockquote><div><br></div><div>Yes, as far as I know, folks approached those at Apple to figure out how to collaborate on upstreaming things.</div><div><br></div><div>FWIW, I don't think having this branch in the upstream LLVM repository would make much sense without that -- the only purpose it solves is to allow a group of interested people across the LLVM community to collaborate effectively.</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
I'm mostly asking because we also have a fork of LLVM that we<br>
continuously keep aligned with <a href="http://github.com/llvm/llvm-project/master" rel="noreferrer" target="_blank" class="cremed">github.com/llvm/llvm-project/master</a><br>
with the intention of deltas being broken out to be moved back<br>
upstream. That branch is currently at<br>
<a href="https://github.com/GPUOpen-Drivers/llvm-project" rel="noreferrer" target="_blank" class="cremed">https://github.com/GPUOpen-Drivers/llvm-project</a>, but if the LLVM<br>
community decides that branches whose goal is to be contributed<br>
upstream can (and should?) live in <a href="http://github.com/llvm/llvm-project" rel="noreferrer" target="_blank" class="cremed">github.com/llvm/llvm-project</a>, we'd<br>
probably be interested in doing that and having a branch such as<br>
amd/gfx-dev in the <a href="http://github.com/llvm/llvm-project" rel="noreferrer" target="_blank" class="cremed">github.com/llvm/llvm-project</a> repository.<br></blockquote><div><br></div><div>See above -- I personally think this is an effective strategy when it solves a practical problem for people in the LLVM community at different organizations who want to collaborate on upstreaming something. I'd hope that anything like that was only done contingent on genuine interest in the community and with a pretty clear "it goes away" plan when merging stuff is complete.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
Cheers,<br>
Nicolai<br>
<br>
<br>
> So whatever happens needs to be quite explicit in its nature as a contribution. IMO, a branch of the repository definitely qualifies.<br>
><br>
> IMO, a pull request isn't as clear given that they haven't been used for contributions before. This is not a time to be innovative IMO. A branch as a staging location has been used many times over the history of the project though and seems nicely unambiguous in that regard.<br>
><br>
>><br>
>> Your initial description mentions "collaboration on an upstreaming effort", maybe you can elaborate a bit on what this collaboration would look like and how these patches would end up in master?<br>
>><br>
>> Thanks,<br>
>><br>
>> --<br>
>> Mehdi<br>
>><br>
>><br>
>> _______________________________________________<br>
>> LLVM Developers mailing list<br>
>> <a href="mailto:llvm-dev@lists.llvm.org" target="_blank" class="cremed">llvm-dev@lists.llvm.org</a><br>
>> <a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank" class="cremed">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
><br>
> _______________________________________________<br>
> LLVM Developers mailing list<br>
> <a href="mailto:llvm-dev@lists.llvm.org" target="_blank" class="cremed">llvm-dev@lists.llvm.org</a><br>
> <a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank" class="cremed">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
<br>
<br>
<br>
-- <br>
Lerne, wie die Welt wirklich ist,<br>
aber vergiss niemals, wie sie sein sollte.<br>
</blockquote></div></div>