Skip to content

[x86 disassembler] i386-only mode instructions are not shown as invalid in x86_64 #11036

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
llvmbot opened this issue Aug 15, 2011 · 4 comments
Closed
Labels
backend:X86 bugzilla Issues migrated from bugzilla

Comments

@llvmbot
Copy link
Member

llvmbot commented Aug 15, 2011

Bugzilla Link 10664
Resolution FIXED
Resolved on Nov 07, 2018 00:17
Version trunk
OS All
Blocks llvm/llvm-bugzilla-archive#10988
Reporter LLVM Bugzilla Contributor
CC @topperc

Extended Description

According to the "Intel® 64 and IA-32 Architectures Software Developer’s Manual
Volume 2 (2A & 2B): Instruction Set Reference, A-Z", p. 3-23:
AAA—ASCII Adjust After Addition
64-bit: Invalid

Using llvm-mc built from trunk revision 135913:
$ echo '0x37'| ./llvm-mc -disassemble -triple="i386" aaa
$ echo '0x37'| ./llvm-mc -disassemble -triple="x86_64" aaa

There are many 32-bit only instructions that are similar to this.

@llvmbot
Copy link
Member Author

llvmbot commented Sep 20, 2011

These are shown as invalid in 64-bit mode on p. 4-188 of the Intel doc:
$ echo '0x1f'| ./llvm-mc -disassemble -triple="x86_64" -x86-asm-syntax=intel
pop %ds
$ echo '0x07'| ./llvm-mc -disassemble -triple="x86_64" -x86-asm-syntax=intel
pop %es
$ echo '0x17'| ./llvm-mc -disassemble -triple="x86_64" -x86-asm-syntax=intel
pop %ss

@topperc
Copy link
Collaborator

topperc commented Sep 26, 2011

Fixed in r140370.

@llvmbot
Copy link
Member Author

llvmbot commented Oct 3, 2011

All of these cases appear to be fixed with llvm-mc built from r140997.

@bcardosolopes
Copy link
Member

mentioned in issue llvm/llvm-bugzilla-archive#10988

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 3, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend:X86 bugzilla Issues migrated from bugzilla
Projects
None yet
Development

No branches or pull requests

3 participants