Re: Re: patch: fix performance problems with repated decomprimation of varlena values in plpgsql
В списке pgsql-hackers по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: Re: patch: fix performance problems with repated decomprimation of varlena values in plpgsql |
| Дата | |
| Msg-id | 3290.1295388021@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: Re: patch: fix performance problems with repated decomprimation of varlena values in plpgsql (Pavel Stehule <pavel.stehule@gmail.com>) |
| Ответы |
Re: Re: patch: fix performance problems with repated
decomprimation of varlena values in plpgsql
|
| Список | pgsql-hackers |
Pavel Stehule <pavel.stehule@gmail.com> writes:
> 2011/1/18 Tom Lane <tgl@sss.pgh.pa.us>:
>> I looked at this patch and found it fairly awkward. What is the point
>> of adding an additional flag to every variable, as opposed to just
>> forcibly detoasting during assignment?
> But detoasting on assignment isn't enought:
> for i in array_lower(a,1) .. array_upper(a,1)
> loop
> if x < a[i] then
> x = a[i];
> end if;
> end loop;
> in this cycle the variable a wasn't modified. Any access to this
> variable means a detoast and decompres.
How so? In what I'm envisioning, a would have been decompressed when it
was originally assigned to.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера