From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22302 invoked by alias); 14 May 2008 14:45:07 -0000 Received: (qmail 22276 invoked by uid 9514); 14 May 2008 14:45:07 -0000 Date: Wed, 14 May 2008 14:45:00 -0000 Message-ID: <20080514144507.22261.qmail@sourceware.org> From: pmuldoon@sourceware.org To: frysk-cvs@sourceware.org Subject: [SCM] master: On unsupported arch, do not check watchpoints in handleTrapped. X-Git-Refname: refs/heads/master X-Git-Reftype: branch X-Git-Oldrev: dd462ac1a619d28bd4410625b5c30f01d1ef4546 X-Git-Newrev: 9da8189a51b382e4d3e46fbf770808d8592e357e Mailing-List: contact frysk-cvs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: frysk-cvs-owner@sourceware.org Reply-To: frysk@sourceware.org X-SW-Source: 2008-q2/txt/msg00237.txt.bz2 The branch, master has been updated via 9da8189a51b382e4d3e46fbf770808d8592e357e (commit) from dd462ac1a619d28bd4410625b5c30f01d1ef4546 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email. - Log ----------------------------------------------------------------- commit 9da8189a51b382e4d3e46fbf770808d8592e357e Author: Phil Muldoon Date: Wed May 14 15:43:48 2008 +0100 On unsupported arch, do not check watchpoints in handleTrapped. 2008-05-14 Phil Muldoon * WatchpointFunctionFactory.java (getWatchpointFunctions): Return null on unknown arch, do not pass along exception. 2008-05-14 Phil Muldoon * LinuxPtraceTaskState.java (Running.checkWatchpoint): Check watchpoint factory does not return null. ----------------------------------------------------------------------- Summary of changes: frysk-core/frysk/isa/watchpoints/ChangeLog | 5 +++++ .../isa/watchpoints/WatchpointFunctionFactory.java | 9 ++++++++- frysk-core/frysk/proc/live/ChangeLog | 5 +++++ .../frysk/proc/live/LinuxPtraceTaskState.java | 4 ++++ 4 files changed, 22 insertions(+), 1 deletions(-) First 500 lines of diff: diff --git a/frysk-core/frysk/isa/watchpoints/ChangeLog b/frysk-core/frysk/isa/watchpoints/ChangeLog index 8c86788..d530ec2 100644 --- a/frysk-core/frysk/isa/watchpoints/ChangeLog +++ b/frysk-core/frysk/isa/watchpoints/ChangeLog @@ -1,3 +1,8 @@ +2008-05-14 Phil Muldoon + + * WatchpointFunctionFactory.java (getWatchpointFunctions): Return null + on unknown arch, do not pass along exception. + 2008-05-13 Phil Muldoon * IA32WatchpointFunctions.java (setWatchpoint): Add alignment check. diff --git a/frysk-core/frysk/isa/watchpoints/WatchpointFunctionFactory.java b/frysk-core/frysk/isa/watchpoints/WatchpointFunctionFactory.java index da434ce..fe8b81b 100644 --- a/frysk-core/frysk/isa/watchpoints/WatchpointFunctionFactory.java +++ b/frysk-core/frysk/isa/watchpoints/WatchpointFunctionFactory.java @@ -53,6 +53,13 @@ public class WatchpointFunctionFactory { ; public static WatchpointFunctions getWatchpointFunctions(ISA isa) { - return (WatchpointFunctions) watchpointTables.get(isa); + WatchpointFunctions function; + try { + function = (WatchpointFunctions) watchpointTables.get(isa); + } catch (RuntimeException e) { + return null; + } + + return function; } } diff --git a/frysk-core/frysk/proc/live/ChangeLog b/frysk-core/frysk/proc/live/ChangeLog index fe2cff5..5c4a96f 100644 --- a/frysk-core/frysk/proc/live/ChangeLog +++ b/frysk-core/frysk/proc/live/ChangeLog @@ -1,3 +1,8 @@ +2008-05-14 Phil Muldoon + + * LinuxPtraceTaskState.java (Running.checkWatchpoint): Check watchpoint + factory does not return null. + 2008-05-12 Phil Muldoon * LinuxPtraceProc.java (requestAddWatchObserver): Call addFailed diff --git a/frysk-core/frysk/proc/live/LinuxPtraceTaskState.java b/frysk-core/frysk/proc/live/LinuxPtraceTaskState.java index 0556c3c..d8c61a3 100644 --- a/frysk-core/frysk/proc/live/LinuxPtraceTaskState.java +++ b/frysk-core/frysk/proc/live/LinuxPtraceTaskState.java @@ -932,6 +932,10 @@ abstract class LinuxPtraceTaskState extends State { // First test if this is a watchpoint event. WatchpointFunctions watchpointFunction = WatchpointFunctionFactory. getWatchpointFunctions(task.getISA()); + + if (watchpointFunction == null) { + return blockers; + } for (int i=0; i