Comments (1)
Looked into it and wouldn't restore the version of v5
.
As you already said, the v1
and q1
refer to the same register. Due to the Vector Arrangement Specifier
and the Vector index
, the offset in the register can be determined definitely. So semantically we shouldn't have a problem.
Now, simply printing v1
instead of q1
is not easily possible, because the API doesn't allow it. The cs_reg_name()
function only takes register identifiers. And v1
and q1
share the same identifier: AArch64_REG_Q1
. Hence it cannot decide which name to print.
Now, we could duplicate the register identifiers for Vn
registers (as in v5
), but this complicates usage of the API again. Because users have to check for AArch64_REG_V1
and AArch64_REG_Q1
to check, if they deal with the same register.
Second alternative is some complicated handling of this exception in cs_reg_name()
. But I don't think this is worth it, for such a small syntactical difference, which is semantically correct. (Also I am not sure it would actually work).
I added a flag in aarch64_op
which indicates if the register is a Vn
register.
And for cstool
I simply added the (vreg)
postfix.
cstool -d aarch64be 0e043c34
0 0e 04 3c 34 mov w20, v1.s[0]
ID: 1285 (umov)
Is alias: 1429 (mov) with ALIAS operand set
op_count: 2
operands[0].type: REG = w20
operands[0].access: WRITE
operands[1].type: REG = q1 (vreg)
operands[1].access: READ
Vector Arrangement Specifier: 0x20
Vector Index: 0
Registers read: q1
Registers modified: w20
Groups: HasNEONorSME
What do you think?
cc @FinnWilkinson.
from capstone.
Related Issues (20)
- Ability to Generate Bitmasks for Specific Instruction Components? HOT 3
- x64 disassembler big endian bug
- Compiler warnings in the next branch HOT 2
- python bindings depends on setuptools HOT 3
- Remove python2 leftovers
- [AArch64] Instr. with groups `HasNEON`, don't have `HasNEONorSME` and similar assigned. HOT 25
- Release v4.0.3
- Wrong operand type for RISCV compressed instruction disassemble
- [5.0.1] Warning in Mapping.c module
- [Auto-Sync] Add `PatchFiles` and `WriteFiles` steps to `ASUpdater`
- [Auto-Sync] Smarter MC test generator
- Add documentation about LLVM imported `FEATURE` groups.
- Capstone v5 compile issues HOT 1
- Capstone Next Bug in code. modRMRequired has an invalid index read
- register accesses for Implicit operands
- Add "DIET" CI job
- Incorrect aarch64 umov decoding HOT 3
- ARM AArch32 instruction ADD may decode wrong in ADR situation HOT 3
- HPPA, ARM disassemblers "error: comparison of unsigned expression in ‘< 0’ is always false [-Werror=type-limits]"
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from capstone.