changeset 1477:db61663b8232

2009-04-27 Gary Benson <gbenson@redhat.com> * ports/hotspot/src/share/vm/shark/sharkState.hpp (SharkState::SharkState): Add explicit block argument. (SharkState::copy): Pass block to constructor. * ports/hotspot/src/share/vm/shark/sharkState.cpp (SharkState::SharkState): Add explicit block argument. * ports/hotspot/src/share/vm/shark/sharkBlock.cpp (SharkBlock::initial_current_state): Pass block to SharkState constructor.
author Gary Benson <gbenson@redhat.com>
date Mon, 27 Apr 2009 05:35:03 -0400
parents ac377bd5008f
children 010cb02d0958
files ChangeLog ports/hotspot/src/share/vm/shark/sharkBlock.cpp ports/hotspot/src/share/vm/shark/sharkState.cpp ports/hotspot/src/share/vm/shark/sharkState.hpp
diffstat 4 files changed, 16 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Fri Apr 24 14:09:22 2009 -0400
+++ b/ChangeLog	Mon Apr 27 05:35:03 2009 -0400
@@ -1,3 +1,14 @@
+2009-04-27  Gary Benson  <gbenson@redhat.com>
+
+	* ports/hotspot/src/share/vm/shark/sharkState.hpp
+	(SharkState::SharkState): Add explicit block argument.
+	(SharkState::copy): Pass block to constructor.
+	* ports/hotspot/src/share/vm/shark/sharkState.cpp
+	(SharkState::SharkState): Add explicit block argument.
+	* ports/hotspot/src/share/vm/shark/sharkBlock.cpp
+	(SharkBlock::initial_current_state): Pass block to
+	SharkState constructor.
+
 2009-04-24  Lillian Angel  <langel@redhat.com>
 
 	Fixes #497191
--- a/ports/hotspot/src/share/vm/shark/sharkBlock.cpp	Fri Apr 24 14:09:22 2009 -0400
+++ b/ports/hotspot/src/share/vm/shark/sharkBlock.cpp	Mon Apr 27 05:35:03 2009 -0400
@@ -853,7 +853,7 @@
 
 SharkState* SharkBlock::initial_current_state()
 {
-  return new SharkState(entry_state());
+  return new SharkState(this, entry_state());
 }
 
 int SharkBlock::switch_default_dest()
--- a/ports/hotspot/src/share/vm/shark/sharkState.cpp	Fri Apr 24 14:09:22 2009 -0400
+++ b/ports/hotspot/src/share/vm/shark/sharkState.cpp	Mon Apr 27 05:35:03 2009 -0400
@@ -38,8 +38,8 @@
   initialize(NULL);
 }
 
-SharkState::SharkState(const SharkState* state)
-  : _block(state->block()),
+SharkState::SharkState(SharkBlock* block, const SharkState* state)
+  : _block(block),
     _function(state->function()),
     _method(state->method())
 {
--- a/ports/hotspot/src/share/vm/shark/sharkState.hpp	Fri Apr 24 14:09:22 2009 -0400
+++ b/ports/hotspot/src/share/vm/shark/sharkState.hpp	Mon Apr 27 05:35:03 2009 -0400
@@ -32,7 +32,7 @@
   SharkState(SharkBlock*    block,
              SharkFunction* function = NULL,
              llvm::Value*   method = NULL);
-  SharkState(const SharkState* state);
+  SharkState(SharkBlock* block, const SharkState* state);
 
  private:
   void initialize(const SharkState* state);
@@ -137,7 +137,7 @@
  public:
   SharkState* copy() const
   {
-    return new SharkState(this);
+    return new SharkState(block(), this);
   }
   void merge(SharkState*       other,
              llvm::BasicBlock* other_block,