Re: Expression Evaluator used for creating the plan tree / stmt ?

From: Vaibhav Kaushal <vaibhavkaushal123(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Expression Evaluator used for creating the plan tree / stmt ?
Date: 2011-05-27 03:59:17
Message-ID: BANLkTimXMzcjZNWHP6+CTuv9esow6WAL8w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Thanks Tom. Comparing to you people, I am definitely new to almost
everything here. I did debug a few smaller programs and never seen anything
as such. So asked. Moreover, those programs I compiled never used any
optimization.

While everything seems to be working, it looks like the slot values do not
change and all rows in a sequential scan return the first value it finds on
the disk, n number of times, where n = number of rows in the table! I am
going to compile without optimization now. Hopefully that would change a few
things in the debugging process.

Seems beautiful, complicated, mysterious. And I thought I was beginning to
understand computers. :)

Whatever be the case, I will look more into it and ask again if I get into
too much of trouble.

Regards,
Vaibhav

On Fri, May 27, 2011 at 9:18 AM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> Vaibhav Kaushal <vaibhavkaushal123(at)gmail(dot)com> writes:
> > Why do these lines:
> > ...
> > repeat twice?
>
> Hm, you're new to using gdb, no? That's pretty normal: gdb is just
> reflecting back the fact that the compiler rearranges individual
> instructions as it sees fit. You could eliminate most, though perhaps
> not all, of that noise if you built the program-under-test (ie postgres)
> at -O0.
>
> regards, tom lane
>

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Stephen Frost 2011-05-27 04:08:47 Re: Pre-alloc ListCell's optimization
Previous Message Greg Stark 2011-05-27 03:58:58 Re: Pre-alloc ListCell's optimization