* configure.ac: New switch for disabling -O2 (--disable-optimizations).
[cacao.git] / src / vm / vm.hpp
index 30242d4f07e6b604d212c121d4f6059b27269307..0430fa4d6a30be141f7a43469bd9cd9352ecca36 100644 (file)
@@ -65,6 +65,7 @@ private:
        bool    _created;
        bool    _exiting;
        int64_t _starttime;
+       int64_t _inittime;
 
        // Subsystems.
        Properties      _properties;      ///< Commandline properties.
@@ -77,6 +78,9 @@ private:
 #endif
        NativeLibraries _nativelibraries; ///< Native library table.
        NativeMethods   _nativemethods;   ///< Native methods table.
+#if defined(ENABLE_JVMTI)
+       NativeAgents    _nativeagents;    ///< Native agents table.
+#endif
        SuckClasspath   _suckclasspath;   ///< Classpath entries list.
 
 public:
@@ -98,6 +102,7 @@ public:
        bool    is_created()      { return _created; }
        bool    is_exiting()      { return _exiting; }
        int64_t get_starttime()   { return _starttime; }
+       int64_t get_inittime()    { return _inittime; }
 
        Properties&      get_properties     () { return _properties; }
        Recompiler&      get_recompiler     () { return _recompiler; } // REMOVEME
@@ -108,15 +113,15 @@ public:
        NativeLibraries& get_nativelibraries() { return _nativelibraries; }
        NativeMethods&   get_nativemethods  () { return _nativemethods; }
        SuckClasspath&   get_suckclasspath  () { return _suckclasspath; }
+
+private:
+       // Internal helper methods.
+       bool start_runtime_agents();
 };
 
 #else
 
-JavaVM* VM_get_javavm();
 JNIEnv* VM_get_jnienv();
-bool    VM_is_initializing();
-bool    VM_is_created();
-int64_t VM_get_starttime();
 
 #endif
 
@@ -152,9 +157,6 @@ extern uint8_t* intrp_main_stack;
 extern "C" {
 #endif
 
-void usage(void);
-
-bool vm_create(JavaVMInitArgs *vm_args);
 void vm_run(JavaVM *vm, JavaVMInitArgs *vm_args);
 int32_t   vm_destroy(JavaVM *vm);
 void vm_exit(int32_t status);