From 4bc44fc943c8ec3ba35b629d16fe459bea806961 Mon Sep 17 00:00:00 2001 From: ghintern Date: Tue, 15 Jul 2025 14:30:29 +0000 Subject: [PATCH] GP-5829: respect emulator quantize flag for addressing --- .../AbstractLongOffsetPcodeExecutorStatePiece.java | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AbstractLongOffsetPcodeExecutorStatePiece.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AbstractLongOffsetPcodeExecutorStatePiece.java index 6a76f9f7be..2cc8c5007d 100644 --- a/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AbstractLongOffsetPcodeExecutorStatePiece.java +++ b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AbstractLongOffsetPcodeExecutorStatePiece.java @@ -4,9 +4,9 @@ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. @@ -296,7 +296,9 @@ public abstract class AbstractLongOffsetPcodeExecutorStatePiece return; } S s = getForSpace(space, true); - offset = quantizeOffset(space, offset); + if (quantize) { + offset = quantizeOffset(space, offset); + } setInSpace(s, offset, size, val); } @@ -320,7 +322,9 @@ public abstract class AbstractLongOffsetPcodeExecutorStatePiece if (s == null) { return getFromNullSpace(size, reason); } - offset = quantizeOffset(space, offset); + if (quantize) { + offset = quantizeOffset(space, offset); + } return getFromSpace(s, offset, size, reason); }