<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">On Fri, Jan 27, 2017 at 2:48 PM Mehdi Amini <<a href="mailto:mehdi.amini@apple.com">mehdi.amini@apple.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg"><blockquote type="cite" class="gmail_msg"><div class="gmail_msg">On Jan 27, 2017, at 2:44 PM, David Blaikie <<a href="mailto:dblaikie@gmail.com" class="gmail_msg" target="_blank">dblaikie@gmail.com</a>> wrote:</div><br class="m_5315317863130017011Apple-interchange-newline gmail_msg"><div class="gmail_msg"><div dir="ltr" style="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" class="gmail_msg"><br class="gmail_msg"><br class="gmail_msg"><div class="gmail_quote gmail_msg"><div dir="ltr" class="gmail_msg">On Fri, Jan 27, 2017 at 2:11 PM Mehdi AMINI via Phabricator <<a href="mailto:reviews@reviews.llvm.org" class="gmail_msg" target="_blank">reviews@reviews.llvm.org</a>> wrote:<br class="gmail_msg"></div><blockquote class="gmail_quote gmail_msg" 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">mehdi_amini accepted this revision.<br class="gmail_msg">mehdi_amini added a comment.<br class="gmail_msg">This revision is now accepted and ready to land.<br class="gmail_msg"><br class="gmail_msg">LGTM.<br class="gmail_msg"><br class="gmail_msg"><br class="gmail_msg"><br class="gmail_msg">================<br class="gmail_msg">Comment at: lib/AST/ASTContext.cpp:8909<br class="gmail_msg">+<br class="gmail_msg">+    // Itanium ABI (& MSVC seems to do similarly) requires static locals in<br class="gmail_msg">+    // inline functions to be emitted anywhere they're needed, even if the<br class="gmail_msg">----------------<br class="gmail_msg">I assume you looked it up, do you have a ref? (Citation or pointer to right section/paragraph).<br class="gmail_msg"></blockquote><div class="gmail_msg"><br class="gmail_msg">Would you like a citation in source?</div></div></div></div></blockquote><div class="gmail_msg"><br class="gmail_msg"></div></div></div><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg"><div class="gmail_msg">Sure, why not?</div></div></div><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg"><br class="gmail_msg"><blockquote type="cite" class="gmail_msg"><div class="gmail_msg"><div dir="ltr" style="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" class="gmail_msg"><div class="gmail_quote gmail_msg"><div class="gmail_msg"> I thought that might be a bit strong since this is ABI-neutral code, notionally (so I was straddling that line a bit).<br class="gmail_msg"></div></div></div></div></blockquote><div class="gmail_msg"><br class="gmail_msg"></div></div></div><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg"><div class="gmail_msg">Well you refer to the ABI anyway already to explain the chosen behavior :)</div><div class="gmail_msg"><br class="gmail_msg"></div><div class="gmail_msg">And technically I’m not sure what the C++ standard mandates, the possibility of having different need for different ABI would indicate that the code can’t be totally ABI-neutral?</div></div></div></blockquote><div><br>Right, this one is beyond the C++ standard's reach. It's really an ABI issue, so arguably should be sunk into Clang's ABI understanding, just that for now all (Itanium + MSVC) the situations we know of/support have this behavior so there's no immediate need for that abstraction/extension point.<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg"><div class="gmail_msg"><br class="gmail_msg"></div><div class="gmail_msg">— </div></div></div><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg"><div class="gmail_msg">Mehdi</div></div></div><div style="word-wrap:break-word" class="gmail_msg"><div class="gmail_msg"><div class="gmail_msg"> </div><br class="gmail_msg"><blockquote type="cite" class="gmail_msg"><div class="gmail_msg"><div dir="ltr" style="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" class="gmail_msg"><div class="gmail_quote gmail_msg"><div class="gmail_msg"><br class="gmail_msg">I can't quite figure out how to navigate/find the ABI document nor cast the runes as Richard did for the citation, so hopefully he can chime in here.<br class="gmail_msg"> </div><blockquote class="gmail_quote gmail_msg" 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"><br class="gmail_msg"><br class="gmail_msg"><a href="https://reviews.llvm.org/D29233" rel="noreferrer" class="gmail_msg" target="_blank">https://reviews.llvm.org/D29233</a></blockquote></div></div></div></blockquote></div></div></blockquote></div></div>