[sun-sparc-solaris2.6] crash in
ObjectPointer_dispatchTo_arity_above_
Lee Salzman
lsalzman1 at cox.net
Mon Aug 9 11:34:37 PDT 2004
Okay, I walked around with a debugger on a sparc. It seems that
map->dispatchID, while at a proper 8 byte boundary from the start of the
Map struct, is still offset 4 bytes (the GC's allocator only guarentees
4 byte word alignment), which pisses off sparcs. However, the sparc
version of GCC does not seem to have an option like -mno-strict-align to
compile this. A short term fix would be to edit your sources to use
memcpy() where it tries to copy the currentDispatchID into
map->dispatchID.
Lee
On Mon, Aug 09, 2004 at 04:49:13PM +0200, nicolas n pelletier wrote:
> Hello,
>
> Compiling the latest vm.c, vm.h with the lates cvs gave me the
> following warning:
>
> vm.c: In function `PSInterpreter_apply_to_arity_withOptionals_':
> vm.c:3021: warning: assignment from incompatible pointer type
>
> I am using gcc-2.95.2. Disregarding the warning and running the
> generated vm led to a bus error in vm.c:2779.
>
> I recompiled with debug information to get more information about the
> crash, and include it here in the hope it will help.
>
> --
> Nicolas
>
> COPTFLAGS = -g -O0 -fomit-frame-pointer -DNDEBUG=1
>
> (gdb) where
> #0 0x0001928c in ObjectPointer_dispatchTo_arity_above_ (name=265372,
> arguments=0xb0604, n=1, resendMethod=0) at vm.c:2779
> #1 0x00019d28 in PSInterpreter_send_to_through_arity_withOptionals_ (
> i=0xb0624, selector=265372, args=0xb0604, dispatchers=0xb0604, n=1,
> opts=0x0) at vm.c:2979
> #2 0x0001fcd0 in PSInterpreter_sendMessage_withOptionals_ (i=0xb0624, n=1,
> opts=0x0) at vm.c:1012
> #3 0x0001a98c in PSInterpreter_interpret (i=0xb0624) at vm.c:3153
> #4 0x00013a4c in main (argc=2, argv=0xefffaf14)
> at src/mobius/vm/platform/boot.c:95
> (gdb) print name
> $1 = 265372
> (gdb) print *arguments
> $2 = 236700
> (gdb) print n
> $3 = 1
> (gdb) print resendMethod
> $4 = 0
> (gdb) print map
> $5 = (struct Map *) 0xb8db4
> (gdb) print *map
> $6 = {header = {isMarked = 1, isForwarded = 0, idHash = 12220, objectSize = 8,
> objectFormat = 2}, map = 0xb8944, traits = 236900, representative = 236700,
> numDelegates = 7, numSlots = 1, slotTable = 0xb8de4, roleTable = 0xb8e14,
> dispatchID = 0, visitedPositions = 0}
> (gdb) print currentDispatchID
> $7 = 1
> (gdb) up
> #1 0x00019d28 in PSInterpreter_send_to_through_arity_withOptionals_ (
> i=0xb0624, selector=265372, args=0xb0604, dispatchers=0xb0604, n=1,
> opts=0x0) at vm.c:2979
> (gdb) up
> #2 0x0001fcd0 in PSInterpreter_sendMessage_withOptionals_ (i=0xb0624, n=1,
> opts=0x0) at vm.c:1012
> (gdb) print *i
> $8 = {header = {isMarked = 1, isForwarded = 0, idHash = 11549, objectSize = 6,
> objectFormat = 2}, map = 0xb2580, traits = 237000, stack = 0xb05d4,
> method = 0x404e8, lexicalContext = 0x38b68, framePointer = 4,
> codePointer = 7, codeSize = 41808, stackPointer = 8, stackSize = 16}
More information about the Slate
mailing list