Add MIN/MAX folding from fold_cond_expr_with_comparison to match.pd
The following adds MIN/MAX folding from fold_cond_expr_with_comparison
to the part GIMPLE of match.pd, leaving the GENERIC part in
fold-const.cc since that's constrainted on frontend specific things
I did not want to carry to match.pd.
The effect becomes appearant when we no longer can rely on GENERIC
folding of COND_EXPRs in gcc.dg/tree-ssa/pr92834.c and
gcc.dg/tree-ssa/pr94786.c.
2022-05-13 Richard Biener <rguenther@suse.de>
* match.pd (A cmp B ? A : B -> min/max): New patterns
carried over from fold_cond_expr_with_comparison.