<div dir="ltr">I'm going to check this out now.<div><br></div><div>Regarding cputype/cpusubtype, I think the challenge we'll run on non-Apple platforms is that I think those constants are all controlled by Apple (i.e. authoritative source).  What happens when a gdb-remote stub is sending cputype/cpusubtype and using a non-Apple-supported cpu architecture, which surely is a possibility at some point?  I think to avoid that scenario, it's best to avoid Apple-specific cputype/cpusubtype info on non-Apple gdb-remote stubs.</div><div><br></div><div>(Apple guys - correct me if I'm wrong here).</div><div><br></div><div>Testing the change now.</div><div><br></div><div>-Todd</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Sep 10, 2014 at 1:50 PM, Todd Fiala <span dir="ltr"><<a href="mailto:tfiala@google.com" target="_blank">tfiala@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">I'm not averse to the change.  But I stumbled across a few places in the code where, once we see cputype/cpuinfo, we start assuming we are in Apple code.  And to keep everyone sane, if you can migrate to using triples on non-Apple hardware, I think that's a good idea.<div><br></div><div>Probably good if there's a once over on the change from an Apple team member on this here.</div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Sep 10, 2014 at 1:43 PM, Stephane Sezer <span dir="ltr"><<a href="mailto:sas@fb.com" target="_blank">sas@fb.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hey Todd,<br>
<br>
Yes, you are correct. I needed this patch for non-Apple targets that send a cputype/cpusubtype couple instead of a full triple. If this is something that you guys think is invalid, I can deal with it on the debug server we are using.<br>
<br>
AFAICT, right now we have two ways of getting the process info: one with the triples, which works everywhere, and one with cputype/cpusubtype that works only with apple targets. This would make both ways work everywhere in theory.<br>
<div><div><br>
On Sep 10, 2014, at 10:36 AM, Todd Fiala <<a href="mailto:tfiala@google.com" target="_blank">tfiala@google.com</a>> wrote:<br>
<br>
> Hey Stephane!<br>
><br>
> On this patch, one of the things I'm seeing is that it appears you are (maybe?) sending cputype and cpusubtype in cases where the target is not a MachO-based system.  In general, the cputype/cpusubtype are meant to be a MachO-xnu specific mechanism.  We try to *not* send those for non-Apple targets and instead send just the triples.<br>
><br>
> Are you in a position where this might be the case?  I can try out the patch but it looks like it's basically geared to handle qProcessInfo for non-MachO platforms sending cpu type info if I'm reading it right.<br>
><br>
> -Todd<br>
><br>
> On Tue, Sep 9, 2014 at 5:23 PM, Stephane Sezer <<a href="mailto:sas@fb.com" target="_blank">sas@fb.com</a>> wrote:<br>
> Instead of forcing the remote arch type to MachO all the time, we<br>
> inspect the OS/vendor that the remote debug server reports and use it to<br>
> set the arch type to MachO, ELF or COFF accordingly.<br>
><br>
><br>
> _______________________________________________<br>
> lldb-commits mailing list<br>
> <a href="mailto:lldb-commits@cs.uiuc.edu" target="_blank">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>
><br>
><br>
><br>
> --<br>
> Todd Fiala |   Software Engineer |     <a href="mailto:tfiala@google.com" target="_blank">tfiala@google.com</a> |     <a href="tel:650-943-3180" value="+16509433180" target="_blank">650-943-3180</a><br>
><br>
<br>
</div></div></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>
</div></div></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>