This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/28252] pow(x,1/3.0) should be converted to cbrt(x)
- From: "uros at kss-loka dot si" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 5 Jul 2006 08:25:56 -0000
- Subject: [Bug middle-end/28252] pow(x,1/3.0) should be converted to cbrt(x)
- References: <bug-28252-10259@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from uros at kss-loka dot si 2006-07-05 08:25 -------
Created an attachment (id=11824)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=11824&action=view)
Patch to implement pow(x,1.0/3.0) = cbrt(x) optimization
I have the patch that implements the optimization ready, just waiting for the
mainline to open again. Should I post it to gcc-patches anyway?
2006-07-05 Uros Bizjak <uros@kss-loka.si>
* builtins.c (fold_builtin): Fold pow(x,1.0/3.0) as cbrt(x) if
flag_unsafe_math_optimizations is set.
testsuite:
* gcc.dg/builtins-8.c: Also check pow(x,1.0/3.0) to cbrt(x)
transformation.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28252