[Mono-devel-list] tramp-s390 changes
Zoltan Varga
vargaz at gmail.com
Mon Dec 6 19:00:12 EST 2004
Hi,
I think this is because mini-s390<X>.c includes calls to
mono_arch_create_jit_trampoline.
These calls should be changed to mono_create_jit_trampoline ().
Zoltan
On Mon, 6 Dec 2004 18:47:23 -0500, neale.ferguson at softwareag-usa.com
<neale.ferguson at softwareag-usa.com> wrote:
> I followed the changes made by Zoltan in:
>
> tramp-x86.c (mono_arch_create_jit_trampoline): Remove code which is
> now in the xp code.
>
> Now, synchronized.exe fails:
>
> Unhandled Exception: System.Threading.SynchronizationLockException: Not
> locked
> in (unmanaged) (wrapper managed-to-native)
> System.Threading.Monitor:Monitor_exit (object)
> in <0x00000050> (wrapper managed-to-native)
> System.Threading.Monitor:Monitor_exit (object)
> in <0x0000006e> System.Threading.Monitor:Exit (object)
> in <0x0000001c> Test:test ()
> in <0x000000a6> Test:Main (string[])
>
> I've backed out that change and it's working again. Are there any
> implications keeping the code as it was?
>
> --- tramp-s390.c 2004-12-06 18:38:35.131265460 -0500
> +++ tramp-s390.c 2004-12-02 17:09:07.000000000 -0500
> @@ -549,16 +549,10 @@
> {
> guint8 *code, *buf;
> static guint8 *vc = NULL;
> gint32 displace;
>
> - if (method->info)
> - return (method->info);
> -
> - if (method->iflags & METHOD_IMPL_ATTRIBUTE_SYNCHRONIZED)
> - return (mono_arch_create_jit_trampoline
> (mono_marshal_get_synchronized_wrapper (method)));
> -
> vc = create_trampoline_code (MONO_TRAMPOLINE_GENERIC);
>
> /* This is the method-specific part of the trampoline. Its
> purpose is
> to provide the generic part with the MonoMethod *method pointer.
> We'll
> use r13 to keep that value, for instance. However, the generic
> part of
> @@ -577,13 +571,10 @@
> mono_arch_flush_icache (code, buf - code);
>
> /* Sanity check */
> g_assert ((buf - code) <= METHOD_TRAMPOLINE_SIZE);
>
> - method->info = code;
> - mono_jit_stats.method_trampolines++;
> -
> return code;
> }
>
> Neale
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
>
More information about the Mono-devel-list
mailing list