[Mono-list] Nasty x86_magic_trampoline gremlin: ambiguous call
sequences
Eric Kidd
eric.kidd@pobox.com
24 Feb 2002 14:57:29 -0500
On Sun, 2002-02-24 at 12:24, Paolo Molaro wrote:
> There is some support to write out stab information that you can later
> load in gdb: it's not complete and it has the limitation of the stab
> format, but it may be useful. A brief doc explains how to use it in
> mono/docs/jit-debug. It's more useful if the jit can compile all the
> methods of a class you need to debug.
Oooh, pretty. :-) My segfault is happening somewhere down here:
#0 0x48f7c094 in Mono_CSharp_FieldExpr__Emit_0x820f0d8 (this=0x81b5df8,
ec=0x81bd1a8) at mcs.il:46228
#1 0x48ebf29d in Mono_CSharp_Invocation__EmitCall_0x82420a8 (ec=0x81bd1a8,
is_base=0 '\000', is_static=0 '\000', instance_expr=0x81b5df8,
method=0x8216c08, Arguments=0x82854e0) at mcs.il:56267
#2 0x4946805a in Mono_CSharp_DelegateInvocation__Emit_0x81de648 (
this=0x81bd600, ec=0x81bd1a8) at mcs.il:39038
The code around the PC appears as follows:
(gdb) disassemble 0x48f7c094-20 0x48f7c094+20
Dump of assembler code from 0x48f7c080 to 0x48f7c0a8:
0x48f7c080 <Mono_CSharp_FieldExpr__Emit_0x820f0d8+120>: mov $0x1,%eax
0x48f7c085 <Mono_CSharp_FieldExpr__Emit_0x820f0d8+125>:
mov %al,0xfffffffb(%ebp)
0x48f7c088 <Mono_CSharp_FieldExpr__Emit_0x820f0d8+128>:
mov 0xfffffff4(%ebp),%eax
0x48f7c08b <Mono_CSharp_FieldExpr__Emit_0x820f0d8+131>:
mov %eax,0xffffffe4(%ebp)
0x48f7c08e <Mono_CSharp_FieldExpr__Emit_0x820f0d8+134>:
mov 0xffffffe4(%ebp),%eax
0x48f7c091 <Mono_CSharp_FieldExpr__Emit_0x820f0d8+137>:
mov 0xffffffe4(%ebp),%ecx
0x48f7c094 <Mono_CSharp_FieldExpr__Emit_0x820f0d8+140>: movzbl 0x24(%ecx),%ecx
0x48f7c098 <Mono_CSharp_FieldExpr__Emit_0x820f0d8+144>: mov $0x2,%edx
0x48f7c09d <Mono_CSharp_FieldExpr__Emit_0x820f0d8+149>: or %edx,%ecx
0x48f7c09f <Mono_CSharp_FieldExpr__Emit_0x820f0d8+151>: mov %cl,0x24(%eax)
0x48f7c0a2 <Mono_CSharp_FieldExpr__Emit_0x820f0d8+154>: mov 0x8(%ebp),%ebx
0x48f7c0a5 <Mono_CSharp_FieldExpr__Emit_0x820f0d8+157>: mov 0x10(%ebx),%ebx
End of assembler dump.
(gdb) p $ecx
$1 = 0
(gdb) p $ebp
$2 = (void *) 0xbffff600
Now that I've got debugging symbols, I've got a *much* better chance of
figuring out what's going on. ;-)
Are there any C functions buried down somewhere in the runtime which
could be called from GDB to call ToString on a value?
Cheers,
Eric