C optimizer

Steve Summit scs at adam.pika.mit.edu
Sun Feb 19 11:04:40 AEST 1989


In article <13134 at steinmetz.ge.com> davidsen at crdos1.UUCP (bill davidsen) writes:
>  I agree. One solution would be to provide a keyword, perhaps something
>like 'pure' or 'deterministic', which would indicate...

Just Say No to new keywords.  This sort of optimization is a fine
idea, and it does require a hint to the compiler, for the reasons
already discussed.  However, outside-the-language mucking around
is exactly what #pragmas are for:

	#pragma pure(sin)

(Someone, probably Karl Heuer, already made passing reference to
the use of #pragmas for this example.)  Extra keywords are messy,
even if they do follow the rules and use leading underscores.

                                            Steve Summit
                                            scs at adam.pika.mit.edu



More information about the Comp.lang.c mailing list