public inbox for frysk-cvs@sourceware.org
help / color / mirror / Atom feed
From: tthomas@sourceware.org
To: frysk-cvs@sourceware.org
Subject: [SCM]  master: Add SteppingEngine.blockedByActionPoint.
Date: Thu, 17 Apr 2008 18:55:00 -0000	[thread overview]
Message-ID: <20080417185545.26828.qmail@sourceware.org> (raw)

The branch, master has been updated
       via  3b312031cd9b151a21d5d0ad3d7a35cd4a1fd4d3 (commit)
      from  35624ff9b23a0d4113a5f41f3840d600aacda7df (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit 3b312031cd9b151a21d5d0ad3d7a35cd4a1fd4d3
Author: Teresa Thomas <tthomas@redhat.com>
Date:   Thu Apr 17 14:49:58 2008 -0400

    Add SteppingEngine.blockedByActionPoint.
    
    frysk-core/frysk/stepping/ChangeLog:
    2008-04-17  Teresa Thomas  <tthomas@redhat.com>
    
    	* SteppingEngine.java (blockedByActionPoint): New.
    
    frysk-core/frysk/hpd/ChangeLog:
    2008-04-17  Teresa Thomas  <tthomas@redhat.com>
    
    	* WatchCommand.java (WatchpointObserver.updateHit):
    	  Use SteppingEngine.blockedByActionPoint

-----------------------------------------------------------------------

Summary of changes:
 frysk-core/frysk/hpd/ChangeLog                |    7 +++++-
 frysk-core/frysk/hpd/WatchCommand.java        |    8 ++----
 frysk-core/frysk/stepping/ChangeLog           |    6 ++++-
 frysk-core/frysk/stepping/SteppingEngine.java |   27 +++++++++++++------------
 4 files changed, 28 insertions(+), 20 deletions(-)

First 500 lines of diff:
diff --git a/frysk-core/frysk/hpd/ChangeLog b/frysk-core/frysk/hpd/ChangeLog
index e468416..029315c 100644
--- a/frysk-core/frysk/hpd/ChangeLog
+++ b/frysk-core/frysk/hpd/ChangeLog
@@ -1,5 +1,10 @@
-2008-04-17  Andrew Cagney  <cagney@redhat.com>
+2008-04-17  Teresa Thomas  <tthomas@redhat.com>
 
+	* WatchCommand.java (WatchpointObserver.updateHit): 
+	  Use SteppingEngine.blockedByActionPoint
+	  
+2008-04-17  Andrew Cagney  <cagney@redhat.com>
+	  
 	* TestBreakpoints.java: Use frysk.config.Prefix.
 	* TestWatchCommand.java: Ditto.
 	* TestSysRoot.java: Ditto.
diff --git a/frysk-core/frysk/hpd/WatchCommand.java b/frysk-core/frysk/hpd/WatchCommand.java
index 55b98d9..5a8170f 100644
--- a/frysk-core/frysk/hpd/WatchCommand.java
+++ b/frysk-core/frysk/hpd/WatchCommand.java
@@ -134,11 +134,9 @@ class WatchCommand extends ParameterizedCommand {
 	    cli.outWriter.println(); 
 	    // Remember the previous value
 	    oldValue = newValue.toPrint();
-	  	    
-	    cli.getSteppingEngine().requestAddSteppingObserver(task);
-	    // Add the watch observer to the task's blockers list
-	    cli.getSteppingEngine().addBlocker(task, this);
-	    cli.getSteppingEngine().setTaskStopped(task);
+
+	    cli.getSteppingEngine().blockedByActionPoint(task, this);
+	    task.requestUnblock(this);
 	    return Action.BLOCK;
 	}
 
diff --git a/frysk-core/frysk/stepping/ChangeLog b/frysk-core/frysk/stepping/ChangeLog
index 6012bc6..d3dd5b6 100644
--- a/frysk-core/frysk/stepping/ChangeLog
+++ b/frysk-core/frysk/stepping/ChangeLog
@@ -1,5 +1,9 @@
-2008-04-16  Andrew Cagney  <cagney@redhat.com>
+2008-04-17  Teresa Thomas  <tthomas@redhat.com>
+
+	* SteppingEngine.java (blockedByActionPoint): New.
 
+2008-04-16  Andrew Cagney  <cagney@redhat.com>
+	
 	* TestStepping.java: Use frysk.config.Prefix.
 	* TestSteppingEngine.java: Ditto.
 
diff --git a/frysk-core/frysk/stepping/SteppingEngine.java b/frysk-core/frysk/stepping/SteppingEngine.java
index 8902d4e..c380dd3 100644
--- a/frysk-core/frysk/stepping/SteppingEngine.java
+++ b/frysk-core/frysk/stepping/SteppingEngine.java
@@ -981,13 +981,25 @@ public class SteppingEngine {
     }
     
     /**
-     * Set the current state of the task as stopped.  
+     * Sets the stepping engine on being hit by an action point.  
+     * 
+     * to - Observer that causes task to block.
      */    
-    public void setTaskStopped(Task task) {
+    public void blockedByActionPoint(Task task, TaskObserver to) {
 
+	 // Requests the addition of the stepping observer to task if 
+	 // not inserted already.
+	if (!(task.isInstructionObserverAdded(this.steppingObserver))) {
+	    task.requestAddInstructionObserver(this.steppingObserver);
+	}
+	
+	// Add the observer to the task's blockers list
+	addBlocker(task, to);
+		
 	TaskStepEngine tse = null;
 	tse = (TaskStepEngine) this.taskStateMap.get(task);	
 	if (!tse.isStopped()) {
+	    // Set the state of task as stopped
 	    tse.setState(new StoppedState(task));	
 	    // Remove the task from the running tasks list      
 	    this.runningTasks.remove(task);
@@ -995,17 +1007,6 @@ public class SteppingEngine {
     }
     
     /**
-     * Requests the addition of the stepping observer to task if 
-     * not inserted already.
-     */
-    public void requestAddSteppingObserver(Task task) {
-
-	if (!(task.isInstructionObserverAdded(this.steppingObserver))) {
-	    task.requestAddInstructionObserver(this.steppingObserver);
-	}
-    }
-    
-    /**
      * Adds the given Observer to this.steppingObserver's Observer list.
      * 
      * @param o The Observer to be added.


hooks/post-receive
--
frysk system monitor/debugger


                 reply	other threads:[~2008-04-17 18:55 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080417185545.26828.qmail@sourceware.org \
    --to=tthomas@sourceware.org \
    --cc=frysk-cvs@sourceware.org \
    --cc=frysk@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).