Re: Fixed length data types issue

Поиск
Список
Период
Сортировка
От Gregory Stark
Тема Re: Fixed length data types issue
Дата
Msg-id 87ac56waju.fsf@enterprisedb.com
обсуждение исходный текст
Ответ на Re: Fixed length data types issue  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Fixed length data types issue  (Jim Nasby <jim@nasby.net>)
Список pgsql-hackers
Tom Lane <tgl@sss.pgh.pa.us> writes:

> Gregory Stark <stark@enterprisedb.com> writes:
>> In any case it seems a bit backwards to me. Wouldn't it be better to
>> preserve bits in the case of short length words where they're precious
>> rather than long ones? If we make 0xxxxxxx the 1-byte case it means ...
>
> Well, I don't find that real persuasive: you're saying that it's
> important to have a 1-byte not 2-byte header for datums between 64 and
> 127 bytes long.  Which is by definition less than a 2% savings for those
> values.  

Sure, but my thinking was that saving one byte on data between 64 and 127
bytes long is more important than saving two bytes on data between 4k and 8k
or whatever the range was in that proposal.

> I think its's more important to pick bitpatterns that reduce the number of
> cases heap_deform_tuple has to think about while decoding the length of a
> field --- every "if" in that inner loop is expensive.

I'll have to spend a few hours tomorrow becoming one with that section of
code. I looked at it already and was surprised at how short it was already so
I can understand what you mean.


--  Gregory Stark EnterpriseDB          http://www.enterprisedb.com


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Stefan Kaltenbrunner
Дата:
Сообщение: -HEAD planner issue wrt hash_joins on dbt3 ?
Следующее
От: Tom Lane
Дата:
Сообщение: set_pglocale_pgservice considered harmful