harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smish...@apache.org
Subject svn commit: r496237 [4/4] - in /harmony/enhanced/drlvm/trunk/vm: include/ include/open/ vmcore/include/
Date Mon, 15 Jan 2007 06:22:35 GMT
Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_rt.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_rt.h?view=diff&rev=496237&r1=496236&r2=496237
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_rt.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_rt.h Sun Jan 14 22:22:34 2007
@@ -1,10 +1,10 @@
 /*
  *  Licensed to the Apache Software Foundation (ASF) under one or more
- *  contributor license agreements. See the NOTICE file distributed with
+ *  contributor license agreements.  See the NOTICE file distributed with
  *  this work for additional information regarding copyright ownership.
  *  The ASF licenses this file to You under the Apache License, Version 2.0
  *  (the "License"); you may not use this file except in compliance with
- *  the License. You may obtain a copy of the License at
+ *  the License.  You may obtain a copy of the License at
  *
  *     http://www.apache.org/licenses/LICENSE-2.0
  *
@@ -14,11 +14,16 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
+/** 
+ * @author Intel, Alexei Fedotov
+ * @version $Revision: 1.1.2.1.4.3 $
+ */  
 
-/**
- * These are the functions that a JIT built as a DLL must export for
- * the purpose of runtime interaction.
- */
+
+//
+// These are the functions that a JIT built as a DLL must export for
+// the purpose of runtime interaction.
+//
 
 #ifndef _JIT_EXPORT_RT_H
 #define _JIT_EXPORT_RT_H
@@ -31,16 +36,15 @@
 extern "C" {
 #endif // __cplusplus
 
-/////////
+
+
+///////////////////////////////////////////////////////
 // begin Frame Contexts for JITs
-////////
 
 #ifdef _IPF_
 
-/**
- * @note The code in transfer context is very depend upon the ordering of fields 
- *       in this structure. Be very careful in changing this structure.
- */
+// Note that the code in transfer context is very depend upon the ordering of fields in this
structure.
+// Be very careful in changing this structure.
 typedef
 struct JitFrameContext {
     uint64 *p_ar_pfs;
@@ -105,7 +109,7 @@
     uint32 *p_ecx;
     uint32 *p_edx;
 
- 
+    // To restore processor flags during transfer
     uint32 eflags;
 
     Boolean is_ip_past;
@@ -124,47 +128,34 @@
 // begin direct call support
 
 
-/**
- * The following are optional functions used by the direct call-related
- * JIT interface. 
- * These functions are implemented by a JIT and invoked by the VM. They allow 
- * a JIT to be notified whenever, e.g., a VM data structure changes that would 
- * require code patching or recompilation.
- *
- * The callback that corresponds to <code>vm_register_jit_extended_class_callback</code>.
- * The newly loaded class is <code>new_class</code>. 
- *
- * @return <code>TRUE</code> if any code was modified
- *        (consequently the VM will ensure correctness such as synchronizing 
- *         I- and D-caches); otherwise, <code>FALSE</code>.
- */
+// The following are optional functions used by the direct call-related JIT interface. 
+// These functions are implemented by a JIT and invoked by the VM. They allow a JIT 
+// to be notified whenever, e.g., a VM data structure changes that would require 
+// code patching or recompilation.
+ 
+// The callback that corresponds to vm_register_jit_extended_class_callback.  
+// The newly loaded class is new_class.  The JIT should return TRUE if any code was modified
+// (consequently the VM will ensure correctness such as synchronizing I- and D-caches), 
+// and FALSE otherwise.
 JITEXPORT Boolean 
 JIT_extended_class_callback(JIT_Handle jit, 
                             Class_Handle  extended_class,
                             Class_Handle  new_class,
                             void         *callback_data);
 
-/**
- * The callback that corresponds to <codevm_register_jit_overridden_method_callback</code>.
- * The overriding method is <code>new_method</code>. 
- * 
- * @return <code>TRUE</code> if any code was modified (consequently the VM will

- *         ensure correctness such as synchronizing I- and D-caches); otherwise,
- *         <code>FALSE</code>.
- */
-
+// The callback that corresponds to vm_register_jit_overridden_method_callback. 
+// The overriding method is new_method. The JIT should return TRUE if any code was modified
+// (consequently the VM will ensure correctness such as synchronizing I- and D-caches),
+// and FALSE otherwise.
 JITEXPORT Boolean 
 JIT_overridden_method_callback(JIT_Handle jit,
                                Method_Handle  overridden_method,
                                Method_Handle  new_method, 
                                void          *callback_data);
 
-/**
- * The callback that corresponds to <code>vm_register_jit_recompiled_method_callback</code>.
- * 
- * @return <code>TRUE</code> if any code was modified (consequently the VM will
ensure 
- *         correctness such as synchronizing I- and D-caches); otherwise, <code>FALSE</code>.
- */
+// The callback that corresponds to vm_register_jit_recompiled_method_callback.  
+// The JIT should return TRUE if any code was modified (consequently the VM will ensure 
+// correctness such as synchronizing I- and D-caches), and FALSE otherwise.
 JITEXPORT Boolean 
 JIT_recompiled_method_callback(JIT_Handle jit,
                                Method_Handle  recompiled_method,
@@ -237,14 +228,9 @@
 // begin compressed references
 
 
-/**
- * @return <code>TRUE</code> if the JIT will compress references within 
- *         objects and vector elements by representing them as offsets 
- *         rather than raw pointers. The JIT should call the VM function 
- *         <code>vm_references_are_compressed()</code> during initialization

- *         in order to decide whether it should compress references.
- */
-
+// Returns TRUE if the JIT will compress references within objects and vector elements by
representing 
+// them as offsets rather than raw pointers. The JIT should call the VM function vm_references_are_compressed()
+// during initialization in order to decide whether it should compress references.
 JITEXPORT Boolean 
 JIT_supports_compressed_references(JIT_Handle jit);
 

Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_runtime_support_common.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_runtime_support_common.h?view=diff&rev=496237&r1=496236&r2=496237
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_runtime_support_common.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_runtime_support_common.h Sun Jan 14
22:22:34 2007
@@ -1,10 +1,10 @@
 /*
  *  Licensed to the Apache Software Foundation (ASF) under one or more
- *  contributor license agreements. See the NOTICE file distributed with
+ *  contributor license agreements.  See the NOTICE file distributed with
  *  this work for additional information regarding copyright ownership.
  *  The ASF licenses this file to You under the Apache License, Version 2.0
  *  (the "License"); you may not use this file except in compliance with
- *  the License. You may obtain a copy of the License at
+ *  the License.  You may obtain a copy of the License at
  *
  *     http://www.apache.org/licenses/LICENSE-2.0
  *
@@ -14,6 +14,14 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
+/** 
+ * @author Intel, Evgueni Brevnov, Ivan Volosyuk
+ * @version $Revision: 1.1.2.1.4.4 $
+ */  
+
+
+
+
 
 #ifndef _JIT_RUNTIME_SUPPORT_COMMON_H_
 #define _JIT_RUNTIME_SUPPORT_COMMON_H_
@@ -25,15 +33,11 @@
 VMEXPORT // temporary solution for interpreter unplug
 int __stdcall vm_instanceof(ManagedObject *obj, Class *c) stdcall__;
 
-/**
- * Implements <code>VM_RT_AASTORE</code>.
- */
+// Implements VM_RT_AASTORE
 void * __stdcall
 vm_rt_aastore(ManagedObject *elem, int idx, Vector_Handle array) stdcall__;
 
-/**
- * Implements <code>VM_RT_AASTORE_TEST</code>.
- */
+// Implements VM_RT_AASTORE_TEST
 int __stdcall
 vm_aastore_test(ManagedObject *elem, Vector_Handle array) stdcall__;
 
@@ -52,21 +56,16 @@
 Vector_Handle vm_rt_new_vector_using_vtable_and_thread_pointer(
         int length, Allocation_Handle vector_handle, void *tp);
 
-/** 
- * Creates a LIL code stub for checkcast or instance of
- * can be used by both IA32 and IPF code
- */
-  LilCodeStub *gen_lil_typecheck_stub(bool is_checkcast).
- 
-/**
- * Creates a <code>SPECIALIZED LIL</code> code stub for checkcast or instance
of
- * it assumes that the class is suitable for fast instanceof checks.
- *
- * @return Different fast stub for every class. <code>will_inline</code>
- *         is set to <code>TRUE</code>, if this stub will be inlined in a JIT,
- *         and <code>FALSE</code>, if it will be passed to a code generator
- *         (this is due to the slightly different treatment of exceptions).
- */
+// creates a LIL code stub for checkcast or instanceof
+// can be used by both IA32 and IPF code
+LilCodeStub *gen_lil_typecheck_stub(bool is_checkcast);
+
+// creates a SPECIALIZED LIL code stub for checkcast or instanceof
+// it assumes that the class is suitable for fast instanceof checks.
+// The result is a different fast stub for every class.
+// will_inline should be set to TRUE if this stub will be inlined
+// in a JIT, and false if it will be passed to a code generator
+// (this is due to the slightly different treatment of exceptions)
 LilCodeStub *gen_lil_typecheck_stub_specialized(bool is_checkcast,
                                                 bool will_inline,
                                                 Class *superclass);

Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/include/mon_enter_exit.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/include/mon_enter_exit.h?view=diff&rev=496237&r1=496236&r2=496237
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/include/mon_enter_exit.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/include/mon_enter_exit.h Sun Jan 14 22:22:34 2007
@@ -14,6 +14,10 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
+/** 
+ * @author Andrey Chernyshev
+ * @version $Revision: 1.1.2.1.4.4 $
+ */  
 
 
 #ifndef MON_ENTER_EXIT_HEADER
@@ -31,23 +35,17 @@
 #define P_HASH_CONTENTION_BYTE(x) ( (uint8 *)(x->get_obj_info_addr()) )
 #define P_HASH_CONTENTION(x)      ((POINTER_SIZE_INT)P_HASH_CONTENTION_BYTE(x))
 
-/**
- * This is called once at startup, before any classes are loaded,
- * and after arguments are parsed. It should set function pointers
- * to the appropriate values.
- */
- void vm_monitor_init();
+// This is called once at startup, before any classes are loaded,
+// and after arguments are parsed.  It should set function pointers
+// to the appropriate values.
+void vm_monitor_init();
 
-/** 
- * Monitor exit from synchronized method
- */
- struct StackIterator;
+// monitor exit from synchronized method
+struct StackIterator;
 void vm_monitor_exit_synchronized_method(StackIterator *si);
 
-/**
- * Does a monitorexit operation.
- */
- extern void (*vm_monitor_exit)(ManagedObject *p_obj);
+// Does a monitorexit operation.
+extern void (*vm_monitor_exit)(ManagedObject *p_obj);
 extern void (*vm_monitor_enter)(ManagedObject *p_obj);
 extern uint32 (*vm_monitor_try_enter)(ManagedObject *p_obj);
 extern uint32 (*vm_monitor_try_exit)(ManagedObject *p_obj);

Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/include/vm_strings.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/include/vm_strings.h?view=diff&rev=496237&r1=496236&r2=496237
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/include/vm_strings.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/include/vm_strings.h Sun Jan 14 22:22:34 2007
@@ -1,10 +1,10 @@
 /*
  *  Licensed to the Apache Software Foundation (ASF) under one or more
- *  contributor license agreements. See the NOTICE file distributed with
+ *  contributor license agreements.  See the NOTICE file distributed with
  *  this work for additional information regarding copyright ownership.
  *  The ASF licenses this file to You under the Apache License, Version 2.0
  *  (the "License"); you may not use this file except in compliance with
- *  the License. You may obtain a copy of the License at
+ *  the License.  You may obtain a copy of the License at
  *
  *     http://www.apache.org/licenses/LICENSE-2.0
  *
@@ -14,10 +14,14 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
+/** 
+ * @author Intel, Alexei Fedotov
+ * @version $Revision: 1.1.2.1.4.3 $
+ */  
+
+
+// This describes the VM internal interface for manipulating strings
 
-/**
- * This describes the VM internal interface for manipulating strings.
- */
 #ifndef _VM_STRINGS_H_
 #define _VM_STRINGS_H_
 
@@ -61,100 +65,57 @@
 
 jstring String_to_interned_jstring(String* str);
 
-/** 
- * @name New Interface
- */
-//@{
-
-
-/**
- * GC must be disabled, but at a GC safe point.
- */
+//***** New Interface
 
+// GC must be disabled, but at a GC safe point
 ManagedObject* string_create_from_utf8(const char* buf, unsigned length);
 ManagedObject* string_create_from_unicode(const uint16* buf, unsigned length);
 ManagedObject* string_create_blank(unsigned length);  // Create a string of given length
(in characters) with arbitrary characters
 
-/**
- * GC must be disabled.
- *
- * @return Length in characters.
- */
+// GC must be disabled
+// returns length in characters
 unsigned string_get_length(ManagedObject*);
 
-/** 
- * GC must be disabled.
- * 
- * @return The length of the UTF8 encoding of the string
- */
+// GC must be disabled
+// returns the length of the UTF8 encoding of the string
 unsigned string_get_utf8_length(ManagedObject* str);
 
-/** 
- * GC must be disabled.
- * Result is zero terminated.
- * Caller should free the result.
- */
-
+// GC must be disabled
+// result is zero terminated 
+// Caller should free the result
 const uint16* string_get_unicode_chars(ManagedObject* string);
 
-/**
- * GC must be disabled
- * Result is zero terminated.
- * Caller should free the result.
- */
-
+// GC must be disabled
+// result is zero terminated
+// Caller should free the result
 const char* string_get_utf8_chars(ManagedObject* string);
 
-/** 
- * GC must be disabled.
- * Copy the characters <code>offset..offset+count-1</code> into res.
- */
+// GC must be disabled
+// Copy the characters offset..offset+count-1 into res
 void string_get_unicode_region(ManagedObject* str, unsigned offset, unsigned count, uint16*
res);
 
-/**
- * GC must be disabled.
- * Encode characters <code>offset..offset+count-1</code> into UTF8 and place
in res.
- */
-
+// GC must be disabled
+// Encode characters offset..offset+count-1 into UTF8 and place in res
 void string_get_utf8_region(ManagedObject* str, unsigned offset, unsigned count, char* res);
 
-
-/** 
- * @name Handle versions
- */
-//@{
-
+//*** Handle versions
 
 ObjectHandle string_create_from_utf8_h(const char* buf, unsigned length);
 ObjectHandle string_create_from_unicode_h(const uint16* buf, unsigned length);
 
-/**
- * @return Length in characters.
- */ 
-
+// returns length in characters
 unsigned string_get_length_h(ObjectHandle str);
 
-/**
- * @return The length of the UTF8 encoding of the string.
- */
-
+// returns the length of the UTF8 encoding of the string
 unsigned string_get_utf8_length_h(ObjectHandle str);
 
-/**
- * Caller should free the result.
- */
-
+// Caller should free the result
 const char* string_get_utf8_chars_h(ObjectHandle string);
 
-/**
- * Copy the characters <code>offset..offset+count-1</code> into buf.
- */
-
+// Copy the characters offset..offset+count-1 into buf
 void string_get_unicode_region_h(ObjectHandle str, unsigned offset, unsigned count, uint16*
buf);
 
-/**
- * Encode characters <code>offset..offset+count-1</code> into UTF8 and place
in buf.
- */ 
+// Encode characters offset..offset+count-1 into UTF8 and place in buf
 void string_get_utf8_region_h(ObjectHandle str, unsigned offset, unsigned count, char* buf);
 
 #endif //!_VM_STRINGS_H_



Mime
View raw message