Main Page | Namespace List | Alphabetical List | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

jvm.c File Reference


Detailed Description

Java Virtual Machine implementation on this real machine.

Main entry point to the JVM and top-level implementation.

Note:
Notice that the "Main Page" documentation resides in this source file. In order for the users of Unix man(1) format of these documents to see the "Main Page" item that is present on the HTML format of these documents, please refer to the source code of this file.
Todo:
Need to verify which web document for the Java 5 class file definition is either "official", actually correct, or is the de facto standard.

Control

$URL: https://svn.apache.org/path/name/jvm.c $ $Id: jvm.c 0 09/28/2005 dlydick $

Copyright 2005 The Apache Software Foundation or its licensors, as applicable.

Licensed 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

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.

See the License for the specific language governing permissions and limitations under the License.

Version:
$LastChangedRevision: 0 $
Date:
$LastChangedDate: 09/28/2005 $
Author:
$LastChangedBy: dlydick $ Original code contributed by Daniel Lydick on 09/28/2005.

Reference

Definition in file jvm.c.

#include "arch.h"
#include <signal.h>
#include <strings.h>
#include <unistd.h>
#include "jvmcfg.h"
#include "cfmacros.h"
#include "classfile.h"
#include "classpath.h"
#include "exit.h"
#include "gc.h"
#include "jvm.h"
#include "jvmclass.h"
#include "linkage.h"
#include "method.h"
#include "nts.h"
#include "opcode.h"
#include "utf.h"
#include "util.h"

Go to the source code of this file.

Roll call globals for JVM initialization and shutdown.

Determine if a portion of the JVM has been initialized or not.

At the very end of initializing a part of the JVM, if everything was set up properly, then the associated flag is set to rtrue. If an error occurs such that jvm_shutdown() is initiated via exit_init(), then only those components that were fully and properly initialized will be cleaned up. This helps to avoid unnecessary checks for null pointers and invalid data values in uninitialized memory areas.

rboolean jvm_argv_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.
rboolean jvm_class_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.
rboolean jvm_classpath_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.
rboolean jvm_heap_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.
rboolean jvm_model_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.
rboolean jvm_object_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.
rboolean jvm_thread_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.
rboolean jvm_timeslice_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.
rboolean jvm_tmparea_initialized = ((rboolean) 0)
 Permit boolean "false" manifest constant for initializing static and global storage.

Defines

#define MANUAL_THREAD_SHUTDOWN(thridx)
 Bring a thread down from the RUNNING state all the way through DEAD to an empty thread table slot.
#define MANUAL_THREAD_STARTUP(thridx)
 Bring a thread up from the NEW condition all the way to RUNNING.
#define STATE_MODEL_SWITCH(somestate_rc, casebody)
 State model switch statement macro, less the default case.

Functions

rint jvm (int argc, char **argv, char **envp)
 Main entry point for this library implementing the Java Virtural Machine.
static void jvm_c_dummy (void)
static rvoid jvm_init (int argc, char **argv, char **envp)
 Initialize the Java Virtual Machine.
rvoid jvm_manual_thread_run (jvm_thread_index thridx, rboolean shutdown, rchar *clsname, rchar *mthname, rchar *mthdesc)
 Manually start a thread in the JVM execution engine, but outside of the normal runtime loop.
rvoid jvm_model_init ()
 Initialize JVM internal structures.
rvoid jvm_model_shutdown ()
 Shut down the JVM model after JVM execution is finished.
static rvoid jvm_run ()
 Start up JVM execution engine and let Java program code take over.
rvoid jvm_shutdown ()
 Shut down the Java Virtual Machine.
rvoid jvm_signal (int sig)
 Common signal handler to shut down JVM upon receipt of common signals.

Variables

static char * jvm_c_copyright = "\0" "$URL: https://svn.apache.org/path/name/jvm.c $ $Id: jvm.c 0 09/28/2005 dlydick $" " " "Copyright 2005 The Apache Software Foundation or its licensors, as applicable."
rjvmpjvm = ((rvoid *) 0)
 Declared in jvm.c .


Define Documentation

#define MANUAL_THREAD_STARTUP thridx   ) 
 

Value:

Bring a thread up from the NEW condition all the way to RUNNING.

The JVM thread state machine normally takes NEW threads and moves them along through the states as requested by Java code, in particular methods in java.lang.Thread . However, when starting up the JVM, methods like <clinit> and <init> are run from within the initialization. As such, there must be a mechanism to drive the thread machine into the RUNNING state for these special methods. This macro implements such a requirement and is used in several places in jvm_manual_thread_run() and jvm_init().

Notice that all functions run if predecessor returns rtrue. Notice also that threadstate_request_runnable() is a part of the processing of threadstate_process_start() and so is not needed here.

Parameters:
thridx Thread table index of thread containing code to run.
Returns:
rtrue when startup proceeded all the way from the NEW state through to RUNNING, rfalse otherwise.

Definition at line 897 of file jvm.c.

#define MANUAL_THREAD_SHUTDOWN thridx   ) 
 

Value:

((rtrue == threadstate_request_complete(thridx))  && \
 (rtrue == threadstate_activate_complete(thridx)) && \
 (rtrue == threadstate_process_complete(thridx))  && \
 (rtrue == threadstate_activate_dead(thridx))     && \
 (rtrue == thread_die(thridx)))
Bring a thread down from the RUNNING state all the way through DEAD to an empty thread table slot.

See rationale above for MANUAL_THREAD_STARTUP. Notice that all functions run if predecessor returns rtrue. Notice also that threadstate_request_dead() is a part of the processing of threadstate_process_complete() and so is not needed here.

Parameters:
thridx Thread table index of thread to be killed.
Returns:
rtrue when shutdown proceeded all the way from the RUNNING state through to an empty slot, rfalse otherwise.

Definition at line 931 of file jvm.c.

#define STATE_MODEL_SWITCH somestate_rc,
casebody   ) 
 

Value:

case THREAD_STATE_NEW:     somestate_rc = casebody(new); break;    \
    case THREAD_STATE_START:   somestate_rc = casebody(start); break;  \
    case THREAD_STATE_RUNNABLE:somestate_rc = casebody(runnable);break;\
    case THREAD_STATE_RUNNING: somestate_rc = casebody(running); break;\
    case THREAD_STATE_COMPLETE:somestate_rc = casebody(complete);break;\
    case THREAD_STATE_BLOCKINGEVENT:                                   \
                               somestate_rc = casebody(blockingevent); \
                               break;                                  \
    case THREAD_STATE_BLOCKED: somestate_rc = casebody(blocked); break;\
    case THREAD_STATE_UNBLOCKED:somestate_rc=casebody(unblocked);break;\
    case THREAD_STATE_SYNCHRONIZED:                                    \
                               somestate_rc = casebody(synchronized);  \
                               break;                                  \
    case THREAD_STATE_RELEASE: somestate_rc = casebody(release); break;\
    case THREAD_STATE_WAIT:    somestate_rc = casebody(wait); break;   \
    case THREAD_STATE_NOTIFY:  somestate_rc = casebody(notify); break; \
    case THREAD_STATE_LOCK:    somestate_rc = casebody(lock); break;   \
    case THREAD_STATE_ACQUIRE: somestate_rc = casebody(acquire); break;\
    case THREAD_STATE_DEAD:    somestate_rc = casebody(dead); break;   \
    case THREAD_STATE_BADLOGIC:somestate_rc = casebody(badlogic); break;
State model switch statement macro, less the default case.

This macro is used in jvm_run() to implement all three phases of the JVM thread state model for requesting, activating, and processing a thread state. The three phases, REQUEST, ACTIVATE, and PROCESS, are instantiated by passing different parameters to the macro.

Parameters:
somestate_rc Name of return code variable from casebody
casebody Macro name of code to process as the body of each case, not including break statement.
Returns:
Each casebody returns rtrue or rfalse to somestate_rc, which is passed out of the switch() statement.
The final case does include a break statement for completeness, even though each invocation of this macro is also followed by a break statement in its switch().

Definition at line 1103 of file jvm.c.

Referenced by jvm_run().


Function Documentation

static void jvm_c_dummy void   )  [static]
 

Definition at line 700 of file jvm.c.

rvoid jvm_model_init  ) 
 

Initialize JVM internal structures.

Wipe structure, set to all zeroes. Certain of the xxx_init() functions depend on a zeroed structure at initialization time. Once cleared, store off command line parameters from main() as passed into jvm_init().

Must run HEAP_INIT() before calling this function.

DO NOT use sysDbgMsg() here as message level cannot be set until pjvm is initialized.

Parameters: rvoid

Returns:
rvoid

Definition at line 825 of file jvm.c.

rvoid jvm_model_shutdown  ) 
 

Shut down the JVM model after JVM execution is finished.

Parameters: rvoid

Returns:
rvoid

Definition at line 851 of file jvm.c.

rvoid jvm_manual_thread_run jvm_thread_index  thridx,
rboolean  shutdown,
rchar clsname,
rchar mthname,
rchar mthdesc
 

Manually start a thread in the JVM execution engine, but outside of the normal runtime loop.

This is used typically by initialization of the main JVM engine. All parameters except thridx are for the purpose of reporting errors. The thread must have its code loaded and ready to run, and must be in the NEW state. It will be moved into the RUNNING state, allowed to run to completion, and then optionally taken through the COMPLETE state into DEAD, shut down, and the thread terminated.

The thread is typically set up via thread_class_load() in preparation to call this function.

Parameters:
thridx Thread index of thread containing an executable Java program.
shutdown rtrue if thread should be shut down after it finishes running, otherwise rfalse.
clsname Null-terminated string of name of class
mthname Null-terminated string of method to run in class
mthdesc Null-terminated string of method signature
Returns:
rvoid
< This current thread state.

< Next requested thread state.

< Previous actual thread state.

< This current thread state.

< This current thread state.

< Next requested thread state.

Definition at line 973 of file jvm.c.

References exit_jvm(), EXIT_JVM_THREAD, and sysErrMsg().

static rvoid jvm_init int  argc,
char **  argv,
char **  envp
[static]
 

Initialize the Java Virtual Machine.

Set up the pieces necessary to start the JVM running, then load up java.lang.Object and the basic classes that it references, all in the class table. These include:

       java.lang.Object
       <pseudo-class> (byte)
       <pseudo-class> (character)
       <pseudo-class> (double)
       <pseudo-class> (float)
       <pseudo-class> (int)
       <pseudo-class> (long)
       <pseudo-class> (short)
       <pseudo-class> (boolean)
       java.lang.Class
       java.lang.String
       java.lang.Thread
       <startup class from command line>
  
   

All of these will have their <clinit> class initialization methods invoked, if any. The following objects will be created (where pjvm->argcj is the number of command line arguments passed into the program which get passed through to the JVM main() method):

Parameters:
argc Number of entries in argv[] (per main() entry)
argv Command line parameters from main()
envp Environment pointer from main()
Returns:
rvoid
< Convenient alias for DML5

< Initial debug level, may be changed by command line parameter.

< Signed byte

< Unicode character

< Double-precision floating-point value

< Single-precision floating-point value

< Integer

< Long integer

< Signed short

< Boolean, true or false

< Object is an array instead of an object instance

Todo:
Create a java.lang.String as java.lang.String(byte[], int, int) where the call is made, as it were, to java.lang.String.<init>(pjvm->argv[i], 0, strlen(pjvm->argv[i]));
The following jvm_object_hash_null will get replaced by the actual object hash from this operation. What really needs to happen is a function should be written that pushes these arguments onto the JVM stack for this thread and then loads this constructor and runs it in a manner similar to how jvm_manual_thread_run() does it. In fact, this function might be exactly what is needed for this purpose. Simply add some parameters that represent the first and third parameters to the java.lang.String.<init> method and build up a stack frame accordingly.

Note:
This same requirement may be found in class_get_constant_field_attribute() where CONSTANT_String_info needs to get loaded from the class file into an object.
Todo:
POP_FRAME() and do new PUSH_FRAME() with startup class PC (Do new Thread() and hack the PC with startup class main() entry.)
< null-terminated string form of METHOD_CHAR_OPEN_PARM

< null-terminated string form of BASETYPE_CHAR_ARRAY

< null-terminated string form of BASETYPE_CHAR_L

< null-terminated string form of BASETYPE_CHAR_L_TERM

< null-terminated string form of METHOD_CHAR_OPEN_PARM

< null-terminated string form of METHOD_CHAR_VOID

< null-terminated string form of METHOD_CHAR_OPEN_PARM

< null-terminated string form of BASETYPE_CHAR_ARRAY

< null-terminated string form of BASETYPE_CHAR_L

< null-terminated string form of BASETYPE_CHAR_L_TERM

< null-terminated string form of METHOD_CHAR_OPEN_PARM

< null-terminated string form of METHOD_CHAR_VOID

< null-terminated string form of METHOD_CHAR_OPEN_PARM

< null-terminated string form of BASETYPE_CHAR_ARRAY

< null-terminated string form of BASETYPE_CHAR_L

< null-terminated string form of BASETYPE_CHAR_L_TERM

< null-terminated string form of METHOD_CHAR_OPEN_PARM

< null-terminated string form of METHOD_CHAR_VOID

< null-terminated string form of METHOD_CHAR_OPEN_PARM

< null-terminated string form of BASETYPE_CHAR_ARRAY

< null-terminated string form of BASETYPE_CHAR_L

< null-terminated string form of BASETYPE_CHAR_L_TERM

< null-terminated string form of METHOD_CHAR_OPEN_PARM

< null-terminated string form of METHOD_CHAR_VOID

Definition at line 1181 of file jvm.c.

static rvoid jvm_run  )  [static]
 

Start up JVM execution engine and let Java program code take over.

At this point, the class containing main() has been loaded and its class initialization has been performed. The program counter is at the very first instruction of main() and the thread is in the RUNNING state.

Parameters: rvoid

Returns:
rvoid
< Convenient alias for DML1

< Access structures of the thread now running in the JVM.

< Access structures of the thread now running in the JVM.

< Access structures of the thread now running in the JVM.

< This slot contains a thread

< Access structures of the thread now running in the JVM.

< Access structures of the thread now running in the JVM.

< Permit null thread index manifest constant for initializing static and global storage.

< Daemon thread state, vs user thread, per Thread.isdaemon()

< Access structures of the thread now running in the JVM.

               State transition and processing table
               =====================================
              
              
               STATE MODEL PHASE 1:  VERIFY CHANGE
                  Verify whether or not a requested state transition
                  is valid.  Return rtrue if valid, otherwise rfalse.
              
               STATE MODEL PHASE 2:  PERFORM CHANGE
                  Perform known-valid requested state transition.
                  Return rtrue if transition occurred, otherwise rfalse.
              
               STATE MODEL PHASE 3:  PROCESS STATE
                  Perform activities in all states, as long as the
                  state is valid.  Return rtrue if processing occurred,
                  otherwise rfalse.
              
               This logic is the essence of what each of
               the pieces for each state in
               @link src/threadstate.c threadstate.c@endlink
               is all about.  See further comments there.
               

< Access structures of the thread now running in the JVM.

< This current thread state.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< This current thread state.

< Access structures of the thread now running in the JVM.

< Previous actual thread state.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< This current thread state.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< This current thread state.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Activate current thread state, actually moving it from a prior state into a requested state, see link threadstate_activate_new() threadstate_activate_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< This current thread state.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< This current thread state.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Process activities for current thread in its current state, see link threadstate_process_new() threadstate_process_XXX()endlink for specifics.

< Access structures of the thread now running in the JVM.

< Next requested thread state.

< Access structures of the thread now running in the JVM.

< Access structures of the thread now running in the JVM.

< This current thread state.

< Access structures of the thread now running in the JVM.

< Place a thread into requested thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Request that the current thread move into a certain thread state, see link threadstate_request_new() threadstate_request_XXX()endlink for specifics.

< Convenient alias for DML1

Definition at line 1704 of file jvm.c.

References CURRENT_THREAD_REQUEST_NEXT_STATE, NEXT_STATE, PREV_STATE, STATE_MODEL_SWITCH, sysErrMsg(), and THIS_STATE.

rvoid jvm_shutdown  ) 
 

Shut down the Java Virtual Machine.

Use a global for roll call of initialization to determine whether each area has been set up properly in case of abort during initialization.

Parameters: rvoid

Returns:
rvoid

Definition at line 2760 of file jvm.c.

rvoid jvm_signal int  sig  ) 
 

Common signal handler to shut down JVM upon receipt of common signals.

Parameters:
sig Signal number
Returns:
non-local return via exit_jvm()

Definition at line 2864 of file jvm.c.

rint jvm int  argc,
char **  argv,
char **  envp
 

Main entry point for this library implementing the Java Virtural Machine.

Parameters: rvoid

Returns:
rvoid

Definition at line 2885 of file jvm.c.

Referenced by main().


Variable Documentation

char* jvm_c_copyright = "\0" "$URL: https://svn.apache.org/path/name/jvm.c $ $Id: jvm.c 0 09/28/2005 dlydick $" " " "Copyright 2005 The Apache Software Foundation or its licensors, as applicable." [static]
 

Definition at line 700 of file jvm.c.

rjvm* pjvm = ((rvoid *) 0)
 

Declared in jvm.c .

This pointer is initialized by jvm_model_init() and is used extensivel throughout the code, both directly and through macros like CLASS and OBJECT().

Definition at line 732 of file jvm.c.

Referenced by argv_init(), class_allocate_slot(), jvmutil_get_dml(), jvmutil_set_dml(), object_allocate_slot(), object_init(), opcode_run(), thread_init(), thread_state_get_name(), threadutil_update_sleeptime_interval(), timeslice_get_thread_sleeptime(), timeslice_init(), and timeslice_tick().

rboolean jvm_timeslice_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 756 of file jvm.c.

Referenced by timeslice_init(), and timeslice_shutdown().

rboolean jvm_class_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 761 of file jvm.c.

rboolean jvm_object_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 766 of file jvm.c.

Referenced by object_init().

rboolean jvm_thread_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 771 of file jvm.c.

Referenced by thread_init().

rboolean jvm_argv_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 776 of file jvm.c.

Referenced by argv_init().

rboolean jvm_classpath_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 781 of file jvm.c.

rboolean jvm_tmparea_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 786 of file jvm.c.

rboolean jvm_model_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 791 of file jvm.c.

rboolean jvm_heap_initialized = ((rboolean) 0)
 

Permit boolean "false" manifest constant for initializing static and global storage.

Definition at line 796 of file jvm.c.

Referenced by heap_init_bimodal(), and heap_init_simple().


Generated on Fri Sep 30 18:49:56 2005 by  doxygen 1.4.4