Re: Languages: The Bigger the Uglier (was: Re: Aliasing in ISO C)

platon!adrian@uunet.uu.net (A Johnstone)
25 Mar 1996 21:47:46 -0500

          From comp.compilers

Related articles
[19 earlier articles]
Re: Languages: The Bigger the Uglier (was: Re: Aliasing in ISO C) WStreett@shell.monmouth.com (1996-03-03)
Re: Languages: The Bigger the Uglier (was: Re: Aliasing in ISO C) jens.hansson@mailbox.swipnet.se (1996-03-06)
Re: Languages: The Bigger the Uglier (was: Re: Aliasing in ISO C) jens.hansson@mailbox.swipnet.se (1996-03-08)
Re: Languages: The Bigger the Uglier (was: Re: Aliasing in ISO C) rfg@monkeys.com (1996-03-10)
Re: Languages: The Bigger the Uglier (was: Re: Aliasing in ISO C) jan@neuroinformatik.ruhr-uni-bochum.de (1996-03-11)
Re: Languages: The Bigger the Uglier (was: Re: Aliasing in ISO C) kanze@lts.sel.alcatel.de (James Kanze US/ESC 60/3/141 #40763) (1996-03-12)
Re: Languages: The Bigger the Uglier (was: Re: Aliasing in ISO C) platon!adrian@uunet.uu.net (1996-03-25)
| List of all articles for this month |

From: platon!adrian@uunet.uu.net (A Johnstone)
Newsgroups: comp.compilers
Date: 25 Mar 1996 21:47:46 -0500
Organization: Royal Holloway, Univ of London
References: 96-02-187 96-03-050 96-03-080 96-03-084
Keywords: standards, arithmetic

James Kanze US/ESC 60/3/141 #40763 (kanze@lts.sel.alcatel.de) wrote:
: There is currently a proposal before the C standardization committee
: to do something like this. It actually goes considerably farther: for
: example, most of the time, you need a minimum of n bits, but sometimes
: you need exactly n bits (in which case, the compiler must typically
: generate masking operations). And when you only need the minimum, you
: may want the actual type optimized for either speed or space.


A few years ago we did some work on an optimising compiler for
bit-serial array processors that kept track of the precision of
operations. We did this because on a bit-serial processor every extra
bit of precision needs an extra cycle to calculate. We could bound the
operations since, when adding two three bit numbers together you knew
that the result would fit in four bits even if you didn't know the
run-time values. This approach worked well for us because we were
doing image processing which is mostly short-integer arithmetic.


We never wrote the work up, although I believe that something similar
was done in the FORTRAN compiler for the ICL DAP. Does anybody know of
any similar work? If C is going to acquire resolution specifiers
then maybe we should revive the work: there's a whole new class of
optimisations here.


                                      Adrian
--
    Dr Adrian Johnstone, Dean of the Science Faculty, Dept of Computer Science,
        Royal Holloway, University of London, Egham, Surrey, TW20 0EX, England.
Email: adrian@dcs.rhbnc.ac.uk Tel: +44 (0)1784 443425 Fax: +44 (0)1784 443420
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.