Re: Failing assertions in indxpath.c, placeholder.c and brin_minmax.c
Michael Paquier <michael.paquier@gmail.com>
On Sun, Jul 26, 2015 at 9:55 PM, Andreas Seltenreich <seltenreich@gmx.de> wrote:
> when running my random query generator contraption[1] against the
> regression database of 9.5 or master, it occasionally triggers one of
> the following three assertions. Someone more knowledgeable might want
> to take a look at them...
>
> -- FailedAssertion("!(outer_rel->rows > 0)", File: "indxpath.c", Line: 1911)
> -- sample query:
> select
> rel1925354.loid as c0,
> rel1925353.version as c1
> from
> (select
> rel1925352.aa as c0,
> rel1925352.aa as c1
> from
> public.b as rel1925352
> where (rel1925352.bb is NULL)
> and (rel1925352.bb < rel1925352.bb)) as subq_303136
> inner join pg_catalog.pg_stat_ssl as rel1925353
> on (subq_303136.c0 = rel1925353.pid )
> right join pg_catalog.pg_largeobject as rel1925354
> on (subq_303136.c0 = rel1925354.pageno )
> where (rel1925353.clientdn !~ rel1925353.clientdn)
> and (rel1925353.cipher <= rel1925353.clientdn);
>
> ,----[ git bisect ]
> | first bad commit: [3f8c23c4d31d4a0e801041733deb2c7cfa577b32] Improve
> | predtest.c's ability to reason about operator expressions.
> `----
>
> -- FailedAssertion("!(!bms_is_empty(phinfo->ph_eval_at))", File: "placeholder.c", Line: 109)
> -- sample query:
> select
> rel1600276.viewowner as c0,
> rel1600274.maxwritten_clean as c1,
> rel1600275.n_tup_hot_upd as c2
> from
> pg_catalog.pg_stat_bgwriter as rel1600274
> inner join pg_catalog.pg_stat_xact_all_tables as rel1600275
> on (rel1600274.maxwritten_clean = rel1600275.seq_scan )
> right join pg_catalog.pg_views as rel1600276
> right join pg_catalog.pg_operator as rel1600277
> on (rel1600276.viewname = rel1600277.oprname )
> on (rel1600275.relname = rel1600277.oprname )
> where 3 is not NULL;
>
> ,----[ git bisect ]
> | first bad commit: [f4abd0241de20d5d6a79b84992b9e88603d44134] Support
> | flattening of empty-FROM subqueries and one-row VALUES tables.
> `----
>
> -- FailedAssertion("!(key->sk_flags & 0x0080)", File: "brin_minmax.c", Line: 177)
> -- sample query:
> select
> rel167978.namecol as c0
> from
> information_schema.parameters as rel167972
> left join public.student as rel167977
> inner join public.brintest as rel167978
> on (rel167977.age = rel167978.int4col )
> on (rel167972.interval_precision = rel167977.age )
> where rel167977.name <> rel167977.name;
> Footnotes:
> [1] https://github.com/anse1/sqlsmith
This is really interesting stuff. I think that it would be possible to
extract self-contained test cases from your tool and those queries to
reproduce the failures. It is written that this tools connects to a
database to retrieve the schema, what is it exactly in the case of
those failures?
--
Michael
Commits
-
Fix broken assertion in BRIN code
- c81276241b61 9.6.0 landed
- 244c378e243e 9.5.0 landed
-
Support flattening of empty-FROM subqueries and one-row VALUES tables.
- f4abd0241de2 9.5.0 cited
-
Fix resource leak pointed out by Coverity.
- 3b5a89c4820f 9.5.0 cited
-
Add missing volatile qualifier.
- 68e66923ff62 9.5.0 cited
-
Remove dependency on wsock32.lib in favor of ws2_32
- a16bac36eca8 9.5.0 cited
-
Check interrupts during logical decoding more frequently.
- 1cbc94801062 9.5.0 cited
-
Fix contrib/pg_upgrade/test.sh for $PWD containing spaces.
- 686f362bee12 9.5.0 cited
-
Secure Unix-domain sockets of "make check" temporary clusters.
- be76a6d39e28 9.5.0 cited
-
Adjust 9.4 release notes.
- a7205d81573c 9.5.0 cited
-
Improve predtest.c's ability to reason about operator expressions.
- 3f8c23c4d31d 9.5.0 cited
-
Fix pg_restore's processing of old-style BLOB COMMENTS data.
- c81e63d85f0c 9.5.0 cited
-
Improve tuplestore's error messages for I/O failures.
- 6554656ea204 9.5.0 cited
-
Remove unnecessary output expressions from unflattened subqueries.
- 55d5b3c08279 9.5.0 cited
-
Stamp 9.4beta1.
- e6df2e1be633 9.4.0 cited