<div dir="ltr">Hi Chijun,<br><br>Thanks for your interest in the project.<br><br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">I have gone through most of the LLVM Kaleidoscope tutorial and I have</span><br style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">watched the video of the presentation “Dominator Trees and incremental</span><br style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">updates that transcend time” presented on the 2017 LLVM Developers’</span><br style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">Meeting. I have also started to understand the algorithm mentioned in</span><br style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">the comments of the code related to the dominator tree.</span></blockquote><div> </div><div>This sounds like a good start, but I don't think there's strong need to understand the Depth Based Search algorithm in detail -- grasping the main idea behind it should be enough. If you want to have some rough idea on how it works you can try to run domtree tests with <font face="monospace, monospace">-debug-only=dom-tree-builder</font><font face="arial, helvetica, sans-serif">.<br>To run just the IR tests for dominators, you can do: </font><font face="monospace, monospace">./unittests/IR/IRTests --gtest_filter=DominatorTree*</font><font face="arial, helvetica, sans-serif">. Additionally, you can also play with </font><font face="monospace, monospace">Holder.F->viewCFG()</font><font face="arial, helvetica, sans-serif"> and </font><font face="monospace, monospace">DT->viewGraph()</font><font face="arial, helvetica, sans-serif"> to see what's going on inside the tests.</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><font face="arial, helvetica, sans-serif"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">I am wondering if there are some other bugs or materials I can go over</span><br style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">in order to achieve a better understanding on the LLVM’s codebase (or</span><br style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">the project mentioned above)? Which part of the codebase do you</span><br style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">recommend to view to learn more about the usage and drawbacks of the</span><br style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">current dominator tree related API? I would appreciate it.</span></font></blockquote><div> </div><div>I think that the programmer's manual is extremely useful when you want to get more familiar with the code base: <a href="http://llvm.org/docs/ProgrammersManual.html">http://llvm.org/docs/ProgrammersManual.html</a>. I would recommend to focus on how to interact with IR, llvm's data structures, and debug utilities.<br>The most important files related to the projects are probably: GenericDomTreeConstruction.h, GenericDomTree.h, Dominators.h, Dominators.cpp.<br><br>If you want to see the incremental API in action, take a look at some simpler transforms like loop deletion and aggressive dead code elimination (ADCE). The problems the project mentions can be seen in various 'helper'/'utils' functions used by transforms. Take a look at these code reviews, especially the functions that can accept DT* and/or DDT*:<br><a href="https://reviews.llvm.org/D41302">https://reviews.llvm.org/D41302</a><br><a href="https://reviews.llvm.org/D40146">https://reviews.llvm.org/D40146</a><br><a href="https://reviews.llvm.org/D42804">https://reviews.llvm.org/D42804</a><br><br>I think that it's worth adding that a better API is only one part the project; the second, perhaps bigger and more fun, is to figure out how to prune redundant PostDomTree updates when we have a fully-updated DomTree available.<br><br>Feel free to ask more questions should you have any -- I and others will be more than happy to clarify.<br><br>Best,<br>Kuba </div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Mar 1, 2018 at 2:29 PM, Chijun Sima via llvm-dev <span dir="ltr"><<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">Hello,<br>
<br>
I’m an undergraduate student studying CS in the South China University<br>
of Technology.<br>
<br>
I have been using clang compiler and related tools since I started<br>
studying C++ and I would like to work on LLVM in this year’s GSoC. I<br>
am interested in “Implement a single updater class for Dominators”.<br>
[1] I have achieved a bronze medal in the 2017 ACM-ICPC Asia Xian<br>
Regional Contest [2] (being a member of the team “Charizard”) thus I<br>
think I have some knowledge on basic tree/graph algorithms and data<br>
structures.<br>
<br>
I have gone through most of the LLVM Kaleidoscope tutorial and I have<br>
watched the video of the presentation “Dominator Trees and incremental<br>
updates that transcend time” presented on the 2017 LLVM Developers’<br>
Meeting. I have also started to understand the algorithm mentioned in<br>
the comments of the code related to the dominator tree. I have created<br>
a Bugzilla account and I am now working on a small bug related to<br>
syntax warning (Sema).<br>
<br>
I am wondering if there are some other bugs or materials I can go over<br>
in order to achieve a better understanding on the LLVM’s codebase (or<br>
the project mentioned above)? Which part of the codebase do you<br>
recommend to view to learn more about the usage and drawbacks of the<br>
current dominator tree related API? I would appreciate it.<br>
<br>
Best regards,<br>
<br>
Chijun Sima<br>
<br>
[1] <a href="https://llvm.org/OpenProjects.html#llvm_domtree_updater" rel="noreferrer" target="_blank">https://llvm.org/OpenProjects.<wbr>html#llvm_domtree_updater</a><br>
[2] <a href="https://icpc.baylor.edu/regionals/finder/asia-xian-2017/standings" rel="noreferrer" target="_blank">https://icpc.baylor.edu/<wbr>regionals/finder/asia-xian-<wbr>2017/standings</a><br>
______________________________<wbr>_________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/llvm-dev</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div>Jakub Kuderski</div></div>
</div>