-
Notifications
You must be signed in to change notification settings - Fork 20
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
AArch64 Capstone Update / SME2 support #429
base: dev
Are you sure you want to change the base?
Conversation
ce8e138
to
4921682
Compare
e3f2486
to
8ea3727
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A fair few comments but there's a lot of work done here so expected. Great job on this, a significant amount of effort done!
if (((Opcode::AArch64_FMOVD0 <= metadata_.opcode && | ||
metadata_.opcode <= Opcode::AArch64_FMOVS0) || | ||
(Opcode::AArch64_FMOVDXHighr <= metadata_.opcode && | ||
metadata_.opcode <= Opcode::AArch64_FMOVv8f16_ns)) && |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aren't the _ns
instructions moving immediates into vector registers? (and thus aren't "move to general instructions")
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For this I replaced the numbers with Opcodes (and referred to the previous Capstone version to make sure they aligned). If this is the case then we can remove the _ns
ones from this catch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Double-checked and we should remove _ns
from this catch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated catch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not much to add on top of the others' comments. Will approve once theirs have been resolved
…manual DDI0487K issue K.a 20th March 2024.
ec02455
to
e7d34e1
Compare
97fb519
This PR updates SimEng to work with a newer release of Capstone who's AArch64 engine is based on LLVM18, hence allowing SME2 support.
The reccommended version of LLVM has also been changed to 18.1.8 and the test suite has been updated to work with this version in order to dissassemble new AArch64 instructions.
Closes Issue #349
There have been large changes to Capstone internally for AArch64, some of the main ones which effect our current development / usage include:
A writeback from a pre/post index load/store is now included as an implicit destination. Hence, in instruction_execute the updated base address register is
resuts[0]
rather thanresults[1]
(for example).Post index immediate operands are now included as part of the memory operand in
mem.disp
. Post indexing with a register however is added as an additional operand.Aliasing can be dissabled for auto-sync architectures, and has been done for AArch64. This means expected registers for the operand are now correct and allows us to remove
revertalias()
from instruction_metadata completely! The only oddity is themnemonic
andoperandStr
are still that of the alias. This means exceptions or debugging print statements may be confusing. To indicate aliases better, anisAlias
bool has been added to the metadata and exception print out.Get automatic LLVM download and install working for version 18.1.8
Add AArch64 multi-vector operand enum decoding logic to instruction_decode