diff options
| author | Samuel Arnold <samuel.arnold@crowdstrike.com> | 2026-06-18 12:48:36 -0700 |
|---|---|---|
| committer | iximeow <me@iximeow.net> | 2026-06-19 21:33:11 +0000 |
| commit | 1bff2519a50ac4e3ca98b4d874f70c02628c3f4a (patch) | |
| tree | 82afd2744696ec5656f05f76e35cbff7f9d2c7ae | |
| parent | fa24eedf78fb9fe2d87ac3f59763e25d3ba4462f (diff) | |
Add armv7::InstDecoder::in_thumb_mode() method
| -rw-r--r-- | CHANGELOG | 2 | ||||
| -rw-r--r-- | src/armv7.rs | 5 |
2 files changed, 7 insertions, 0 deletions
@@ -7,6 +7,8 @@ * support non-`*2` forms of coprocessor instructions * collapse `*2` encoding choice for coprocessor instructions into a paramter on the opcode (rather than distinct opcodes) +* ARMv7: added `armv7::InstDecoder::in_thumb_mode` to read back if an ARMv7 + decoder is operating in thumb mode. thank you for the patch, @Grond66! ## 0.4.0 diff --git a/src/armv7.rs b/src/armv7.rs index cb46d60..2ce8122 100644 --- a/src/armv7.rs +++ b/src/armv7.rs @@ -1131,6 +1131,11 @@ impl InstDecoder { self } + /// returns whether the decoder is currently set to decode in Thumb mode + pub fn in_thumb_mode(&self) -> bool { + self.thumb + } + /// initialize a new `arm` `InstDecoder` with default ("everything") support, but in `thumb` /// mode. pub fn default_thumb() -> Self { |
