<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 12 (filtered medium)">
<base href="http://llvm.org/bugs/"><!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0in;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:.5in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;}
span.EmailStyle20
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
/* List Definitions */
@list l0
        {mso-list-id:387648736;
        mso-list-template-ids:1324254700;}
@list l0:level1
        {mso-level-number-format:bullet;
        mso-level-text:;
        mso-level-tab-stop:.5in;
        mso-level-number-position:left;
        text-indent:-.25in;
        mso-ansi-font-size:10.0pt;
        font-family:Symbol;}
@list l1
        {mso-list-id:1324430474;
        mso-list-type:hybrid;
        mso-list-template-ids:1509720032 -961101884 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
@list l1:level1
        {mso-level-start-at:0;
        mso-level-number-format:bullet;
        mso-level-text:-;
        mso-level-tab-stop:none;
        mso-level-number-position:left;
        text-indent:-.25in;
        font-family:"Calibri","sans-serif";
        mso-fareast-font-family:Calibri;}
ol
        {margin-bottom:0in;}
ul
        {margin-bottom:0in;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Thanks for the patch, Robert,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">I suspect that using pre-processor logic to determine the architecture will only help in the case where lldb is compiled using the same architecture as the
 debug target.  For instance, when running an i386 application on x86_64, the lower register half of the x86_64 registers should be reported.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Options include removing the logging code, adding parameters to PtraceWrapper to specify the target architecture, lifting the code to a base class of ReadRegOperation
 and ReadGPROperation, or lifting the code to RegisterContext_x86_64/RegisterContext_i386.   If maintaining the logging code is preferred, please consider limiting the log to the case where “log enable” uses the --verbose parameter.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Cheers,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoListParagraph" style="text-indent:-.25in;mso-list:l1 level1 lfo2"><![if !supportLists]><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><span style="mso-list:Ignore">-<span style="font:7.0pt "Times New Roman"">       
</span></span></span><![endif]><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Ashok<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> lldb-dev-bounces@cs.uiuc.edu [mailto:lldb-dev-bounces@cs.uiuc.edu]
<b>On Behalf Of </b>bugzilla-daemon@llvm.org<br>
<b>Sent:</b> Monday, July 01, 2013 3:22 PM<br>
<b>To:</b> lldb-dev@cs.uiuc.edu<br>
<b>Subject:</b> [lldb-dev] [Bug 16511] New: FreeBSD ProcessMonitor.cpp uses AMD64 register names unconditionally<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<table class="MsoNormalTable" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Bug ID<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal"><a href="http://llvm.org/bugs/show_bug.cgi?id=16511" title="NEW --- - FreeBSD ProcessMonitor.cpp uses AMD64 register names unconditionally">16511</a>
<o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Summary<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">FreeBSD ProcessMonitor.cpp uses AMD64 register names unconditionally
<o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Product<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">lldb <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Version<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">unspecified <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Hardware<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">PC <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>OS<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">other <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Status<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">NEW <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Severity<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">normal <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Priority<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">P <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Component<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">All Bugs <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Assignee<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal"><a href="mailto:lldb-dev@cs.uiuc.edu">lldb-dev@cs.uiuc.edu</a>
<o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Reporter<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal"><a href="mailto:rmh@gnu.org">rmh@gnu.org</a> <o:p></o:p></p>
</td>
</tr>
<tr>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal" align="center" style="text-align:center"><b>Classification<o:p></o:p></b></p>
</td>
<td style="padding:4.8pt 4.8pt 4.8pt 4.8pt">
<p class="MsoNormal">Unclassified <o:p></o:p></p>
</td>
</tr>
</tbody>
</table>
<div>
<pre>Created <a name="attach_10803"></a><a href="attachment.cgi?id=10803" title="untested patch to fix build on i386-kfreebsd-gnu (and possibly i386-freebsd)">attachment 10803</a> <a href="attachment.cgi?id=10803&action=edit" title="untested patch to fix build on i386-kfreebsd-gnu (and possibly i386-freebsd)">[details]</a><o:p></o:p></pre>
<pre>untested patch to fix build on i386-kfreebsd-gnu (and possibly i386-freebsd)<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>I found this on GNU/kFreeBSD, but I believe FreeBSD would be affected as well.<o:p></o:p></pre>
<pre>Please let me know if I may be missing something.<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>As you can see in last attempted build for i386-kfreebsd-gnu [1],<o:p></o:p></pre>
<pre>ProcessMonitor.cpp won't build because it's referring to registers which exist<o:p></o:p></pre>
<pre>on AMD64, but not on IA32.<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>I think this could be fixed using special case for i386 and amd64. Please see<o:p></o:p></pre>
<pre>attached patch (UNTESTED).<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>[1]<o:p></o:p></pre>
<pre><a href="https://buildd.debian.org/status/fetch.php?pkg=llvm-toolchain-3.3&arch=kfreebsd-i386&ver=1%3A3.3-3&stamp=1372679969">https://buildd.debian.org/status/fetch.php?pkg=llvm-toolchain-3.3&arch=kfreebsd-i386&ver=1%3A3.3-3&stamp=1372679969</a><o:p></o:p></pre>
</div>
<div class="MsoNormal" align="center" style="text-align:center">
<hr size="3" width="100%" align="center">
</div>
<p class="MsoNormal">You are receiving this mail because: <o:p></o:p></p>
<ul type="disc">
<li class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;mso-list:l0 level1 lfo1">
You are the assignee for the bug.<o:p></o:p></li></ul>
</div>
</body>
</html>