Global register variables on Sparc

Ken Shan ken@digitas.harvard.edu
Sat, 1 Sep 2001 14:27:49 -0400


--SUOF0GtieIMvvwua
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On 2001-07-26T10:43:13+0100, Simon Marlow wrote:
> > Using GHC 5.00.2 on Sparc (Solaris 2.7) yields
> >=20
> >    warning: call-clobbered register used for global register variable
> >=20
> > when -Wall is given (for registers F1, F2, F3, F4, D1, and D2).
> > Nevertheless, things seem to work fine. Is this only an artifact of
> > -Wall or something more serious?
>=20
> It's harmless.  It means that some of the registers we steal are
> caller-saves registers, so calling a library routine that wasn't
> compiled with these register declarations will cause the registers to be
> clobbered.  But we are indeed careful to save these registers around
> calls, so everything is ok.
>=20
> GHC's driver used to filter out these warnings, but it doesn't any more.
> I guess we should reinstate that at some point.

So, what's the best way to do this?  It would be really useful, for
the sake of comparing testsuite output and so on, to filter out these
spurious warning messages.  Ideally, if gcc says something like

    in file included from xxx.h:
                          yyy.h:
    zzz.h: warning: spurious warning

then we should filter out all three lines.  What's the best way to
filter standard error in Haskell?  I suppose it would be ideal to
avoid the posix library, but it seems difficult.

--=20
Edit this signature at http://www.digitas.harvard.edu/cgi-bin/ken/sig
<This space for rent>

--SUOF0GtieIMvvwua
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE7kSilzjAc4f+uuBURAlB3AJ41RvHa1clCpPL7rFwBjZMCyFgUTACfQpaV
tjlfMv9AtKjnb/v5H6k/bH8=
=bGaH
-----END PGP SIGNATURE-----

--SUOF0GtieIMvvwua--