<div dir="ltr">Committed in r206241. Thanks Jim!<div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Apr 14, 2014 at 5:00 PM, Jim Grosbach <span dir="ltr"><<a href="mailto:grosbach@apple.com" target="_blank">grosbach@apple.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">LGTM. Thanks!<div><br><div><div><div class="h5"><div>On Apr 11, 2014, at 8:15 PM, Lang Hames <<a href="mailto:lhames@gmail.com" target="_blank">lhames@gmail.com</a>> wrote:</div>
<br></div></div><blockquote type="cite"><div><div class="h5"><div dir="ltr">Hi All,<div><br></div><div>I would like to require that MCDisassemblers be constructed with MCContexts.</div><div><br></div><div>There are two main reasons for this:</div>
<div><br></div><div>(1) It is reasonable for an MCDisassembler to want to create constant and/or target-specific MCExprs, but there is currently no attached MCContext to create the expr in. (There was previously an MCContext member in MCDisassembler, but this was removed in r<font face="arial, sans-serif"> 206063, and only ever initialised in an ad-hoc fashion.)</font></div>

<div><br></div><div>(2) Many in-tree targets are redundantly constructing MCRegisterInfo instances that could be obtained via the MCContext. </div><div><br></div><div>The attached patch adds an MCContext member to MCDisassembler, and adds an MCContext argument to the MCDisassembler constructor. All in-tree targets and tools are updated. Any out-of-tree targets should be easily updated by following the template used in this patch. There should be no functional change to the behaviour of any disassembler.</div>

<div><br></div><div>Cheers,</div><div>Lang.</div><div><br></div><div><font face="arial, sans-serif"><br></font></div></div>
</div></div><span><RequireMCContextForMCDisassembler.patch></span>_______________________________________________<br>llvm-commits mailing list<br><a href="mailto:llvm-commits@cs.uiuc.edu" target="_blank">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br></blockquote></div><br></div></div>
</blockquote></div><br></div>