This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: std::pow implementation
- From: Alexandre Oliva <aoliva at redhat dot com>
- To: Gabriel Dos Reis <gdr at integrable-solutions dot net>
- Cc: dewar at gnat dot com (Robert Dewar), gcc at gcc dot gnu dot org, rguenth at tat dot physik dot uni-tuebingen dot de, s dot bosscher at student dot tudelft dot nl
- Date: 30 Jul 2003 18:51:31 -0300
- Subject: Re: std::pow implementation
- Organization: GCC Team, Red Hat
- References: <20030730134614.2C021F2DFE@nile.gnat.com><m3wue03ylf.fsf@uniton.integrable-solutions.net>
On Jul 30, 2003, Gabriel Dos Reis <gdr@integrable-solutions.net> wrote:
> But the fact is that the compiler is not doing better by going its own
> programmed logic. We've not reached the same level of sophistication
> as for register allocation.
And your solution for the problem is to dumb it down further such that
it doesn't even attempt to do a good job? Heck, it seems obvious to
me that the right solution is to improve the logic, not take it out
and assume the programmer knows better. The developer of the function
that is a candidate for inlining can seldom foretell whether it's
going to be profitable to inline or not in each and every potential
uses of the function. The cases in which the developer does have such
complete information are rare, and we should optimize for the common
case.
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist Professional serial bug killer