From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Hannu Krosing <hannu(at)tm(dot)ee> |
Cc: | Dann Corbit <DCorbit(at)connx(dot)com>, Steve Crawford <scrawford(at)pinpointresearch(dot)com>, pgsql-performance(at)postgreSQL(dot)org, pgsql-hackers(at)postgreSQL(dot)org |
Subject: | Re: [PERFORM] Terrible performance on wide selects |
Date: | 2003-01-23 14:46:50 |
Message-ID: | 25701.1043333210@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-performance |
Hannu Krosing <hannu(at)tm(dot)ee> writes:
> as tuple (int,int,int,varchar,varchar)
> which is currently stored as
> (intdata1, intdata2, intdata3, (len4, vardata4), (len5,vardata5))
> should be rewritten on storage to
> (ptr4,ptr5),(intdata1, intdata2, intdata3, vardata4,vardata5)
I do not see that this buys anything at all. heap_getattr still has to
make essentially the same calculation as before to determine column
locations, namely adding up column widths. All you've done is move the
data that it has to fetch to make the calculation. If anything, this
will be slower not faster, because now heap_getattr has to keep track
of two positions not one --- not just the next column offset, but also
the index of the next "ptr" to use. In the existing method it only
needs the column offset, because that's exactly where it can pick up
the next length from.
But the really serious objection is that the datatype functions that
access the data would now also need to be passed two pointers, since
after all they would like to know the length too. That breaks APIs
far and wide :-(
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2003-01-23 14:50:02 | Re: Terrible performance on wide selects |
Previous Message | Tom Lane | 2003-01-23 14:41:25 | Re: Terrible performance on wide selects |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2003-01-23 14:50:02 | Re: Terrible performance on wide selects |
Previous Message | Tom Lane | 2003-01-23 14:41:25 | Re: Terrible performance on wide selects |