Re: elog/ereport VS misleading backtrace_function function address

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Cc: Devrim Gündüz <devrim(at)gunduz(dot)org>, Jakub Wartak <jakub(dot)wartak(at)enterprisedb(dot)com>, Peter Eisentraut <peter(at)eisentraut(dot)org>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: elog/ereport VS misleading backtrace_function function address
Date: 2024-05-14 15:05:08
Message-ID: 1093444.1715699108@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> writes:
> On 2024-May-14, Jakub Wartak wrote:
>> Reality is apparently mixed,at least from what I have checked :
>> - all RHEL 7.x/8.x (PGDG and our forks) do NOT come with
>> --enable-debug according to pg_config.

> Ooh, yeah, that's true according to
> https://git.postgresql.org/gitweb/?p=pgrpms.git;a=blob;f=rpm/redhat/main/non-common/postgresql-16/main/postgresql-16.spec;h=ab2f6edc903f083e04b8f7a1d3bad8e1b7018791;hb=1a8b9fa7019d3f73322ca873b62dc0b33e73ed1d

> 507 %if %beta
> 508 --enable-debug \
> 509 --enable-cassert \
> 510 %endif

> Maybe a better approach for this whole thing is to change the specs so
> that --enable-debug is always given, not just for %beta.

My recollection from my time at Red Hat is that their standard policy
is to build everything with debug symbols all the time; so this is
violating that policy, and we should change it just on those grounds.
However, I'm not sure how much the change will help Joe Average User
with respect to the thread topic. RH actually has infrastructure that
splits the debug symbol tables out into separate "debuginfo" RPMs,
which you have to install manually if you want to debug a particular
package. This is good for disk space consumption, but it means that
most users are still only going to see the same backtrace they see
currently.

I don't know how much of that applies to, eg, Debian.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2024-05-14 15:09:39 Re: broken JIT support on Fedora 40
Previous Message Alexander Lakhin 2024-05-14 15:00:00 Re: Why is citext/regress failing on hamerkop?