[profiler] Rename mono_profiler_install to mono_profiler_create.
[mono.git] / mono / mini / debugger-agent.c
index acabbbdb0930d55a8b68d838005efc6ee6e145a1..b625580c1fe4c347fedcc46b41f7473db085cc88 100644 (file)
@@ -595,11 +595,6 @@ typedef struct {
        MonoClass *klass;
 } EventInfo;
 
-/* Dummy structure used for the profiler callbacks */
-typedef struct {
-       void* dummy;
-} DebuggerProfiler;
-
 typedef struct {
        guint8 *buf, *p, *end;
 } Buffer;
@@ -700,8 +695,6 @@ static MonoCoopCond debugger_thread_exited_cond;
 /* Mutex for the cond var above */
 static MonoCoopMutex debugger_thread_exited_mutex;
 
-static DebuggerProfiler debugger_profiler;
-
 /* The single step request instance */
 static SingleStepReq *ss_req;
 
@@ -745,9 +738,9 @@ static void runtime_initialized (MonoProfiler *prof);
 
 static void runtime_shutdown (MonoProfiler *prof);
 
-static void thread_startup (MonoProfiler *prof, uint64_t tid);
+static void thread_startup (MonoProfiler *prof, uintptr_t tid);
 
-static void thread_end (MonoProfiler *prof, uint64_t tid);
+static void thread_end (MonoProfiler *prof, uintptr_t tid);
 
 static void appdomain_load (MonoProfiler *prof, MonoDomain *domain);
 
@@ -999,7 +992,7 @@ mono_debugger_agent_init (void)
        mono_coop_mutex_init (&debugger_thread_exited_mutex);
        mono_coop_cond_init (&debugger_thread_exited_cond);
 
-       MonoProfilerHandle prof = mono_profiler_install ((MonoProfiler*)&debugger_profiler);
+       MonoProfilerHandle prof = mono_profiler_create (NULL);
        mono_profiler_set_runtime_shutdown_end_callback (prof, runtime_shutdown);
        mono_profiler_set_runtime_initialized_callback (prof, runtime_initialized);
        mono_profiler_set_domain_loaded_callback (prof, appdomain_load);
@@ -3870,7 +3863,7 @@ runtime_shutdown (MonoProfiler *prof)
 }
 
 static void
-thread_startup (MonoProfiler *prof, uint64_t tid)
+thread_startup (MonoProfiler *prof, uintptr_t tid)
 {
        MonoInternalThread *thread = mono_thread_internal_current ();
        MonoInternalThread *old_thread;
@@ -3931,7 +3924,7 @@ thread_startup (MonoProfiler *prof, uint64_t tid)
 }
 
 static void
-thread_end (MonoProfiler *prof, uint64_t tid)
+thread_end (MonoProfiler *prof, uintptr_t tid)
 {
        MonoInternalThread *thread;
        DebuggerTlsData *tls = NULL;