* fold-const (fold_binary) [RDIV_EXPR]: Also optimize a/cbrt(b/c)
into a*cbrt(c/b) if flag_unsafe_math_optimizations is set.
testuite/ChangeLog:
* gcc.dg/builtins-11.c: Also check folding of a/cbrt(b/c).
From-SVN: r125641
+2007-06-12 Uros Bizjak <ubizjak@gmail.com>
+
+ * fold-const (fold_binary) [RDIV_EXPR]: Also optimize a/cbrt(b/c)
+ into a*cbrt(c/b) if flag_unsafe_math_optimizations is set.
+
2007-06-11 Diego Novillo <dnovillo@google.com>
* Makefile.in (reload1.o-warn): Remove.
}
}
- /* Optimize a/sqrt(b/c) into a*sqrt(c/b). */
- if (BUILTIN_SQRT_P (fcode1))
+ /* Optimize a/root(b/c) into a*root(c/b). */
+ if (BUILTIN_ROOT_P (fcode1))
{
tree rootarg = CALL_EXPR_ARG (arg1, 0);
+2007-06-12 Uros Bizjak <ubizjak@gmail.com>
+
+ * gcc.dg/builtins-11.c: Also check folding of a/cbrt(b/c).
+
2007-06-12 Paul Thomas <pault@gcc.gnu.org>
PR fortran/29786
extern double exp(double);
extern double sqrt(double);
+extern double cbrt(double);
extern double pow(double,double);
void test(double x, double y, double z)
if (x/sqrt(y/z) != x*sqrt(z/y))
link_error ();
+
+ if (x/cbrt(y/z) != x*cbrt(z/y))
+ link_error ();
}
int main()