mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2026-05-26 15:14:20 +08:00
Merge remote-tracking branch 'origin/GP-2719_Dan_watchUpdates' into Ghidra_10.2
This commit is contained in:
+23
-1
@@ -883,11 +883,29 @@ public class DebuggerWatchesProvider extends ComponentProviderAdapter
|
||||
reevaluate();
|
||||
}
|
||||
|
||||
protected void clearCachedState() {
|
||||
if (asyncWatchExecutor != null) {
|
||||
asyncWatchExecutor.getState().clear();
|
||||
}
|
||||
if (prevValueExecutor != null) {
|
||||
prevValueExecutor.getState().clear();
|
||||
}
|
||||
}
|
||||
|
||||
public synchronized void doCheckDepsAndReevaluate() {
|
||||
asyncWatchExecutor.getState().clear();
|
||||
if (asyncWatchExecutor == null) {
|
||||
return;
|
||||
}
|
||||
List<WatchRow> toReevaluate = new ArrayList<>();
|
||||
for (WatchRow row : watchTableModel.getModelData()) {
|
||||
AddressSetView reads = row.getReads();
|
||||
if (reads == null || reads.intersects(changed)) {
|
||||
toReevaluate.add(row);
|
||||
}
|
||||
}
|
||||
if (!toReevaluate.isEmpty()) {
|
||||
clearCachedState();
|
||||
for (WatchRow row : toReevaluate) {
|
||||
row.reevaluate();
|
||||
}
|
||||
}
|
||||
@@ -895,6 +913,10 @@ public class DebuggerWatchesProvider extends ComponentProviderAdapter
|
||||
}
|
||||
|
||||
public void reevaluate() {
|
||||
if (asyncWatchExecutor == null) {
|
||||
return;
|
||||
}
|
||||
clearCachedState();
|
||||
for (WatchRow row : watchTableModel.getModelData()) {
|
||||
row.reevaluate();
|
||||
}
|
||||
|
||||
@@ -72,7 +72,13 @@ public enum DebuggerPcodeUtils {
|
||||
}
|
||||
PcodeExecutorState<byte[]> local = new RWTargetRegistersPcodeExecutorState(
|
||||
access.getDataForLocalState(coordinates.getThread(), coordinates.getFrame()), Mode.RW);
|
||||
return new ThreadPcodeExecutorState<>(shared, local);
|
||||
return new ThreadPcodeExecutorState<>(shared, local) {
|
||||
@Override
|
||||
public void clear() {
|
||||
shared.clear();
|
||||
local.clear();
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user