Re: [PATCH] Improve VRP range intersection for partly symbolic ranges

2017-04-28 Thread Richard Biener
On Thu, 27 Apr 2017, Richard Biener wrote: > On April 27, 2017 4:06:48 PM GMT+02:00, "Bin.Cheng" > wrote: > >On Thu, Apr 27, 2017 at 2:49 PM, Richard Biener > >wrote: > >> > >> The following makes intersecting [-INF, +10] and [a + -1, +INF] > >> to [10, a + -1] possible with the chance that for

Re: [PATCH] Improve VRP range intersection for partly symbolic ranges

2017-04-27 Thread Richard Biener
On April 27, 2017 4:06:48 PM GMT+02:00, "Bin.Cheng" wrote: >On Thu, Apr 27, 2017 at 2:49 PM, Richard Biener >wrote: >> >> The following makes intersecting [-INF, +10] and [a + -1, +INF] >> to [10, a + -1] possible with the chance that for a <= 10 the >> resulting range will be empty (but not tri

Re: [PATCH] Improve VRP range intersection for partly symbolic ranges

2017-04-27 Thread Bin.Cheng
On Thu, Apr 27, 2017 at 2:49 PM, Richard Biener wrote: > > The following makes intersecting [-INF, +10] and [a + -1, +INF] > to [10, a + -1] possible with the chance that for a <= 10 the > resulting range will be empty (but not trivially visible as so). Hi, I noticed operand_less_p is quite simple

[PATCH] Improve VRP range intersection for partly symbolic ranges

2017-04-27 Thread Richard Biener
The following makes intersecting [-INF, +10] and [a + -1, +INF] to [10, a + -1] possible with the chance that for a <= 10 the resulting range will be empty (but not trivially visible as so). Bootstrap / regtest running on x86_64-unknown-linux-gnu. I'll add a testcase later. Richard. 2017-04-27

[PATCH] Improve VRP range intersection

2016-09-30 Thread Richard Biener
I noticed we intersect ~[a_1, a_1] and [2, 2] to ~[a_1, a_1]. While we don't generally want to choose an integral range a singleton integral range is always preferable. Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2016-09-30 Richard Biener * tree-vrp.c (in