Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
c5f72a72
Commit
c5f72a72
authored
Jul 24, 2017
by
Vincent Povirk
Committed by
Alexandre Julliard
Jul 25, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mscoree: Update for mono profiler api v2.
Signed-off-by:
Vincent Povirk
<
vincent@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
6287b3fb
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
1 deletion
+19
-1
metahost.c
dlls/mscoree/metahost.c
+19
-1
No files found.
dlls/mscoree/metahost.c
View file @
c5f72a72
...
...
@@ -71,6 +71,10 @@ static HMODULE mono_handle;
BOOL
is_mono_started
;
static
BOOL
is_mono_shutdown
;
typedef
struct
_MonoProfilerDesc
*
MonoProfilerHandle
;
typedef
void
(
CDECL
*
MonoProfilerRuntimeShutdownBeginCallback
)
(
MonoProfiler
*
prof
);
MonoImage
*
(
CDECL
*
mono_assembly_get_image
)(
MonoAssembly
*
assembly
);
MonoAssembly
*
(
CDECL
*
mono_assembly_load_from
)(
MonoImage
*
image
,
const
char
*
fname
,
MonoImageOpenStatus
*
status
);
MonoAssembly
*
(
CDECL
*
mono_assembly_open
)(
const
char
*
filename
,
MonoImageOpenStatus
*
status
);
...
...
@@ -95,7 +99,9 @@ MonoDomain* (CDECL *mono_object_get_domain)(MonoObject *obj);
MonoMethod
*
(
CDECL
*
mono_object_get_virtual_method
)(
MonoObject
*
obj
,
MonoMethod
*
method
);
MonoObject
*
(
CDECL
*
mono_object_new
)(
MonoDomain
*
domain
,
MonoClass
*
klass
);
void
*
(
CDECL
*
mono_object_unbox
)(
MonoObject
*
obj
);
static
MonoProfilerHandle
(
CDECL
*
mono_profiler_create
)(
MonoProfiler
*
prof
);
static
void
(
CDECL
*
mono_profiler_install
)(
MonoProfiler
*
prof
,
MonoProfileFunc
shutdown_callback
);
static
void
(
CDECL
*
mono_profiler_set_runtime_shutdown_begin_callback
)(
MonoProfilerHandle
handle
,
MonoProfilerRuntimeShutdownBeginCallback
cb
);
MonoType
*
(
CDECL
*
mono_reflection_type_from_name
)(
char
*
name
,
MonoImage
*
image
);
MonoObject
*
(
CDECL
*
mono_runtime_invoke
)(
MonoMethod
*
method
,
void
*
obj
,
void
**
params
,
MonoObject
**
exc
);
void
(
CDECL
*
mono_runtime_object_init
)(
MonoObject
*
this_obj
);
...
...
@@ -199,7 +205,6 @@ static HRESULT load_mono(LPCWSTR mono_path)
LOAD_MONO_FUNCTION
(
mono_object_get_virtual_method
);
LOAD_MONO_FUNCTION
(
mono_object_new
);
LOAD_MONO_FUNCTION
(
mono_object_unbox
);
LOAD_MONO_FUNCTION
(
mono_profiler_install
);
LOAD_MONO_FUNCTION
(
mono_reflection_type_from_name
);
LOAD_MONO_FUNCTION
(
mono_runtime_invoke
);
LOAD_MONO_FUNCTION
(
mono_runtime_object_init
);
...
...
@@ -222,13 +227,26 @@ static HRESULT load_mono(LPCWSTR mono_path)
} while (0);
LOAD_OPT_MONO_FUNCTION
(
mono_image_open_from_module_handle
,
image_open_module_handle_dummy
);
LOAD_OPT_MONO_FUNCTION
(
mono_profiler_create
,
NULL
);
LOAD_OPT_MONO_FUNCTION
(
mono_profiler_install
,
NULL
);
LOAD_OPT_MONO_FUNCTION
(
mono_profiler_set_runtime_shutdown_begin_callback
,
NULL
);
LOAD_OPT_MONO_FUNCTION
(
mono_set_crash_chaining
,
set_crash_chaining_dummy
);
LOAD_OPT_MONO_FUNCTION
(
mono_trace_set_print_handler
,
set_print_handler_dummy
);
LOAD_OPT_MONO_FUNCTION
(
mono_trace_set_printerr_handler
,
set_print_handler_dummy
);
#undef LOAD_OPT_MONO_FUNCTION
if
(
mono_profiler_create
!=
NULL
)
{
/* Profiler API v2 */
MonoProfilerHandle
handle
=
mono_profiler_create
(
NULL
);
mono_profiler_set_runtime_shutdown_begin_callback
(
handle
,
mono_shutdown_callback_fn
);
}
else
if
(
mono_profiler_install
!=
NULL
)
{
/* Profiler API v1 */
mono_profiler_install
(
NULL
,
mono_shutdown_callback_fn
);
}
mono_set_crash_chaining
(
TRUE
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment