<div dir="ltr">Hey Tong,<div><br></div><div>I think the intent here was simply a mistake of forgetting a reference.  Let's go with a simpler fix:</div><div><br></div><div>Index: source/Plugins/Process/Utility/RegisterContextLinux_x86_64.cpp<br>
</div><div><div>===================================================================</div><div>--- source/Plugins/Process/Utility/RegisterContextLinux_x86_64.cpp<span class="" style="white-space:pre"> </span>(revision 215418)</div>
<div>+++ source/Plugins/Process/Utility/RegisterContextLinux_x86_64.cpp<span class="" style="white-space:pre">  </span>(working copy)</div><div>@@ -90,7 +90,7 @@</div><div> static const RegisterInfo *</div><div> GetRegisterInfo_i386(const lldb_private::ArchSpec &arch)</div>
<div> {</div><div>-    static std::vector<lldb_private::RegisterInfo> g_register_infos (GetPrivateRegisterInfoVector ());</div><div>+    std::vector<lldb_private::RegisterInfo> &g_register_infos = GetPrivateRegisterInfoVector ();</div>
<div> </div><div>     // Allocate RegisterInfo only once</div><div>     if (g_register_infos.empty())</div></div><div><br></div><div>This removes the need for the global destructor and doesn't pay a price if that register info type is never hit.</div>
<div><br></div><div>Can you verify if this patch still fixes the issue?  If so, I'd rather go with this.</div><div><br></div><div>Thanks!</div><div><br></div><div>-Todd</div><div><br></div><div><br></div></div><div class="gmail_extra">
<br><br><div class="gmail_quote">On Mon, Aug 11, 2014 at 3:43 PM, Tong Shen <span dir="ltr"><<a href="mailto:endlessroad@google.com" target="_blank">endlessroad@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">Hi,<div><br></div><div>This patch fixes assertion for i386 process on x86_64 linux host.</div><div>Static variables with the same name in different functions are different variables.<span class="HOEnZb"><font color="#888888"><br clear="all">
<div><br>
</div>-- <br><div dir="ltr">Best Regards, Tong Shen</div>
</font></span></div></div>
<br>_______________________________________________<br>
lldb-commits mailing list<br>
<a href="mailto:lldb-commits@cs.uiuc.edu">lldb-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><table cellspacing="0" cellpadding="0" style="color:rgb(136,136,136);font-family:'Times New Roman'"><tbody><tr style="color:rgb(85,85,85);font-family:sans-serif;font-size:small">
<td nowrap style="border-top-style:solid;border-top-color:rgb(213,15,37);border-top-width:2px">Todd Fiala |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(51,105,232);border-top-width:2px"> Software Engineer |</td>
<td nowrap style="border-top-style:solid;border-top-color:rgb(0,153,57);border-top-width:2px"> <a href="mailto:tfiala@google.com" style="color:rgb(17,85,204)" target="_blank"><span style="background-color:rgb(255,255,204);color:rgb(34,34,34);background-repeat:initial initial">tfiala@google.com</span></a> |</td>
<td nowrap style="border-top-style:solid;border-top-color:rgb(238,178,17);border-top-width:2px"><font color="#1155cc"> <a>650-943-3180</a></font></td></tr></tbody></table><br></div>
</div>