<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">
Hi Steve, Eric
<div class=""><br class="">
</div>
<div class="">I believe (please correct me if I’m wrong!) that the only places that C-style string handling and manipulation currently happens is in the functions that interact with the file system and perform IO, as this is currently mostly written with posix
 IO calls. I am currently working actively on changing these cases to use LLVM’s file IO functions and/or llvm::MemoryBuffer, which is certainly necessary to happen before merging. As part of this, I will transition the string handling to use C++-style strings
 and manipulation. I’ve already done this for the module writer in this PR for example: <a href="https://github.com/flang-compiler/f18/pull/993" class="">https://github.com/flang-compiler/f18/pull/993</a></div>
<div class=""><br class="">
</div>
<div class="">Regardless of whether I’m right about that being the only place it happens, I think we should separate out two things here: replacing any C-style string handling with more modern C++ string handling, and replacing uses of std::string/std::string_view
 with llvm::SmallString/llvm::StringRef where appropriate. The former certainly should happen before the merge (again, regardless of whether it happens in more places than IO). What we meant in the list that Richard sent was that the latter is more open-ended
 and should happen after the merge.</div>
<div class=""><br class="">
</div>
<div class="">I hope that helps to clarify what we were talking about.</div>
<div class=""><br class="">
</div>
<div class="">David Truby</div>
<div class="">
<div><br class="">
<blockquote type="cite" class="">
<div class="">On 25 Feb 2020, at 14:57, Steve Scalpone 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 class="WordSection1" style="page: WordSection1; caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Hi Eric,<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<o:p class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Old flang certainly uses C-style strings but f18 uses std::string with few exceptions.  Most of the instances in f18 of “char *” aren’t really strings in the C sense – they’re not null terminated and are really just pointers into raw or cooked source files/streams. 
 I can’t think of an instance where the compiler dynamically allocates an array of characters and uses it as a C string.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<o:p class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
- Steve<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<o:p class=""> </o:p></div>
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<o:p class=""> </o:p></div>
<div style="border-style: solid none none; border-top-width: 1pt; border-top-color: rgb(181, 196, 223); padding: 3pt 0in 0in;" class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<b class=""><span style="font-size: 12pt;" class="">From:<span class="Apple-converted-space"> </span></span></b><span style="font-size: 12pt;" class="">llvm-dev <<a href="mailto:llvm-dev-bounces@lists.llvm.org" style="color: blue; text-decoration: underline;" class="">llvm-dev-bounces@lists.llvm.org</a>>
 on behalf of Eric Christopher via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" style="color: blue; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>><br class="">
<b class="">Reply-To:<span class="Apple-converted-space"> </span></b>Eric Christopher <<a href="mailto:echristo@gmail.com" style="color: blue; text-decoration: underline;" class="">echristo@gmail.com</a>><br class="">
<b class="">Date:<span class="Apple-converted-space"> </span></b>Monday, February 24, 2020 at 5:01 PM<br class="">
<b class="">To:<span class="Apple-converted-space"> </span></b>Timothy Keith <<a href="mailto:tkeith@nvidia.com" style="color: blue; text-decoration: underline;" class="">tkeith@nvidia.com</a>><br class="">
<b class="">Cc:<span class="Apple-converted-space"> </span></b>"<a href="mailto:llvm-dev@lists.llvm.org" style="color: blue; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>" <<a href="mailto:llvm-dev@lists.llvm.org" style="color: blue; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>><br class="">
<b class="">Subject:<span class="Apple-converted-space"> </span></b>Re: [llvm-dev] Plan for landing flang in monorepo<o:p class=""></o:p></span></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<o:p class=""> </o:p></div>
</div>
<table class="MsoNormalTable" border="1" cellpadding="0" style="margin-left: 0.5in; background-color: rgb(255, 235, 156); background-position: initial initial; background-repeat: initial initial;">
<tbody class="">
<tr class="">
<td style="padding: 0.75pt;" class="">
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<b class=""><span style="font-size: 7.5pt; font-family: Verdana, sans-serif;" class="">External email: Use caution opening links or attachments</span></b><span style="font-size: 7.5pt; font-family: Verdana, sans-serif;" class=""></span><o:p class=""></o:p></div>
</td>
</tr>
</tbody>
</table>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<o:p class=""> </o:p></div>
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Last I looked there's a lot of char * based string manipulation in f18. I'd like that moved to std::string/string_view/StringRef uses.<o:p class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<o:p class=""> </o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
-eric<o:p class=""></o:p></div>
</div>
</div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<o:p class=""> </o:p></div>
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
On Mon, Feb 24, 2020 at 4:57 PM Timothy Keith <<a href="mailto:tkeith@nvidia.com" style="color: blue; text-decoration: underline;" class="">tkeith@nvidia.com</a>> wrote:<o:p class=""></o:p></div>
</div>
<blockquote style="border-style: none none none solid; border-left-width: 1pt; border-left-color: rgb(204, 204, 204); padding: 0in 0in 0in 6pt; margin-left: 4.8pt; margin-right: 0in;" class="" type="cite">
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Can you elaborate on this?<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 1in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
-  to move the std::string/string_view/StringRef changes to pre-merge unless you're going to have someone dedicated to handling them post-merge (rather than "time permits"). The C vs C++ ism here is fairly strong and I'd like to get the C-style string handling
 out fairly quickly.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
I understood this item to be looking into replacing uses of std::string with a more appropriate LLVM data structure where there is one. What is the “C-style string handling” part of it?<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Tim<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
<div style="border-style: solid none none; border-top-width: 1pt; border-top-color: rgb(181, 196, 223); padding: 3pt 0in 0in;" class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<b class=""><span style="font-size: 12pt;" class="">From:<span class="Apple-converted-space"> </span></span></b><span style="font-size: 12pt;" class="">llvm-dev <<a href="mailto:llvm-dev-bounces@lists.llvm.org" target="_blank" style="color: blue; text-decoration: underline;" class="">llvm-dev-bounces@lists.llvm.org</a>>
 on behalf of Eric Christopher via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" style="color: blue; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>><br class="">
<b class="">Reply-To:<span class="Apple-converted-space"> </span></b>Eric Christopher <<a href="mailto:echristo@gmail.com" target="_blank" style="color: blue; text-decoration: underline;" class="">echristo@gmail.com</a>><br class="">
<b class="">Date:<span class="Apple-converted-space"> </span></b>Monday, February 24, 2020 at 3:26 PM<br class="">
<b class="">To:<span class="Apple-converted-space"> </span></b>Richard Barton <<a href="mailto:Richard.Barton@arm.com" target="_blank" style="color: blue; text-decoration: underline;" class="">Richard.Barton@arm.com</a>><br class="">
<b class="">Cc:<span class="Apple-converted-space"> </span></b>"<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" style="color: blue; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>" <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" style="color: blue; text-decoration: underline;" class="">llvm-dev@lists.llvm.org</a>><br class="">
<b class="">Subject:<span class="Apple-converted-space"> </span></b>Re: [llvm-dev] Plan for landing flang in monorepo</span><o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<table class="MsoNormalTable" border="1" cellpadding="0" style="margin-left: 0.5in; background-color: rgb(255, 235, 156); background-position: initial initial; background-repeat: initial initial;">
<tbody class="">
<tr class="">
<td style="padding: 0.75pt;" class="">
<div style="margin: 0in 0in 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<b class=""><span style="font-size: 7.5pt; font-family: Verdana, sans-serif;" class="">External email: Use caution opening links or attachments</span></b><span style="font-size: 7.5pt; font-family: Verdana, sans-serif;" class=""></span><o:p class=""></o:p></div>
</td>
</tr>
</tbody>
</table>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<span style="color: white;" class=""> </span><o:p class=""></o:p></div>
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Hi Richard,<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Thanks for the work and mail with a plan. Other than the two comments below I think this plan is quite workable and am in support.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
I think the only requests I'd make is:<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 -  to move the std::string/string_view/StringRef changes to pre-merge unless you're going to have someone dedicated to handling them post-merge (rather than "time permits"). The C vs C++ ism here is fairly strong and I'd like to get the C-style string handling
 out fairly quickly. In my personal priority list I'd put this above the std:list migration.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 - large scale renames: For naming issues I think you can automate a lot of it via clang-tidy ahead of time if you wanted to go down that path. I think it could turn it from a fairly arduous task to one that's a little easier.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Thanks!<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
-eric<o:p class=""></o:p></div>
</div>
</div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
On Thu, Feb 20, 2020 at 9:41 AM Richard Barton <<a href="mailto:Richard.Barton@arm.com" target="_blank" style="color: blue; text-decoration: underline;" class="">Richard.Barton@arm.com</a>> wrote:<o:p class=""></o:p></div>
</div>
<blockquote style="border-style: none none none solid; border-left-width: 1pt; border-left-color: rgb(204, 204, 204); padding: 0in 0in 0in 6pt; margin: 5pt 0in 5pt 4.8pt;" class="" type="cite">
<div class="">
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Hi llvm-dev<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
It's been a few weeks since I last gave an update on F18 and our progress on readying it for inclusion into the monorepo. Last time we discussed this the community challenged us to make the F18 source code look more like an LLVM project and to come up with
 a plan and schedule for completing this work (<a href="http://lists.llvm.org/pipermail/llvm-dev/2020-January/137989.html" target="_blank" style="color: blue; text-decoration: underline;" class=""><span style="color: rgb(5, 99, 193);" class="">http://lists.llvm.org/pipermail/llvm-dev/2020-January/137989.html</span></a>)<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
The full list of changes that could be made to make F18 more LLVM-like is very long. We're interested in identifying what the absolute dealbreakers are that block inclusion into the monorepo and which changes would be acceptable to make after inclusion to the
 monorepo. We've come up with strawman lists for each and would like to propose the following plan of action:<o:p class=""></o:p></div>
</div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
1.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>We have captured our strawman proposal for all the changes that need to happen to F18 to make it ready for inclusion into
 the monorepo on a github project board:<span class="Apple-converted-space"> </span><a href="https://github.com/orgs/flang-compiler/projects/8" target="_blank" style="color: blue; text-decoration: underline;" class=""><span style="color: rgb(5, 99, 193);" class="">https://github.com/orgs/flang-compiler/projects/8</span></a><span class="Apple-converted-space"> </span>(also
 repeated at the end of this mail.)<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
1.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>We are working through this list and we believe that we can complete this work in time for a new upstreaming date of 16th
 March.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
2.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>We have captured further work that we plan to complete on F18 after merging to the monorepo<span class="Apple-converted-space"> </span><a href="https://github.com/orgs/flang-compiler/projects/10" target="_blank" style="color: blue; text-decoration: underline;" class=""><span style="color: rgb(5, 99, 193);" class="">https://github.com/orgs/flang-compiler/projects/10</span></a>(also
 repeated below)<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
3.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>We believe that we can complete this work before the LLVM11 branching date in June.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
4.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>After this date, we'll keep improving the code as we go along and not on any specific timescale.<o:p class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
We'd really appreciate feedback on the two lists of changes, specifically: are these lists complete? Is everyone satisfied that with all the items on<a href="https://github.com/orgs/flang-compiler/projects/8" target="_blank" style="color: blue; text-decoration: underline;" class=""><span style="color: rgb(5, 99, 193);" class="">https://github.com/orgs/flang-compiler/projects/8</span></a>,
 we'd be happy to accept F18 into the monorepo? Are there any further changes that would need to be made to F18 for this to happen?<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Thanks<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Rich<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
More info on the lists:<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Pre-merge list:<span class="Apple-converted-space"> </span><a href="https://github.com/orgs/flang-compiler/projects/8" target="_blank" style="color: blue; text-decoration: underline;" class=""><span style="color: rgb(5, 99, 193);" class="">https://github.com/orgs/flang-compiler/projects/8</span></a><o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
The status today is that many of the items on the pre-merge list are well underway or complete.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
1.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Integrate into the monorepo CMake<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
a.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>This will be as an optional project, and default to not building.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
b.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>This also adds Doxygen infrastructure so we can start to improve interface documentation and continue post-merge.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
2.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>F18 changes to make it more LLVM-like in code style<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
c.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>Rationalise headers to put public headers in /include and not /lib<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
d.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Examine F18's clang-format file and minimise deviations to the LLVM clang-format<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
e.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>Rename all .cc files to .cpp<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
f.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>Capitalize the module directory names in /lib and /include (e.g. /lib/Parser)<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
3.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Increase use of LLVM APIs and utilities in F18<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
g.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>Switch F18 custom File handling to LLVM's File handling (helps with non-POSIX platform support)<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
h.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Change uses of C++ standard stream IO library to LLVM's equivalent library<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
i.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">       <span class="Apple-converted-space"> </span></span>Audit use of std::list and consider migrating to a suitable alternative in LLVM's API<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
j.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">       <span class="Apple-converted-space"> </span></span>Use llvm_unreachable with an error message for unreachable cases<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
4.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Convert the regression test suite to using lit rather than ctest<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
k.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>Porting off the custom scripts to FileCheck will continue after this but we think it should not gate inclusion to the monorepo.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
5.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Ensure that F18 builds with the same compilers as the rest of the monorepo<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
l.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">       <span class="Apple-converted-space"> </span></span>One caveat is that we can only support C++17 compilers<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
m.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">   <span class="Apple-converted-space"> </span></span>We propose to defer Windows support until after we merge<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
n.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>We will specifically also check with the latest LLVM 10 rc<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Post-merge list:<span class="Apple-converted-space"> </span><a href="https://github.com/orgs/flang-compiler/projects/10" target="_blank" style="color: blue; text-decoration: underline;" class=""><span style="color: rgb(5, 99, 193);" class="">https://github.com/orgs/flang-compiler/projects/10</span></a><o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
This is the work that will happen right away after merging to the monorepo<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
1.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>F18 changes to make it more LLVM-like in code style - We will perform a one-off exercise where we audit the code to find
 these instances and bring them in line. We'll look at:<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
a.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>Braces on all single-line if statements<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
b.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Uses of else-after-return.<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
2.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Increase use of LLVM APIs and utilities in F18 - We'll audit the uses of these datatypes and try to move to a suitable LLVM
 alternative<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
c.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>std::string/std::string_view<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
d.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>std::vector<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
e.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>std::set<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
f.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>std::map<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
3.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Further work on porting the test suite to make it more LLVM-like<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
g.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>Port lit tests to FileCheck<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
h.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Port unit tests to gtest<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
i.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">       <span class="Apple-converted-space"> </span></span>Implement equivalent to clang -verify and port tests to that<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
4.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Support Windows<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
j.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">       <span class="Apple-converted-space"> </span></span>Porting to LLVM file I/O is the main blocker - included in the post-merge worklist - but there will be more to do after
 this.<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
k.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">      <span class="Apple-converted-space"> </span></span>Isuru Fernando is going to lead this effort<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
5.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Set up official builders<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
l.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">       <span class="Apple-converted-space"> </span></span>Arm will handle bots for AArch64<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
m.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">   <span class="Apple-converted-space"> </span></span>Nvidia will handle X86<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
n.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Tarique Islam at IBM will set up a builder for Power:<span class="Apple-converted-space"> </span><a href="http://lists.llvm.org/pipermail/flang-dev/2020-February/000232.html" target="_blank" style="color: blue; text-decoration: underline;" class=""><span style="color: rgb(5, 99, 193);" class="">http://lists.llvm.org/pipermail/flang-dev/2020-February/000232.html</span></a><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
o.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Any further help from community bot maintainers to cover all the platforms and compilers would be greatly appreciated.<o:p class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
One specific ask in the last round of feedback was on sharing lib/common/Although we see the benefit of doing this exercise, we feel it is a bit too early to start. One design principle we wish to stick to is for the Fortran runtime and compiler align on their
 implementations. For the specific example of<span class="Apple-converted-space"> </span><a href="https://github.com/flang-compiler/f18/blob/master/include/flang/common/bit-population-count.h" target="_blank" style="color: blue; text-decoration: underline;" class=""><span style="color: rgb(5, 99, 193);" class="">https://github.com/flang-compiler/f18/blob/master/include/flang/common/bit-population-count.h</span></a><span class="Apple-converted-space"> </span>we'd
 want the compiler and runtime POPCNT intrinsic to align on implementation. The F18 runtime is still a work in progress. We need to decide on how or if this could share code with LLVM libraries and then we can revisit the implementations in include/flang/common.<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
 <o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
Future work<o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
After all the above is done, we will continue to bring the code more in line with LLVM style and API usage by fixing things as we find them during development and enforce the new style through code review. A few specific areas that have been mentioned before
 that we will tackle in this way are: <span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
</div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
1.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Add Doxygen style comments to interfaces<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
2.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Classes, files, names, etc. where a more LLVM-standard naming can be used.<span class="Apple-converted-space"> </span><o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
3.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Refactor code to use early exits when suitable<o:p class=""></o:p></div>
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
4.<span style="font-size: 7pt; font-family: "Times New Roman", serif;" class="">     <span class="Apple-converted-space"> </span></span>Audit functions in include/flang/common and port to LLVM equivalents (e.g. builtin_popcount)<o:p class=""></o:p></div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<span style="font-family: "Times New Roman", serif;" class=""> </span><o:p class=""></o:p></div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
<span style="font-family: "Times New Roman", serif;" class=""> </span><o:p class=""></o:p></div>
</div>
</div>
</blockquote>
</div>
</div>
</div>
<div class="">
<div class="MsoNormal" align="center" style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif; text-align: center;">
<hr size="0" width="100%" align="center" class="">
</div>
</div>
<div class="">
<div style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif;" class="">
This email message is for the sole use of the intended recipient(s) and may contain confidential information.  Any unauthorized review, use, disclosure or distribution is prohibited.  If you are not the intended recipient, please contact the sender by reply
 email and destroy all copies of the original message.<o:p class=""></o:p></div>
</div>
<div class="">
<div class="MsoNormal" align="center" style="margin: 0in 0in 0.0001pt 0.5in; font-size: 11pt; font-family: Calibri, sans-serif; text-align: center;">
<hr size="0" width="100%" align="center" class="">
</div>
</div>
</div>
</blockquote>
</div>
</div>
</div>
<span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">_______________________________________________</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">
<span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class="">LLVM
 Developers mailing list</span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">
<span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class=""><a href="mailto:llvm-dev@lists.llvm.org" class="">llvm-dev@lists.llvm.org</a></span><br style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">
<span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class=""><a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" class="">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a></span></div>
</blockquote>
</div>
<br class="">
</div>
</body>
</html>