#include "debug_malloc.h"

Go to the source code of this file.
Defines | |
| #define | WITH_LOCAL_REFS(env, number) |
| #define | END_WITH_LOCAL_REFS |
| #define | CHECK_EXCEPTIONS(env) |
| #define | END_CHECK_EXCEPTIONS |
| #define | HPROF_MALLOC(size) hprof_malloc(size) |
| #define | HPROF_FREE(ptr) hprof_free(ptr) |
Functions | |
| JNIEnv * | getEnv (void) |
| jobject | newGlobalReference (JNIEnv *env, jobject object) |
| jobject | newWeakGlobalReference (JNIEnv *env, jobject object) |
| void | deleteGlobalReference (JNIEnv *env, jobject object) |
| jobject | newLocalReference (JNIEnv *env, jobject object) |
| void | deleteLocalReference (JNIEnv *env, jobject object) |
| void | deleteWeakGlobalReference (JNIEnv *env, jobject object) |
| jclass | getObjectClass (JNIEnv *env, jobject object) |
| jmethodID | getMethodID (JNIEnv *env, jclass clazz, const char *name, const char *sig) |
| jclass | getSuperclass (JNIEnv *env, jclass klass) |
| jmethodID | getStaticMethodID (JNIEnv *env, jclass clazz, const char *name, const char *sig) |
| jfieldID | getStaticFieldID (JNIEnv *env, jclass clazz, const char *name, const char *sig) |
| jclass | findClass (JNIEnv *env, const char *name) |
| void | setStaticIntField (JNIEnv *env, jclass clazz, jfieldID field, jint value) |
| jboolean | isSameObject (JNIEnv *env, jobject o1, jobject o2) |
| void | pushLocalFrame (JNIEnv *env, jint capacity) |
| void | popLocalFrame (JNIEnv *env, jobject ret) |
| jobject | exceptionOccurred (JNIEnv *env) |
| void | exceptionDescribe (JNIEnv *env) |
| void | exceptionClear (JNIEnv *env) |
| void | registerNatives (JNIEnv *env, jclass clazz, JNINativeMethod *methods, jint count) |
| char * | getErrorName (jvmtiError error_number) |
| jvmtiPhase | getPhase (void) |
| char * | phaseString (jvmtiPhase phase) |
| void | disposeEnvironment (void) |
| jlong | getObjectSize (jobject object) |
| jobject | getClassLoader (jclass klass) |
| jint | getClassStatus (jclass klass) |
| jlong | getTag (jobject object) |
| void | setTag (jobject object, jlong tag) |
| void | getObjectMonitorUsage (jobject object, jvmtiMonitorUsage *uinfo) |
| void | getOwnedMonitorInfo (jthread thread, jobject **ppobjects, jint *pcount) |
| void | getSystemProperty (const char *name, char **value) |
| void | getClassSignature (jclass klass, char **psignature, char **pgeneric_signature) |
| void | getSourceFileName (jclass klass, char **src_name_ptr) |
| jvmtiPrimitiveType | sigToPrimType (char *sig) |
| int | sigToPrimSize (char *sig) |
| char | primTypeToSigChar (jvmtiPrimitiveType primType) |
| void | getAllClassFieldInfo (JNIEnv *env, jclass klass, jint *field_count_ptr, FieldInfo **fields_ptr) |
| void | getMethodName (jmethodID method, char **name_ptr, char **signature_ptr) |
| void | getMethodClass (jmethodID method, jclass *pclazz) |
| jboolean | isMethodNative (jmethodID method) |
| void | getPotentialCapabilities (jvmtiCapabilities *capabilities) |
| void | addCapabilities (jvmtiCapabilities *capabilities) |
| void | setEventCallbacks (jvmtiEventCallbacks *pcallbacks) |
| void | setEventNotificationMode (jvmtiEventMode mode, jvmtiEvent event, jthread thread) |
| void * | getThreadLocalStorage (jthread thread) |
| void | setThreadLocalStorage (jthread thread, void *ptr) |
| void | getThreadState (jthread thread, jint *threadState) |
| void | getThreadInfo (jthread thread, jvmtiThreadInfo *info) |
| void | getThreadGroupInfo (jthreadGroup thread_group, jvmtiThreadGroupInfo *info) |
| void | getLoadedClasses (jclass **ppclasses, jint *pcount) |
| jint | getLineNumber (jmethodID method, jlocation location) |
| jlong | getMaxMemory (JNIEnv *env) |
| void | createAgentThread (JNIEnv *env, const char *name, jvmtiStartFunction func) |
| jlong | getThreadCpuTime (jthread thread) |
| void | getStackTrace (jthread thread, jvmtiFrameInfo *pframes, jint depth, jint *pcount) |
| void | getThreadListStackTraces (jint count, jthread *threads, jint depth, jvmtiStackInfo **stack_info) |
| void | getFrameCount (jthread thread, jint *pcount) |
| void | followReferences (jvmtiHeapCallbacks *pHeapCallbacks, void *user_data) |
| void | runGC (void) |
| void | getJvmti (void) |
| jint | jvmtiVersion (void) |
| jrawMonitorID | createRawMonitor (const char *str) |
| void | rawMonitorEnter (jrawMonitorID m) |
| void | rawMonitorWait (jrawMonitorID m, jlong pause_time) |
| void | rawMonitorNotifyAll (jrawMonitorID m) |
| void | rawMonitorExit (jrawMonitorID m) |
| void | destroyRawMonitor (jrawMonitorID m) |
| void * | jvmtiAllocate (int size) |
| void | jvmtiDeallocate (void *ptr) |
| void * | hprof_malloc (int size) |
| void | hprof_free (void *ptr) |
| #define CHECK_EXCEPTIONS | ( | env | ) |
{ \
JNIEnv *_env = (env); \
jobject _exception; \
_exception = exceptionOccurred(_env); \
if ( _exception != NULL ) { \
exceptionDescribe(_env); \
HPROF_ERROR(JNI_TRUE, "Unexpected Exception found beforehand");\
} \
{
Definition at line 53 of file hprof_util.h.
| #define END_CHECK_EXCEPTIONS |
} \
_exception = exceptionOccurred(_env); \
if ( _exception != NULL ) { \
exceptionDescribe(_env); \
HPROF_ERROR(JNI_TRUE, "Unexpected Exception found afterward");\
} \
}
Definition at line 64 of file hprof_util.h.
| #define END_WITH_LOCAL_REFS |
} /* END OF WITH SCOPE */ \ popLocalFrame(_env, NULL); \ }
Definition at line 47 of file hprof_util.h.
| #define HPROF_FREE | ( | ptr | ) | hprof_free(ptr) |
Definition at line 187 of file hprof_util.h.
| #define HPROF_MALLOC | ( | size | ) | hprof_malloc(size) |
Definition at line 186 of file hprof_util.h.
| #define WITH_LOCAL_REFS | ( | env, | |||
| number | ) |
{ \
JNIEnv *_env = (env); \
pushLocalFrame(_env, number); \
{
Definition at line 41 of file hprof_util.h.
| void addCapabilities | ( | jvmtiCapabilities * | capabilities | ) |
Definition at line 1293 of file hprof_util.c.


| void createAgentThread | ( | JNIEnv * | env, | |
| const char * | name, | |||
| jvmtiStartFunction | func | |||
| ) |
Definition at line 1530 of file hprof_util.c.


| jrawMonitorID createRawMonitor | ( | const char * | str | ) |
| void deleteGlobalReference | ( | JNIEnv * | env, | |
| jobject | object | |||
| ) |
| void deleteLocalReference | ( | JNIEnv * | env, | |
| jobject | object | |||
| ) |
| void deleteWeakGlobalReference | ( | JNIEnv * | env, | |
| jobject | object | |||
| ) |
| void destroyRawMonitor | ( | jrawMonitorID | m | ) |
| void disposeEnvironment | ( | void | ) |
Definition at line 684 of file hprof_util.c.
| void exceptionClear | ( | JNIEnv * | env | ) |
| void exceptionDescribe | ( | JNIEnv * | env | ) |
Definition at line 343 of file hprof_util.c.
| jobject exceptionOccurred | ( | JNIEnv * | env | ) |
Definition at line 337 of file hprof_util.c.
| jclass findClass | ( | JNIEnv * | env, | |
| const char * | name | |||
| ) |
| void followReferences | ( | jvmtiHeapCallbacks * | pHeapCallbacks, | |
| void * | user_data | |||
| ) |
| void getAllClassFieldInfo | ( | JNIEnv * | env, | |
| jclass | klass, | |||
| jint * | field_count_ptr, | |||
| FieldInfo ** | fields_ptr | |||
| ) |
Definition at line 1202 of file hprof_util.c.


| jobject getClassLoader | ( | jclass | klass | ) |
| void getClassSignature | ( | jclass | klass, | |
| char ** | psignature, | |||
| char ** | pgeneric_signature | |||
| ) |
Definition at line 839 of file hprof_util.c.


| jint getClassStatus | ( | jclass | klass | ) |
| JNIEnv* getEnv | ( | void | ) |
Definition at line 63 of file hprof_util.c.


| char* getErrorName | ( | jvmtiError | error_number | ) |
| void getFrameCount | ( | jthread | thread, | |
| jint * | pcount | |||
| ) |
| void getJvmti | ( | void | ) |
Definition at line 1683 of file hprof_util.c.


| jint getLineNumber | ( | jmethodID | method, | |
| jlocation | location | |||
| ) |
Definition at line 1485 of file hprof_util.c.


| void getLoadedClasses | ( | jclass ** | ppclasses, | |
| jint * | pcount | |||
| ) |
| jlong getMaxMemory | ( | JNIEnv * | env | ) |
Definition at line 1506 of file hprof_util.c.


| void getMethodClass | ( | jmethodID | method, | |
| jclass * | pclazz | |||
| ) |
| jmethodID getMethodID | ( | JNIEnv * | env, | |
| jclass | clazz, | |||
| const char * | name, | |||
| const char * | sig | |||
| ) |
Definition at line 456 of file hprof_util.c.


| void getMethodName | ( | jmethodID | method, | |
| char ** | name_ptr, | |||
| char ** | signature_ptr | |||
| ) |
Definition at line 1261 of file hprof_util.c.


| jclass getObjectClass | ( | JNIEnv * | env, | |
| jobject | object | |||
| ) |
| void getObjectMonitorUsage | ( | jobject | object, | |
| jvmtiMonitorUsage * | uinfo | |||
| ) |
| jlong getObjectSize | ( | jobject | object | ) |
| void getOwnedMonitorInfo | ( | jthread | thread, | |
| jobject ** | ppobjects, | |||
| jint * | pcount | |||
| ) |
| jvmtiPhase getPhase | ( | void | ) |
| void getPotentialCapabilities | ( | jvmtiCapabilities * | capabilities | ) |
Definition at line 1279 of file hprof_util.c.


| void getSourceFileName | ( | jclass | klass, | |
| char ** | src_name_ptr | |||
| ) |
| void getStackTrace | ( | jthread | thread, | |
| jvmtiFrameInfo * | pframes, | |||
| jint | depth, | |||
| jint * | pcount | |||
| ) |
| jfieldID getStaticFieldID | ( | JNIEnv * | env, | |
| jclass | clazz, | |||
| const char * | name, | |||
| const char * | sig | |||
| ) |
| jmethodID getStaticMethodID | ( | JNIEnv * | env, | |
| jclass | clazz, | |||
| const char * | name, | |||
| const char * | sig | |||
| ) |
| jclass getSuperclass | ( | JNIEnv * | env, | |
| jclass | klass | |||
| ) |
| void getSystemProperty | ( | const char * | name, | |
| char ** | value | |||
| ) |
| jlong getTag | ( | jobject | object | ) |
| jlong getThreadCpuTime | ( | jthread | thread | ) |
Definition at line 1588 of file hprof_util.c.
| void getThreadGroupInfo | ( | jthreadGroup | thread_group, | |
| jvmtiThreadGroupInfo * | info | |||
| ) |
| void getThreadInfo | ( | jthread | thread, | |
| jvmtiThreadInfo * | info | |||
| ) |
| void getThreadListStackTraces | ( | jint | count, | |
| jthread * | threads, | |||
| jint | depth, | |||
| jvmtiStackInfo ** | stack_info | |||
| ) |
| void* getThreadLocalStorage | ( | jthread | thread | ) |
| void getThreadState | ( | jthread | thread, | |
| jint * | threadState | |||
| ) |
| void hprof_free | ( | void * | ptr | ) |
Definition at line 166 of file hprof_util.c.
| void* hprof_malloc | ( | int | size | ) |
Definition at line 153 of file hprof_util.c.
| jboolean isMethodNative | ( | jmethodID | method | ) |
| jboolean isSameObject | ( | JNIEnv * | env, | |
| jobject | o1, | |||
| jobject | o2 | |||
| ) |
| void* jvmtiAllocate | ( | int | size | ) |
| void jvmtiDeallocate | ( | void * | ptr | ) |
| jint jvmtiVersion | ( | void | ) |
| jobject newGlobalReference | ( | JNIEnv * | env, | |
| jobject | object | |||
| ) |
| jobject newLocalReference | ( | JNIEnv * | env, | |
| jobject | object | |||
| ) |
| jobject newWeakGlobalReference | ( | JNIEnv * | env, | |
| jobject | object | |||
| ) |
| char* phaseString | ( | jvmtiPhase | phase | ) |
| void popLocalFrame | ( | JNIEnv * | env, | |
| jobject | ret | |||
| ) |
Definition at line 614 of file hprof_util.c.
| char primTypeToSigChar | ( | jvmtiPrimitiveType | primType | ) |
| void pushLocalFrame | ( | JNIEnv * | env, | |
| jint | capacity | |||
| ) |
Definition at line 600 of file hprof_util.c.
| void rawMonitorEnter | ( | jrawMonitorID | m | ) |
| void rawMonitorExit | ( | jrawMonitorID | m | ) |
| void rawMonitorNotifyAll | ( | jrawMonitorID | m | ) |
| void rawMonitorWait | ( | jrawMonitorID | m, | |
| jlong | pause_time | |||
| ) |
| void registerNatives | ( | JNIEnv * | env, | |
| jclass | clazz, | |||
| JNINativeMethod * | methods, | |||
| jint | count | |||
| ) |
| void runGC | ( | void | ) |
| void setEventCallbacks | ( | jvmtiEventCallbacks * | pcallbacks | ) |
| void setEventNotificationMode | ( | jvmtiEventMode | mode, | |
| jvmtiEvent | event, | |||
| jthread | thread | |||
| ) |
| void setStaticIntField | ( | JNIEnv * | env, | |
| jclass | clazz, | |||
| jfieldID | field, | |||
| jint | value | |||
| ) |
| void setTag | ( | jobject | object, | |
| jlong | tag | |||
| ) |
| void setThreadLocalStorage | ( | jthread | thread, | |
| void * | ptr | |||
| ) |
| int sigToPrimSize | ( | char * | sig | ) |
| jvmtiPrimitiveType sigToPrimType | ( | char * | sig | ) |
1.6.1