Re: Infinity vs Error for division by zero - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Infinity vs Error for division by zero
Date
Msg-id 20190301182605.f66tcmkoyvfmewxf@alap3.anarazel.de
Whole thread Raw
In response to Re: Infinity vs Error for division by zero  ("David G. Johnston" <david.g.johnston@gmail.com>)
List pgsql-hackers
On 2019-03-01 11:04:04 -0700, David G. Johnston wrote:
> Changing the behavior is not going to happen for any existing data types.

For the overflow case that really sucks, because we're leaving a very
significant amount of performance on the table because we recheck for
overflow in every op. The actual float operation is basically free, but
the overflow check and the calling convention is not. JIT can get of the
latter, but not the former. Which is why we spend like 30% in one of the
TPCH queries doing overflow checks...

I still kinda wonder whether we can make trapping operations work, but
it's not trivial.


pgsql-hackers by date:

Previous
From: Chapman Flack
Date:
Subject: Re: Infinity vs Error for division by zero
Next
From: Robert Haas
Date:
Subject: Re: reloption to prevent VACUUM from truncating empty pages at theend of relation