|[9 earlier articles]|
|Re: register variables in C. metaware!miker@uunet.UU.NET (1992-05-01)|
|Re: register variables in C. firstname.lastname@example.org (1992-05-01)|
|Re: register variables in C. email@example.com (1992-05-01)|
|Re: register variables in C. firstname.lastname@example.org (1992-05-02)|
|Re: register variables in C. email@example.com (1992-05-04)|
|Re: register variables in C. firstname.lastname@example.org (1992-05-04)|
|Re: register variables in C. email@example.com (1992-05-04)|
|Re: register variables in C. firstname.lastname@example.org (1992-05-06)|
|From:||email@example.com (Gregory N. Bond)|
|Keywords:||C, registers, optimize|
|Organization:||Burdett, Buckeridge & Young, Melbourne, Australia|
|Date:||Mon, 4 May 1992 23:38:02 GMT|
firstname.lastname@example.org (Gene Ressler) said:
> In this context, it seems more appropriate to have programmers tag uses of
> variables rather than declarations.
The problem with this (inherent in any scheme, including "register", that
focuses on source language variables) is that the really chunky bits are
hidden from the programmer (such as common subexpressions, address
arithmetic etc); such schemes don't help compilers much when making
decisions about these hidden entities.
A far preferable use of effort (either programmer effort in #pragma's or
system effort in getting profiling) is to tell the compiler the likely
flow control so more informed decisions can be made.
I'm not really a compiler weenie; what is the current state of the art
w.r.t. discovering branch possibilities or loop frequencies? Do compilers
routinely differentiate between "for (i = 1; i < 3; i++)" and "for (i = 1;
i < 300; i++)" or similar constructs? What about extracting info from the
equivalent DO or WHILE loops?
Gregory Bond <email@example.com>
Burdett Buckeridge & Young Ltd Melbourne Australia
Return to the
Search the comp.compilers archives again.