A proposition of user-readable instruction disassembler for ARM64. It's only a framework and requires adding some the most common instruction opcodes.
Details
Diff Detail
- Repository
- rS FreeBSD src repository - subversion
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
sys/arm64/arm64/disassem.c | ||
---|---|---|
2 ↗ | (On Diff #12812) | Cavium? |
94 ↗ | (On Diff #12812) | Maybe uint32_t will be better to implicitly show the instruction length. |
144 ↗ | (On Diff #12812) | Maybe switch would be more readable. |
168 ↗ | (On Diff #12812) | Must we panic() here? We could return with error or place KASSERT here an return with error when invariants disabled. |
179 ↗ | (On Diff #12812) | Same here |
198 ↗ | (On Diff #12812) | Aaand here |
255 ↗ | (On Diff #12812) | matchp != 0 |
303 ↗ | (On Diff #12812) | Hmm if this is needed very early, etc. we may want to set a global variable indicating that this was already done. |
sys/arm64/include/disassem.h | ||
2 ↗ | (On Diff #12812) | Cavium? |
sys/arm64/arm64/disassem.c | ||
---|---|---|
287 ↗ | (On Diff #12817) | This looks a little odd given the distance between ret = 0 above and here. Why not just make this ret = arm64_..., and not set it above? |
sys/arm64/include/disassem.h | ||
29 ↗ | (On Diff #12817) | No tab after #ifndef (style(9) is a little odd about this) |
36 ↗ | (On Diff #12817) | Does this need to be a typedef? It hides the details on what is an internal to arm64 struct. |