harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nadi...@apache.org
Subject svn commit: r496108 [4/4] - in /harmony/enhanced/drlvm/trunk/vm: include/ include/open/ vmcore/include/
Date Sun, 14 Jan 2007 18:13:55 GMT
Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_jpda.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_jpda.h?view=diff&rev=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_jpda.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/include/jit_export_jpda.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.1.4.4 $
- */  
 
 #ifndef _JIT_EXPORT_JPDA_H
 #define _JIT_EXPORT_JPDA_H
@@ -28,9 +24,9 @@
 extern "C" {
 #endif // __cplusplus
 
-/**
+   /**
     * Elements of this enum denote various error conditions which can
-    * arise when working with the OpenExeJPDA interface.
+    * arise when working with the <code>OpenExeJPDA</code> interface.
     */
 typedef enum OpenExeJpdaError {
     EXE_ERROR_NONE,
@@ -42,19 +38,21 @@
 } OpenExeJpdaError;
 
 
-/** 
+   /** 
     * Gets corresponding native code location for given bytecode location.
-    * @param method    method whose bytecode contains the location
-    * @param bc_pc     location within the bytecode
-    * @param native_pc (out) upon successfull return points to corresponding native
-    *     code location 
+	*
+    * @param method          - method whose bytecode contains the location
+    * @param bc_pc           - location within the bytecode
+    * @param[out] native_pc  - upon successfull return points to corresponding native
+    *                          code location 
     * @return
-    *     EXE_ERROR_NONE on success
-    *     EXE_ERROR_INVALID_METHODID if the given method handle is invalid
+    *     EXE_ERROR_NONE              on success.<br>
+    *     EXE_ERROR_INVALID_METHODID if the given method handle is invalid.<br>
     *     EXE_ERROR_INVALID_LOCATION if either the execution engine is unable to map
-    *         the bytecode location or if the location is invalid (does not correspond to
-    *         a valid offset of a bytecode instruction)
-    *     EXE_ERROR_UNSUPPORTED if the execution engine does not support this functionality
+    *                                the bytecode location or if the location is invalid

+	*                                (does not correspond to a valid offset of a bytecode 
+	*                                instruction).<br>
+    *     EXE_ERROR_UNSUPPORTED      if the execution engine does not support this functionality.
     */ 
 JITEXPORT OpenExeJpdaError get_native_location_for_bc(
         JIT_Handle jit,
@@ -63,18 +61,23 @@
         NativeCodePtr  *native_pc
         );
 
-/**
-    * Gets corresponding bytecode location for given native location (absolute code address).
-    * @param method    method whose (compiled native) code contains the location
-    * @param native_pc location within the native code
-    * @param bc_pc     (out) upon successfull return points to corresponding bytecode location

+   /**
+    * Gets corresponding bytecode location for given native location (absolute 
+	* code address).
+	*
+    * @param method      - method whose (compiled native) code contains the location
+    * @param native_pc   - location within the native code
+    * @param[out] bc_pc  - upon successfull return points to corresponding bytecode 
+	*                      location 
     * @return
-    *     EXE_ERROR_NONE on success
-    *     EXE_ERROR_INVALID_METHODID if the given method handle is invalid
+    *     EXE_ERROR_NONE             on success.<br>
+    *     EXE_ERROR_INVALID_METHODID if the given method handle is invalid.<br>
     *     EXE_ERROR_INVALID_LOCATION if either the execution engine is unable to map
-    *         the native location or if the location is invalid (does not correspond to
-    *         a valid offset of a processor instruction within the compiled code)
-    *     EXE_ERROR_UNSUPPORTED if the execution engine does not support this functionality
+    *                                the native location or if the location is 
+	*                                invalid (does not correspond to a valid offset 
+	*                                of a processor instruction within the compiled code).<br>
+    *     EXE_ERROR_UNSUPPORTED      if the execution engine does not support this 
+	*                                functionality.
     */ 
 JITEXPORT OpenExeJpdaError get_bc_location_for_native(
         JIT_Handle jit,
@@ -84,23 +87,28 @@
         );
 
 
-/** 
+   /** 
     * Gets the value of the bytecode local variable in given method stack frame.
-    * @param method    method in whose frame the variable is to be read
-    * @param context   stack frame of the method describing its current execution state
-    *     (at the point of thread suspension)
-    * @param var_num    the variable's slot number
-    * @param var_type  the variable's type
-    * @param value_ptr address of the buffer to write variable value into. Caller is responsible
for
-    *     providing enough (OPEN_VM::get_vm_type_size(var_type) bytes) memory in the buffer.
+	*
+    * @param method     - method in whose frame the variable is to be read
+    * @param context    - stack frame of the method describing its current execution state
+    *                     (at the point of thread suspension)
+    * @param var_num    - the variable's slot number
+    * @param var_type   - the variable's type
+    * @param value_ptr  - address of the buffer to write variable value into. 
+	*                     Caller is responsible for providing enough 
+	*                     <code>(OPEN_VM::get_vm_type_size(var_type)</code> bytes)

+	*                     memory in the buffer
+	*
     * @return
-    *     EXE_ERROR_NONE on success
-    *     EXE_ERROR_INVALID_METHODID if the given method handle is invalid
-    *     EXE_ERROR_INVALID_LOCATION if the execution engine does not support local variable
access
-    *         at current execution point in the method, specified by the context
-    *     EXE_ERROR_TYPE_MISMATCH if the variable with given slot is of different type,
-    *     EXE_ERROR_INVALID_SLOT if the stack frame does not have variable with given slot
number,
-    *     EXE_ERROR_UNSUPPORTED if the execution engine does not support this functionality
+    *     EXE_ERROR_NONE             on success.<br>
+    *     EXE_ERROR_INVALID_METHODID if the given method handle is invalid.<br>
+    *     EXE_ERROR_INVALID_LOCATION if the execution engine does not support local 
+	*                                variable access at current execution point 
+	*                                in the method, specified by the context.<br>
+    *     EXE_ERROR_TYPE_MISMATCH    if the variable with given slot is of different type.<br>
+    *     EXE_ERROR_INVALID_SLOT     if the stack frame does not have variable with given
slot number.<br>
+    *     EXE_ERROR_UNSUPPORTED      if the execution engine does not support this functionality.
     */ 
 JITEXPORT OpenExeJpdaError get_local_var(
         JIT_Handle jit,
@@ -112,22 +120,25 @@
         );
 
 
-/** 
+   /** 
     * Sets the value of the bytecode local variable in given method stack frame.
-    * @param method    method in whose frame the variable is to be changed
-    * @param context   stack frame of the method describing its current execution state
-    *     (at the point of thread suspension)
+	*
+    * @param method     method in whose frame the variable is to be changed
+    * @param context    stack frame of the method describing its current execution state
+    *                   (at the point of thread suspension)
     * @param var_num    the variable's slot number
-    * @param var_type  the variable's type
-    * @param value_ptr address of the new value for the variable
+    * @param var_type   the variable's type
+    * @param value_ptr  address of the new value for the variable
+	*
     * @return
-    *     EXE_ERROR_NONE on success
-    *     EXE_ERROR_INVALID_METHODID if the given method handle is invalid
+    *     EXE_ERROR_NONE             on success.<br>
+    *     EXE_ERROR_INVALID_METHODID if the given method handle is invalid.<br>
     *     EXE_ERROR_INVALID_LOCATION if the execution engine does not support local variable
access
-    *         at current execution point in the method, specified by the context
-    *     EXE_ERROR_TYPE_MISMATCH if the variable with given slot is of different type,
-    *     EXE_ERROR_INVALID_SLOT if the stack frame does not have variable with given slot
number,
-    *     EXE_ERROR_UNSUPPORTED if the execution engine does not support this functionality
+    *                                at current execution point in the method, 
+	*                                specified by the context.<br>
+    *     EXE_ERROR_TYPE_MISMATCH    if the variable with given slot is of different type.<br>
+    *     EXE_ERROR_INVALID_SLOT     if the stack frame does not have variable with given
slot number.<br>
+    *     EXE_ERROR_UNSUPPORTED      if the execution engine does not support this functionality.
     */ 
 JITEXPORT OpenExeJpdaError set_local_var(
         JIT_Handle jit,

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=496108&r1=496107&r2=496108
==============================================================================
--- 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 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,16 +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 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
@@ -36,15 +31,16 @@
 extern "C" {
 #endif // __cplusplus
 
-
-
-///////////////////////////////////////////////////////
+/////////
 // begin Frame Contexts for JITs
+////////
 
 #ifdef _IPF_
 
-// 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.
+/**
+ * @note 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;
@@ -109,7 +105,7 @@
     uint32 *p_ecx;
     uint32 *p_edx;
 
-    // To restore processor flags during transfer
+ 
     uint32 eflags;
 
     Boolean is_ip_past;
@@ -128,34 +124,47 @@
 // 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 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.
+/**
+ * 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>.
+ */
 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 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.
+/**
+ * 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>.
+ */
+
 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 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.
+/**
+ * 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>.
+ */
 JITEXPORT Boolean 
 JIT_recompiled_method_callback(JIT_Handle jit,
                                Method_Handle  recompiled_method,
@@ -228,9 +237,14 @@
 // begin compressed 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.
+/**
+ * @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.
+ */
+
 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=496108&r1=496107&r2=496108
==============================================================================
--- 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
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,14 +14,6 @@
  *  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_
@@ -33,11 +25,15 @@
 VMEXPORT // temporary solution for interpreter unplug
 int __stdcall vm_instanceof(ManagedObject *obj, Class *c) stdcall__;
 
-// Implements VM_RT_AASTORE
+/**
+ * Implements <code>VM_RT_AASTORE</code>.
+ */
 void * __stdcall
 vm_rt_aastore(ManagedObject *elem, int idx, Vector_Handle array) stdcall__;
 
-// Implements VM_RT_AASTORE_TEST
+/**
+ * Implements <code>VM_RT_AASTORE_TEST</code>.
+ */
 int __stdcall
 vm_aastore_test(ManagedObject *elem, Vector_Handle array) stdcall__;
 
@@ -56,16 +52,21 @@
 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 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)
+/** 
+ * 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).
+ */
 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=496108&r1=496107&r2=496108
==============================================================================
--- 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 10:13:53 2007
@@ -14,10 +14,6 @@
  *  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
@@ -35,17 +31,23 @@
 #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=496108&r1=496107&r2=496108
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/include/vm_strings.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/include/vm_strings.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,14 +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.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_
 
@@ -65,57 +61,100 @@
 
 jstring String_to_interned_jstring(String* str);
 
-//***** New Interface
+/** 
+ * @name New Interface
+ */
+//@{
+
+
+/**
+ * GC must be disabled, but at a GC safe point.
+ */
 
-// 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
-// returns length in characters
+/**
+ * GC must be disabled.
+ *
+ * @return Length in characters.
+ */
 unsigned string_get_length(ManagedObject*);
 
-// GC must be disabled
-// returns the length of the UTF8 encoding of the string
+/** 
+ * GC must be disabled.
+ * 
+ * @return 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 offset..offset+count-1 into res
+/** 
+ * GC must be disabled.
+ * Copy the characters <code>offset..offset+count-1</code> into res.
+ */
 void string_get_unicode_region(ManagedObject* str, unsigned offset, unsigned count, uint16*
res);
 
-// GC must be disabled
-// Encode characters offset..offset+count-1 into UTF8 and place in res
+/**
+ * GC must be disabled.
+ * Encode characters <code>offset..offset+count-1</code> into UTF8 and place
in res.
+ */
+
 void string_get_utf8_region(ManagedObject* str, unsigned offset, unsigned count, char* res);
 
-//*** Handle versions
+
+/** 
+ * @name Handle versions
+ */
+//@{
+
 
 ObjectHandle string_create_from_utf8_h(const char* buf, unsigned length);
 ObjectHandle string_create_from_unicode_h(const uint16* buf, unsigned length);
 
-// returns length in characters
+/**
+ * @return Length in characters.
+ */ 
+
 unsigned string_get_length_h(ObjectHandle str);
 
-// returns the length of the UTF8 encoding of the string
+/**
+ * @return 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 offset..offset+count-1 into buf
+/**
+ * Copy the characters <code>offset..offset+count-1</code> into buf.
+ */
+
 void string_get_unicode_region_h(ObjectHandle str, unsigned offset, unsigned count, uint16*
buf);
 
-// Encode characters offset..offset+count-1 into UTF8 and place in buf
+/**
+ * Encode characters <code>offset..offset+count-1</code> 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