<html>
<head>
<base href="http://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - Incorrect intptr_t type on aarch64 (cross compiling from x86_64)"
href="http://llvm.org/bugs/show_bug.cgi?id=18292">18292</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Incorrect intptr_t type on aarch64 (cross compiling from x86_64)
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>-New Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>simon.hosie@arm.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=11758" name="attach_11758" title="testcase">attachment 11758</a> <a href="attachment.cgi?id=11758&action=edit" title="testcase">[details]</a></span>
testcase
The type eventually comes from system /usr/include/stdint.h, but the header
that led me there belongs to Clang, so I _assume_ this is a Clang issue, and
may be a general problem with cross-compilation.
intptr_t and uintptr_t come out as 32-bit types when cross-compiling for
aarch64, on my system.
intptr.c attached. Command line:
% clang --target=aarch64-linux-gnu -c intptr.c
output:
intptr.c:9:9: warning: cast to 'void *' from smaller integer type 'int'
[-Wint-to-void-pointer-cast]
y = (void *)((intptr_t)&x ^ 0x5555aaaa);
^
1 warning generated.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>