pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Sync our DTrace infrastructure with c.h's definition of type boo
2+ messages / 1 participants
[nested] [flat]

* pgsql: Sync our DTrace infrastructure with c.h's definition of type boo
@ 2019-11-06 16:12 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 2+ messages in thread

From: Tom Lane @ 2019-11-06 16:12 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Sync our DTrace infrastructure with c.h's definition of type bool.

Since commit d26a810eb, we've defined bool as being either _Bool from
<stdbool.h>, or "unsigned char"; but that commit overlooked the fact
that probes.d has "#define bool char".  For consistency, make it say
"unsigned char" instead.  This should be strictly a cosmetic change,
but it seems best to be in sync.

Formally, in the now-normal case where we're using <stdbool.h>, it'd
be better to write "#define bool _Bool".  However, then we'd need
some build infrastructure to inject that configuration choice into
probes.d, and it doesn't seem worth the trouble.  We only use
<stdbool.h> if sizeof(_Bool) is 1, so having DTrace think that
bool parameters are "unsigned char" should be close enough.

Back-patch to v12 where d26a810eb came in.

Discussion: https://postgr.es/m/CAA4eK1LmaKO7Du9M9Lo=kxGU8sB6aL8fa3sF6z6d5yYYVe3BuQ@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/ff43b3e88eceb94b3a2b2579e8510e4f3aedbe09

Modified Files
--------------
doc/src/sgml/monitoring.sgml | 2 +-
src/backend/utils/probes.d   | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)



^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* pgsql: Sync our DTrace infrastructure with c.h's definition of type boo
@ 2019-11-06 16:12 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 2+ messages in thread

From: Tom Lane @ 2019-11-06 16:12 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Sync our DTrace infrastructure with c.h's definition of type bool.

Since commit d26a810eb, we've defined bool as being either _Bool from
<stdbool.h>, or "unsigned char"; but that commit overlooked the fact
that probes.d has "#define bool char".  For consistency, make it say
"unsigned char" instead.  This should be strictly a cosmetic change,
but it seems best to be in sync.

Formally, in the now-normal case where we're using <stdbool.h>, it'd
be better to write "#define bool _Bool".  However, then we'd need
some build infrastructure to inject that configuration choice into
probes.d, and it doesn't seem worth the trouble.  We only use
<stdbool.h> if sizeof(_Bool) is 1, so having DTrace think that
bool parameters are "unsigned char" should be close enough.

Back-patch to v12 where d26a810eb came in.

Discussion: https://postgr.es/m/CAA4eK1LmaKO7Du9M9Lo=kxGU8sB6aL8fa3sF6z6d5yYYVe3BuQ@mail.gmail.com

Branch
------
REL_12_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/d4d0cd6ee23e2a111a24cbb7cc0be2b8453c8d4c

Modified Files
--------------
doc/src/sgml/monitoring.sgml | 2 +-
src/backend/utils/probes.d   | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2019-11-06 16:12 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2019-11-06 16:12 pgsql: Sync our DTrace infrastructure with c.h's definition of type boo Tom Lane <tgl@sss.pgh.pa.us>
2019-11-06 16:12 pgsql: Sync our DTrace infrastructure with c.h's definition of type boo Tom Lane <tgl@sss.pgh.pa.us>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox