aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSomebody Whoisbored <13044396+shadowninja108@users.noreply.github.com>2023-11-05 04:32:17 -0700
committerGitHub <noreply@github.com>2023-11-05 12:32:17 +0100
commit617c5700ca520d80fd25fc0fc9f2389394a46150 (patch)
tree41d2052a48a8ffaa147e32b20ffe869899818cf3 /src
parent7b62f7475eae8cfef82f7a60d45aaef55c1efde7 (diff)
Better handle instruction aborts when hitting unmapped memory (#5869)1.1.1070
* Adjust ARMeilleure to better handle instruction aborts when hitting unmapped memory * Update src/ARMeilleure/Decoders/Decoder.cs Co-authored-by: gdkchan <gab.dark.100@gmail.com> --------- Co-authored-by: gdkchan <gab.dark.100@gmail.com>
Diffstat (limited to 'src')
-rw-r--r--src/ARMeilleure/Decoders/Decoder.cs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ARMeilleure/Decoders/Decoder.cs b/src/ARMeilleure/Decoders/Decoder.cs
index 6d07827a..66d28692 100644
--- a/src/ARMeilleure/Decoders/Decoder.cs
+++ b/src/ARMeilleure/Decoders/Decoder.cs
@@ -38,7 +38,9 @@ namespace ARMeilleure.Decoders
{
block = new Block(blkAddress);
- if ((dMode != DecoderMode.MultipleBlocks && visited.Count >= 1) || opsCount > instructionLimit || !memory.IsMapped(blkAddress))
+ if ((dMode != DecoderMode.MultipleBlocks && visited.Count >= 1) ||
+ opsCount > instructionLimit ||
+ (visited.Count > 0 && !memory.IsMapped(blkAddress)))
{
block.Exit = true;
block.EndAddress = blkAddress;