This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: std::pow implementation
- From: Richard Guenther <rguenth at tat dot physik dot uni-tuebingen dot de>
- To: Gabriel Dos Reis <gdr at integrable-solutions dot net>
- Cc: Steven Bosscher <s dot bosscher at student dot tudelft dot nl>, Scott Robert Ladd <coyote at coyotegulch dot com>, Alexandre Oliva <aoliva at redhat dot com>, Richard Guenther <rguenth at tat dot physik dot uni-tuebingen dot de>, <gcc at gcc dot gnu dot org>
- Date: Wed, 30 Jul 2003 17:52:52 +0200 (CEST)
- Subject: Re: std::pow implementation
On 30 Jul 2003, Gabriel Dos Reis wrote:
> Steven Bosscher <s.bosscher@student.tudelft.nl> writes:
>
> | > IMNSHO, the keyword "inline" means precisely what it says: to inline the
> | > code for a given function, if possible.
> |
> | Richard Guenther's experience with this meaning for "inline" are not
> | that positive: http://gcc.gnu.org/ml/gcc/2003-07/msg02140.html.
>
> It is no surprise that inlinig with no proper constant propagation and
> dead code elimination does not produce better code.
I think this statement is way too harsh, as cprop and dce are quite good
with gcc - apart from some special cases such as your std::pow(T, int)
implementation (for which we need to blame the loop unroller, not cprop
or dce).
Richard.