You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by na...@apache.org on 2007/01/14 19:13:55 UTC

svn commit: r496108 [1/4] - in /harmony/enhanced/drlvm/trunk/vm: include/ include/open/ vmcore/include/

Author: nadinem
Date: Sun Jan 14 10:13:53 2007
New Revision: 496108

URL: http://svn.apache.org/viewvc?view=rev&rev=496108
Log:
HARMONY-2802, fixes for formatting in include/ and vmcore interface files

Modified:
    harmony/enhanced/drlvm/trunk/vm/include/component_manager.h
    harmony/enhanced/drlvm/trunk/vm/include/interpreter_exports.h
    harmony/enhanced/drlvm/trunk/vm/include/jit_import.h
    harmony/enhanced/drlvm/trunk/vm/include/jit_import_rt.h
    harmony/enhanced/drlvm/trunk/vm/include/jit_runtime_support.h
    harmony/enhanced/drlvm/trunk/vm/include/jvmti.h
    harmony/enhanced/drlvm/trunk/vm/include/jvmti_types.h
    harmony/enhanced/drlvm/trunk/vm/include/open/common.h
    harmony/enhanced/drlvm/trunk/vm/include/open/ee_em_intf.h
    harmony/enhanced/drlvm/trunk/vm/include/open/em_profile_access.h
    harmony/enhanced/drlvm/trunk/vm/include/open/gc.h
    harmony/enhanced/drlvm/trunk/vm/include/open/hycomp.h
    harmony/enhanced/drlvm/trunk/vm/include/open/hythread_ext.h
    harmony/enhanced/drlvm/trunk/vm/include/open/jthread.h
    harmony/enhanced/drlvm/trunk/vm/include/open/thread_externals.h
    harmony/enhanced/drlvm/trunk/vm/include/open/thread_helpers.h
    harmony/enhanced/drlvm/trunk/vm/include/open/ti_thread.h
    harmony/enhanced/drlvm/trunk/vm/include/open/types.h
    harmony/enhanced/drlvm/trunk/vm/include/open/vm.h
    harmony/enhanced/drlvm/trunk/vm/include/open/vm_gc.h
    harmony/enhanced/drlvm/trunk/vm/include/open/vm_util.h
    harmony/enhanced/drlvm/trunk/vm/vmcore/include/exceptions.h
    harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export.h
    harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_jpda.h
    harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_rt.h
    harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_runtime_support_common.h
    harmony/enhanced/drlvm/trunk/vm/vmcore/include/mon_enter_exit.h
    harmony/enhanced/drlvm/trunk/vm/vmcore/include/vm_strings.h

Modified: harmony/enhanced/drlvm/trunk/vm/include/component_manager.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/include/component_manager.h?view=diff&rev=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/include/component_manager.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/include/component_manager.h Sun Jan 14 10:13:53 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,6 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
-/** 
- * @author Intel, Alexei Fedotov
- * @version $Revision: 1.1.2.2.4.3 $
- */  
 
 #ifndef _VM_COMPONENT_MANAGER_H
 #define _VM_COMPONENT_MANAGER_H
@@ -34,9 +30,10 @@
  *
  * This function is safe to call from multiple threads.
  * 
- * @param[out] p_cm on return, points to a component manager
- * interface handle
- * @return APR_SUCCESS if successful, or a non-zero error code
+ * @param[out] p_cm - on return, points to a component manager
+ *                    interface handle
+ *
+ * @return <code>APR_SUCCESS</code> if successful, or a non-zero error code.
  */
 int CmAcquire(OpenComponentManagerHandle* p_cm);
 
@@ -46,19 +43,19 @@
  *
  * This function is safe to call from multiple threads.
  *
- * @return APR_SUCCESS if successful, or a non-zero error code
+ * @return <code>APR_SUCCESS</code> if successful, or a non-zero error code.
  */
 int CmRelease();
 
 /**
  * Register a buitin component in a component manager.
- * @param init_func initializer function which
- * provides a default and private interfaces for the
- * component
+ *
+ * @param init_func - initializer function which provides a default
+ *                    and private interfaces for the component
  *
  * This function is safe to call from multiple threads.
  *
- * @return APR_SUCCESS if successful, or a non-zero error code
+ * @return <code>APR_SUCCESS</code> if successful, or a non-zero error code.
  */
 int CmAddComponent(OpenComponentInitializer init_func);
 
@@ -69,27 +66,25 @@
  *
  * This function is safe to call from multiple threads.
  *
- * @param path path to DLL which contains a component
- * @param initializer_function_name a name of a function
- * of <code>OpenComponentInitializer</code> type
- * that registers a component in a component manager
- * @return APR_SUCCESS if successful, or a non-zero error code
+ * @param path                       - path to DLL which contains a component
+ * @param initializer_function_name  - a name of a function of <code>OpenComponentInitializer</code> 
+ *                                     type that registers a component in a component manager
+ *
+ * @return <code>APR_SUCCESS</code> if successful, or a non-zero error code.
  */
 int CmLoadComponent(const char* path,
                     const char* initializer_function_name);
 
 /**
- * Deallocate all instances of a given component,
- * unregister a component in a component manager,
- * and free all component resources using
- * <code>Free</code> function. If the component
- * is loaded from a dynamic library and no
- * components are using the library, then unload
+ * Deallocate all instances of a given component, unregister a component in a 
+ * component manager, and free all component resources using
+ * <code>Free</code> function. If the component is loaded from a dynamic 
+ * library and no components are using the library, then unload
  * the dynamic library.
  *
  * This function is safe to call from multiple threads.
  *
- * @return APR_SUCCESS if successful, or a non-zero error code
+ * @return <code>APR_SUCCESS</code> if successful, or a non-zero error code.
  */
 int CmFreeComponent(const char* component_name);
 

Modified: harmony/enhanced/drlvm/trunk/vm/include/interpreter_exports.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/include/interpreter_exports.h?view=diff&rev=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/include/interpreter_exports.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/include/interpreter_exports.h Sun Jan 14 10:13:53 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,46 +14,12 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
-/** 
- * @author Ivan Volosyuk
- * @version $Revision: 1.1.2.1.4.3 $
- */  
+
 #ifndef _INTERPRETER_EXPORTS_H_
 #define _INTERPRETER_EXPORTS_H_
 
 #include "open/types.h"
 #include "jvmti.h"
-
-typedef struct FrameHandle FrameHandle;
-
-typedef struct {
-    bool (*interpreter_st_get_frame) (unsigned target_depth, struct StackTraceFrame* stf);
-    void (*interpreter_st_get_trace) (class VM_thread *thread, unsigned* res_depth, struct StackTraceFrame** stfs);
-    void (*interpreter_enumerate_thread) (class VM_thread *thread);
-
-    FrameHandle* (*interpreter_get_last_frame) (class VM_thread *thread);
-    FrameHandle* (*interpreter_get_prev_frame) (FrameHandle* frame);
-	// 'end' is not inclusive
-    bool (*is_frame_in_native_frame) (struct FrameHandle* frame, void* begin, void* end);
-
-    void (*interpreter_ti_enumerate_thread) (jvmtiEnv*, class VM_thread *thread);
-
-#ifdef _IPF_
-    uint64* (*interpreter_get_stacked_register_address) (uint64* bsp, unsigned reg);
-#endif
-
-    jvmtiError (*interpreter_ti_getFrameLocation) ( jvmtiEnv*, class VM_thread*,
-            int, struct _jmethodID * *, int64 *);
-    jvmtiError (*interpreter_ti_getLocal32) ( jvmtiEnv*, class VM_thread*, int, int, int *);
-    jvmtiError (*interpreter_ti_getLocal64) ( jvmtiEnv*, class VM_thread*, int, int, int64 *);
-    jvmtiError (*interpreter_ti_getObject) ( jvmtiEnv*, class VM_thread*, int, int, struct _jobject * *);
-    jvmtiError (*interpreter_ti_getStackTrace) (jvmtiEnv*, class VM_thread*, int, int, jvmtiFrameInfo*, int *);
-    jvmtiError (*interpreter_ti_get_frame_count) ( jvmtiEnv*, class VM_thread*, int *);
-    jvmtiError (*interpreter_ti_setLocal32) ( jvmtiEnv*, class VM_thread*, int, int, int);
-    jvmtiError (*interpreter_ti_setLocal64) ( jvmtiEnv*, class VM_thread*, int, int, int64);
-    jvmtiError (*interpreter_ti_setObject) ( jvmtiEnv*, class VM_thread*, int, int, struct _jobject *);
-    unsigned int (*interpreter_st_get_interrupted_method_native_bit) (class VM_thread *);
-
     // Open interfaces part begins
 
     /**
@@ -61,8 +27,8 @@
      * that atleast one of jvmtiEnv's enabled the event or the event was
      * disabled in all enviroments.
      *
-     * @param event_type -  jvmti to enable / disable
-     * @param enable - enable or disable the events in exe.
+     * @param event_type  -  jvmti to enable / disable
+     * @param enable      - enable or disable the events in exe.
      */
     void (*interpreter_ti_set_notification_mode)(jvmtiEvent event_type, bool enable);
 
@@ -70,22 +36,24 @@
      * Set breakpoint in place identified by method and location.
      * No more then one breakpoint will be set at any specific place. Handling
      * for multiple jvmti environments is done by jvmti framework.
-     * @return bytecode has been replaced by instrumentation
+	 *
+     * @return Bytecode has been replaced by instrumentation.
      */
     jbyte (*interpreter_ti_set_breakpoint)(jmethodID method, jlocation location);
 
     /**
      * Clear breakpoint in place identified by method and location.
-     * Replaced bytecode (returned by interpreter_ti_set_breakpoint(..)
+     * Replaced bytecode (returned by <code>interpreter_ti_set_breakpoint(..)</code>)
      * is also passed as a parameter.
      */
     void (*interpreter_ti_clear_breakpoint)(jmethodID method, jlocation location, jbyte saved);
 
     /**
      * Set callback to notify JVMTI about frame pop event.
-     * @return JVMTI_ERROR_NONE - successfully added notification.
-     *         JVMTI_ERROR_OPAQUE_FRAME - frame is native.
-     *         JVMTI_ERROR_NO_MORE_FRAMES - depth too large.
+	 *
+     * @return JVMTI_ERROR_NONE           - successfully added notification<br>
+     *         JVMTI_ERROR_OPAQUE_FRAME   - frame is native<br>
+     *         JVMTI_ERROR_NO_MORE_FRAMES - depth too large<br>
      */
     jvmtiError (*interpreter_ti_notify_frame_pop) (jvmtiEnv*,
                                                    VM_thread *thread,
@@ -98,6 +66,38 @@
 } Interpreter;
 
 VMEXPORT Interpreter *interpreter_table();
+
+typedef struct FrameHandle FrameHandle;
+
+typedef struct {
+    bool (*interpreter_st_get_frame) (unsigned target_depth, struct StackTraceFrame* stf);
+    void (*interpreter_st_get_trace) (class VM_thread *thread, unsigned* res_depth, struct StackTraceFrame** stfs);
+    void (*interpreter_enumerate_thread) (class VM_thread *thread);
+
+    FrameHandle* (*interpreter_get_last_frame) (class VM_thread *thread);
+    FrameHandle* (*interpreter_get_prev_frame) (FrameHandle* frame);
+	// 'end' is not inclusive
+    bool (*is_frame_in_native_frame) (struct FrameHandle* frame, void* begin, void* end);
+
+    void (*interpreter_ti_enumerate_thread) (jvmtiEnv*, class VM_thread *thread);
+
+#ifdef _IPF_
+    uint64* (*interpreter_get_stacked_register_address) (uint64* bsp, unsigned reg);
+#endif
+
+    jvmtiError (*interpreter_ti_getFrameLocation) ( jvmtiEnv*, class VM_thread*,
+            int, struct _jmethodID * *, int64 *);
+    jvmtiError (*interpreter_ti_getLocal32) ( jvmtiEnv*, class VM_thread*, int, int, int *);
+    jvmtiError (*interpreter_ti_getLocal64) ( jvmtiEnv*, class VM_thread*, int, int, int64 *);
+    jvmtiError (*interpreter_ti_getObject) ( jvmtiEnv*, class VM_thread*, int, int, struct _jobject * *);
+    jvmtiError (*interpreter_ti_getStackTrace) (jvmtiEnv*, class VM_thread*, int, int, jvmtiFrameInfo*, int *);
+    jvmtiError (*interpreter_ti_get_frame_count) ( jvmtiEnv*, class VM_thread*, int *);
+    jvmtiError (*interpreter_ti_setLocal32) ( jvmtiEnv*, class VM_thread*, int, int, int);
+    jvmtiError (*interpreter_ti_setLocal64) ( jvmtiEnv*, class VM_thread*, int, int, int64);
+    jvmtiError (*interpreter_ti_setObject) ( jvmtiEnv*, class VM_thread*, int, int, struct _jobject *);
+    unsigned int (*interpreter_st_get_interrupted_method_native_bit) (class VM_thread *);
+
+
 
 #ifdef BUILDING_VM
 extern Interpreter interpreter;

Modified: harmony/enhanced/drlvm/trunk/vm/include/jit_import.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/include/jit_import.h?view=diff&rev=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/include/jit_import.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/include/jit_import.h Sun Jan 14 10:13:53 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,15 +14,10 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
-/** 
- * @author Intel, Alexei Fedotov
- * @version $Revision: 1.1.2.1.2.1.2.3 $
- */  
-
 
-//
-// These are the functions that a JIT built as a DLL may call.
-//
+/**
+ * These are the functions that a JIT built as a DLL may call.
+ */
 
 #ifndef _JIT_IMPORT_H
 #define _JIT_IMPORT_H
@@ -41,79 +36,108 @@
 
 typedef void *Method_Iterator;
 
+/** 
+ * @name Direct call-related functions
+ */
+//@{
 
-
-///////////////////////////////////////////////////////
-// begin direct call-related functions.
-
-// These functions allow a JIT to be notified whenever a VM data structure changes that 
-// would require code patching or recompilation. 
-
-// Called by a JIT in order to be notified whenever the given class (or any of its subclasses?) 
-// is extended. The callback_data pointer will be passed back to the JIT during the callback. 
-// The callback function is JIT_extended_class_callback.
+/**
+ * These functions allow a JIT to be notified whenever a VM data structure changes that 
+ * would require code patching or recompilation. 
+ *
+ * Called by a JIT in order to be notified whenever the given class (or any of 
+ * its subclasses?) is extended. The <code>callback_data</code> pointer will 
+ * be passed back to the JIT during the callback. The callback function is 
+ * <code>JIT_extended_class_callback</code>.
+ */
 VMEXPORT void vm_register_jit_extended_class_callback(JIT_Handle jit, Class_Handle clss, 
                                                         void *callback_data);
 
-// Called by a JIT in order to be notified whenever the given method is overridden by a newly 
-// loaded class. The callback_data pointer will be passed back to the JIT during the callback.  
-// The callback function is JIT_overridden_method_callback.
+/**
+ * Called by a JIT in order to be notified whenever the given method is 
+ * overridden by a newly loaded class. The <code>callback_data</code> pointer 
+ * will be passed back to the JIT during the callback. The callback function is 
+ * <code>JIT_overridden_method_callback</code>.
+ */
 VMEXPORT void vm_register_jit_overridden_method_callback(JIT_Handle jit, Method_Handle method,
                                                            void *callback_data);
 
-// Called by a JIT in order to be notified whenever the vtable entries for the given method 
-// are changed. This could happen, e.g., when a method is first compiled, or when it is 
-// recompiled.  The callback_data pointer will be passed back to the JIT during the callback.  
-// The callback method is JIT_recompiled_method_callback.
+/**
+ * Called by a JIT in order to be notified whenever the vtable entries for the 
+ * given method are changed. This could happen, e.g., when a method is first 
+ * compiled, or when it is recompiled. The <code>callback_data</code> pointer 
+ * will be passed back to the JIT during the callback. The callback method is 
+ * <code>JIT_recompiled_method_callback</code>.
+ */
 VMEXPORT void vm_register_jit_recompiled_method_callback(JIT_Handle jit, Method_Handle method,
                                                            void *callback_data);
 
-// Called by a JIT to have the VM replace a section of executable code in a thread-safe fashion.  
-// This function does not synchronize the I- or D-caches. It may be a lot cheaper to batch up
-// the patch requests, so we may need to extend this interface.
+/**
+ * Called by a JIT to have the VM replace a section of executable code in a 
+ * thread-safe fashion. This function does not synchronize the I- or D-caches. 
+ * It may be a lot cheaper to batch up the patch requests, so we may need to 
+ * extend this interface.
+ */
 VMEXPORT void vm_patch_code_block(Byte *code_block, Byte *new_code, size_t size);
 
-// Called by a JIT to have the VM recompile a method using the specified JIT. After 
-// recompilation, the corresponding vtable entries will be updated, and the necessary 
-// callbacks to JIT_recompiled_method_callback will be made. It is a requirement that 
-// the method has not already been compiled by the given JIT; this means that multiple 
-// instances of a JIT may need to be active at the same time. (See vm_clone_jit.)
-VMEXPORT void vm_recompile_method(JIT_Handle jit, Method_Handle method);
+/**
+ * Called by a JIT to have the VM recompile a method using the specified JIT. After 
+ * recompilation, the corresponding vtable entries will be updated, and the necessary 
+ * callbacks to <code>JIT_recompiled_method_callback</code> will be made. It is a 
+ * requirement that the method has not already been compiled by the given JIT; 
+ * this means that multiple instances of a JIT may need to be active at the same time. 
+ * 
+ * @sa vm_clone_jit
+ */
 
-// Called by a JIT to have VM synchronously (in the same thread) compile a method
-// It is a requirement that JIT calls this routine only during compilation of other method,
-// not during run-time.
-VMEXPORT JIT_Result vm_compile_method(JIT_Handle jit, Method_Handle method);
+VMEXPORT void vm_recompile_method(JIT_Handle jit, Method_Handle method);
 
-// Creates and returns a new instance of the given JIT. The new JIT's implementation of
-// JIT_init_with_data is invoked with the jit_data argument.
-VMEXPORT JIT_Handle vm_clone_jit(JIT_Handle jit, void *jit_data);
+/** 
+ * Called by a JIT to have VM synchronously (in the same thread) compile a method
+ * It is a requirement that JIT calls this routine only during compilation of 
+ * other method, not during run-time.
+ */
 
-// end direct call-related functions.
-///////////////////////////////////////////////////////
+VMEXPORT JIT_Result vm_compile_method(JIT_Handle jit, Method_Handle method);
 
+/** 
+ * Creates and returns a new instance of the given JIT. The new JIT's 
+ * implementation of <code>JIT_init_with_data</code> is invoked with the 
+ * <code>jit_data</code> argument.
+ */
 
+VMEXPORT JIT_Handle vm_clone_jit(JIT_Handle jit, void *jit_data);
 
-///////////////////////////////////////////////////////
-// begin exception-related compile-time functions.
+//@}
+/** @name Exception-related compile-time functions
+ */
+//@{
 
+/**
+ * @return The number of exception handlers defined for this method in the
+ *         bytecodes.
+ */
 
-// Return the number of exception handlers defined for this method in the
-// bytecodes.
 VMEXPORT unsigned method_get_num_handlers(Method_Handle method);
 
-//deprecated: see method_get_handler_info
-//VMEXPORT void method_get_handler_info_full(Method_Handle method,
-                                            //unsigned handler_id,
-                                            //unsigned *begin_offset,
-                                            //unsigned *end_offset,
-                                            //unsigned *handler_offset,
-                                            //unsigned *handler_len,
-                                            //unsigned *filter_offset,
-                                            //unsigned *handler_class_index);
-
-// This is a simpler version of method_get_handler_info_full() that works
-// only for JVM.
+/**
+ * Deprecated.
+ * 
+ * @sa method_get_handler_info
+ */
+VMEXPORT void method_get_handler_info_full(Method_Handle method,
+                                            unsigned handler_id,
+                                            unsigned *begin_offset,
+                                            unsigned *end_offset,
+                                            unsigned *handler_offset,
+                                            unsigned *handler_len,
+                                            unsigned *filter_offset,
+                                            unsigned *handler_class_index);
+
+/**
+ * This is a simpler version of method_get_handler_info_full() that works
+ * only for JVM.
+ */
 VMEXPORT void method_get_handler_info(Method_Handle method,
                                        unsigned handler_id,
                                        unsigned *begin_offset,
@@ -121,30 +145,50 @@
                                        unsigned *handler_offset,
                                        unsigned *handler_class_index);
 
-// deprecated: For Java methods, it always returns FALSE since JVM
-// handlers do not have a finally clause.
-//VMEXPORT Boolean method_handler_has_finally(Method_Handle method,
-//                                           unsigned handler_id);
-
-// deprecated:  For Java methods, it always returns FALSE since JVM
-// handlers do not have a filters.
-//VMEXPORT Boolean method_handler_has_filter(Method_Handle method,
-//                                            unsigned handler_id);
-
-// deprecated:  For Java methods, it always returns FALSE since JVM
-// handlers do not have a fault clause.
-//VMEXPORT Boolean method_handler_has_fault(Method_Handle method,
-//                                           unsigned handler_id);
-
-// Set the number of exception handlers in the code generated by the JIT j
-// for a given method.  The JIT must then call method_set_target_handler_info()
-// for each of the num_handlers exception handlers.
+/**
+ * Deprecated.
+ *
+ * @return For Java methods, it always returns <code>FALSE</code> since JVM
+ *         handlers do not have a finally clause.
+ */
+VMEXPORT Boolean method_handler_has_finally(Method_Handle method,
+                                           unsigned handler_id);
+
+/**
+ * Deprecated.
+ * 
+ * @return For Java methods, it always returns <code>FALSE</code> since JVM
+ * handlers do not have a filters.
+ */
+
+VMEXPORT Boolean method_handler_has_filter(Method_Handle method,
+                                            unsigned handler_id);
+
+/**
+ * Deprecated.
+ * 
+ * @return For Java methods, it always returns <code>FALSE</code> since JVM
+ *         handlers do not have a fault clause.
+ */
+
+VMEXPORT Boolean method_handler_has_fault(Method_Handle method,
+                                           unsigned handler_id);
+
+/**
+ * Set the number of exception handlers in the code generated by the JIT 
+ * <code>j</code> for a given method. The JIT must then 
+ * call method_set_target_handler_info()
+ * for each of the num_handlers exception handlers.
+ */
+
 VMEXPORT void method_set_num_target_handlers(Method_Handle method,
                                               JIT_Handle j,
                                               unsigned num_handlers);
 
-// Set the information about an exception handler in the code generated by
-// the JIT.
+/**
+ * Set the information about an exception handler in the code generated by
+ * the JIT.
+ */
 VMEXPORT void method_set_target_handler_info(Method_Handle method,
                                               JIT_Handle j,
                                               unsigned      eh_number,
@@ -154,101 +198,139 @@
                                               Class_Handle  catch_cl,
                                               Boolean       exc_obj_is_dead);
 
-// end exception-related compile-time functions.
-///////////////////////////////////////////////////////
-
-
 
-///////////////////////////////////////////////////////
-// begin method-related functions.
+//@}
+/** @name Method-related functions
+ */
+//@{
 
+/**
+ * @ingroup bytecodes
+ */
 ///////////////////////////////////////////////////////
 // begin method-related functions: bytecodes
+///////////////////////////////////
 
-// Get a pointer to the buffer containing the bytecodes for this method.
-// Bytecodes are either JVML instructions or CIL instructions.
-VMEXPORT const Byte *method_get_byte_code_addr(Method_Handle method);
+/**
+ * Get a pointer to the buffer containing the bytecodes for this method.
+ * Bytecodes are either JVML instructions or CIL instructions.
+ */
+ VMEXPORT const Byte *method_get_byte_code_addr(Method_Handle method);
+
+/**
+ * Size if the buffer returned by method_get_byte_code_addr().
+ */
 
-// Size if the buffer returned by method_get_byte_code_addr().
 VMEXPORT size_t method_get_byte_code_size(Method_Handle method);
 
-// Maximum depth of the evaluation stack in this method.
-VMEXPORT unsigned method_get_max_stack(Method_Handle method);
+/**
+ * Maximum depth of the evaluation stack in this method.
+ */
 
+VMEXPORT unsigned method_get_max_stack(Method_Handle method);
+//////////////////////////
 // end method-related functions: bytecodes
 ///////////////////////////////////////////////////////
 
 
 ///////////////////////////////////////////////////////
 // begin method-related functions: compiled code
+////////////////////////////
+/**
+ * @return The address where the code pointer for a given method is.
+ * 
+ * A simple JIT that doesn't support recompilation (see e.g. 
+ * <code>vm_register_jit_recompiled_method_callback</code>) can only 
+ * generate code with indirect branches through the address provided 
+ * by method_get_indirect_address().
+ */
 
-// Return the address where the code pointer for a given method is.
-// A simple JIT that doesn't support recompilation
-// (see e.g. vm_register_jit_recompiled_method_callback) can only generate
-// code with indirect branches through the address provided by
-// method_get_indirect_address().
 VMEXPORT void *method_get_indirect_address(Method_Handle method);
 
-// Return the offset in bytes from the start of the vtable to the entry for
-// a given method.
+/**
+ * @return The offset in bytes from the start of the vtable to the entry for
+ *         a given method.
+ */
 VMEXPORT unsigned method_get_offset(Method_Handle method);
-
+///////////////////////////
 // end method-related functions: compiled code
 ///////////////////////////////////////////////////////
 
 
 ///////////////////////////////////////////////////////
 // begin method memory allocation-related functions.
+/////////////////////////////////
+
+/**
+ * Allocate the "read-write" data block for this method. This memory block
+ * cannot be retrieved later. The intention is to use the data block for data
+ * that may be needed during the program execution (e.g. tables for
+ * switch statements).
+ *
+ * Separation of data allocated by method_allocate_data_block() and
+ * method_allocate_info_block() may help improve locality of 
+ * references to data accessed during execution of compiled code and data 
+ * accessed during stack uwinding.
+ *
+ * @sa method_allocate_info_block
+ */
 
-// Allocate the "read-write" data block for this method.  This memory block
-// cannot be retrieved later.  The intention is to use the data block for data
-// that may be needed during the program execution (e.g. tables for
-// switch statements).
-//
-// Separation of data allocated by method_allocate_data_block() and
-// method_allocate_info_block() may help improve locality of references to data
-// accessed during execution of compiled code and data accessed during
-// stack uwinding.
-//
-// (See method_allocate_info_block).
 VMEXPORT Byte *method_allocate_data_block(Method_Handle method,
                                            JIT_Handle j,
                                            size_t size,
                                            size_t alignment);
 
-// Allocated a "read-only" data block.
-//
-// (? 20030314) This function is deprecated.  In all new code, use
-// method_allocate_data_block() only.  At some point, we will revisit
-// this interface to have more control over the layout of various
-// memory blocks allocated by the VM.
+/**
+ * Allocated a "read-only" data block.
+ *
+ * (? 20030314) This function is deprecated. In all new code, use
+ * method_allocate_data_block() only. At some point, we 
+ * will revisit this interface to have more control over the layout 
+ * of various memory blocks allocated by the VM.
+ */
+
 VMEXPORT Byte *method_allocate_jit_data_block(Method_Handle method,
                                                JIT_Handle j,
                                                size_t size,
                                                size_t alignment);
 
 
-// The following values should be used as the "heat" argument for calls like
-// method_allocate_code_block() or malloc_fixed_code_for_jit().
+/**
+ * The following values should be used as the "heat" argument for 
+ * calls like method_allocate_code_block() or 
+ * <code>malloc_fixed_code_for_jit()</code>.
+ */
+
 #define CODE_BLOCK_HEAT_COLD 0
 #define CODE_BLOCK_HEAT_DEFAULT 1
 #define CODE_BLOCK_HEAT_MAX 20
 
-// See method_allocate_code_block.
+/**
+ * @sa method_allocate_code_block
+ */
+
 typedef enum Code_Allocation_ActionEnum {
     CAA_Simulate,
     CAA_Allocate
 }Code_Allocation_Action;
  
 
-// This function allows allocation of multiple chunks of code with different
-// heat values.  The JIT is responsible for specifying ids that are unique
-// within the same method.
-// The first instruction of the chunk with id=0 is the entry point of the method.
-// DEPRECATED: If the CAA_Allocate argument is specified, memory is allocated and a pointer
-// to it is returned.  If the CAA_Simulate argument is specified, no memory is
-// allocated - the same as pass parameter size = 0 - function returns only current 
-// address for allocation in pool but no memory is allocated.  
+/**
+ * This function allows allocation of multiple chunks of code with different
+ * heat values. The JIT is responsible for specifying ids that are unique
+ * within the same method.
+ * The first instruction of the chunk with <code>id=0</code> is the entry point 
+ * of the method.
+ * 
+ * Deprecated.
+ *
+ * @return If the <code>CAA_Allocate</code> argument is specified, memory is 
+ *         allocated and a pointer to it is returned. If the 
+ *         <code>CAA_Simulate</code> argument is specified, no memory is
+ *         allocated - the same as pass parameter size = 0 - function returns 
+ *         only current address for allocation in pool but no memory is allocated.  
+ */
+
 VMEXPORT Byte *
 method_allocate_code_block(Method_Handle m,
                            JIT_Handle j,
@@ -263,209 +345,288 @@
 method_set_relocatable(Method_Handle m, JIT_Handle j, NativeCodePtr code_address, Boolean is_relocatable);
 
 
-// Allocate an info block for this method.  An info block can be later
-// retrieved by the JIT.  The JIT may for instance store GC maps for
-// root set enumeration and stack unwinding in the onfo block.
-// (See method_allocate_data_block)
+/**
+ * Allocate an info block for this method. An info block can be later
+ * retrieved by the JIT. The JIT may for instance store GC maps for
+ * root set enumeration and stack unwinding in the onfo block.
+ *
+ * @sa method_allocate_data_block
+ */
 VMEXPORT Byte *method_allocate_info_block(Method_Handle method,
                                            JIT_Handle j,
                                            size_t size);
 
 
-// Retrieve the memory block allocated earlier by method_allocate_code_block().
-// A pair <method, jit> uniquely identifies a code block.
+/**
+ * Retrieve the memory block allocated earlier by 
+ * method_allocate_code_block().
+ * A pair <code><method, jit></code> uniquely identifies a code block.
+ */
+
 VMEXPORT Byte *method_get_code_block_addr_jit(Method_Handle method,
                                                JIT_Handle j);
 
-// Get the size of the memory block allocated earlier by
-// method_allocate_code_block().
+/**
+ * Get the size of the memory block allocated earlier by
+ * method_allocate_code_block().
+ */
+
 VMEXPORT unsigned method_get_code_block_size_jit(Method_Handle method,
                                                   JIT_Handle j);
 
-// Retrieve the memory block allocated earlier by
-// method_allocate_code_block().
-// A triple <method, jit, id> uniquely identifies a code block.
+/**
+ * Retrieve the memory block allocated earlier by
+ * method_allocate_code_block().
+ * A triple <code><method, jit, id></code> uniquely identifies a 
+ * code block.
+ */
+
 VMEXPORT Byte *method_get_code_block_addr_jit_new(Method_Handle method,
                                                    JIT_Handle j,
                                                    int id);
 
-// Get the size of the memory block allocated earlier by
-// method_allocate_code_block().
-// A triple <method, jit, id> uniquely identifies a code block.
+/**
+ * Get the size of the memory block allocated earlier by
+ * method_allocate_code_block().
+ * A triple <code><method, jit, id></code> uniquely identifies a 
+ * code block.
+ */
+
 VMEXPORT unsigned method_get_code_block_size_jit_new(Method_Handle method,
                                                       JIT_Handle j,
                                                       int id);
 
-// Retrieve the memory block allocated earlier by method_allocate_info_block().
-// A pair <method, jit> uniquely identifies a JIT info block.
+/**
+ * Retrieve the memory block allocated earlier by 
+ * method_allocate_info_block().
+ * A pair <code><method, jit></code> uniquely identifies a JIT info block.
+ */ 
+
 VMEXPORT Byte *method_get_info_block_jit(Method_Handle method,
                                           JIT_Handle j);
 
-// Get the size of the memory block allocated earlier by
-// method_allocate_info_block().
+/**
+ * Get the size of the memory block allocated earlier by
+ * method_allocate_info_block().
+ */
+
 VMEXPORT unsigned method_get_info_block_size_jit(Method_Handle method,
                                                   JIT_Handle j);
 
 ///////////////////////////////////////////////////////
 // begin functions for iterating over methods compiled by a given JIT.
+/////////////////////////////////////
 
 #define METHOD_JIT_ITER_END 0
 
-// Here are the obvious three functions to iterate over all methods
-// compiled by a given JIT.
+/**
+ * Here are the obvious three functions to iterate over all methods
+ * compiled by a given JIT.
+ */
+
 VMEXPORT Method_Iterator method_get_first_method_jit(JIT_Handle j);
 VMEXPORT Method_Iterator method_get_next_method_jit(Method_Iterator mi);
 VMEXPORT Method_Handle   method_get_method_jit(Method_Iterator mi);
 
-
+/////////////////////////////////////////
 // end functions for iterating over methods compiled by a given JIT.
 ///////////////////////////////////////////////////////
-
+//////////////////////////////
 // end method-related functions.
 ///////////////////////////////////////////////////////
 
+/** 
+ * @name Resolution-related functions
+ */
+//@{
 
+/**
+ * Resolve a class.
+ *
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ */
 
-///////////////////////////////////////////////////////
-// begin resolution-related functions.
-
-
-// Resolve a class.
-// The 'idx' parameter is interpreted as a constant pool index for JVM. 
 VMEXPORT Class_Handle 
 vm_resolve_class(Compile_Handle h, Class_Handle ch, unsigned idx);
 
-// Resolve a class and provide error checking if the class cannot have an
-// instance, i.e. it is abstract (or is an interface class).
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
+/**
+ * Resolve a class and provide error checking if the class cannot have an
+ * instance, i.e. it is abstract (or is an interface class).
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ */
+
 VMEXPORT Class_Handle 
 vm_resolve_class_new(Compile_Handle h, Class_Handle c, unsigned index);
 
-// Resolve a reference to a non-static field.
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
-// Used for getfield and putfield in JVM.
+/**
+ * Resolve a reference to a non-static field.
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ * Used for getfield and putfield in JVM.
+ */
+
 VMEXPORT Field_Handle 
 resolve_nonstatic_field(Compile_Handle h, Class_Handle ch, unsigned idx, unsigned putfield);
 
-// Resolve constant pool reference to a static field
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
-// Used for getstatic and putstatic in JVM.
+/**
+ * Resolve constant pool reference to a static field.
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ * Used for getstatic and putstatic in JVM.
+ */
+
 VMEXPORT Field_Handle
 resolve_static_field(Compile_Handle h, Class_Handle ch, unsigned idx, unsigned putfield);
 
-// Resolve a method.
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
+/**
+ * Resolve a method.
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ */ 
 VMEXPORT Method_Handle 
 resolve_method(Compile_Handle h, Class_Handle ch, unsigned idx);
 
 
-// Resolve a method.  Same as resolve_method() but the VM checks that the
-// method can be used for a virtual dispatch.
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
+/**
+ * Resolve a method. Same as resolve_method() but the VM checks 
+ * that the method can be used for a virtual dispatch.
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ */
+
 VMEXPORT Method_Handle 
 resolve_virtual_method(Compile_Handle h, Class_Handle c, unsigned index);
 
-// Resolve a method.  Same as resolve_method() but the VM checks that the
-// method is static (i.e. it is not an instance method).
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
+/**
+ * Resolve a method. Same as resolve_method() but the VM checks 
+ * that the method is static (i.e. it is not an instance method).
+ * The <code>idx</code> parameter is interpreted as a constant pool index for 
+ * JVM.
+ */
+
 VMEXPORT Method_Handle 
 resolve_static_method(Compile_Handle h, Class_Handle c, unsigned index);
 
-// Resolve a method.  Same as resolve_method() but the VM checks that the
-// method is declared in an interface type.
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
+/** 
+ * Resolve a method. Same as resolve_method() but the VM checks 
+ * that the method is declared in an interface type.
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ */
+
 VMEXPORT Method_Handle 
 resolve_interface_method(Compile_Handle h, Class_Handle c, unsigned index);
 
+//@}
+/** @name Miscellaneous functions
+ */
+//@{
 
-// end resolution-related functions.
-///////////////////////////////////////////////////////
+/**
+ * @return A UTF8 representation of a string declared in a class.
+ *
+ * The <code>idx</code> parameter is interpreted as a constant pool 
+ * index for JVM.
+ * <code>class_get_const_string</code> is generally only for JIT internal use,
+ * e.g. printing a string pool constant in a bytecode disassembler.
+ * The resulting const char* should of course not be inserted into
+ * the jitted code.
+ */
 
+VMEXPORT const char *class_get_const_string(Class_Handle ch, unsigned idx);
 
-/////////////////////////////////////////////////////////////////
-// begin miscellaneous functions.
 
+/**
+ * @return The address where the interned version of the string
+ *         is stored. 
+ * 
+ * Calling <code>class_get_const_string_intern_addr</code> has
+ * a side-effect of interning the string, so that the JIT can
+ * load a reference to the interned string without checking if
+ * it is null.
+ */
 
-// Returns a UTF8 representation of a string declared in a class.
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
-// class_get_const_string is generally only for JIT internal use,
-// e.g. printing a string pool constant in a bytecode disassembler.
-// The resulting const char* should of course not be inserted into
-// the jitted code.
-VMEXPORT const char *class_get_const_string(Class_Handle ch, unsigned idx);
+VMEXPORT void *class_get_const_string_intern_addr(Class_Handle ch, unsigned idx);
 
+/**
+ * @return The type of a compile-time constant.
+ *
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ */
 
-// Returns the address where the interned version of the string
-// is stored.  Calling class_get_const_string_intern_addr has
-// a side-effect of interning the string, so that the JIT can
-// load a reference to the interned string without checking if
-// it is null.
-VMEXPORT void *class_get_const_string_intern_addr(Class_Handle ch, unsigned idx);
+ VMEXPORT VM_Data_Type class_get_const_type(Class_Handle ch, unsigned idx);
 
-// Returns the type of a compile-time constant.
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
-VMEXPORT VM_Data_Type class_get_const_type(Class_Handle ch, unsigned idx);
+/**
+ * @return The signature for field or (interface) method in constant pool entry.
+ * The <code>cp_index</code> parameter is interpreted as a constant pool index 
+ * for JVM.
+ */
 
-// Returns the signature for field or (interface) method in constant pool entry
-// The 'cp_index' parameter is interpreted as a constant pool index for JVM.
 VMEXPORT const char* class_get_cp_entry_signature(Class_Handle src_class,
                                                   unsigned short cp_index);
 
-// Returns the data type for field in constant pool entry
-// The 'cp_index' parameter is interpreted as a constant pool index for JVM.
+/**
+ * @return The data type for field in constant pool entry.
+ * 
+ * The <code>cp_index</code> parameter is interpreted as a constant pool index 
+ * for JVM.
+ */
+
 VMEXPORT VM_Data_Type class_get_cp_field_type(Class_Handle src_class,
                                               unsigned short cp_index);
 
-// Returns a pointer to the location where the constant is stored.
-// The 'idx' parameter is interpreted as a constant pool index for JVM.
-// This function shouldn't be called for constant strings.  
-// Instead, either:
-//  1. the jitted code should get the string object at runtime by calling
-//     VM_RT_LDC_STRING, or
-//  2. use class_get_const_string_intern_addr().
-VMEXPORT const void  *class_get_const_addr(Class_Handle ch, unsigned idx);
-
-// Returns the JIT handle for a the current compilation.  The VM keeps track
-// of the JIT that was invoked for and can return this value at any point
-// during the compilation.
-// (? 20030314) Does the "method_" prefix really make sense here?  Perhaps
-// we should rename this function?
-VMEXPORT JIT_Handle method_get_JIT_id(Compile_Handle h);
-
-
-// end miscellaneous functions.
-/////////////////////////////////////////////////////////////////
-
+/**
+ * @return A pointer to the location where the constant is stored.
+ *
+ * The <code>idx</code> parameter is interpreted as a constant pool index for JVM.
+ * This function shouldn't be called for constant strings. Instead, either:<br>
+ * <ul><li>The jitted code should get the string object at runtime by calling
+ *         <code>VM_RT_LDC_STRING</code>, or
+ *     <li>Use class_get_const_string_intern_addr().
+ *</ul>
+ */
 
+VMEXPORT const void  *class_get_const_addr(Class_Handle ch, unsigned idx);
 
-/////////////////////////////////////////////////////////////////
-// begin experimental functions.
-//
-// These functions are currently not part of the official interface,
-// although they may be promoted in some form in the future.
+/**
+ * @return The JIT handle for a the current compilation. 
+ *
+ * The VM keeps track of the JIT that was invoked for and can return this value at 
+ * any point during the compilation.
+ * (? 20030314) Does the <code>method_</code> prefix really make sense here? 
+ * Perhaps we should rename this function?
+ */
 
+VMEXPORT JIT_Handle method_get_JIT_id(Compile_Handle h);
 
+//@}
+/** @name Experimental functions
+ */
+//@{
 
-// Returns TRUE if the VM's functionality for monitorenter and monitorexit
-// may be inlined by the JIT, and FALSE if not.  If TRUE is returned, then
-// the output arguments will be filled in with the synchronization parameters.
-// The parameters are the following:
-//   thread_id_register: the register number that holds the thread ID which
-//                       is used to identify the locking thread
-//   sync_header_offset: the offset in bytes of the synchronization header
-//                       from the start of the object
-//   sync_header_width:  the width in bytes of the synchronization header
-//   lock_owner_offset:  the offset in bytes of the lock owner field from
-//                       the start of the object
-//   lock_owner_width:   the width in bytes of the lock owner field in the
-//                       synchronization header
-//   jit_clears_ccv:     TRUE if the JIT-generated code needs to clear the
-//                       ar.ccv register, FALSE if the VM ensures it is
-//                       already cleared
-//
-// Note that this is useful only for monitorenter/monitorexit, but not
-// monitorenter_static/monitorexit_static, since the JIT doesn't know how to
-// map the class_handle to an object.
+/**
+ * These functions are currently not part of the official interface,
+ * although they may be promoted in some form in the future.
+ *
+ * @return <code>TRUE</code> if the VM's functionality for monitorenter 
+ *         and monitorexit may be inlined by the JIT; otherwise, <code>FALSE</code>.
+ *         
+ * If <code>TRUE</code> is returned, then the output arguments will be 
+ * filled in with the synchronization parameters.
+ *
+ * @param thread_id_register  - the register number that holds the thread ID which
+ *                              is used to identify the locking thread
+ * @param sync_header_offset  - the offset in bytes of the synchronization header
+ *                              from the start of the object
+ * @param sync_header_width   - the width in bytes of the synchronization header
+ * @param lock_owner_offset   - the offset in bytes of the lock owner field from
+ *                              the start of the object
+ * @param lock_owner_width    - the width in bytes of the lock owner field in the
+ *                              synchronization header
+ * @param jit_clears_ccv      - <code>TRUE</code> if the JIT-generated code needs 
+ *                              to clear the <code>ar.ccv</code> register, 
+ *                              <code>FALSE</code> if the VM ensures it is 
+ *                              already cleared
+ *
+ * @note This is useful only for <code>monitorenter/monitorexit</code>, but not
+ *       <code>monitorenter_static/monitorexit_static</code>, since the JIT doesn't 
+ *       know how to map the <code>class_handle</code> to an object.
+ */
 VMEXPORT Boolean jit_may_inline_object_synchronization(unsigned *thread_id_register,
                                                         unsigned *sync_header_offset,
                                                         unsigned *sync_header_width,
@@ -482,10 +643,6 @@
 } CallingConvention;
 
 VMEXPORT CallingConvention vm_managed_calling_convention();
-
-// end experimental functions.
-/////////////////////////////////////////////////////////////////
-
 
 #ifdef __cplusplus
 }

Modified: harmony/enhanced/drlvm/trunk/vm/include/jit_import_rt.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/include/jit_import_rt.h?view=diff&rev=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/include/jit_import_rt.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/include/jit_import_rt.h Sun Jan 14 10:13:53 2007
@@ -14,15 +14,11 @@
  *  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 may call.
-//
+/**
+ * @file
+ * These are the functions that a JIT built as a DLL may call.
+ */
 
 #ifndef _JIT_IMPORT_RT_H
 #define _JIT_IMPORT_RT_H
@@ -34,38 +30,44 @@
 #ifdef __cplusplus
 extern "C" {
 #endif
-
-
-///////////////////////////////////////////////////////
-// begin root set enumeration functions.
-
-
-// Enumerate a root entry.  The argument is a pointer to the memory
-// location that contains a managed reference.  The GC may update
-// this location if the object pointed to has been moved during
-// collection.
+/**
+ * Begin root set enumeration functions.
+ *
+ * Enumerate a root entry. The argument is a pointer to the memory
+ * location that contains a managed reference. The GC may update
+ * this location if the object pointed to has been moved during
+ * collection.
+ */
 VMEXPORT void vm_enumerate_root_reference(Managed_Object_Handle *ref, Boolean is_pinned);
 
-// Resembles vm_enumerate_root_reference() but is passed the address of
-// a slot containing a compressed reference.
+/**
+ * Resembles vm_enumerate_root_reference(), but is passed the 
+ * address of a slot containing a compressed reference.
+ */
 VMEXPORT void vm_enumerate_compressed_root_reference(uint32 *ref, Boolean is_pinned);
 
-// Like vm_enumerate_root_reference() but the first argument points
-// to a location that contains a pointer to an inside of an object.
+/** 
+ * Like vm_enumerate_root_reference(), but the first argument 
+ * points to a location that contains a pointer to an inside of an object.
+ */
 VMEXPORT void vm_enumerate_root_interior_pointer(void **slot, int offset, Boolean is_pinned);
 
-// The JIT enumerates a managed pointer.  The pointer can be declared as
-// pinned.  The pointer can point to the managed heap or any other area
-// where data can be stored: stack or static fields.  It is the responsibility
-// of the runtime system to ignore pointers that are not in the managed heap.
+/** 
+ * The JIT enumerates a managed pointer. The pointer can be declared as
+ * pinned.  The pointer can point to the managed heap or any other area
+ * where data can be stored: stack or static fields. It is the responsibility
+ * of the runtime system to ignore pointers that are not in the managed heap.
+ */
 VMEXPORT void vm_enumerate_root_pointer(void **ptr, Boolean is_pinned);
 
 
-// end root set enumeration functions.
-///////////////////////////////////////////////////////
+/** 
+ * End root set enumeration functions.
+ */
 
-///////////////////////////////////////////////////////
-//enumerates alive references for owned monitor calculation
+/** 
+ * Enumerates alive references for owned monitor calculation.
+ */
 
 VMEXPORT void vm_check_if_monitor(void  **reference,
                                        void  **base_reference,

Modified: harmony/enhanced/drlvm/trunk/vm/include/jit_runtime_support.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/include/jit_runtime_support.h?view=diff&rev=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/include/jit_runtime_support.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/include/jit_runtime_support.h Sun Jan 14 10:13:53 2007
@@ -14,30 +14,23 @@
  *  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.2.4.4 $
- */  
-
-
-
 
 #ifndef _JIT_RUNTIME_SUPPORT_H_
 #define _JIT_RUNTIME_SUPPORT_H_
 
 #include "open/types.h"
 
-//
-// This is a complete set of functions used by the code generated by the JIT.
-// The address of a function is obtained from the VM by invoking the
-// function vm_get_rt_support_addr (see below).
-//
-
-// We should also note which exceptions can be thrown by each
-// of those function.
-
-// If changes are made to enum VM_RT_SUPPORT below, the list of JIT support functions in vm_stats.cpp must also be changed.
-
+/**
+ * This is a complete set of functions used by the code generated by the JIT.
+ * The address of a function is obtained from the VM by invoking the
+ * function <code>vm_get_rt_support_addr</code> (see below).
+ *
+ * We should also note which exceptions can be thrown by each
+ * of those function.
+ *
+ * If changes are made to enum <code>VM_RT_SUPPORT</code> below, the list of 
+ * JIT support functions in <code>vm_stats.cpp</code> must also be changed.
+ */
 
 #ifdef __cplusplus
 extern "C" {
@@ -46,378 +39,459 @@
 typedef
 enum VM_RT_SUPPORT {
 
-    //////////////////////////////////////////////////////////////////////////
-    // Object creation routines
-    //////////////////////////////////////////////////////////////////////////
+/**
+ * Object creation routines.
+ */
 
     VM_RT_NEW_RESOLVED_USING_VTABLE_AND_SIZE=100,
-    // Arguments:
-    //  - Size of the instance to be created
-    //  - Allocation_Handle for the class whose instance we want to create
-    // Return value:
-    //  - Reference to the new object
-    //
-    // Like VM_RT_NEW_VECTOR_USING_VTABLE, allocates a new object of a class, but also takes a
-    // size argument.  The size can be obtained using class_get_boxed_data_size(Class_Handle).
-    // This function should be used for classes which inherit the finalize method 
-    // of java.lang.Object.
+/**
+ * @param The parameters are the following:
+ *        \arg Size of the instance to be created
+ *        \arg <code>Allocation_Handle</code> for the class whose instance we want to create
+ * 
+ * @return Reference to the new object.
+ *
+ * Like <code>VM_RT_NEW_VECTOR_USING_VTABLE</code>, allocates a new object of 
+ * a class, but also takes a size argument. The size can be obtained using 
+ * class_get_boxed_data_size(Class_Handle).
+ * This function should be used for classes which inherit the finalize method 
+ * of <code>java.lang.Object</code>.
+ */
 
     VM_RT_NEW_VECTOR_USING_VTABLE=101,
-    // Arguments:
-    //  - Allocation_Handle for the vector class
-    //  - Vector length
-    // Return value:
-    //  - Reference to the new object
-    //
-    // Like VM_RT_NEW_VECTOR. creates a vector (zero-based, one dimensional array) of the given type,
-    // but takes a Allocation_Handle instead of a Class_Handle.
-
+/**   
+ * @param The parameters are the following:
+ *        \arg <code>Allocation_Handle</code> for the vector class
+ *        \arg Vector length
+ *
+ * @return Reference to the new object.
+ *
+ * Like <code>VM_RT_NEW_VECTOR</code> creates a vector 
+ * (zero-based, one dimensional array) of the given type,
+ * but takes a <code>Allocation_Handle</code> instead of a 
+ * <code>Class_Handle</code>.
+ */
     VM_RT_MULTIANEWARRAY_RESOLVED=102,
-    // There is a variable # of arguments:
-    //  - Class handle
-    //  - Number of dimensions
-    //  - Count_n
-    //  - ...
-    //  - Count_1
-    // Return value:
-    //  - Reference to the new object
-    //
-    // This is __cdecl function and the caller must pop the arguments.
-    // Create a multidimensional Java array
-    //
+ /**
+  * There is a variable # of arguments:
+  * \arg Class handle
+  * \arg Number of dimensions
+  * \arg Count_n
+  * \arg ...
+  * \arg Count_1
+  *
+  * @return Reference to the new object.
+  *
+  * This is <code>__cdecl</code> function and the caller must pop the arguments.
+  * Create a multidimensional Java array.
+  */
 
     VM_RT_LDC_STRING=103,
-    // Arguments:
-    //  - Const pool index pointing to a CONSTANT_Class.
-    //  - Class handle of the class owning the const pool
-    // Return value:
-    //  - Reference to the String object.
-    //
-    // Returns a reference to the const string represented by an entry in the
-    // const pool.
-
-
+/**
+ * @param The parameters are the following:
+ *        \arg Const pool index pointing to a CONSTANT_Class.
+ *        \arg Class handle of the class owning the const pool
+ *
+ * @return \arg Reference to the String object.
+ *         \arg Reference to the const string represented by an entry in the
+ *         const pool.
+ */
 
-    //////////////////////////////////////////////////////////////////////////
-    // Exception throwing routines
-    //////////////////////////////////////////////////////////////////////////
+/////
+// Exception throwing routines
+/////
 
     VM_RT_THROW=200,
-    // Arguments:
-    //  - Object reference
-    // Return value: none.
-    //
-    // The only argument is a reference to the exception to be thrown.
-    // Throw the exception without modifying the stack trace associated
-    // with the exception object.  This function is appropriate for the
-    // JVML athrow instruction.
-    // This function never returns.
+/**
+ * @param Object reference
+ *
+ * @return None.
+ *
+ * The only argument is a reference to the exception to be thrown.
+ * Throw the exception without modifying the stack trace associated
+ * with the exception object. This function is appropriate for the
+ * JVML athrow instruction.
+ * This function never returns.
+ */
 
     VM_RT_THROW_SET_STACK_TRACE=210,
-    // Arguments:
-    //  - Object reference
-    // Return value: none.
-    //
-    // The only argument is a reference to the exception to be thrown.
-    // Throw the exception and set the stack trace associated
-    // with the exception object.  This function is appropriate for the
-    // CIL throw instruction.
-    // This function never returns.
-
+ 
+	
+/** 
+ * @param Object reference.
+ *
+ * @return None.
+ *
+ * The only argument is a reference to the exception to be thrown.
+ * Throw the exception and set the stack trace associated
+ * with the exception object. This function is appropriate for the
+ * CIL throw instruction. 
+ *
+ *This function never returns.
+ */
 
     VM_RT_THROW_LAZY=201,
-    // Arguments:
-    //  - Method handle
-    //  - ...
-    //  - arg 2
-    //  - arg 1
-    //  - Class handle
-    // Return value: none.
-    //
-    // The arguments to the constructor are pushed the same way they would have
-    // been pushed to invoke the constructor, except that the (non-existing)
-    // this pointer is replaced with the class handle of the exception.
-    // The method handle representing the constructor is pushed last.
-    //
-    // This function never returns.
+/**
+ * @param The parameters are the following:
+ *        \arg Method handle
+ *        \arg ...
+ *        \arg arg 2
+ *        \arg arg 1
+ *        \arg Class handle
+ *
+ * @return None.
+ *
+ * The arguments to the constructor are pushed the same way they would have
+ * been pushed to invoke the constructor, except that the (non-existing)
+ * this pointer is replaced with the class handle of the exception.
+ * The method handle representing the constructor is pushed last.
+ *
+ * This function never returns.
+ */
 
     VM_RT_IDX_OUT_OF_BOUNDS=202,
-    // Arguments: none
-    // Return value: none.
-    //
-    // Throw the java/lang/ArrayIndexOutOfBoundsException
-    // This function never returns.
-
+ 
+/**
+ * @param none
+ *  
+ * @return None.
+ *
+ * Throw the <code>java/lang/ArrayIndexOutOfBoundsException</code>.
+ *
+ * This function never returns.
+ */
     VM_RT_NULL_PTR_EXCEPTION=203,
-    // Arguments: none
-    // Return value: none.
-    //
-    // Throw the java/lang/NullPointerException
-    // This function never returns.
-
+ 
+/**
+ * @param none
+ *
+ * @return None.
+ *
+ * Throw the <code>java/lang/NullPointerException</code>
+ *
+ * This function never returns.
+ */
     VM_RT_DIVIDE_BY_ZERO_EXCEPTION=204,
-    // Arguments: none
-    // Return value: none.
-    //
-    // Throw the java/lang/ArithmeticException
-    // This function never returns.
+  
+/**
+ * @param none
+ *
+ * @return None.
+ *
+ * Throw the <code>java/lang/ArithmeticException</code>.
+ *
+ * This function never returns.
+ */
 
     VM_RT_ARRAY_STORE_EXCEPTION=205,
-    // Arguments: none
-    // Return value: none.
-    //
-    // Throw the java/lang/ArrayStoreException
-    // This function never returns.
+   
+/**
+ * @param none
+ * 
+ * @return None.
+ *
+ * Throw the <code>java/lang/ArrayStoreException</code>.
+ *
+ * This function never returns.
+ */
 
     VM_RT_THROW_LINKING_EXCEPTION=206,
-    // Arguments:
-    //  - Const pool index.
-    //  - Class handle of the class owning the const pool.
-    //  - Loader exception returned by the VM.
-    // Return value: none.
-    //
-    // Throws a linking exception reported by the VM at compile-time.
-
+/**
+ * @param The parameters are the following:
+ *        \arg Const pool index
+ *        \arg Class handle of the class owning the const pool
+ *        \arg Loader exception returned by the VM
+ *
+ * @return None.
+ *
+ * Throws a linking exception reported by the VM at compile-time.
+ */
 
-    //////////////////////////////////////////////////////////////////////////
-    // Synchronization routines
-    //////////////////////////////////////////////////////////////////////////
+ ////
+ // Synchronization routines
+ //// 
 
     VM_RT_MONITOR_ENTER=300,
-    // Arguments:
-    //  - Object
-    // Return value: none.
-    //
-    // Acquire the monitor associated with the object.
-    // Throw java/lang/NullPointerException if the argument is null.
-
+/**
+ * @param Object
+ *
+ * @return None.
+ *
+ * Acquire the monitor associated with the object.
+ * Throw <code>java/lang/NullPointerException</code>, if the argument is null.
+ */
     VM_RT_MONITOR_ENTER_NON_NULL=304,
-    // Arguments:
-    //  - Object
-    // Return value: none.
-    //
-    // Acquire the monitor associated with the object.
-    // This function is identical to VM_RT_MONITOR_ENTER except that it
-    // assumes that the argument is non-null.  Passing a null argument
-    // will result in undefined behavior.
-
+ /**
+  * @param Object
+  *
+  * @return None.
+  *
+  * Acquire the monitor associated with the object.
+  * This function is identical to <code>VM_RT_MONITOR_ENTER</code> except that it
+  * assumes that the argument is non-null. Passing a null argument
+  * will result in undefined behavior.
+  */
     VM_RT_MONITOR_EXIT=301,
-    // Arguments:
-    //  - Object
-    // Return value: none.
-    //
-    // Release the monitor associated with the object.
-    // Throw java/lang/NullPointerException if the argument is null.
-    // Throw java/lang/IllegalMonitorStateException if the current thread
-    // is not the owner of the lock.
-
+/**   
+ * @param Object
+ *
+ * @return None.
+ *
+ * Release the monitor associated with the object.
+ * Throw <code>java/lang/NullPointerException</code>, if the argument is null.
+ * Throw <code>java/lang/IllegalMonitorStateException</code>, if the current 
+ * thread is not the owner of the lock.
+ */
     VM_RT_MONITOR_EXIT_NON_NULL=305,
-    // Arguments:
-    //  - Object
-    // Return value: none.
-    //
-    // Release the monitor associated with the object.
-    // This function is identical to VM_RT_MONITOR_EXIT except that it
-    // assumes that the argument is non-null.  Passing a null argument
-    // will result in undefined behavior.
-    // Throw java/lang/IllegalMonitorStateException if the current thread
-    // is not the owner of the lock.
-
+  
+/**
+ * @param Object
+ *
+ * @return None.
+ *
+ * Release the monitor associated with the object.
+ * This function is identical to <code>VM_RT_MONITOR_EXIT</code> except that it
+ * assumes that the argument is non-null. Passing a null argument
+ * will result in undefined behavior.
+ * Throw <code>java/lang/IllegalMonitorStateException</code>, if the current thread
+ * is not the owner of the lock.
+ */
     VM_RT_MONITOR_ENTER_STATIC=302,
-    // Arguments:
-    //  - Class handle
-    // Return value: none.
-    //
-    // Acquire the monitor associated with the class passed as the argument.
-
+/**  
+ * @param Class handle
+ *
+ * @return None.
+ *
+ * Acquire the monitor associated with the class passed as the argument.
+ */
     VM_RT_MONITOR_EXIT_STATIC=303,
-    // Arguments:
-    //  - Class handle
-    // Return value: none.
-    //
-    // Release the monitor associated with the class passed as the argument.
-    // Throw java/lang/IllegalMonitorStateException if the current thread
-    // is not the owner of the lock.
-
-
-
+/**
+ * @param Class handle
+ *
+ * @return None.
+ *
+ * Release the monitor associated with the class passed as the argument.
+ * Throw <code>java/lang/IllegalMonitorStateException</code>, if the current thread
+ * is not the owner of the lock.
+ */
 
-    //////////////////////////////////////////////////////////////////////////
-    // Type access routines
-    //////////////////////////////////////////////////////////////////////////
+////
+// Type access routines
+////
 
     VM_RT_CHECKCAST=400,
-    // Arguments:
-    //  - Object
-    //  - Class
-    // Return value:
-    //  - Object
-    //
-    // If object can't be cast to class, throw ClassCastException
-
+/**
+ * @param The parameters are the following:
+ *        \arg Object
+ *        \arg Class
+ * 
+ * @return Object.
+ *
+ * If object can't be cast to class, throw <code>ClassCastException</code>
+ */
 
     VM_RT_INSTANCEOF=401,
-    // Arguments:
-    //  - Object
-    //  - Class
-    // Return value:
-    //  - 1 if object is not null and can be cast to class
-    //  - 0 otherwise
-
+/**
+ * @param The parameters are the following:
+ *        \arg Object
+ *        \arg Class
+ *
+ * @return 1 if object is not null and can be cast to class;
+ *         0 otherwise
+ */
     VM_RT_AASTORE=402,
-    // Arguments:
-    //  - Element
-    //  - Index
-    //  - Array
-    // Return value: none.
-    //
-    // Store a reference element into into an array.
-
+/**
+ * @param The parameters are the following:
+ *        \arg Element
+ *        \arg Index
+ *        \arg Array
+ *
+ * @return None.
+ *
+ * Store a reference element into into an array.
+ */
     VM_RT_AASTORE_TEST=403,
-    // Arguments:
-    //  - Element
-    //  - Array
-    // Return value: 1 if the element can be stored in the array, 0 otherwise.
-    //
-    // Check if a reference element into into an array.  If the 'array'
-    // argument is null, return 0.  This function does not throw exceptions.
-
+/**
+ * @param The parameters are the following:
+ *        \arg Element
+ *        \arg Array
+ *
+ * @return 1 if the element can be stored in the array; 0 otherwise.
+ *
+ * Check if a reference element into into an array. If the <code>array</code>
+ * argument is null, return 0. This function does not throw exceptions.
+ */
     VM_RT_GET_INTERFACE_VTABLE_VER0=404,
-    // Arguments:
-    //  - Object reference
-    //  - Class handle for the interface
-    // Return value:
-    //  - Interface vtable with method entries for the implementation
-    //    of that interface by the actual class of the object.
-
-
+/**
+ * @param The parameters are the following:
+ *        \arg Object reference
+ *        \arg Class handle for the interface
+ *
+ * @return Interface vtable with method entries for the implementation
+ *         of that interface by the actual class of the object.
+ */
 
+ /////
+ //Class initialization
+ /////
 
-    //////////////////////////////////////////////////////////////////////////
-    // Class initialization
-    //////////////////////////////////////////////////////////////////////////
 
     VM_RT_INITIALIZE_CLASS=500,
-    // Arguments:
-    //  - Class handle
-    // Return value: none.
-    //
-    // If the class hasn't been initialized yet, initialize it.
-    //
-    // A call to this function must be generated before every putstatic
-    // and getstatic unless the JIT can prove that the class would have
-    // been already initialized at that point.
-
-
-
+/**
+ * @param Class handle
+ *
+ * @return None.
+ *
+ * If the class hasn't been initialized yet, initialize it.
+ *
+ * A call to this function must be generated before every putstatic
+ * and getstatic unless the JIT can prove that the class would have
+ * been already initialized at that point.
+ */
 
-    //////////////////////////////////////////////////////////////////////////
-    // Write barrier routines
-    //////////////////////////////////////////////////////////////////////////
+ ////
+ // Write barrier routines
+ ////
 
     VM_RT_GC_HEAP_WRITE_REF=600,
-    // Arguments:
-    //  - Address of the base of the object (or array) being written to.
-    //  - Address of a memory location being written to
-    //  - Value being written.
-    // Return value: none.
-    //
-    // Write barrier for GC. Updates the slot with the value provided.
-    // The type being written is indicated in the name.
-
+/**
+ * @param The parameters are the following:
+ *        \arg Address of the base of the object (or array) being written to
+ *        \arg Address of a memory location being written to
+ *        \arg Value being written
+ *
+ * @return None.
+ *
+ * Write barrier for GC. Updates the slot with the value provided.
+ * The type being written is indicated in the name.
+ */
     VM_RT_GC_SAFE_POINT=601,
-    // Arguments: none
-    // Return value: none.
-    // Use this helper to notify GC about safe point in managed code
-
+/**
+ * @param none
+ *
+ * @return None.
+ *
+ * Use this helper to notify GC about safe point in managed code.
+ */
     VM_RT_GC_GET_TLS_BASE=602,
-    // Arguments: none
-    // Return value: pointer to int-sized suspension request flag
-    //
-    // When the flag is non zero, managed code should call VM_RT_GC_SAFE_POINT
-    // helper.
-    // Note: The flag must be used for read only !
-
-    //////////////////////////////////////////////////////////////////////////
-    // JVMTI specific routines
-    //////////////////////////////////////////////////////////////////////////
+/**
+ * @param none
+ *
+ * @return Pointer to int-sized suspension request flag.
+ *
+ * When the flag is non zero, managed code should call <code>VM_RT_GC_SAFE_POINT</code>
+ * helper.
+ *
+ * @note The flag must be used for read only!
+ */
+ 
+ 
+ /////
+ // JVMTI specific routines
+ /////  
 
     VM_RT_JVMTI_METHOD_ENTER_CALLBACK = 700,
-    // Arguments: handle of the method which gets control
-    // Return value: none
-    //
-    // This call-back should be used to notify about method enter event.
-    // Do a call-back when such capability is requested only.
-
+/**
+ * @param handle of the method which gets control
+ *
+ * @return None.
+ *
+ * This call-back should be used to notify about method enter event.
+ * Do a call-back when such capability is requested only.
+ */
     VM_RT_JVMTI_METHOD_EXIT_CALLBACK = 701,
-    // Arguments:
-    //  - handle of the method which is about to lose control
-    //  - method's return value
-    // Return value: none
-    //
-    // This call-back should be used to notify about method exit event.
-    // Do a call-back when such capability is requested only.
-
-    VM_RT_JVMTI_FIELD_ACCESS_CALLBACK = 702,
-    // Arguments:
-    //  - handle of the field under access
-    //  - handle of the method, which accesses field
-    //  - location of code which accesses field
-    //  - pointer to the reference of the object, which field is beeng
-    //    accessed or NULL for static field
-    // Return value: none
-    //
-    // Notifies about field access.
+/**
+ * @param The parameters are the following:
+ *        \arg handle of the method which is about to lose control
+ *        \arg method's return value
+ *
+ * @return None.
+ *
+ * This call-back should be used to notify about method exit event.
+ * Do a call-back when such capability is requested only.
+ */
+ 
+ VM_RT_JVMTI_FIELD_ACCESS_CALLBACK = 702,
 
+/**
+ * @param The parameters are the following:
+ *        arg\ handle of the field under access
+ *        arg\ handle of the method, which accesses field
+ *        arg\ location of code which accesses field
+ *        arg\ pointer to the reference of the object, which field is beeng
+ *             accessed or NULL for static field
+ *
+ * @return None.
+ *
+ * Notifies about field access.
+ */
     VM_RT_JVMTI_FIELD_MODIFICATION_CALLBACK = 703,
-    // Arguments:
-    // - handle of the field under modification
-    // - handle of the method, which modifies field
-    // - location of code which modifies field
-    // - pointer to the reference of the object, which field is beeng
-    //   modified or NULL for static field
-    // - pointer to the new value for the field
-    // Return value: none
-    //
-    // Notifies about field modification.
-
-    //////////////////////////////////////////////////////////////////////////
-    // Runtime resolution routine
-    //////////////////////////////////////////////////////////////////////////
+/**
+ * @param The parameters are the following:
+ *        arg\ handle of the field under modification
+ *        arg\ handle of the method, which modifies field
+ *        arg\ location of code which modifies field
+ *        arg\ pointer to the reference of the object, which field is beeng
+ *             modified or NULL for static field
+ *        arg\ pointer to the new value for the field
+ *
+ * @return none
+ *
+ * Notifies about field modification.
+ */
+
+ /////
+ /// Runtime resolution routine
+ /////
 
     VM_RT_RESOLVE = 801,
-    // Arguments:
-    //  - Class handle
-    //  - Constant pool index of an item to be resolved
-    //  - A java byte code instruction (JavaByteCodes) the resolution
-    //    is performed for
-    //
-    // The helper performs resolution of symbolic references during runtime.
-    // If resolution failed, the helper throws appropriate LinkageError.
-    // Otherwise, the value depends on byte code passed:
-    //
-    //  === JavaByteCodes ===          === result of call ===
-    //  OPCODE_INVOKESTATIC:        resolve_static_method
-    //  OPCODE_INVOKEINTERFACE:     resolve_interface_method
-    //  OPCODE_INVOKEVIRTUAL,
-    //  OPCODE_INVOKESPECIAL:       resolve_virtual_method
-    //  OPCODE_INSTANCEOF,
-    //  OPCODE_CHECKCAST,
-    //  OPCODE_MULTIANEWARRAY       resolve_class
-    //  OPCODE_ANEWARRAY:           class_get_array_of_class(resolve_class())
-    //  OPCODE_NEW:                 resolve_class_new
-    //  OPCODE_GETFIELD,
-    //  OPCODE_PUTFIELD:            resolve_nonstatic_field
-    //  OPCODE_PUTSTATIC,
-    //  OPCODE_GETSTATIC:           resolve_static_field
-    //
-    // The helper initializes class if the class hasn't been initialized yet
-    // for PUTSTATIC and GETSTATIC
-    //
-
-    //////////////////////////////////////////////////////////////////////////
-    // Non-VM specific helpers for the JIT
-    //////////////////////////////////////////////////////////////////////////
+  
+/**
+ * @param The parameters are the following:
+ *        arg\ Class handle
+ *        arg\ Constant pool index of an item to be resolved
+ *        arg\ A java byte code instruction (<code>JavaByteCodes</code>) 
+ *             the resolution is performed for
+ *
+ * The helper performs resolution of symbolic references during runtime.
+ * If resolution failed, the helper throws appropriate <code>LinkageError</code>.
+ * Otherwise, the value depends on byte code passed:
+ *
+ *  === JavaByteCodes ===          === result of call ===
+ *
+ *  OPCODE_INVOKESTATIC:        resolve_static_method
+ *
+ *  OPCODE_INVOKEINTERFACE:     resolve_interface_method
+ *
+ *  OPCODE_INVOKEVIRTUAL,
+ *
+ *  OPCODE_INVOKESPECIAL:       resolve_virtual_method
+ *
+ *  OPCODE_INSTANCEOF,
+ *
+ *  OPCODE_CHECKCAST,
+ *
+ *  OPCODE_MULTIANEWARRAY       resolve_class
+ *
+ *  OPCODE_ANEWARRAY:           class_get_array_of_class(resolve_class())
+ *
+ *  OPCODE_NEW:                 resolve_class_new
+ *
+ *  OPCODE_GETFIELD,
+ *
+ *  OPCODE_PUTFIELD:            resolve_nonstatic_field
+ *
+ *  OPCODE_PUTSTATIC,
+ *
+ *  OPCODE_GETSTATIC:           resolve_static_field
+ *
+ * The helper initializes class if the class hasn't been initialized yet
+ * for <code>PUTSTATIC</code> and <code>GETSTATIC</code>.
+ */
+
+ /////
+ // Non-VM specific helpers for the JIT
+ ///// 
 
     VM_RT_F2I=900,
     VM_RT_F2L=901,
@@ -429,16 +503,16 @@
     VM_RT_LSHL=910,
     VM_RT_LSHR=911,
     VM_RT_LUSHR=912,
-    // Arguments:
-    // (new version)
-    //  - Long value to be shifted
-    //  - Int value with count
-    // (old version)
-    //  - (edx:eax) A long value to be shifted
-    //  - (ecx)     Count 
-    // Return value: (edx:eax)
-    //  - The shifted value
-    //
+    * Arguments:
+    * (new version)
+    *  - Long value to be shifted
+    *  - Int value with count
+    * (old version)
+    *  - (edx:eax) A long value to be shifted
+    *  - (ecx)     Count 
+    * Return value: (edx:eax)
+    *  - The shifted value
+    *
 
 
     VM_RT_LMUL=920,
@@ -464,57 +538,62 @@
     // Float/double arithmetic
 
     VM_RT_CHAR_ARRAYCOPY_NO_EXC=950,
-    // Arguments:
-    //  - Object reference for the source array. Must be non-null and refer to an array 
-    //    of 16 bit chars.
-    //  - int32 containing the starting index of the source array to copy.
-    //  - Object reference for the destination array. Must be non-null and refer to an array 
-    //    of 16 bit chars.
-    //  - int32 containing the starting index of the destination array to copy into.
-    //  - int32 containing the number of 16 bit chars to copy.
-    // Return value: none.
-    // 
-    // This runtime helper function provides a specialized implementation for System.arraycopy
-    // for the common case where the elements of the arrays are 
-    // 16 bit characters and the array references are both non-null. The JIT must guarantee
-    // that no exceptions will need to be thrown. That is, both array references are non-null,
-    // the types match (and are both arrays of 16 bit characters), 
-    // and the starting indexes and length are such that the copying will only access
-    // data in the bounds of the arrays.
-
-
+/**
+ * @param The parameters are the following:
+ *        arg\ Object reference for the source array. Must be non-null and refer to an array 
+ *             of 16 bit chars
+ *        arg\ int32 containing the starting index of the source array to copy
+ *        arg\ Object reference for the destination array. Must be non-null and refer to an array 
+ *             of 16 bit chars.
+ *        arg\ int32 containing the starting index of the destination array to copy into.
+ *        arg\ int32 containing the number of 16 bit chars to copy.
+ *
+ * @return None.
+ * 
+ * This runtime helper function provides a specialized implementation for <code>System.arraycopy</code>
+ * for the common case where the elements of the arrays are 
+ * 16 bit characters and the array references are both non-null. The JIT must guarantee
+ * that no exceptions will need to be thrown. That is, both array references are non-null,
+ * the types match (and are both arrays of 16 bit characters), 
+ * and the starting indexes and length are such that the copying will only access
+ * data in the bounds of the arrays.
+ */
 
-    //////////////////////////////////////////////////////////////////////////
-    // Deprecated routines
-    //////////////////////////////////////////////////////////////////////////
+ ////
+ // Deprecated routines
+ ////
 
     VM_RT_NEW_RESOLVED=1000,
-    // Arguments:
-    //  - Class handle for the class whose object we want to create
-    // Return value:
-    //  - Reference to the new object
-    //
-    // Allocates a new object of the class.  This function should be used
-    // for classes which inherit the finalize method of java.lang.Object.
-    // See also VM_RT_NEW_RESOLVED_USING_VTABLE.
-
+/**
+ * @param Class handle for the class whose object we want to create
+ *
+ * @return Reference to the new object.
+ *
+ * Allocates a new object of the class. This function should be used
+ * for classes which inherit the finalize method of <code>java.lang.Object</code>.
+ * See also <code>VM_RT_NEW_RESOLVED_USING_VTABLE</code>.
+ */
     VM_RT_NEW_VECTOR=1001,
-    // Arguments:
-    //  - Vector length
-    //  - Class handle of the vector class
-    // Return value:
-    //  - Reference to the new object
-    //
-    // Create a vector (zero-based, one dimensional array)
-    // of the given type. See also VM_RT_NEW_VECTOR_USING_VTABLE.
-
+/**
+ * @param The parameters are the following:
+ *        arg\ Vector length
+ *        arg\ Class handle of the vector class
+ *
+ * @return Reference to the new object
+ *
+ * Create a vector (zero-based, one dimensional array)
+ * of the given type. See also <code>VM_RT_NEW_VECTOR_USING_VTABLE</code>.
+ */
     VM_RT_WRITE_BARRIER_FASTCALL=1002
-    // Arguments:
-    //  - Address of a memory location being written to
-    //  - Object reference being written.
-    // Return value: none.
-    //
-    // Write barrier for GC.
+/**
+ * @param The parameters are the following:
+ *        arg\ Address of a memory location being written to
+ *        arg\ Object reference being written.
+ *
+ * @return None.
+ *
+ * Write barrier for GC.
+ */
 
 } VM_RT_SUPPORT; //VM_RT_SUPPORT
 
@@ -525,16 +604,18 @@
 VMEXPORT void *vm_get_rt_support_addr(VM_RT_SUPPORT f);
 
 
-/* temporary interface addition
- * same as vm_get_rt_support_addr, but tries to optimize the stubs it creates,
+/**
+ * Temporary interface addition
+ * same as <code>vm_get_rt_support_addr</code>, but tries to optimize the stubs it creates,
  * by specializing them.
  */
 VMEXPORT void *vm_get_rt_support_addr_optimized(VM_RT_SUPPORT f, Class_Handle c);
 
-
-// instead of returning a stub address, this support function returns
-// parsed LIL code.
-typedef struct LilCodeStub LilCodeStub;
+/**
+ * Instead of returning a stub address, this support function returns
+ * parsed LIL code.
+ */
+ typedef struct LilCodeStub LilCodeStub;
 VMEXPORT LilCodeStub *vm_get_rt_support_stub(VM_RT_SUPPORT f, Class_Handle c);
 
 

Modified: harmony/enhanced/drlvm/trunk/vm/include/jvmti.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/include/jvmti.h?view=diff&rev=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/include/jvmti.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/include/jvmti.h Sun Jan 14 10:13:53 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,7 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
-/** 
- * @author Gregory Shimansky
- * @version $Revision: 1.1.2.1.4.4 $
- */  
+  
 #ifndef _JVMTI_H_
 #define _JVMTI_H_
 
@@ -61,7 +58,7 @@
 #endif
 
     /**
-     * Agent Start-Up
+     * Agent Start-Up.
      * The library must export a start-up function with the following
      * prototype:
      */
@@ -69,7 +66,7 @@
         Agent_OnLoad(JavaVM * vm, char *options, void *reserved);
 
     /**
-     * Agent Shutdown
+     * Agent Shutdown.
      * The library may optionally export a shutdown function with the
      * following prototype:
      */

Modified: harmony/enhanced/drlvm/trunk/vm/include/jvmti_types.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/include/jvmti_types.h?view=diff&rev=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/include/jvmti_types.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/include/jvmti_types.h Sun Jan 14 10:13:53 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,7 @@
  *  See the License for the specific language governing permissions and
  *  limitations under the License.
  */
-/** 
-* @author Gregory Shimansky
-* @version $Revision: 1.1.2.1.4.4 $
-*/  
+ 
 #ifndef _JVMTI_TYPES_H_
 #define _JVMTI_TYPES_H_
 
@@ -115,28 +112,28 @@
      */
     enum
     {
-        /*
-         * Class bytecodes have been verified
+        /**
+         * Class bytecodes have been verified.
          */
         JVMTI_CLASS_STATUS_VERIFIED = 1,
-        /*
-         * Class preparation is complete
+        /**
+         * Class preparation is complete.
          */
         JVMTI_CLASS_STATUS_PREPARED = 2,
-        /*
+        /**
          * Class initialization is complete. Static initializer has been run.
          */
         JVMTI_CLASS_STATUS_INITIALIZED = 4,
-        /*
-         * Error during initialization makes class unusable
+        /**
+         * Error during initialization makes class unusable.
          */
         JVMTI_CLASS_STATUS_ERROR = 8,
-        /*
+        /**
          * Class is an array. If set, all other bits are zero.
          */
         JVMTI_CLASS_STATUS_ARRAY = 16,
-        /*
-         * Class is a primitive class (for example, java.lang.Integer.TYPE).
+        /**
+         * Class is a primitive class (for example, <code>java.lang.Integer.TYPE</code>).
          * If set, all other bits are zero.
          */
         JVMTI_CLASS_STATUS_PRIMITIVE = 32
@@ -244,7 +241,7 @@
 
     /**
      * Event numbers (from spec). Custom events could be added
-     * after JVMTI_MAX_EVENT_TYPE_VAL.
+     * after <code>JVMTI_MAX_EVENT_TYPE_VAL</code>.
      */
     typedef enum
     {
@@ -362,8 +359,8 @@
         jint slot;
     } jvmtiLocalVariableEntry;
 
-    /* ******************************************************
-     * Event management is exposed to other OPEN components.
+    /**
+     * Event management is exposed to other <code>OPEN</code> components.
      */
 
     typedef void (JNICALL * jvmtiEventVMInit)
@@ -598,7 +595,7 @@
     } jvmtiExtensionEventInfo;
 
     /**
-     * OPEN components should be aware of event management
+     * <code>OPEN</code> components should be aware of event management
      * capabilities.
      */
     typedef struct