Move sqrt and cbrt simplifications to match.pd
This patch moves the sqrt and cbrt simplification rules to match.pd. builtins.c now only does the constant folding. Bootstrapped & regression-tested on x86_64-linux-gnu. gcc/ * builtins.c (fold_builtin_sqrt, fold_builtin_cbrt): Delete. (fold_builtin_1): Update accordingly. Handle constant arguments here. * match.pd: Add rules previously handled by fold_builtin_sqrt and fold_builtin_cbrt. gcc/testsuite/ * gcc.dg/builtins-47.c: Test the optimized dump instead. From-SVN: r228616
Showing
Please
register
or
sign in
to comment