<html>
<head>
<base href="https://bugs.llvm.org/">
</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 - [IA][ARM64] literal value out of range for directive"
href="https://bugs.llvm.org/show_bug.cgi?id=38642">38642</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>[IA][ARM64] literal value out of range for directive
</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>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Frontend
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>ndesaulniers@google.com
</td>
</tr>
<tr>
<th>CC</th>
<td>echristo@gmail.com, kristof.beyls@arm.com, kristof.beyls@gmail.com, llvm-bugs@lists.llvm.org, oliver.stannard@arm.com, srhines@google.com
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=20744" name="attach_20744" title="test.S">attachment 20744</a> <a href="attachment.cgi?id=20744&action=edit" title="test.S">[details]</a></span>
test.S
In the Linux kernel
(<a href="https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/crypto/aes-modes.S">https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/crypto/aes-modes.S</a>),
there's an assembly instruction:
ldr q8, =0x30000000200000001 /* addends 1,2,3[,0] */
This produces the error: literal value out of range for directive
I'm not sure what the `=` is supposed to do. 0x30000000200000001 is 9B (72b),
so q8 must be a vector register?
$ cat /tmp/test.S
.text
.global _start
_start:
ldr q8, =0x30000000200000001
$ aarch64-linux-gnu-as /tmp/test.S
$ aarch64-linux-gnu-objdump -D a.out
a.out: file format elf64-littleaarch64
Disassembly of section .text:
0000000000000000 <_start>:
0: 9c000088 ldr q8, 10 <_start+0x10>
...
10: 00000001 .word 0x00000001
14: 00000002 .word 0x00000002
18: 00000003 .word 0x00000003
1c: 00000000 .word 0x00000000
$ clang -target aarch64-linux-gnu /tmp/test.S
/tmp/test.S:5:12: error: literal value out of range for directive
ldr q8, =0x30000000200000001
^
I thought that =0x30000000200000001 was maybe an immediate, but changing the
`=` to a `#` produces a `bignum invalid` error in gas, and the same error in
this bug's title in Clang.</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>