/[classpath]/classpath/doc/vmintegration.texinfo
ViewVC logotype

Diff of /classpath/doc/vmintegration.texinfo

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.6 by mark, Sun Nov 11 16:07:09 2001 UTC revision 1.7 by mark, Fri Oct 4 15:26:25 2002 UTC
# Line 12  This file contains important information Line 12  This file contains important information
12  are going to write an interface between GNU Classpath and a Virtual  are going to write an interface between GNU Classpath and a Virtual
13  Machine.  Machine.
14    
15  Copyright (C) 1998-2001 Free Software Foundation, Inc.  Copyright (C) 1998-2002 Free Software Foundation, Inc.
16    
17  @end ifinfo  @end ifinfo
18    
# Line 24  Copyright (C) 1998-2001 Free Software Fo Line 24  Copyright (C) 1998-2001 Free Software Fo
24    
25  @page  @page
26  @vskip 0pt plus 1filll  @vskip 0pt plus 1filll
27  Copyright @copyright{} 1998-2001 Free Software Foundation, Inc.  Copyright @copyright{} 1998-2002 Free Software Foundation, Inc.
28  @sp 2  @sp 2
29  Permission is granted to make and distribute verbatim copies of  Permission is granted to make and distribute verbatim copies of
30  this document provided the copyright notice and this permission notice  this document provided the copyright notice and this permission notice
# Line 142  The order of initialization, as far as I Line 142  The order of initialization, as far as I
142  yet.  However, when we move to 1.2 support, it probably will matter, so  yet.  However, when we move to 1.2 support, it probably will matter, so
143  we'll have a note in here at that time.  we'll have a note in here at that time.
144    
145    The current initialization order is currently documented in the
146    Runtime.java source file.
147    
148  @node Classpath Hooks, VM Hooks, Initialization, Top  @node Classpath Hooks, VM Hooks, Initialization, Top
149  @comment node-name, next, previous, up  @comment node-name, next, previous, up
150  @chapter Classpath Hooks  @chapter Classpath Hooks
# Line 153  work.  These classes are: Line 156  work.  These classes are:
156  @item java.lang.Class  @item java.lang.Class
157  @item java.lang.Runtime  @item java.lang.Runtime
158  @item java.lang.Thread  @item java.lang.Thread
 @item java.lang.Throwable  
159  @item java.lang.reflect.Constructor  @item java.lang.reflect.Constructor
160  @item java.lang.reflect.Method  @item java.lang.reflect.Method
161  @item java.lang.reflect.Field  @item java.lang.reflect.Field
# Line 175  method and the identityHashCode of an Ob Line 177  method and the identityHashCode of an Ob
177  @item java.lang.VMSecurityManager  @item java.lang.VMSecurityManager
178  provides the class context (stack trace) of the currently  provides the class context (stack trace) of the currently
179  executing thread and a way to get the currently active ClassLoader.  executing thread and a way to get the currently active ClassLoader.
180    @item java.lang.VMThrowable
181    used to hold the VM state of a throwable, created when a Throwable is
182    created or the fillInStacktrace() method is called, when the actual stack
183    trace is needed (a lot of exceptions are never actually used), the
184    getStackTrace() method is used to create a real StackTraceElement array
185    for the exception.
186  @end itemize  @end itemize
187    
188  Some of the classes you implement for the VM will need to call back to  Some of the classes you implement for the VM will need to call back to
# Line 231  done.  No harm will come, as long as you Line 239  done.  No harm will come, as long as you
239  @emph{Note: this is written in anticipation of 1.2 support and does not  @emph{Note: this is written in anticipation of 1.2 support and does not
240  apply just yet.}  apply just yet.}
241    
 @item java.lang.Throwable (Classpath 0.02) @*  
 The VM may choose to implement this class in whatever fashion it would  
 like.  If you choose to use the reference implementation, then you must  
 define two functions within some library and change Throwable.java to  
 load your library.  The two functions are printStackTrace0(Object), and  
 fillInStackTrace().  
   
242  @item Top-level Exception Handler @*  @item Top-level Exception Handler @*
243  Exceptions take care of themselves in Classpath; all you need to do in  Exceptions take care of themselves in Classpath; all you need to do in
244  the top-level exception handler is call Throwable.printStackTrace().  the top-level exception handler is call Throwable.printStackTrace().
245    
 XXX I think this was a bad design on my part.  It takes up memory and  
 CPU cycles that do not need to be taken up for exceptions which are  
 simply caught.  This portion of the VM interface will be changed so that  
 VMs must associate native stacktrace data with the Throwable itself or  
 even do some sort of lazy stacktrace information addition to the  
 Throwable, only copying stacktrace data as it is lost (as functions are  
 exited) to preserve memory and cycles.  The usual case is the one where  
 an exception is caught.  The top-level exception handler is, well, an  
 exception among exceptions.  
   
246  @item Security and Traces @*  @item Security and Traces @*
247  There will eventually be a feature in the 1.2 security that keeps the  There will eventually be a feature in the 1.2 security that keeps the
248  AccessController from having to evaluate @emph{all} of the  AccessController from having to evaluate @emph{all} of the

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26