Skip to content
Snippets Groups Projects
Commit 3e93828e authored by Richard Sandiford's avatar Richard Sandiford
Browse files

Make more places handle exact_div like trunc_div

I tried to look for places where we were handling TRUNC_DIV_EXPR
more favourably than EXACT_DIV_EXPR.

Most of the places that I looked at but didn't change were handling
div/mod pairs.  But there's bound to be others I missed...

gcc/
	* match.pd: Extend some rules to handle exact_div like trunc_div.
	* tree.h (trunc_or_exact_div_p): New function.
	* tree-ssa-loop-niter.cc (is_rshift_by_1): Use it.
	* tree-ssa-loop-ivopts.cc (force_expr_to_var_cost): Handle
	EXACT_DIV_EXPR.
parent f24e1087
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment