<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Thanks David and Jessica, I probably wouldn't have noticed this thread from the title.<div class=""><br class=""></div><div class="">Hi Pooja,<br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Jun 10, 2021, at 10:12, David Blaikie via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" class="">llvm-dev@lists.llvm.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">+Jessica - I think she's got context on GlobalISel and might be able to rope in other folks with context if needed.<br class=""></div><br class=""><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Jun 9, 2021 at 10:03 PM Pooja Yadav via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" class="">llvm-dev@lists.llvm.org</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class="">Hi everyone!<div class="">I am Pooja Yadav, an outreachy intern and I am working on the project "Create Documentation and Tutorials for the LLVM Global Instruction Selection Framework". I have been going through the documents and tutorials of GISel and I thought to list out the updates that should be made. It would be very helpful if anyone wants to add anything to the list or if they think something needs to be updated or added in the documentation.  </div><div class=""><br class=""></div><div class="">1. Adding <a title="https://llvm.org/docs/GlobalISel/index.html" href="https://llvm.org/docs/GlobalISel/index.html" rel="noreferrer noopener" style="margin:0px;padding:0px;border:0px;font-family:Whitney,"Helvetica Neue",Helvetica,Arial,sans-serif;vertical-align:baseline;outline:0px;word-break:break-word;white-space:break-spaces;background-color:rgba(4,4,5,0.07)" target="_blank" class="">https://llvm.org/docs/GlobalISel/index.html</a> before this-<a title="https://llvm.org/docs/GlobalISel/GenericOpcode.html#g-fence" href="https://llvm.org/docs/GlobalISel/GenericOpcode.html#g-fence" rel="noreferrer noopener" style="margin:0px;padding:0px;border:0px;font-family:Whitney,"Helvetica Neue",Helvetica,Arial,sans-serif;vertical-align:baseline;outline:0px;word-break:break-word;white-space:break-spaces;background-color:rgba(250,166,26,0.08)" target="_blank" class="">https://llvm.org/docs/GlobalISel/GenericOpcode.html#g-fence</a><span style="color:rgb(220,221,222);font-family:Whitney,"Helvetica Neue",Helvetica,Arial,sans-serif;white-space:break-spaces;background-color:rgba(250,166,26,0.08)" class=""> </span> </div></div></blockquote></div></div></blockquote><div><br class=""></div><div>I'm not sure what you mean for this one. The index currently links to GenericOpcode.html in this section: <a href="https://llvm.org/docs/GlobalISel/index.html#design-and-implementation-reference" class="">https://llvm.org/docs/GlobalISel/index.html#design-and-implementation-reference</a></div><br class=""><blockquote type="cite" class=""><div class=""><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class=""><div class="">2. <a title="https://llvm.org/docs/GlobalISel/GenericOpcode.html#g-fence" href="https://llvm.org/docs/GlobalISel/GenericOpcode.html#g-fence" rel="noreferrer noopener" style="margin:0px;padding:0px;border:0px;font-family:Whitney,"Helvetica Neue",Helvetica,Arial,sans-serif;vertical-align:baseline;outline:0px;word-break:break-word;white-space:break-spaces;background-color:rgba(250,166,26,0.08)" target="_blank" class="">https://llvm.org/docs/GlobalISel/GenericOpcode.html#g-fence</a><span style="color:rgb(220,221,222);font-family:Whitney,"Helvetica Neue",Helvetica,Arial,sans-serif;white-space:break-spaces;background-color:rgba(250,166,26,0.08)" class=""> .</span><span style="color:rgb(220,221,222);font-family:Whitney,"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:16px;white-space:break-spaces;background-color:rgba(250,166,26,0.08)" class=""> </span><span style="background-color:rgba(250,166,26,0.08);font-family:Whitney,"Helvetica Neue",Helvetica,Arial,sans-serif;white-space:break-spaces" class=""><font class="">There are many opcodes like this one that need documenting.</font></span></div></div></blockquote></div></div></blockquote><div><br class=""></div><div>Definitely. Most of the instructions also need documentation on the type constraints (e.g. G_ADD only has one type and all three operands must agree on it, also G_PTR_ADD's first type must be a pointer), and any limitations on the types (e.g. G_MERGE_VALUES result must have the same number of bits as the sum of the operand sizes).</div><div><br class=""></div><div>It really ought to be tied into the source somehow so people update the docs as they change things too. I don't know of a good way to do this though.</div><div><br class=""></div><div>As an aside, if we're using a new enough version of pygments I added a syntax highlighter we can be using on the code examples.</div><br class=""><blockquote type="cite" class=""><div class=""><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class=""><div class=""><span style="background-color:rgba(250,166,26,0.08);font-family:Whitney,"Helvetica Neue",Helvetica,Arial,sans-serif;white-space:break-spaces" class=""><font class="">3. There are some TODOs that I am listing here . Need help to find out whether these TODOs been implemented so that I can try updating the documentation regarding these:  </font></span></div><div class="">          <a href="https://llvm.org/docs/GlobalISel/IRTranslator.html#aggregates" target="_blank" class="">https://llvm.org/docs/GlobalISel/IRTranslator.html#aggregates</a></div></div></blockquote></div></div></blockquote><div><br class=""></div><div>I'm afraid I haven't dug into this section.</div><br class=""><blockquote type="cite" class=""><div class=""><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class=""><div class="">          <a href="https://llvm.org/docs/GlobalISel/Legalizer.html#api-legalizerinfo" target="_blank" class="">https://llvm.org/docs/GlobalISel/Legalizer.html#api-legalizerinfo</a></div></div></blockquote></div></div></blockquote><div><br class=""></div><div>You mean the bit about using std::function? I did some work towards this fairly recently but I haven't got it working yet. The main problem is that calling LegalizerHelper methods from LegalizerInfo without some kind of indirection (like the LegalizerAction enum provides) is tricky. We're currently cheating a bit with custom rules as their implementation is in the LegalizerInfo which was meant to describe what needs to happen, rather than exactly how to do it.</div><br class=""><blockquote type="cite" class=""><div class=""><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class=""><div class="">          <a href="https://llvm.org/docs/GlobalISel/RegBankSelect.html#api-registerbankinfo" target="_blank" class="">https://llvm.org/docs/GlobalISel/RegBankSelect.html#api-registerbankinfo</a></div></div></blockquote></div></div></blockquote><div><br class=""></div><div>Quentin and Matt might be able to help with this bit.</div><div><br class=""></div><div>Hope this helps</div><br class=""><blockquote type="cite" class=""><div class=""><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr" class=""><div class="">Some feedback on this would be very helpful.</div><div class="">Thank you!</div><div class=""><br class=""></div><div class="">Pooja Yadav</div></div>
_______________________________________________<br class="">
LLVM Developers mailing list<br class="">
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" class="">llvm-dev@lists.llvm.org</a><br class="">
<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank" class="">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br class="">
</blockquote></div>
_______________________________________________<br class="">LLVM Developers mailing list<br class=""><a href="mailto:llvm-dev@lists.llvm.org" class="">llvm-dev@lists.llvm.org</a><br class="">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev<br class=""></div></blockquote></div><br class=""></div></body></html>