On Mon, Nov 23, 2009 at 10:17 AM, Ian Bolton wrote:
> David Edelsohn wrote:
>> On Fri, Nov 20, 2009 at 10:05 AM, Ian Bolton
>> wrote:
>> > From some simple experiments (see below), it appears as though GCC
>> aims
>> > to
>> > create a lop-sided tree when there are constants involved (func1
>> be
On Wed, Nov 25, 2009 at 2:52 PM, Bingfeng Mei wrote:
> Hello,
> It seems to me that tree balancing risk of producing wrong result due
> to overflow of subexpression.
>
> Say a = INT_MIN, b = 10, c = 10, d = INT_MAX.
>
> If
> ((a + b) + c) + d))
>
> becomes
> ((a + b) + (c + d))
>
> c + d will over
Hello,
It seems to me that tree balancing risk of producing wrong result due
to overflow of subexpression.
Say a = INT_MIN, b = 10, c = 10, d = INT_MAX.
If
((a + b) + c) + d))
becomes
((a + b) + (c + d))
c + d will overflow and the original won't. So the behaviour of
two are different. Thoug
On Nov 23, 2009, at 10:17, Ian Bolton wrote:
> Regardless of the architecture, I can't see how an unbalanced tree would
> ever be a good thing. With a balanced tree, you can still choose to
> process it in either direction (broad versus deep) - whichever is better
> for your architecture - but,
David Edelsohn wrote:
> On Fri, Nov 20, 2009 at 10:05 AM, Ian Bolton
> wrote:
> > From some simple experiments (see below), it appears as though GCC
> aims
> > to
> > create a lop-sided tree when there are constants involved (func1
> below),
> > but a balanced tree when there aren't (func2 below)
On Fri, 2009-11-20 at 10:18 -0500, David Edelsohn wrote:
> On Fri, Nov 20, 2009 at 10:05 AM, Ian Bolton wrote:
> > From some simple experiments (see below), it appears as though GCC aims
> > to
> > create a lop-sided tree when there are constants involved (func1 below),
> > but a balanced tree wh
On Fri, Nov 20, 2009 at 4:18 PM, David Edelsohn wrote:
> On Fri, Nov 20, 2009 at 10:05 AM, Ian Bolton wrote:
>> From some simple experiments (see below), it appears as though GCC aims
>> to
>> create a lop-sided tree when there are constants involved (func1 below),
>> but a balanced tree when the
On Fri, Nov 20, 2009 at 10:05 AM, Ian Bolton wrote:
> From some simple experiments (see below), it appears as though GCC aims
> to
> create a lop-sided tree when there are constants involved (func1 below),
> but a balanced tree when there aren't (func2 below).
>
> Our assumption is that GCC likes