Re: BUG #15899: Valgrind detects errors on create gist index

Поиск
Список
Период
Сортировка
От Alexander Lakhin
Тема Re: BUG #15899: Valgrind detects errors on create gist index
Дата
Msg-id 38f18230-e766-3a87-e3ad-fef6562c0c23@gmail.com
обсуждение исходный текст
Ответ на BUG #15899: Valgrind detects errors on create gist index  (PG Bug reporting form <noreply@postgresql.org>)
Ответы Re: BUG #15899: Valgrind detects errors on create gist index  (Michael Paquier <michael@paquier.xyz>)
Список pgsql-bugs
> When executing under valgrind the following script:
> create table gist_point_tbl(id int4, p point);
> insert into gist_point_tbl (id, p)
> select g+100000, point(g*10+1, g*10+1) from generate_series(1, 10000) g;
> create index gist_pointidx2 on gist_point_tbl using gist(p) with (buffering
> = on, fillfactor=50);
>
> I get several valgrind errors:
> 2019-07-07 22:01:02.957 MSK|law|regression|5d22416b.5a20|LOG:  statement:
> create index gist_pointidx2 on gist_point_tbl using gist(p) with (buffering
> = on, fillfactor=50);
> ==00:00:00:12.567 23072== Conditional jump or move depends on uninitialised
> value(s)
> ==00:00:00:12.567 23072==    at 0x1F977B: gistAddLoadedBuffer
> (gistbuildbuffers.c:205)
> ==00:00:00:12.567 23072==    by 0x1F9E05: gistPushItupToNodeBuffer
> (gistbuildbuffers.c:356)
> ==00:00:00:12.567 23072==    by 0x1F89F2: gistProcessItup
> (gistbuild.c:645)
> ==00:00:00:12.567 23072==    by 0x1F8AE2: gistBufferingBuildInsert
> (gistbuild.c:536)
>
> ...
> ==00:00:00:12.662 23072== Syscall param pwrite64(buf) points to
> uninitialised byte(s)
> ==00:00:00:12.662 23072==    at 0x5055014: pwrite (pwrite64.c:29)
> ==00:00:00:12.662 23072==    by 0x4F1CC0: FileWrite (fd.c:1963)
> ==00:00:00:12.662 23072==    by 0x4F3C83: BufFileDumpBuffer
> (buffile.c:487)
> ==00:00:00:12.662 23072==    by 0x4F4275: BufFileWrite (buffile.c:589)
> ==00:00:00:12.662 23072==    by 0x1F9841: WriteTempFileBlock
> (gistbuildbuffers.c:770)
> ==00:00:00:12.662 23072==    by 0x1F9E2E: gistPushItupToNodeBuffer
> (gistbuildbuffers.c:375)
> ==00:00:00:12.662 23072==    by 0x1F89F2: gistProcessItup
> (gistbuild.c:645)
The attached patch eliminates these errors (but maybe
MemoryContextAllocZero is too superficial).

Best regards,
Alexander

Вложения

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

Предыдущее
От: PG Bug reporting form
Дата:
Сообщение: BUG #15899: Valgrind detects errors on create gist index
Следующее
От: Manuel Rigger
Дата:
Сообщение: Issue with CHAR column and "column LIKE column" condition