smallworld-re 1.0.3__py3-none-any.whl → 2.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- smallworld/analyses/__init__.py +8 -0
- smallworld/analyses/analysis.py +8 -67
- smallworld/analyses/code_coverage.py +1 -2
- smallworld/analyses/colorizer.py +301 -534
- smallworld/analyses/colorizer_def_use.py +217 -0
- smallworld/analyses/colorizer_summary.py +173 -83
- smallworld/analyses/field_detection/field_analysis.py +7 -8
- smallworld/analyses/field_detection/hints.py +1 -1
- smallworld/analyses/field_detection/malloc.py +2 -2
- smallworld/analyses/trace_execution.py +160 -0
- smallworld/analyses/trace_execution_types.py +42 -0
- smallworld/analyses/unstable/angr/divergence.py +1 -2
- smallworld/analyses/unstable/angr/model.py +5 -6
- smallworld/analyses/unstable/angr_nwbt.py +3 -4
- smallworld/analyses/unstable/code_coverage.py +2 -3
- smallworld/analyses/unstable/code_reachable.py +2 -3
- smallworld/analyses/unstable/control_flow_tracer.py +2 -3
- smallworld/analyses/unstable/pointer_finder.py +2 -3
- smallworld/analyses/unstable/utils/tui.py +71 -0
- smallworld/emulators/__init__.py +3 -1
- smallworld/emulators/angr/angr.py +30 -9
- smallworld/emulators/angr/machdefs/__init__.py +2 -0
- smallworld/emulators/angr/machdefs/aarch64.py +1 -1
- smallworld/emulators/angr/machdefs/amd64.py +0 -4
- smallworld/emulators/angr/machdefs/arm.py +0 -2
- smallworld/emulators/angr/machdefs/i386.py +0 -2
- smallworld/emulators/angr/machdefs/loongarch.py +340 -0
- smallworld/emulators/angr/machdefs/machdef.py +1 -8
- smallworld/emulators/angr/machdefs/mips.py +0 -2
- smallworld/emulators/angr/machdefs/mips64.py +0 -2
- smallworld/emulators/angr/machdefs/ppc.py +1 -2
- smallworld/emulators/angr/machdefs/riscv.py +8 -10
- smallworld/emulators/angr/machdefs/xtensa.py +7 -4
- smallworld/emulators/emulator.py +22 -0
- smallworld/emulators/ghidra/__init__.py +37 -0
- smallworld/emulators/ghidra/ghidra.py +513 -0
- smallworld/emulators/ghidra/machdefs/__init__.py +31 -0
- smallworld/emulators/ghidra/machdefs/aarch64.py +289 -0
- smallworld/emulators/ghidra/machdefs/amd64.py +185 -0
- smallworld/emulators/ghidra/machdefs/arm.py +370 -0
- smallworld/emulators/ghidra/machdefs/i386.py +109 -0
- smallworld/emulators/ghidra/machdefs/loongarch.py +162 -0
- smallworld/emulators/ghidra/machdefs/machdef.py +81 -0
- smallworld/emulators/ghidra/machdefs/mips.py +163 -0
- smallworld/emulators/ghidra/machdefs/mips64.py +186 -0
- smallworld/emulators/ghidra/machdefs/ppc.py +98 -0
- smallworld/emulators/ghidra/machdefs/riscv.py +208 -0
- smallworld/emulators/ghidra/machdefs/xtensa.py +21 -0
- smallworld/emulators/ghidra/typing.py +28 -0
- smallworld/emulators/hookable.py +18 -4
- smallworld/emulators/panda/machdefs/__init__.py +2 -2
- smallworld/emulators/panda/machdefs/aarch64.py +186 -11
- smallworld/emulators/panda/machdefs/amd64.py +103 -11
- smallworld/emulators/panda/machdefs/arm.py +216 -20
- smallworld/emulators/panda/machdefs/i386.py +30 -7
- smallworld/emulators/panda/machdefs/machdef.py +9 -16
- smallworld/emulators/panda/machdefs/mips.py +49 -5
- smallworld/emulators/panda/machdefs/mips64.py +57 -5
- smallworld/emulators/panda/machdefs/ppc.py +38 -13
- smallworld/emulators/panda/panda.py +146 -44
- smallworld/emulators/unicorn/__init__.py +2 -0
- smallworld/emulators/unicorn/machdefs/aarch64.py +253 -264
- smallworld/emulators/unicorn/machdefs/amd64.py +254 -259
- smallworld/emulators/unicorn/machdefs/arm.py +200 -212
- smallworld/emulators/unicorn/machdefs/i386.py +84 -90
- smallworld/emulators/unicorn/machdefs/machdef.py +2 -23
- smallworld/emulators/unicorn/machdefs/mips.py +127 -135
- smallworld/emulators/unicorn/unicorn.py +52 -13
- smallworld/helpers.py +4 -19
- smallworld/hinting/hinting.py +22 -192
- smallworld/hinting/hints.py +50 -18
- smallworld/instructions/bsid.py +8 -8
- smallworld/logging.py +4 -2
- smallworld/platforms/__init__.py +12 -0
- smallworld/platforms/defs/__init__.py +36 -0
- smallworld/platforms/defs/aarch64.py +450 -0
- smallworld/platforms/defs/amd64.py +463 -0
- smallworld/platforms/defs/arm.py +519 -0
- smallworld/platforms/defs/i386.py +258 -0
- smallworld/platforms/defs/loongarch.py +270 -0
- smallworld/platforms/defs/mips.py +321 -0
- smallworld/platforms/defs/mips64.py +313 -0
- smallworld/platforms/defs/platformdef.py +97 -0
- smallworld/platforms/defs/powerpc.py +259 -0
- smallworld/platforms/defs/riscv.py +257 -0
- smallworld/platforms/defs/xtensa.py +96 -0
- smallworld/{platforms.py → platforms/platforms.py} +3 -0
- smallworld/state/cpus/__init__.py +2 -0
- smallworld/state/cpus/aarch64.py +0 -9
- smallworld/state/cpus/amd64.py +6 -28
- smallworld/state/cpus/arm.py +0 -11
- smallworld/state/cpus/cpu.py +0 -11
- smallworld/state/cpus/i386.py +0 -7
- smallworld/state/cpus/loongarch.py +299 -0
- smallworld/state/cpus/mips.py +4 -47
- smallworld/state/cpus/mips64.py +18 -58
- smallworld/state/cpus/powerpc.py +2 -9
- smallworld/state/cpus/riscv.py +1 -11
- smallworld/state/cpus/xtensa.py +0 -5
- smallworld/state/memory/code.py +38 -2
- smallworld/state/memory/elf/__init__.py +5 -1
- smallworld/state/memory/elf/coredump/__init__.py +3 -0
- smallworld/state/memory/elf/coredump/coredump.py +46 -0
- smallworld/state/memory/elf/coredump/prstatus/__init__.py +27 -0
- smallworld/state/memory/elf/coredump/prstatus/aarch64.py +46 -0
- smallworld/state/memory/elf/coredump/prstatus/amd64.py +40 -0
- smallworld/state/memory/elf/coredump/prstatus/arm.py +53 -0
- smallworld/state/memory/elf/coredump/prstatus/i386.py +30 -0
- smallworld/state/memory/elf/coredump/prstatus/mips.py +55 -0
- smallworld/state/memory/elf/coredump/prstatus/mips64.py +57 -0
- smallworld/state/memory/elf/coredump/prstatus/ppc.py +82 -0
- smallworld/state/memory/elf/coredump/prstatus/prstatus.py +129 -0
- smallworld/state/memory/elf/elf.py +211 -57
- smallworld/state/memory/elf/register_state.py +36 -0
- smallworld/state/memory/elf/rela/__init__.py +2 -0
- smallworld/state/memory/elf/rela/aarch64.py +3 -1
- smallworld/state/memory/elf/rela/amd64.py +4 -2
- smallworld/state/memory/elf/rela/arm.py +4 -2
- smallworld/state/memory/elf/rela/i386.py +4 -2
- smallworld/state/memory/elf/rela/loongarch.py +32 -0
- smallworld/state/memory/elf/rela/mips.py +39 -18
- smallworld/state/memory/elf/rela/ppc.py +31 -14
- smallworld/state/memory/elf/structs.py +3 -0
- smallworld/state/memory/heap.py +2 -2
- smallworld/state/memory/memory.py +18 -0
- smallworld/state/memory/pe/__init__.py +3 -0
- smallworld/state/memory/pe/pe.py +361 -0
- smallworld/state/memory/pe/structs.py +60 -0
- smallworld/state/memory/stack/__init__.py +2 -0
- smallworld/state/memory/stack/loongarch.py +26 -0
- smallworld/state/models/__init__.py +29 -2
- smallworld/state/models/aarch64/__init__.py +1 -0
- smallworld/state/models/aarch64/systemv/__init__.py +6 -0
- smallworld/state/models/aarch64/systemv/c99/__init__.py +12 -0
- smallworld/state/models/aarch64/systemv/c99/signal.py +16 -0
- smallworld/state/models/aarch64/systemv/c99/stdio.py +265 -0
- smallworld/state/models/aarch64/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/aarch64/systemv/c99/string.py +139 -0
- smallworld/state/models/aarch64/systemv/c99/time.py +61 -0
- smallworld/state/models/aarch64/systemv/posix/__init__.py +6 -0
- smallworld/state/models/aarch64/systemv/posix/libgen.py +16 -0
- smallworld/state/models/aarch64/systemv/posix/signal.py +157 -0
- smallworld/state/models/aarch64/systemv/systemv.py +80 -0
- smallworld/state/models/amd64/__init__.py +1 -0
- smallworld/state/models/amd64/systemv/__init__.py +6 -0
- smallworld/state/models/amd64/systemv/c99/__init__.py +12 -0
- smallworld/state/models/amd64/systemv/c99/signal.py +16 -0
- smallworld/state/models/amd64/systemv/c99/stdio.py +265 -0
- smallworld/state/models/amd64/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/amd64/systemv/c99/string.py +139 -0
- smallworld/state/models/amd64/systemv/c99/time.py +61 -0
- smallworld/state/models/amd64/systemv/posix/__init__.py +6 -0
- smallworld/state/models/amd64/systemv/posix/libgen.py +16 -0
- smallworld/state/models/amd64/systemv/posix/signal.py +157 -0
- smallworld/state/models/amd64/systemv/systemv.py +78 -0
- smallworld/state/models/armel/__init__.py +1 -0
- smallworld/state/models/armel/systemv/__init__.py +6 -0
- smallworld/state/models/armel/systemv/c99/__init__.py +12 -0
- smallworld/state/models/armel/systemv/c99/signal.py +16 -0
- smallworld/state/models/armel/systemv/c99/stdio.py +265 -0
- smallworld/state/models/armel/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/armel/systemv/c99/string.py +139 -0
- smallworld/state/models/armel/systemv/c99/time.py +61 -0
- smallworld/state/models/armel/systemv/posix/__init__.py +6 -0
- smallworld/state/models/armel/systemv/posix/libgen.py +16 -0
- smallworld/state/models/armel/systemv/posix/signal.py +157 -0
- smallworld/state/models/armel/systemv/systemv.py +82 -0
- smallworld/state/models/armhf/__init__.py +1 -0
- smallworld/state/models/armhf/systemv/__init__.py +6 -0
- smallworld/state/models/armhf/systemv/c99/__init__.py +12 -0
- smallworld/state/models/armhf/systemv/c99/signal.py +16 -0
- smallworld/state/models/armhf/systemv/c99/stdio.py +265 -0
- smallworld/state/models/armhf/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/armhf/systemv/c99/string.py +139 -0
- smallworld/state/models/armhf/systemv/c99/time.py +61 -0
- smallworld/state/models/armhf/systemv/posix/__init__.py +6 -0
- smallworld/state/models/armhf/systemv/posix/libgen.py +16 -0
- smallworld/state/models/armhf/systemv/posix/signal.py +157 -0
- smallworld/state/models/armhf/systemv/systemv.py +77 -0
- smallworld/state/models/c99/__init__.py +12 -0
- smallworld/state/models/c99/fmt_print.py +915 -0
- smallworld/state/models/c99/fmt_scan.py +864 -0
- smallworld/state/models/c99/math.py +362 -0
- smallworld/state/models/c99/signal.py +71 -0
- smallworld/state/models/c99/stdio.py +1305 -0
- smallworld/state/models/c99/stdlib.py +595 -0
- smallworld/state/models/c99/string.py +674 -0
- smallworld/state/models/c99/time.py +340 -0
- smallworld/state/models/c99/utils.py +89 -0
- smallworld/state/models/cstd.py +759 -0
- smallworld/state/models/errno.py +581 -0
- smallworld/state/models/filedesc.py +515 -0
- smallworld/state/models/i386/__init__.py +1 -0
- smallworld/state/models/i386/systemv/__init__.py +6 -0
- smallworld/state/models/i386/systemv/c99/__init__.py +12 -0
- smallworld/state/models/i386/systemv/c99/signal.py +16 -0
- smallworld/state/models/i386/systemv/c99/stdio.py +265 -0
- smallworld/state/models/i386/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/i386/systemv/c99/string.py +139 -0
- smallworld/state/models/i386/systemv/c99/time.py +61 -0
- smallworld/state/models/i386/systemv/posix/__init__.py +6 -0
- smallworld/state/models/i386/systemv/posix/libgen.py +16 -0
- smallworld/state/models/i386/systemv/posix/signal.py +157 -0
- smallworld/state/models/i386/systemv/systemv.py +71 -0
- smallworld/state/models/loongarch64/__init__.py +1 -0
- smallworld/state/models/loongarch64/systemv/__init__.py +6 -0
- smallworld/state/models/loongarch64/systemv/c99/__init__.py +12 -0
- smallworld/state/models/loongarch64/systemv/c99/signal.py +16 -0
- smallworld/state/models/loongarch64/systemv/c99/stdio.py +265 -0
- smallworld/state/models/loongarch64/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/loongarch64/systemv/c99/string.py +139 -0
- smallworld/state/models/loongarch64/systemv/c99/time.py +61 -0
- smallworld/state/models/loongarch64/systemv/posix/__init__.py +6 -0
- smallworld/state/models/loongarch64/systemv/posix/libgen.py +16 -0
- smallworld/state/models/loongarch64/systemv/posix/signal.py +157 -0
- smallworld/state/models/loongarch64/systemv/systemv.py +83 -0
- smallworld/state/models/mips/__init__.py +1 -0
- smallworld/state/models/mips/systemv/__init__.py +6 -0
- smallworld/state/models/mips/systemv/c99/__init__.py +12 -0
- smallworld/state/models/mips/systemv/c99/signal.py +16 -0
- smallworld/state/models/mips/systemv/c99/stdio.py +265 -0
- smallworld/state/models/mips/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/mips/systemv/c99/string.py +139 -0
- smallworld/state/models/mips/systemv/c99/time.py +61 -0
- smallworld/state/models/mips/systemv/posix/__init__.py +6 -0
- smallworld/state/models/mips/systemv/posix/libgen.py +16 -0
- smallworld/state/models/mips/systemv/posix/signal.py +157 -0
- smallworld/state/models/mips/systemv/systemv.py +78 -0
- smallworld/state/models/mips64/__init__.py +1 -0
- smallworld/state/models/mips64/systemv/__init__.py +6 -0
- smallworld/state/models/mips64/systemv/c99/__init__.py +12 -0
- smallworld/state/models/mips64/systemv/c99/signal.py +16 -0
- smallworld/state/models/mips64/systemv/c99/stdio.py +265 -0
- smallworld/state/models/mips64/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/mips64/systemv/c99/string.py +139 -0
- smallworld/state/models/mips64/systemv/c99/time.py +61 -0
- smallworld/state/models/mips64/systemv/posix/__init__.py +6 -0
- smallworld/state/models/mips64/systemv/posix/libgen.py +16 -0
- smallworld/state/models/mips64/systemv/posix/signal.py +157 -0
- smallworld/state/models/mips64/systemv/systemv.py +98 -0
- smallworld/state/models/mips64el/__init__.py +1 -0
- smallworld/state/models/mips64el/systemv/__init__.py +6 -0
- smallworld/state/models/mips64el/systemv/c99/__init__.py +12 -0
- smallworld/state/models/mips64el/systemv/c99/signal.py +16 -0
- smallworld/state/models/mips64el/systemv/c99/stdio.py +265 -0
- smallworld/state/models/mips64el/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/mips64el/systemv/c99/string.py +139 -0
- smallworld/state/models/mips64el/systemv/c99/time.py +61 -0
- smallworld/state/models/mips64el/systemv/posix/__init__.py +6 -0
- smallworld/state/models/mips64el/systemv/posix/libgen.py +16 -0
- smallworld/state/models/mips64el/systemv/posix/signal.py +157 -0
- smallworld/state/models/mips64el/systemv/systemv.py +96 -0
- smallworld/state/models/mipsel/__init__.py +1 -0
- smallworld/state/models/mipsel/systemv/__init__.py +6 -0
- smallworld/state/models/mipsel/systemv/c99/__init__.py +12 -0
- smallworld/state/models/mipsel/systemv/c99/signal.py +16 -0
- smallworld/state/models/mipsel/systemv/c99/stdio.py +265 -0
- smallworld/state/models/mipsel/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/mipsel/systemv/c99/string.py +139 -0
- smallworld/state/models/mipsel/systemv/c99/time.py +61 -0
- smallworld/state/models/mipsel/systemv/posix/__init__.py +6 -0
- smallworld/state/models/mipsel/systemv/posix/libgen.py +16 -0
- smallworld/state/models/mipsel/systemv/posix/signal.py +157 -0
- smallworld/state/models/mipsel/systemv/systemv.py +78 -0
- smallworld/state/models/model.py +27 -2
- smallworld/state/models/posix/__init__.py +6 -0
- smallworld/state/models/posix/libgen.py +123 -0
- smallworld/state/models/posix/signal.py +690 -0
- smallworld/state/models/powerpc/__init__.py +1 -0
- smallworld/state/models/powerpc/systemv/__init__.py +6 -0
- smallworld/state/models/powerpc/systemv/c99/__init__.py +12 -0
- smallworld/state/models/powerpc/systemv/c99/signal.py +16 -0
- smallworld/state/models/powerpc/systemv/c99/stdio.py +265 -0
- smallworld/state/models/powerpc/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/powerpc/systemv/c99/string.py +139 -0
- smallworld/state/models/powerpc/systemv/c99/time.py +61 -0
- smallworld/state/models/powerpc/systemv/posix/__init__.py +6 -0
- smallworld/state/models/powerpc/systemv/posix/libgen.py +16 -0
- smallworld/state/models/powerpc/systemv/posix/signal.py +157 -0
- smallworld/state/models/powerpc/systemv/systemv.py +93 -0
- smallworld/state/models/riscv64/__init__.py +1 -0
- smallworld/state/models/riscv64/systemv/__init__.py +6 -0
- smallworld/state/models/riscv64/systemv/c99/__init__.py +12 -0
- smallworld/state/models/riscv64/systemv/c99/signal.py +16 -0
- smallworld/state/models/riscv64/systemv/c99/stdio.py +265 -0
- smallworld/state/models/riscv64/systemv/c99/stdlib.py +169 -0
- smallworld/state/models/riscv64/systemv/c99/string.py +139 -0
- smallworld/state/models/riscv64/systemv/c99/time.py +61 -0
- smallworld/state/models/riscv64/systemv/posix/__init__.py +6 -0
- smallworld/state/models/riscv64/systemv/posix/libgen.py +16 -0
- smallworld/state/models/riscv64/systemv/posix/signal.py +157 -0
- smallworld/state/models/riscv64/systemv/systemv.py +85 -0
- smallworld/state/state.py +65 -24
- smallworld/state/unstable/elf.py +16 -31
- smallworld/utils.py +6 -1
- {smallworld_re-1.0.3.dist-info → smallworld_re-2.0.0.dist-info}/METADATA +74 -42
- smallworld_re-2.0.0.dist-info/RECORD +374 -0
- {smallworld_re-1.0.3.dist-info → smallworld_re-2.0.0.dist-info}/WHEEL +1 -1
- smallworld/state/models/x86/__init__.py +0 -2
- smallworld/state/models/x86/microsoftcdecl.py +0 -35
- smallworld/state/models/x86/systemv.py +0 -240
- smallworld_re-1.0.3.dist-info/RECORD +0 -166
- /smallworld/state/models/{posix.py → _posix.py} +0 -0
- {smallworld_re-1.0.3.dist-info → smallworld_re-2.0.0.dist-info}/entry_points.txt +0 -0
- {smallworld_re-1.0.3.dist-info → smallworld_re-2.0.0.dist-info}/licenses/LICENSE.txt +0 -0
- {smallworld_re-1.0.3.dist-info → smallworld_re-2.0.0.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,450 @@
|
|
1
|
+
import capstone
|
2
|
+
|
3
|
+
from ..platforms import Architecture, Byteorder
|
4
|
+
from .platformdef import PlatformDef, RegisterAliasDef, RegisterDef
|
5
|
+
|
6
|
+
|
7
|
+
class AArch64(PlatformDef):
|
8
|
+
architecture = Architecture.AARCH64
|
9
|
+
byteorder = Byteorder.LITTLE
|
10
|
+
|
11
|
+
address_size = 8
|
12
|
+
capstone_arch = capstone.CS_ARCH_ARM64
|
13
|
+
capstone_mode = capstone.CS_MODE_ARM
|
14
|
+
|
15
|
+
pc_register = "pc"
|
16
|
+
sp_register = "sp"
|
17
|
+
|
18
|
+
# NOTE: aarch64 has unconditional conditions.
|
19
|
+
# "al" is always true, and "nv" is never true.
|
20
|
+
conditional_branch_mnemonics = {
|
21
|
+
# Conditional branches
|
22
|
+
"b.eq",
|
23
|
+
"b.ne",
|
24
|
+
"b.cs",
|
25
|
+
"b.cc",
|
26
|
+
"b.mi",
|
27
|
+
"b.pl",
|
28
|
+
"b.vs",
|
29
|
+
"b.vc",
|
30
|
+
"b.hi",
|
31
|
+
"b.ls",
|
32
|
+
"b.ge",
|
33
|
+
"b.lt",
|
34
|
+
"b.gt",
|
35
|
+
"b.le",
|
36
|
+
# Consistent (unlikely?) conditional branches
|
37
|
+
"bc.eq",
|
38
|
+
"bc.ne",
|
39
|
+
"bc.cs",
|
40
|
+
"bc.cc",
|
41
|
+
"bc.mi",
|
42
|
+
"bc.pl",
|
43
|
+
"bc.vs",
|
44
|
+
"bc.vc",
|
45
|
+
"bc.hi",
|
46
|
+
"bc.ls",
|
47
|
+
"bc.ge",
|
48
|
+
"bc.lt",
|
49
|
+
"bc.gt",
|
50
|
+
"bc.le",
|
51
|
+
# Compare and conditional branch
|
52
|
+
# TODO: How to handle this?
|
53
|
+
"cb.eq",
|
54
|
+
"cb.ne",
|
55
|
+
"cb.cs",
|
56
|
+
"cb.cc",
|
57
|
+
"cb.mi",
|
58
|
+
"cb.pl",
|
59
|
+
"cb.vs",
|
60
|
+
"cb.vc",
|
61
|
+
"cb.hi",
|
62
|
+
"cb.ls",
|
63
|
+
"cb.ge",
|
64
|
+
"cb.lt",
|
65
|
+
"cb.gt",
|
66
|
+
"cb.le",
|
67
|
+
# Extra mnemonics for cb opcodes
|
68
|
+
"cbge",
|
69
|
+
"cbhs",
|
70
|
+
"cble",
|
71
|
+
"cblo",
|
72
|
+
"cbls",
|
73
|
+
"cblt",
|
74
|
+
"cbnz",
|
75
|
+
"cbz",
|
76
|
+
# Compare bytes and conditional branch
|
77
|
+
"cbb.eq",
|
78
|
+
"cbb.ne",
|
79
|
+
"cbb.cs",
|
80
|
+
"cbb.cc",
|
81
|
+
"cbb.mi",
|
82
|
+
"cbb.pl",
|
83
|
+
"cbb.vs",
|
84
|
+
"cbb.vc",
|
85
|
+
"cbb.hi",
|
86
|
+
"cbb.ls",
|
87
|
+
"cbb.ge",
|
88
|
+
"cbb.lt",
|
89
|
+
"cbb.gt",
|
90
|
+
"cbb.le",
|
91
|
+
# Extra mnemonics for cbb opcodes
|
92
|
+
"cbble",
|
93
|
+
"cbblo",
|
94
|
+
"cbbls",
|
95
|
+
"cbblt",
|
96
|
+
# Compare half-words and conditional branch
|
97
|
+
"cbh.eq",
|
98
|
+
"cbh.ne",
|
99
|
+
"cbh.cs",
|
100
|
+
"cbh.cc",
|
101
|
+
"cbh.mi",
|
102
|
+
"cbh.pl",
|
103
|
+
"cbh.vs",
|
104
|
+
"cbh.vc",
|
105
|
+
"cbh.hi",
|
106
|
+
"cbh.ls",
|
107
|
+
"cbh.ge",
|
108
|
+
"cbh.lt",
|
109
|
+
"cbh.gt",
|
110
|
+
"cbh.le",
|
111
|
+
# Extra mnemonics for cbh opcodes
|
112
|
+
"cbhle",
|
113
|
+
"cbhlo",
|
114
|
+
"cbhls",
|
115
|
+
"cbhlt",
|
116
|
+
}
|
117
|
+
|
118
|
+
# TODO: Should arithmetic operations that impact flags be compares?
|
119
|
+
compare_mnemonics = {
|
120
|
+
# Integer comparison
|
121
|
+
# AArch64 supports positive and negative variants of comparisons
|
122
|
+
"cmn",
|
123
|
+
"cmp",
|
124
|
+
"tst",
|
125
|
+
# Conditional comparison
|
126
|
+
# This performs a comparison if the condition flags pass the desired test,
|
127
|
+
# otherwise it sets the flags to an immediate.
|
128
|
+
# NOTE: This takes a condition type, but it's encoded as an operand.
|
129
|
+
"ccmn",
|
130
|
+
"ccmp",
|
131
|
+
# Compare with tag
|
132
|
+
# Performs 56-bit comparison, likely to support tagged pointers
|
133
|
+
"cmpp",
|
134
|
+
# Vector comparisons
|
135
|
+
"cmeq",
|
136
|
+
"cmge",
|
137
|
+
"cmgt",
|
138
|
+
"cmhi",
|
139
|
+
"cmhs",
|
140
|
+
"cmle",
|
141
|
+
"cmlt",
|
142
|
+
"cmtst",
|
143
|
+
# Floating-point comparisons
|
144
|
+
"fcmeq",
|
145
|
+
"fcmge",
|
146
|
+
"fcmgt",
|
147
|
+
"fcmle",
|
148
|
+
"fcmlt",
|
149
|
+
"fcmp",
|
150
|
+
"fcmpe",
|
151
|
+
# Floating-point conditional comparisons
|
152
|
+
# NOTE: This takes a condition type, but it's encoded as an operand
|
153
|
+
"fccmp",
|
154
|
+
"fccmpe",
|
155
|
+
}
|
156
|
+
|
157
|
+
# Special registers:
|
158
|
+
# x29: frame pointer
|
159
|
+
# x30: link register
|
160
|
+
# x31: stack pointer or zero, depending on instruction
|
161
|
+
general_purpose_registers = [f"x{i}" for i in range(0, 29)]
|
162
|
+
|
163
|
+
registers = {
|
164
|
+
# *** General Purpose Registers ***
|
165
|
+
"x0": RegisterDef(name="x0", size=8),
|
166
|
+
"w0": RegisterAliasDef(name="w0", parent="x0", size=4, offset=0),
|
167
|
+
"x1": RegisterDef(name="x1", size=8),
|
168
|
+
"w1": RegisterAliasDef(name="w1", parent="x1", size=4, offset=0),
|
169
|
+
"x2": RegisterDef(name="x2", size=8),
|
170
|
+
"w2": RegisterAliasDef(name="w2", parent="x2", size=4, offset=0),
|
171
|
+
"x3": RegisterDef(name="x3", size=8),
|
172
|
+
"w3": RegisterAliasDef(name="w3", parent="x3", size=4, offset=0),
|
173
|
+
"x4": RegisterDef(name="x4", size=8),
|
174
|
+
"w4": RegisterAliasDef(name="w4", parent="x4", size=4, offset=0),
|
175
|
+
"x5": RegisterDef(name="x5", size=8),
|
176
|
+
"w5": RegisterAliasDef(name="w5", parent="x5", size=4, offset=0),
|
177
|
+
"x6": RegisterDef(name="x6", size=8),
|
178
|
+
"w6": RegisterAliasDef(name="w6", parent="x6", size=4, offset=0),
|
179
|
+
"x7": RegisterDef(name="x7", size=8),
|
180
|
+
"w7": RegisterAliasDef(name="w7", parent="x7", size=4, offset=0),
|
181
|
+
"x8": RegisterDef(name="x8", size=8),
|
182
|
+
"w8": RegisterAliasDef(name="w8", parent="x8", size=4, offset=0),
|
183
|
+
"x9": RegisterDef(name="x9", size=8),
|
184
|
+
"w9": RegisterAliasDef(name="w9", parent="x9", size=4, offset=0),
|
185
|
+
"x10": RegisterDef(name="x10", size=8),
|
186
|
+
"w10": RegisterAliasDef(name="w10", parent="x10", size=4, offset=0),
|
187
|
+
"x11": RegisterDef(name="x11", size=8),
|
188
|
+
"w11": RegisterAliasDef(name="w11", parent="x10", size=4, offset=0),
|
189
|
+
"x12": RegisterDef(name="x12", size=8),
|
190
|
+
"w12": RegisterAliasDef(name="w12", parent="x10", size=4, offset=0),
|
191
|
+
"x13": RegisterDef(name="x13", size=8),
|
192
|
+
"w13": RegisterAliasDef(name="w13", parent="x13", size=4, offset=0),
|
193
|
+
"x14": RegisterDef(name="x14", size=8),
|
194
|
+
"w14": RegisterAliasDef(name="w14", parent="x14", size=4, offset=0),
|
195
|
+
"x15": RegisterDef(name="x15", size=8),
|
196
|
+
"w15": RegisterAliasDef(name="w15", parent="x15", size=4, offset=0),
|
197
|
+
"x16": RegisterDef(name="x16", size=8),
|
198
|
+
"w16": RegisterAliasDef(name="w16", parent="x16", size=4, offset=0),
|
199
|
+
"x17": RegisterDef(name="x17", size=8),
|
200
|
+
"w17": RegisterAliasDef(name="w17", parent="x17", size=4, offset=0),
|
201
|
+
"x18": RegisterDef(name="x18", size=8),
|
202
|
+
"w18": RegisterAliasDef(name="w18", parent="x18", size=4, offset=0),
|
203
|
+
"x19": RegisterDef(name="x19", size=8),
|
204
|
+
"w19": RegisterAliasDef(name="w19", parent="x19", size=4, offset=0),
|
205
|
+
"x20": RegisterDef(name="x20", size=8),
|
206
|
+
"w20": RegisterAliasDef(name="w20", parent="x20", size=4, offset=0),
|
207
|
+
"x21": RegisterDef(name="x21", size=8),
|
208
|
+
"w21": RegisterAliasDef(name="w21", parent="x20", size=4, offset=0),
|
209
|
+
"x22": RegisterDef(name="x22", size=8),
|
210
|
+
"w22": RegisterAliasDef(name="w22", parent="x20", size=4, offset=0),
|
211
|
+
"x23": RegisterDef(name="x23", size=8),
|
212
|
+
"w23": RegisterAliasDef(name="w23", parent="x23", size=4, offset=0),
|
213
|
+
"x24": RegisterDef(name="x24", size=8),
|
214
|
+
"w24": RegisterAliasDef(name="w24", parent="x24", size=4, offset=0),
|
215
|
+
"x25": RegisterDef(name="x25", size=8),
|
216
|
+
"w25": RegisterAliasDef(name="w25", parent="x25", size=4, offset=0),
|
217
|
+
"x26": RegisterDef(name="x26", size=8),
|
218
|
+
"w26": RegisterAliasDef(name="w26", parent="x26", size=4, offset=0),
|
219
|
+
"x27": RegisterDef(name="x27", size=8),
|
220
|
+
"w27": RegisterAliasDef(name="w27", parent="x27", size=4, offset=0),
|
221
|
+
"x28": RegisterDef(name="x28", size=8),
|
222
|
+
"w28": RegisterAliasDef(name="w28", parent="x28", size=4, offset=0),
|
223
|
+
"x29": RegisterDef(name="x29", size=8),
|
224
|
+
"w29": RegisterAliasDef(name="w29", parent="x29", size=4, offset=0),
|
225
|
+
"x30": RegisterDef(name="x30", size=8),
|
226
|
+
"w30": RegisterAliasDef(name="w30", parent="x30", size=4, offset=0),
|
227
|
+
# *** Program Counter ***
|
228
|
+
"pc": RegisterDef(name="pc", size=8),
|
229
|
+
# *** Stack Pointer ***
|
230
|
+
"sp": RegisterDef(name="sp", size=8),
|
231
|
+
"wsp": RegisterAliasDef(name="wsp", parent="sp", size=4, offset=0),
|
232
|
+
# *** Frame Pointer ***
|
233
|
+
"fp": RegisterAliasDef(name="fp", parent="x29", size=8, offset=0),
|
234
|
+
# *** Link Register ***
|
235
|
+
"lr": RegisterAliasDef(name="lr", parent="x30", size=8, offset=0),
|
236
|
+
# *** Zero Register ***
|
237
|
+
"xzr": RegisterDef(name="xzr", size=8),
|
238
|
+
"wzr": RegisterAliasDef(name="wzr", parent="xzr", size=4, offset=0),
|
239
|
+
# *** System Control Registers ***
|
240
|
+
# NOTE: "_elX" indicates that only exception level X or greater can access this register.
|
241
|
+
# NOTE: This list is far from complete; it only covers what Unicorn supports
|
242
|
+
# Condition Code Register
|
243
|
+
"fpcr": RegisterDef(name="fpcr", size=8),
|
244
|
+
# Floating Point Status Register
|
245
|
+
"fpsr": RegisterDef(name="fpsr", size=8),
|
246
|
+
# Banked stack pointers for exception handlers
|
247
|
+
"sp_el0": RegisterDef(name="sp_el0", size=8),
|
248
|
+
"sp_el1": RegisterDef(name="sp_el1", size=8),
|
249
|
+
"sp_el2": RegisterDef(name="sp_el2", size=8),
|
250
|
+
"sp_el3": RegisterDef(name="sp_el3", size=8),
|
251
|
+
# Banked link registers for exception handlers
|
252
|
+
# NOTE: Unicorn thinks there's an elr_el0; according to docs, it doesn't exist
|
253
|
+
"elr_el1": RegisterDef(name="elr_el1", size=8),
|
254
|
+
"elr_el2": RegisterDef(name="elr_el2", size=8),
|
255
|
+
"elr_el3": RegisterDef(name="elr_el3", size=8),
|
256
|
+
# Banked exception syndrome registers for exception handlers
|
257
|
+
# NOTE: Unicorn thinks there's a far_el0; according to docs, it doesn't exist
|
258
|
+
"far_el1": RegisterDef(name="far_el1", size=8),
|
259
|
+
"far_el2": RegisterDef(name="far_el2", size=8),
|
260
|
+
"far_el3": RegisterDef(name="far_el3", size=8),
|
261
|
+
# Banked vector base address registers for exception handlers
|
262
|
+
# NOTE: vbar_el0 and vbar_el1 are aliases for each other.
|
263
|
+
# Since vbar_el0 doesn't exist in angr, vbar_el1 has to be the "real" copy.
|
264
|
+
"vbar_el1": RegisterDef(name="vbar_el1", size=8),
|
265
|
+
"vbar_el0": RegisterAliasDef(
|
266
|
+
name="vbar_el0", parent="vbar_el1", size=8, offset=0
|
267
|
+
),
|
268
|
+
"vbar_el2": RegisterDef(name="vbar_el2", size=8),
|
269
|
+
"vbar_el3": RegisterDef(name="vbar_el3", size=8),
|
270
|
+
# Coprocessor access control register
|
271
|
+
"cpacr_el1": RegisterDef(name="cpacr_el1", size=8),
|
272
|
+
# Memory Attribute Indirection Register
|
273
|
+
"mair_el1": RegisterDef(name="mair_el1", size=8),
|
274
|
+
# Physical Address Register
|
275
|
+
"par_el1": RegisterDef(name="par_el1", size=8),
|
276
|
+
# Translation Table Zero Base Register
|
277
|
+
"ttbr0_el1": RegisterDef(name="ttbr0_el1", size=8),
|
278
|
+
# Translation Table One Base Register
|
279
|
+
"ttbr1_el1": RegisterDef(name="ttbr1_el1", size=8),
|
280
|
+
# Thread ID Register
|
281
|
+
# NOTE: According to docs, there should be an el2 and el3 copy, too.
|
282
|
+
"tpidr_el0": RegisterDef(name="tpidr_el0", size=8),
|
283
|
+
"tpidr_el1": RegisterDef(name="tpidr_el1", size=8),
|
284
|
+
# Userspace-visible Thread ID register
|
285
|
+
"tpidrro_el0": RegisterDef(name="tpidrro_el0", size=8),
|
286
|
+
# *** Floating Point Registers ***
|
287
|
+
# Scalar Floating Point Registers
|
288
|
+
"q0": RegisterDef(name="q0", size=16),
|
289
|
+
"d0": RegisterAliasDef(name="d0", parent="q0", size=8, offset=0),
|
290
|
+
"s0": RegisterAliasDef(name="s0", parent="q0", size=4, offset=0),
|
291
|
+
"h0": RegisterAliasDef(name="h0", parent="q0", size=2, offset=0),
|
292
|
+
"b0": RegisterAliasDef(name="b0", parent="q0", size=1, offset=0),
|
293
|
+
"q1": RegisterDef(name="q1", size=16),
|
294
|
+
"d1": RegisterAliasDef(name="d1", parent="q1", size=8, offset=0),
|
295
|
+
"s1": RegisterAliasDef(name="s1", parent="q1", size=4, offset=0),
|
296
|
+
"h1": RegisterAliasDef(name="h1", parent="q1", size=2, offset=0),
|
297
|
+
"b1": RegisterAliasDef(name="b1", parent="q1", size=1, offset=0),
|
298
|
+
"q2": RegisterDef(name="q2", size=16),
|
299
|
+
"d2": RegisterAliasDef(name="d2", parent="q2", size=8, offset=0),
|
300
|
+
"s2": RegisterAliasDef(name="s2", parent="q2", size=4, offset=0),
|
301
|
+
"h2": RegisterAliasDef(name="h2", parent="q2", size=2, offset=0),
|
302
|
+
"b2": RegisterAliasDef(name="b2", parent="q2", size=1, offset=0),
|
303
|
+
"q3": RegisterDef(name="q3", size=16),
|
304
|
+
"d3": RegisterAliasDef(name="d3", parent="q3", size=8, offset=0),
|
305
|
+
"s3": RegisterAliasDef(name="s3", parent="q3", size=4, offset=0),
|
306
|
+
"h3": RegisterAliasDef(name="h3", parent="q3", size=2, offset=0),
|
307
|
+
"b3": RegisterAliasDef(name="b3", parent="q3", size=1, offset=0),
|
308
|
+
"q4": RegisterDef(name="q4", size=16),
|
309
|
+
"d4": RegisterAliasDef(name="d4", parent="q4", size=8, offset=0),
|
310
|
+
"s4": RegisterAliasDef(name="s4", parent="q4", size=4, offset=0),
|
311
|
+
"h4": RegisterAliasDef(name="h4", parent="q4", size=2, offset=0),
|
312
|
+
"b4": RegisterAliasDef(name="b4", parent="q4", size=1, offset=0),
|
313
|
+
"q5": RegisterDef(name="q5", size=16),
|
314
|
+
"d5": RegisterAliasDef(name="d5", parent="q5", size=8, offset=0),
|
315
|
+
"s5": RegisterAliasDef(name="s5", parent="q5", size=4, offset=0),
|
316
|
+
"h5": RegisterAliasDef(name="h5", parent="q5", size=2, offset=0),
|
317
|
+
"b5": RegisterAliasDef(name="b5", parent="q5", size=1, offset=0),
|
318
|
+
"q6": RegisterDef(name="q6", size=16),
|
319
|
+
"d6": RegisterAliasDef(name="d6", parent="q6", size=8, offset=0),
|
320
|
+
"s6": RegisterAliasDef(name="s6", parent="q6", size=4, offset=0),
|
321
|
+
"h6": RegisterAliasDef(name="h6", parent="q6", size=2, offset=0),
|
322
|
+
"b6": RegisterAliasDef(name="b6", parent="q6", size=1, offset=0),
|
323
|
+
"q7": RegisterDef(name="q7", size=16),
|
324
|
+
"d7": RegisterAliasDef(name="d7", parent="q7", size=8, offset=0),
|
325
|
+
"s7": RegisterAliasDef(name="s7", parent="q7", size=4, offset=0),
|
326
|
+
"h7": RegisterAliasDef(name="h7", parent="q7", size=2, offset=0),
|
327
|
+
"b7": RegisterAliasDef(name="b7", parent="q7", size=1, offset=0),
|
328
|
+
"q8": RegisterDef(name="q8", size=16),
|
329
|
+
"d8": RegisterAliasDef(name="d8", parent="q8", size=8, offset=0),
|
330
|
+
"s8": RegisterAliasDef(name="s8", parent="q8", size=4, offset=0),
|
331
|
+
"h8": RegisterAliasDef(name="h8", parent="q8", size=2, offset=0),
|
332
|
+
"b8": RegisterAliasDef(name="b8", parent="q8", size=1, offset=0),
|
333
|
+
"q9": RegisterDef(name="q9", size=16),
|
334
|
+
"d9": RegisterAliasDef(name="d9", parent="q9", size=8, offset=0),
|
335
|
+
"s9": RegisterAliasDef(name="s9", parent="q9", size=4, offset=0),
|
336
|
+
"h9": RegisterAliasDef(name="h9", parent="q9", size=2, offset=0),
|
337
|
+
"b9": RegisterAliasDef(name="b9", parent="q9", size=1, offset=0),
|
338
|
+
"q10": RegisterDef(name="q10", size=16),
|
339
|
+
"d10": RegisterAliasDef(name="d10", parent="q10", size=8, offset=0),
|
340
|
+
"s10": RegisterAliasDef(name="s10", parent="q10", size=4, offset=0),
|
341
|
+
"h10": RegisterAliasDef(name="h10", parent="q10", size=2, offset=0),
|
342
|
+
"b10": RegisterAliasDef(name="b10", parent="q10", size=1, offset=0),
|
343
|
+
"q11": RegisterDef(name="q11", size=16),
|
344
|
+
"d11": RegisterAliasDef(name="d11", parent="q11", size=8, offset=0),
|
345
|
+
"s11": RegisterAliasDef(name="s11", parent="q11", size=4, offset=0),
|
346
|
+
"h11": RegisterAliasDef(name="h11", parent="q11", size=2, offset=0),
|
347
|
+
"b11": RegisterAliasDef(name="b11", parent="q11", size=1, offset=0),
|
348
|
+
"q12": RegisterDef(name="q12", size=16),
|
349
|
+
"d12": RegisterAliasDef(name="d12", parent="q12", size=8, offset=0),
|
350
|
+
"s12": RegisterAliasDef(name="s12", parent="q12", size=4, offset=0),
|
351
|
+
"h12": RegisterAliasDef(name="h12", parent="q12", size=2, offset=0),
|
352
|
+
"b12": RegisterAliasDef(name="b12", parent="q12", size=1, offset=0),
|
353
|
+
"q13": RegisterDef(name="q13", size=16),
|
354
|
+
"d13": RegisterAliasDef(name="d13", parent="q13", size=8, offset=0),
|
355
|
+
"s13": RegisterAliasDef(name="s13", parent="q13", size=4, offset=0),
|
356
|
+
"h13": RegisterAliasDef(name="h13", parent="q13", size=2, offset=0),
|
357
|
+
"b13": RegisterAliasDef(name="b13", parent="q13", size=1, offset=0),
|
358
|
+
"q14": RegisterDef(name="q14", size=16),
|
359
|
+
"d14": RegisterAliasDef(name="d14", parent="q14", size=8, offset=0),
|
360
|
+
"s14": RegisterAliasDef(name="s14", parent="q14", size=4, offset=0),
|
361
|
+
"h14": RegisterAliasDef(name="h14", parent="q14", size=2, offset=0),
|
362
|
+
"b14": RegisterAliasDef(name="b14", parent="q14", size=1, offset=0),
|
363
|
+
"q15": RegisterDef(name="q15", size=16),
|
364
|
+
"d15": RegisterAliasDef(name="d15", parent="q15", size=8, offset=0),
|
365
|
+
"s15": RegisterAliasDef(name="s15", parent="q15", size=4, offset=0),
|
366
|
+
"h15": RegisterAliasDef(name="h15", parent="q15", size=2, offset=0),
|
367
|
+
"b15": RegisterAliasDef(name="b15", parent="q15", size=1, offset=0),
|
368
|
+
"q16": RegisterDef(name="q16", size=16),
|
369
|
+
"d16": RegisterAliasDef(name="d16", parent="q16", size=8, offset=0),
|
370
|
+
"s16": RegisterAliasDef(name="s16", parent="q16", size=4, offset=0),
|
371
|
+
"h16": RegisterAliasDef(name="h16", parent="q16", size=2, offset=0),
|
372
|
+
"b16": RegisterAliasDef(name="b16", parent="q16", size=1, offset=0),
|
373
|
+
"q17": RegisterDef(name="q17", size=16),
|
374
|
+
"d17": RegisterAliasDef(name="d17", parent="q17", size=8, offset=0),
|
375
|
+
"s17": RegisterAliasDef(name="s17", parent="q17", size=4, offset=0),
|
376
|
+
"h17": RegisterAliasDef(name="h17", parent="q17", size=2, offset=0),
|
377
|
+
"b17": RegisterAliasDef(name="b17", parent="q17", size=1, offset=0),
|
378
|
+
"q18": RegisterDef(name="q18", size=16),
|
379
|
+
"d18": RegisterAliasDef(name="d18", parent="q18", size=8, offset=0),
|
380
|
+
"s18": RegisterAliasDef(name="s18", parent="q18", size=4, offset=0),
|
381
|
+
"h18": RegisterAliasDef(name="h18", parent="q18", size=2, offset=0),
|
382
|
+
"b18": RegisterAliasDef(name="b18", parent="q18", size=1, offset=0),
|
383
|
+
"q19": RegisterDef(name="q19", size=16),
|
384
|
+
"d19": RegisterAliasDef(name="d19", parent="q19", size=8, offset=0),
|
385
|
+
"s19": RegisterAliasDef(name="s19", parent="q19", size=4, offset=0),
|
386
|
+
"h19": RegisterAliasDef(name="h19", parent="q19", size=2, offset=0),
|
387
|
+
"b19": RegisterAliasDef(name="b19", parent="q19", size=1, offset=0),
|
388
|
+
"q20": RegisterDef(name="q20", size=16),
|
389
|
+
"d20": RegisterAliasDef(name="d20", parent="q20", size=8, offset=0),
|
390
|
+
"s20": RegisterAliasDef(name="s20", parent="q20", size=4, offset=0),
|
391
|
+
"h20": RegisterAliasDef(name="h20", parent="q20", size=2, offset=0),
|
392
|
+
"b20": RegisterAliasDef(name="b20", parent="q20", size=1, offset=0),
|
393
|
+
"q21": RegisterDef(name="q21", size=16),
|
394
|
+
"d21": RegisterAliasDef(name="d21", parent="q21", size=8, offset=0),
|
395
|
+
"s21": RegisterAliasDef(name="s21", parent="q21", size=4, offset=0),
|
396
|
+
"h21": RegisterAliasDef(name="h21", parent="q21", size=2, offset=0),
|
397
|
+
"b21": RegisterAliasDef(name="b21", parent="q21", size=1, offset=0),
|
398
|
+
"q22": RegisterDef(name="q22", size=16),
|
399
|
+
"d22": RegisterAliasDef(name="d22", parent="q22", size=8, offset=0),
|
400
|
+
"s22": RegisterAliasDef(name="s22", parent="q22", size=4, offset=0),
|
401
|
+
"h22": RegisterAliasDef(name="h22", parent="q22", size=2, offset=0),
|
402
|
+
"b22": RegisterAliasDef(name="b22", parent="q22", size=1, offset=0),
|
403
|
+
"q23": RegisterDef(name="q23", size=16),
|
404
|
+
"d23": RegisterAliasDef(name="d23", parent="q23", size=8, offset=0),
|
405
|
+
"s23": RegisterAliasDef(name="s23", parent="q23", size=4, offset=0),
|
406
|
+
"h23": RegisterAliasDef(name="h23", parent="q23", size=2, offset=0),
|
407
|
+
"b23": RegisterAliasDef(name="b23", parent="q23", size=1, offset=0),
|
408
|
+
"q24": RegisterDef(name="q24", size=16),
|
409
|
+
"d24": RegisterAliasDef(name="d24", parent="q24", size=8, offset=0),
|
410
|
+
"s24": RegisterAliasDef(name="s24", parent="q24", size=4, offset=0),
|
411
|
+
"h24": RegisterAliasDef(name="h24", parent="q24", size=2, offset=0),
|
412
|
+
"b24": RegisterAliasDef(name="b24", parent="q24", size=1, offset=0),
|
413
|
+
"q25": RegisterDef(name="q25", size=16),
|
414
|
+
"d25": RegisterAliasDef(name="d25", parent="q25", size=8, offset=0),
|
415
|
+
"s25": RegisterAliasDef(name="s25", parent="q25", size=4, offset=0),
|
416
|
+
"h25": RegisterAliasDef(name="h25", parent="q25", size=2, offset=0),
|
417
|
+
"b25": RegisterAliasDef(name="b25", parent="q25", size=1, offset=0),
|
418
|
+
"q26": RegisterDef(name="q26", size=16),
|
419
|
+
"d26": RegisterAliasDef(name="d26", parent="q26", size=8, offset=0),
|
420
|
+
"s26": RegisterAliasDef(name="s26", parent="q26", size=4, offset=0),
|
421
|
+
"h26": RegisterAliasDef(name="h26", parent="q26", size=2, offset=0),
|
422
|
+
"b26": RegisterAliasDef(name="b26", parent="q26", size=1, offset=0),
|
423
|
+
"q27": RegisterDef(name="q27", size=16),
|
424
|
+
"d27": RegisterAliasDef(name="d27", parent="q27", size=8, offset=0),
|
425
|
+
"s27": RegisterAliasDef(name="s27", parent="q27", size=4, offset=0),
|
426
|
+
"h27": RegisterAliasDef(name="h27", parent="q27", size=2, offset=0),
|
427
|
+
"b27": RegisterAliasDef(name="b27", parent="q27", size=1, offset=0),
|
428
|
+
"q28": RegisterDef(name="q28", size=16),
|
429
|
+
"d28": RegisterAliasDef(name="d28", parent="q28", size=8, offset=0),
|
430
|
+
"s28": RegisterAliasDef(name="s28", parent="q28", size=4, offset=0),
|
431
|
+
"h28": RegisterAliasDef(name="h28", parent="q28", size=2, offset=0),
|
432
|
+
"b28": RegisterAliasDef(name="b28", parent="q28", size=1, offset=0),
|
433
|
+
"q29": RegisterDef(name="q29", size=16),
|
434
|
+
"d29": RegisterAliasDef(name="d29", parent="q29", size=8, offset=0),
|
435
|
+
"s29": RegisterAliasDef(name="s29", parent="q29", size=4, offset=0),
|
436
|
+
"h29": RegisterAliasDef(name="h29", parent="q29", size=2, offset=0),
|
437
|
+
"b29": RegisterAliasDef(name="b29", parent="q29", size=1, offset=0),
|
438
|
+
"q30": RegisterDef(name="q30", size=16),
|
439
|
+
"d30": RegisterAliasDef(name="d30", parent="q30", size=8, offset=0),
|
440
|
+
"s30": RegisterAliasDef(name="s30", parent="q30", size=4, offset=0),
|
441
|
+
"h30": RegisterAliasDef(name="h30", parent="q30", size=2, offset=0),
|
442
|
+
"b30": RegisterAliasDef(name="b30", parent="q30", size=1, offset=0),
|
443
|
+
"q31": RegisterDef(name="q31", size=16),
|
444
|
+
"d31": RegisterAliasDef(name="d31", parent="q31", size=8, offset=0),
|
445
|
+
"s31": RegisterAliasDef(name="s31", parent="q31", size=4, offset=0),
|
446
|
+
"h31": RegisterAliasDef(name="h31", parent="q31", size=2, offset=0),
|
447
|
+
"b31": RegisterAliasDef(name="b31", parent="q31", size=1, offset=0),
|
448
|
+
# Vector registers
|
449
|
+
# TODO: Figure out how to model these
|
450
|
+
}
|