changeset in /hg/icedtea6: 2008-08-20 Gary Benson <gbenson at red...

Gary Benson gbenson at redhat.com
Wed Aug 20 01:24:50 PDT 2008


changeset 4f4d268762d7 in /hg/icedtea6
details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=4f4d268762d7
description:
	2008-08-20  Gary Benson  <gbenson at redhat.com>

		* patches/icedtea-shark.patch: Updated to latest Shark.
		* ports/hotspot/src/cpu/zero/vm/assembler_zero.cpp: Likewise.
		* ports/hotspot/src/cpu/zero/vm/assembler_zero.hpp: Likewise.
		* ports/hotspot/src/cpu/zero/vm/cppInterpreterGenerator_zero.hpp:
		Likewise.
		* ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp: Likewise.
		* ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.hpp: Likewise.
		* ports/hotspot/src/cpu/zero/vm/interpreter_zero.cpp: Likewise.
		* ports/hotspot/src/cpu/zero/vm/interpreter_zero.hpp: Likewise.
		* ports/hotspot/src/share/vm/includeDB_shark: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkBlock.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkBlock.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkBuilder.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkBuilder.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkCompiler.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkCompiler.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkConstantPool.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkFunction.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkFunction.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkMonitor.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkRuntime.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkRuntime.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkState.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkState.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkType.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkType.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkValue.hpp: Likewise.
		* ports/hotspot/src/cpu/zero/vm/entry_zero.hpp: New file.
		* ports/hotspot/src/share/vm/shark/sharkEntry.cpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkEntry.hpp: Likewise.
		* ports/hotspot/src/share/vm/shark/sharkMethod.hpp: Removed.

diffstat:

31 files changed, 1536 insertions(+), 628 deletions(-)
ChangeLog                                                      |   34 
patches/icedtea-shark.patch                                    |    2 
ports/hotspot/src/cpu/zero/vm/assembler_zero.cpp               |   25 
ports/hotspot/src/cpu/zero/vm/assembler_zero.hpp               |   27 
ports/hotspot/src/cpu/zero/vm/cppInterpreterGenerator_zero.hpp |   39 
ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp          |   34 
ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.hpp          |   11 
ports/hotspot/src/cpu/zero/vm/entry_zero.hpp                   |   60 
ports/hotspot/src/cpu/zero/vm/interpreter_zero.cpp             |    1 
ports/hotspot/src/cpu/zero/vm/interpreter_zero.hpp             |   10 
ports/hotspot/src/share/vm/includeDB_shark                     |   15 
ports/hotspot/src/share/vm/shark/sharkBlock.cpp                |  981 ++++++++--
ports/hotspot/src/share/vm/shark/sharkBlock.hpp                |   98 
ports/hotspot/src/share/vm/shark/sharkBuilder.cpp              |    2 
ports/hotspot/src/share/vm/shark/sharkBuilder.hpp              |   62 
ports/hotspot/src/share/vm/shark/sharkCompiler.cpp             |  101 -
ports/hotspot/src/share/vm/shark/sharkCompiler.hpp             |   11 
ports/hotspot/src/share/vm/shark/sharkConstantPool.cpp         |   14 
ports/hotspot/src/share/vm/shark/sharkEntry.cpp                |  136 +
ports/hotspot/src/share/vm/shark/sharkEntry.hpp                |   55 
ports/hotspot/src/share/vm/shark/sharkFunction.cpp             |   92 
ports/hotspot/src/share/vm/shark/sharkFunction.hpp             |   57 
ports/hotspot/src/share/vm/shark/sharkMethod.hpp               |   91 
ports/hotspot/src/share/vm/shark/sharkMonitor.hpp              |   12 
ports/hotspot/src/share/vm/shark/sharkRuntime.cpp              |   19 
ports/hotspot/src/share/vm/shark/sharkRuntime.hpp              |    6 
ports/hotspot/src/share/vm/shark/sharkState.cpp                |   25 
ports/hotspot/src/share/vm/shark/sharkState.hpp                |    5 
ports/hotspot/src/share/vm/shark/sharkType.cpp                 |   10 
ports/hotspot/src/share/vm/shark/sharkType.hpp                 |   11 
ports/hotspot/src/share/vm/shark/sharkValue.hpp                |  118 -

diffs (truncated from 3308 to 500 lines):

diff -r 67600de741be -r 4f4d268762d7 ChangeLog
--- a/ChangeLog	Wed Aug 20 04:12:41 2008 -0400
+++ b/ChangeLog	Wed Aug 20 04:24:45 2008 -0400
@@ -1,3 +1,37 @@ 2008-08-20  Gary Benson  <gbenson at redhat
+2008-08-20  Gary Benson  <gbenson at redhat.com>
+
+	* patches/icedtea-shark.patch: Updated to latest Shark.
+	* ports/hotspot/src/cpu/zero/vm/assembler_zero.cpp: Likewise.
+	* ports/hotspot/src/cpu/zero/vm/assembler_zero.hpp: Likewise.
+	* ports/hotspot/src/cpu/zero/vm/cppInterpreterGenerator_zero.hpp: 
+	Likewise.
+	* ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp: Likewise.
+	* ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.hpp: Likewise.
+	* ports/hotspot/src/cpu/zero/vm/interpreter_zero.cpp: Likewise.
+	* ports/hotspot/src/cpu/zero/vm/interpreter_zero.hpp: Likewise.
+	* ports/hotspot/src/share/vm/includeDB_shark: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkBlock.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkBlock.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkBuilder.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkBuilder.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkCompiler.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkCompiler.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkConstantPool.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkFunction.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkFunction.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkMonitor.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkRuntime.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkRuntime.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkState.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkState.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkType.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkType.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkValue.hpp: Likewise.
+	* ports/hotspot/src/cpu/zero/vm/entry_zero.hpp: New file.
+	* ports/hotspot/src/share/vm/shark/sharkEntry.cpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkEntry.hpp: Likewise.
+	* ports/hotspot/src/share/vm/shark/sharkMethod.hpp: Removed.
+
 2008-08-20  Gary Benson  <gbenson at redhat.com>
 
 	* ports/hotspot/src/cpu/zero/vm/bytecodeInterpreter_zero.inline.hpp
diff -r 67600de741be -r 4f4d268762d7 patches/icedtea-shark.patch
--- a/patches/icedtea-shark.patch	Wed Aug 20 04:12:41 2008 -0400
+++ b/patches/icedtea-shark.patch	Wed Aug 20 04:24:45 2008 -0400
@@ -181,7 +181,7 @@ diff -ru openjdk/hotspot/src/share/vm/oo
  
    OrderAccess::storestore();
 +#ifdef SHARK
-+  mh->_from_interpreted_entry = SharkMethod::mark(code->instructions_begin());
++  mh->_from_interpreted_entry = code->instructions_begin();
 +#else
    mh->_from_compiled_entry = code->verified_entry_point();
    OrderAccess::storestore();
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/cpu/zero/vm/assembler_zero.cpp
--- a/ports/hotspot/src/cpu/zero/vm/assembler_zero.cpp	Wed Aug 20 04:12:41 2008 -0400
+++ b/ports/hotspot/src/cpu/zero/vm/assembler_zero.cpp	Wed Aug 20 04:24:45 2008 -0400
@@ -28,11 +28,7 @@
 
 int AbstractAssembler::code_fill_byte()
 {
-#ifdef SHARK
   return 0;
-#else
-  Unimplemented();
-#endif // SHARK
 }
 
 void Assembler::pd_patch_instruction(address branch, address target)
@@ -47,27 +43,26 @@ void Assembler::pd_print_patched_instruc
 }
 #endif // PRODUCT
 
+void MacroAssembler::align(int modulus)
+{
+  while (offset() % modulus != 0)
+    emit_byte(AbstractAssembler::code_fill_byte());
+}
+
 void MacroAssembler::bang_stack_with_offset(int offset)
 {
   Unimplemented();
 }
 
-void MacroAssembler::align(int modulus)
+void MacroAssembler::advance(int bytes)
 {
-  // Loads of places assert that code is generated,
-  // and I'm guessing plenty of places assume that
-  // *something* was generated.  This is a sneaky
-  // place to emit such a something.
-  emit_byte(0x23);
-
-  // Probably ought to align it too, while we're here.
-  while (offset() % modulus != 0)
-    emit_byte(0x23);
+  _code_pos += bytes;
+  sync();
 }
 
 static void _UnimplementedStub()
 {
-  report_unimplemented("fake-generated-code", 23);
+  report_unimplemented(__FILE__, __LINE__);
 }
 
 address UnimplementedStub()
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/cpu/zero/vm/assembler_zero.hpp
--- a/ports/hotspot/src/cpu/zero/vm/assembler_zero.hpp	Wed Aug 20 04:12:41 2008 -0400
+++ b/ports/hotspot/src/cpu/zero/vm/assembler_zero.hpp	Wed Aug 20 04:24:45 2008 -0400
@@ -23,27 +23,20 @@
  *
  */
 
-// The definitions needed for zero assembly code generation.
-
-// The zero Assembler: Pure assembler doing NO optimizations on
-// the instruction level; i.e., what you write is what you get.
-// The Assembler is generating code into a CodeBuffer.
+// In normal, CPU-specific ports of HotSpot these two classes are used
+// for generating assembly language.  We don't do any of this in zero,
+// of course, but we do sneak entry points around in CodeBuffers so we
+// generate those here.
 
 class Assembler : public AbstractAssembler {
  public:
   Assembler(CodeBuffer* code) : AbstractAssembler(code) {}
 
-  // Function to fix up forward branches
   void pd_patch_instruction(address branch, address target);
 #ifndef PRODUCT
   static void pd_print_patched_instruction(address branch);
 #endif // PRODUCT
 };
-
-// MacroAssembler extends Assembler by frequently used macros.
-//
-// Instructions for which a 'better' code sequence exists depending
-// on arguments should also go in here.
 
 class MacroAssembler : public Assembler {
  public:
@@ -52,17 +45,8 @@ class MacroAssembler : public Assembler 
   void align(int modulus);
   void bang_stack_with_offset(int offset);
 
-#ifdef SHARK
  public:
-  void emit_zero_byte()
-  {
-    emit_byte(0);
-  }
-  void emit_intptr(intptr_t x)
-  {
-    emit_address((address) x);
-  }
-#endif // SHARK
+  void advance(int bytes);
 };
 
 #ifdef ASSERT
@@ -79,4 +63,5 @@ address ShouldNotReachHereStub();
 // Nothing to do with the assembler (or lack of),
 // just a real convenient place to include these.
 #include <ffi.h>
+#include <entry_zero.hpp>
 #include <stack_zero.hpp>
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/cpu/zero/vm/cppInterpreterGenerator_zero.hpp
--- a/ports/hotspot/src/cpu/zero/vm/cppInterpreterGenerator_zero.hpp	Wed Aug 20 04:12:41 2008 -0400
+++ b/ports/hotspot/src/cpu/zero/vm/cppInterpreterGenerator_zero.hpp	Wed Aug 20 04:24:45 2008 -0400
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2003-2007 Sun Microsystems, Inc.  All Rights Reserved.
+ * Copyright 2008 Red Hat, Inc.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ *
+ */
+
+ protected:
+  MacroAssembler* assembler() const
+  {
+    return _masm;
+  }
+
+ protected:
+  address generate_entry(ZeroEntry::method_entry_t entry_point)
+  {
+    ZeroEntry *entry = (ZeroEntry *) assembler()->pc();
+    assembler()->advance(sizeof(ZeroEntry));
+    entry->set_entry_point(entry_point);
+    return (address) entry;
+  }
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp
--- a/ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp	Wed Aug 20 04:12:41 2008 -0400
+++ b/ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp	Wed Aug 20 04:24:45 2008 -0400
@@ -37,7 +37,7 @@
   thread->reset_last_Java_frame();              \
   fixup_after_potential_safepoint()
 
-void CppInterpreter::normal_entry(methodOop method, TRAPS)
+void CppInterpreter::normal_entry(methodOop method, intptr_t UNUSED, TRAPS)
 {
   JavaThread *thread = (JavaThread *) THREAD;
   ZeroStack *stack = thread->zero_stack();
@@ -146,7 +146,7 @@ void CppInterpreter::normal_entry(method
     stack->push(result[-i]);
 }
 
-void CppInterpreter::native_entry(methodOop method, TRAPS)
+void CppInterpreter::native_entry(methodOop method, intptr_t UNUSED, TRAPS)
 {
   JavaThread *thread = (JavaThread *) THREAD;
   ZeroStack *stack = thread->zero_stack();
@@ -374,7 +374,7 @@ void CppInterpreter::native_entry(method
   }
 }
 
-void CppInterpreter::accessor_entry(methodOop method, TRAPS)
+void CppInterpreter::accessor_entry(methodOop method, intptr_t UNUSED, TRAPS)
 {
   JavaThread *thread = (JavaThread *) THREAD;
   ZeroStack *stack = thread->zero_stack();
@@ -382,7 +382,7 @@ void CppInterpreter::accessor_entry(meth
 
   // Drop into the slow path if we need a safepoint check
   if (SafepointSynchronize::do_call_back()) {
-    normal_entry(method, THREAD);
+    normal_entry(method, 0, THREAD);
     return;
   }
 
@@ -390,7 +390,7 @@ void CppInterpreter::accessor_entry(meth
   // if we have a NullPointerException
   oop object = LOCALS_OBJECT(0);
   if (object == NULL) {
-    normal_entry(method, THREAD);
+    normal_entry(method, 0, THREAD);
     return;
   }
 
@@ -413,7 +413,7 @@ void CppInterpreter::accessor_entry(meth
   constantPoolCacheOop cache = method->constants()->cache();
   ConstantPoolCacheEntry* entry = cache->entry_at(index);
   if (!entry->is_resolved(Bytecodes::_getfield)) {
-    normal_entry(method, THREAD);
+    normal_entry(method, 0, THREAD);
     return;
   }
 
@@ -505,14 +505,14 @@ void CppInterpreter::accessor_entry(meth
   }
 }
 
-void CppInterpreter::empty_entry(methodOop method, TRAPS)
+void CppInterpreter::empty_entry(methodOop method, intptr_t UNUSED, TRAPS)
 {
   JavaThread *thread = (JavaThread *) THREAD;
   ZeroStack *stack = thread->zero_stack();
 
   // Drop into the slow path if we need a safepoint check
   if (SafepointSynchronize::do_call_back()) {
-    normal_entry(method, THREAD);
+    normal_entry(method, 0, THREAD);
     return;
   }
 
@@ -609,7 +609,7 @@ address InterpreterGenerator::generate_e
   if (!UseFastEmptyMethods)
     return NULL;
 
-  return (address) CppInterpreter::empty_entry;
+  return generate_entry(CppInterpreter::empty_entry);
 }
 
 address InterpreterGenerator::generate_accessor_entry()
@@ -617,19 +617,21 @@ address InterpreterGenerator::generate_a
   if (!UseFastAccessorMethods)
     return NULL;
 
-  return (address) CppInterpreter::accessor_entry;
+  return generate_entry(CppInterpreter::accessor_entry);
 }
 
 address InterpreterGenerator::generate_native_entry(bool synchronized)
 {
   assert (synchronized == false, "should be");
-  return (address) CppInterpreter::native_entry;
+
+  return generate_entry(CppInterpreter::native_entry);
 }
 
 address InterpreterGenerator::generate_normal_entry(bool synchronized)
 {
   assert (synchronized == false, "should be");
-  return (address) CppInterpreter::normal_entry;
+
+  return generate_entry(CppInterpreter::normal_entry);
 }
 
 address AbstractInterpreterGenerator::generate_method_entry(
@@ -679,10 +681,6 @@ address AbstractInterpreterGenerator::ge
   if (entry_point == NULL)
     entry_point = ((InterpreterGenerator*)this)->generate_normal_entry(false);
 
-#ifdef SHARK
-  assert(!SharkMethod::is_shark_method(entry_point), "shouldn't be");
-#endif // SHARK
-  
   return entry_point;
 }
 
@@ -732,21 +730,25 @@ bool CppInterpreter::contains(address pc
 
 address CppInterpreterGenerator::generate_result_handler_for(
     BasicType type) {
+  assembler()->advance(1);
   return ShouldNotReachHereStub();
 }
 
 address CppInterpreterGenerator::generate_tosca_to_stack_converter(
     BasicType type) {
+  assembler()->advance(1);
   return ShouldNotReachHereStub();
 }
 
 address CppInterpreterGenerator::generate_stack_to_stack_converter(
     BasicType type) {
+  assembler()->advance(1);
   return ShouldNotReachHereStub();
 }
 
 address CppInterpreterGenerator::generate_stack_to_native_abi_converter(
     BasicType type) {
+  assembler()->advance(1);
   return ShouldNotReachHereStub();
 }
 
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.hpp
--- a/ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.hpp	Wed Aug 20 04:12:41 2008 -0400
+++ b/ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.hpp	Wed Aug 20 04:24:45 2008 -0400
@@ -25,13 +25,12 @@
 
 
  protected:
-  // Size of interpreter code.  We don't have generated code so
-  // this should be zero, but that hits all kinds of assertions
+  // Size of interpreter code
   const static int InterpreterCodeSize = 6 * K;
 
  private:
   // Method entries
-  static void normal_entry(methodOop method, TRAPS);
-  static void native_entry(methodOop method, TRAPS);
-  static void accessor_entry(methodOop method, TRAPS);
-  static void empty_entry(methodOop method, TRAPS);
+  static void normal_entry(methodOop method, intptr_t UNUSED, TRAPS);
+  static void native_entry(methodOop method, intptr_t UNUSED, TRAPS);
+  static void accessor_entry(methodOop method, intptr_t UNUSED, TRAPS);
+  static void empty_entry(methodOop method, intptr_t UNUSED, TRAPS);
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/cpu/zero/vm/entry_zero.hpp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ports/hotspot/src/cpu/zero/vm/entry_zero.hpp	Wed Aug 20 04:24:45 2008 -0400
@@ -0,0 +1,60 @@
+/*
+ * Copyright 2003-2007 Sun Microsystems, Inc.  All Rights Reserved.
+ * Copyright 2008 Red Hat, Inc.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
+ * CA 95054 USA or visit www.sun.com if you need additional information or
+ * have any questions.
+ *
+ */
+
+class ZeroEntry {
+ public:
+  ZeroEntry()
+  {
+    ShouldNotCallThis();
+  }
+
+ public:
+  typedef void (*method_entry_t)(methodOop method, intptr_t base_pc, TRAPS);
+
+ private:
+  method_entry_t _entry_point;
+
+ public:
+  method_entry_t entry_point() const
+  {
+    return _entry_point;
+  }
+  void set_entry_point(method_entry_t entry_point)
+  {
+    _entry_point = entry_point;
+  }
+
+ public:
+  void invoke(methodOop method, TRAPS) const
+  {
+    entry_point()(method, (intptr_t) this, THREAD);
+  }
+
+ public:
+  static ByteSize entry_point_offset()
+  {
+    return byte_offset_of(ZeroEntry, _entry_point);
+  }
+};
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/cpu/zero/vm/interpreter_zero.cpp
--- a/ports/hotspot/src/cpu/zero/vm/interpreter_zero.cpp	Wed Aug 20 04:12:41 2008 -0400
+++ b/ports/hotspot/src/cpu/zero/vm/interpreter_zero.cpp	Wed Aug 20 04:24:45 2008 -0400
@@ -28,6 +28,7 @@
 
 address AbstractInterpreterGenerator::generate_slow_signature_handler()
 {
+  _masm->advance(1);
   return (address) InterpreterRuntime::slow_signature_handler;
 }
 
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/cpu/zero/vm/interpreter_zero.hpp
--- a/ports/hotspot/src/cpu/zero/vm/interpreter_zero.hpp	Wed Aug 20 04:12:41 2008 -0400
+++ b/ports/hotspot/src/cpu/zero/vm/interpreter_zero.hpp	Wed Aug 20 04:24:45 2008 -0400
@@ -24,17 +24,9 @@
  */
 
  public:
-  typedef void (*method_entry_t)(methodOop method, TRAPS);
-
   static void invoke_method(methodOop method, address entry_point, TRAPS)
   {
-#ifdef SHARK
-    if (SharkMethod::is_shark_method(entry_point)) {
-      SharkMethod::get(entry_point)->invoke(method, THREAD);
-      return;
-    }
-#endif // SHARK
-    ((method_entry_t) entry_point) (method, THREAD);
+    ((ZeroEntry *) entry_point)->invoke(method, THREAD);
   }
 
  public:
diff -r 67600de741be -r 4f4d268762d7 ports/hotspot/src/share/vm/includeDB_shark
--- a/ports/hotspot/src/share/vm/includeDB_shark	Wed Aug 20 04:12:41 2008 -0400
+++ b/ports/hotspot/src/share/vm/includeDB_shark	Wed Aug 20 04:24:45 2008 -0400
@@ -56,9 +56,7 @@ globals.hpp                             
 
 globals.cpp                             shark_globals.hpp
 
-interpreter.hpp                         sharkMethod.hpp
-
-methodOop.cpp                           sharkMethod.hpp
+methodOop.cpp                           sharkEntry.hpp
 
 shark_globals.cpp                       shark_globals.hpp
 
@@ -126,6 +124,7 @@ sharkCompiler.cpp                       
 sharkCompiler.cpp                       oopRecorder.hpp
 sharkCompiler.cpp                       shark_globals.hpp
 sharkCompiler.cpp                       sharkCompiler.hpp
+sharkCompiler.cpp                       sharkEntry.hpp
 sharkCompiler.cpp                       sharkFunction.hpp
 sharkCompiler.cpp                       sharkRuntime.hpp
 
@@ -153,12 +152,18 @@ sharkConstantPool.hpp                   
 sharkConstantPool.hpp                   sharkBlock.hpp
 sharkConstantPool.hpp                   sharkBuilder.hpp
 
+sharkEntry.cpp                          sharkEntry.hpp



More information about the distro-pkg-dev mailing list