On Thu, Feb 3, 2011 at 12:53 AM, Duncan Sands <span dir="ltr"><<a href="mailto:baldrick@free.fr">baldrick@free.fr</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi Talin,<br>
<div class="im"><br>
> I find that I call the static methods in ConstantExpr a *lot* without going<br>
> through IRBuilder - hundreds of times in my frontend. My language generates a<br>
> lot of static data - reflection information, trace tables for the garbage<br>
> collector, dispatch tables, runtime annotations, static object instances, and so<br>
> on. (In fact there's a special helper class "StructBuilder" that automates a lot<br>
> of the work of building constant structs, such as adding the standard object<br>
> header and so on.)<br>
<br>
</div>I think it would be better to create a ConstBuilder class rather than add stuff<br>
to ConstantExpr.<br></blockquote><div><br></div><div>OK I'll do that. A few questions:</div><div><br></div><div>1) Capitalize method names or not? I see both styles - the style guide says lower case, but it appears that the newer code is using capitalized method names.</div>
<div><br></div><div>2) Should methods be named "CreateXXX" (like IRBuilder) or "GetXXX" (like ConstantExpr).</div><div><br></div><div>3) Should method comments use @brief or repeat the method name - I see both styles in the code. </div>
<div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>
Ciao, Duncan.<br>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:LLVMdev@cs.uiuc.edu">LLVMdev@cs.uiuc.edu</a> <a href="http://llvm.cs.uiuc.edu" target="_blank">http://llvm.cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev</a><br>
</blockquote></div><br><br clear="all"><br>-- <br>-- Talin<br>