<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/73481>73481</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
`.intel_syntax` should respect `mov` with 64-bit address
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
workingjubilee
</td>
</tr>
</table>
<pre>
The following LLVM module:
```llvm
source_filename = "example.e8d519bf5b4bcf09-cgu.0"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"
module asm ".intel_syntax"
module asm "mov [0x1234567890], al"
module asm "movabs [0x1234567890], al"
!llvm.module.flags = !{!0, !1}
!0 = !{i32 8, !"PIC Level", i32 2}
!1 = !{i32 2, !"RtLibUseGOT", i32 1}
```
Gives rise to the following encoding:
```asm
.text:
mov BYTE PTR ds:0x34567890, al ; 88 04 25 90 78 56 34
movabs ds:0x1234567890, al ; a2 90 78 56 34 12 00 00 00
```
Note, in the first case, the silent truncation of an address that cannot fit into a 32-bit integer, despite the attempt to use `.intel_syntax`. The `movabs` pseudo-instruction is part of "AT&T syntax", and you will not find it in the Intel 64 SDM. I do not think there is any harm in respecting `movabs` despite that, but `mov` with such a large constant should probably be assembled to the same encoding.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyEVVtvozgU_jXOyxHI2GDIQx7SZjuq1NkdzWRX2qfKwAE8NTbCpkn-_cqQW7s3hBxsn-9cPn8-kc6p1iBuSPZAst1KTr6z4-Zgxzdl2p9TqTTiqrT1abPvEBqrtT0o08LLyx9fobf1pJHwLaE7QrdE0OXV-r1flpydxgpfG6XRyB6B8B0QxvAo-0FjjEWdJeuyycq0rBq6jqp2iilhbEF7ObbooZZeanmyk7_io57wLUYDyynhW87mIUyTj9PwJdJ5iNTloykCKGFFZIrwIS4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