Subject: re: ksh lossage on sparc64
To: None <tech-toolchain@NetBSD.ORG>
From: Greg A. Woods <firstname.lastname@example.org>
Date: 11/20/2000 14:39:40
[ On Tuesday, November 21, 2000 at 01:32:18 (+1100), matthew green wrote: ]
> Subject: re: ksh lossage on sparc64
> Anyway: this bug is not related to sparc64 at all, it's a generic gcc 2.95.2
> problem and the ksh source in tree is broken. So this is not the way to fix
> it, it will hit other ports when they migrate to the newer gcc too.
> this happens with other ports? how is the ksh source broken? i don't see
> why it needs the volatile casts anyway...
If a volatile cast is needed then it should always be there on all ports
-- the fact that it breaks only on one or two ports is just an accident
of how the code generation and optimisation works. I.e. the #ifdef
shoudln't be used -- just the content of the #ifdef.
However, even given my vague memories of the guts of pd-ksh, my guess is
that if one "volatile" cast is needed then the complete fix probably
involves adding "volatile" to a number of variable definitions, and
perhaps more casts too. Careful use of lint and GCC compiler warnings
may reveal where these have to go.
Greg A. Woods
+1 416 218-0098 VE3TCP <email@example.com> <robohack!woods>
Planix, Inc. <firstname.lastname@example.org>; Secrets of the Weird <email@example.com>