Bug 22658 – Inline asm rejects [RIP+RAX] but not [RAX+RIP]

Status
NEW
Severity
normal
Priority
P3
Component
dmd
Product
D
Version
D2
Platform
x86_64
OS
Linux
Creation time
2022-01-08T03:12:51Z
Last change time
2024-12-13T19:20:19Z
Keywords
accepts-invalid, iasm
Assigned to
No Owner
Creator
mhh
Moved to GitHub: dmd#20036 →

Comments

Comment #0 by maxhaton — 2022-01-08T03:12:51Z
``` extern(C) void bdasm() { asm { naked; mov EAX, [RAX+RIP]; //mov EAX, [RIP+RAX]; } } ``` The error message is also terrible when it the check works. GNU AS rejects this correctly with the following: ``` simple.s: Assembler messages: simple.s:15: Error: `[RIP+RAX]' is not a valid base/index expression ```
Comment #1 by robert.schadek — 2024-12-13T19:20:19Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/20036 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB