"Hoehle, Joerg-Cyril" <Joerg-Cyril.Hoehle@...> writes:
> Magnus Henoch writes:
>>I'm trying to build CVS HEAD on NetBSD/sparc64 3.0, with the command
>>line:
>>gcc [...]-g -DDEBUG_OS_ERROR -DDEBUG_SPVW -DDEBUG_BYTECODE -DSAFETY=3
>>-DUNICODE -DNO_GETTEXT -I. -c lisparit.c
>
> Why are you starting with a debug build? Because you encountered
> other problems?
Yes, without the debug option the produced lisp.run failed to start,
with a segfault.
> What version of gcc is this?
gcc (GCC) 3.3.3 (NetBSD nb3 20040520)
>>In file included from lisparit.d:8:
>>lispbibl.d:8962: warning: volatile register variables don't
>>work as you might wish
>>In file included from lisparit.d:36:
>>intdiv.d: In function `I_I_divide_I_I':
>>intdiv.d:312: error: void value not ignored as it ought to be
>>intdiv.d:312: error: void value not ignored as it ought to be
>
> Please try out this change in src/arilev0.d:1175:
> replace divu_6432_3232(...,q=,);}\
> with
> ...,q=,_EMA_);}\
> and reports results. I'm not sure this is it because you use gcc and I would not have expected gcc's cccp to cause trouble here.
I get the same error.
> Otherwise please do
> make lisparit.i
> and try to investigate the section around
> # 285 "intdiv.d"
> static void I_I_divide_I_I (object x, object y)
> ...
> or post the snippet here (or send me whole file, privately).
After narrowing and unwrapping, it turns out that the problem is in
these lines:
_x -= ((uint64)(uint32)(({ register uint32 _lo = mulu32_(_q,((uint32)((uint64)(_y)>>32)));
{ register uint32 _hi __asm__("%g1");
(((uint64)(uint32)(_hi) << 32) | (uint64)(uint32)(_lo));
}
}
)) << 32);
_x -= ({ register uint32 _lo = mulu32_(_q,((uint32)(uint64)(_y)));
{ register uint32 _hi __asm__("%g1");
(((uint64)(uint32)(_hi) << 32) | (uint64)(uint32)(_lo));
}
}
);
which are derived from these lines in arilev0.d:
# x-q*y bilden (eine 32-mal-64-Bit-Multiplikation ohne Überlauf): \
_x -= highlow64_0(mulu32_64(_q,high32(_y))); # q * high32(y) * beta \
# gefahrlos, da q*high32(y) <= q*y/beta <= x/beta < beta \
_x -= mulu32_64(_q,low32(_y)); # q * low32(y) \
Trying to compile this trivial example convinces me that the problem
is the doubly-nested block:
void main(void) {
int i;
/* this causes 'error: void value not ignored as it ought to be' */
i = ({ int j = 1;
{int k = 2;
j + k; } });
printf("%d\n", i);
}
Removing the inner braces before "int k" in this example makes it
compile. I'm not sure how that would be done in the clisp code,
though...
Magnus
|