7127792: Add the ability to change an existing PeriodicTask's execution interval

Enables dynamic enrollment / disenrollment from the PeriodicTasks in WatcherThread.

Reviewed-by: dholmes, mgronlun
This commit is contained in:
Rickard Bäckman 2012-10-04 14:55:57 +02:00
parent 61a5a58cb1
commit e1d995ab86
6 changed files with 162 additions and 92 deletions

View file

@ -140,6 +140,7 @@ Monitor* JfrQuery_lock = NULL;
Monitor* JfrMsg_lock = NULL;
Mutex* JfrBuffer_lock = NULL;
Mutex* JfrStream_lock = NULL;
Monitor* PeriodicTask_lock = NULL;
#define MAX_NUM_MUTEX 128
static Monitor * _mutex_array[MAX_NUM_MUTEX];
@ -285,6 +286,7 @@ void mutex_init() {
def(JfrMsg_lock , Monitor, nonleaf+2, true);
def(JfrBuffer_lock , Mutex, nonleaf+3, true);
def(JfrStream_lock , Mutex, nonleaf+4, true);
def(PeriodicTask_lock , Monitor, nonleaf+5, true);
}
GCMutexLocker::GCMutexLocker(Monitor * mutex) {