diff options
author | tromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-11-25 03:47:08 +0000 |
---|---|---|
committer | tromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-11-25 03:47:08 +0000 |
commit | a4ccc41f9a5f050d518b8c30739a647f67756f9e (patch) | |
tree | 477abdf83653e20b0e74447d6ca47eb67b0511b8 /libjava/include/java-interp.h | |
parent | 2f3c6e08b9d664df3e416a186fd2938de188e706 (diff) | |
download | gcc-a4ccc41f9a5f050d518b8c30739a647f67756f9e.tar.gz |
* Merged gcj-abi-2-dev-branch to trunk.
(Actual changes too large to list in the commit message;
see ChangeLog.)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@91270 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/include/java-interp.h')
-rw-r--r-- | libjava/include/java-interp.h | 50 |
1 files changed, 11 insertions, 39 deletions
diff --git a/libjava/include/java-interp.h b/libjava/include/java-interp.h index 12bc21f2436..c8e041ae387 100644 --- a/libjava/include/java-interp.h +++ b/libjava/include/java-interp.h @@ -1,6 +1,6 @@ // java-interp.h - Header file for the bytecode interpreter. -*- c++ -*- -/* Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation +/* Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation This file is part of libgcj. @@ -36,7 +36,8 @@ _Jv_IsInterpretedClass (jclass c) struct _Jv_ResolvedMethod; void _Jv_InitInterpreter (); -void _Jv_DefineClass (jclass, jbyteArray, jint, jint); +void _Jv_DefineClass (jclass, jbyteArray, jint, jint, + java::security::ProtectionDomain *); void _Jv_InitField (jobject, jclass, int); void * _Jv_AllocMethodInvocation (jsize size); @@ -88,11 +89,7 @@ protected: // Size of raw arguments. _Jv_ushort args_raw_size; - // Chain of addresses to fill in. See _Jv_Defer_Resolution. - void *deferred; - - friend void _Jv_Defer_Resolution (void *cl, _Jv_Method *meth, void **); - friend void _Jv_PrepareClass(jclass); + friend class _Jv_InterpreterEngine; public: _Jv_Method *get_method () @@ -150,10 +147,9 @@ class _Jv_InterpMethod : public _Jv_MethodBase friend class _Jv_BytecodeVerifier; friend class gnu::gcj::runtime::NameFinder; friend class gnu::gcj::runtime::StackTrace; + friend class _Jv_InterpreterEngine; - friend void _Jv_PrepareClass(jclass); - #ifdef JV_MARKOBJ_DECL friend JV_MARKOBJ_DECL; #endif @@ -166,43 +162,15 @@ class _Jv_InterpClass friend class _Jv_ClassReader; friend class _Jv_InterpMethod; - friend void _Jv_PrepareClass(jclass); - friend void _Jv_PrepareMissingMethods (jclass base2, jclass iface_class); + friend class _Jv_InterpreterEngine; friend void _Jv_InitField (jobject, jclass, int); #ifdef JV_MARKOBJ_DECL friend JV_MARKOBJ_DECL; #endif friend _Jv_MethodBase ** _Jv_GetFirstMethod (_Jv_InterpClass *klass); - friend void _Jv_Defer_Resolution (void *cl, _Jv_Method *meth, void **); }; -// We have an interpreted class CL and we're trying to find the -// address of the ncode of a method METH. That interpreted class -// hasn't yet been prepared, so we defer fixups until they are ready. -// To do this, we create a chain of fixups that will be resolved by -// _Jv_PrepareClass. -extern inline void -_Jv_Defer_Resolution (void *cl, _Jv_Method *meth, void **address) -{ - int i; - jclass self = (jclass) cl; - _Jv_InterpClass *interp_cl = (_Jv_InterpClass*) self->aux_info; - - for (i = 0; i < self->method_count; i++) - { - _Jv_Method *m = &self->methods[i]; - if (m == meth) - { - _Jv_MethodBase *imeth = interp_cl->interpreted_methods[i]; - *address = imeth->deferred; - imeth->deferred = address; - return; - } - } - return; -} - extern inline _Jv_MethodBase ** _Jv_GetFirstMethod (_Jv_InterpClass *klass) { @@ -240,7 +208,11 @@ class _Jv_JNIMethod : public _Jv_MethodBase void *ncode (); friend class _Jv_ClassReader; - friend void _Jv_PrepareClass(jclass); + friend class _Jv_InterpreterEngine; + +#ifdef JV_MARKOBJ_DECL + friend JV_MARKOBJ_DECL; +#endif public: // FIXME: this is ugly. |