Re: Bus error in formatting.c NUM_numpart_to_char (9.4.12, 9.6.3, sparc)

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Tom Turelinckx" <tom(at)turelinckx(dot)be>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: Bus error in formatting.c NUM_numpart_to_char (9.4.12, 9.6.3, sparc)
Date: 2017-06-21 16:24:08
Message-ID: 2069.1498062248@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Tom Turelinckx" <tom(at)turelinckx(dot)be> writes:
> I was trying to compile 9.4.12 on sparc from the debian source package
in the pgdg repo, but it's failing multiple regression tests.

Hm. What else fails besides the crash you're showing? It's not very
easy to deduce what's wrong there, but maybe some other symptom would
be more transparent.

> It seems this issue was introduced in 9.4.9: 9.4.9, 9.4.10, 9.4.11 and 9.4.12 all crash at the same test at the same line in formatting.c, but 9.4.8 builds successfully and passes all tests. It also seems that both NUM_numpart_to_char and the failing test have not been touched for, eh, decades, so the root cause must be somewhere else.

Alvaro's right that there was a change in 9.4.9 in formatting.c, but
that seems unrelated. And if you're seeing issues elsewhere, a more
global root cause seems what to postulate.

> A potentially similar issue was introduced in 9.4.7 and resolved in 9.4.8:
> https://www.postgresql.org/message-id/20160413094117.GC21485@msg.credativ.de

We never did get a clear explanation of why that crashed on Sparc.
I hypothesized over-aggressive compiler assumptions about alignment,
but there was no convincing evidence for that. It might be worth taking
a look at the assembly code immediately around the crash point, especially
if you could also get the corresponding code from 9.4.8.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Ben Cook 2017-06-21 19:02:34 Password Error
Previous Message Alvaro Herrera 2017-06-21 15:44:48 Re: Bus error in formatting.c NUM_numpart_to_char (9.4.12, 9.6.3, sparc)