From: | Mark Dilger <hornschnorter(at)gmail(dot)com> |
---|---|
To: | Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com> |
Cc: | Adrien Nayrat <adrien(dot)nayrat(at)dalibo(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: [HACKERS] PATCH: multivariate histograms and MCV lists |
Date: | 2017-11-25 17:14:18 |
Message-ID: | C96BDCC7-250F-479B-BEF4-F9F10A53120F@gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
> On Nov 18, 2017, at 12:28 PM, Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com> wrote:
>
> Hi,
>
> Attached is an updated version of the patch, adopting the psql describe
> changes introduced by 471d55859c11b.
>
> regards
>
> --
> Tomas Vondra http://www.2ndQuadrant.com
> PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
> <0001-multivariate-MCV-lists.patch.gz><0002-multivariate-histograms.patch.gz>
Hello Tomas,
In 0002-multivariate-histograms.patch, src/include/nodes/relation.h,
struct StatisticExtInfo, you change:
- char kind; /* statistic kind of this entry */
+ int kinds; /* statistic kinds of this entry */
to have 'kinds' apparently be a bitmask, based on reading how you use
this in the code. The #defines just below the struct give the four bits
to be used,
#define STATS_EXT_INFO_NDISTINCT 1
#define STATS_EXT_INFO_DEPENDENCIES 2
#define STATS_EXT_INFO_MCV 4
#define STATS_EXT_INFO_HISTOGRAM 8
except that nothing in the file indicates that this is so. Perhaps a comment
could be added here mentioning that 'kinds' is a bitmask, and that these
#defines are related?
mark
From | Date | Subject | |
---|---|---|---|
Next Message | Tomas Vondra | 2017-11-25 17:56:03 | Re: [HACKERS] PATCH: multivariate histograms and MCV lists |
Previous Message | Tom Lane | 2017-11-25 17:09:54 | Re: [HACKERS] More stats about skipped vacuums |