Fix picksplit with nan values - Mailing list pgsql-hackers

From Alexander Korotkov
Subject Fix picksplit with nan values
Date
Msg-id CAPpHfdsRWLoKeJDM8NiX-ChxqAdGw1PQJ7JEhyKEc32+B9UXZA@mail.gmail.com
Whole thread Raw
Responses Re: Fix picksplit with nan values
List pgsql-hackers
Hackers,

PostGIS spotted that picksplit algorithm freezes in infinite loop when dealing with nan values. I discovered same bug is present in core opclasses. Attached patch fixes this issue interpreting nan as value greater than infinity like btree comparison function does. 
This patch contain copy of float8_cmp_internal rather than exposing it from float.c, because it let compiler inline this function.

------
With best regards,
Alexander Korotkov.
Attachment

pgsql-hackers by date:

Previous
From: Jim Nasby
Date:
Subject: Re: [HACKERS] Is it necessary to rewrite table while increasing the scale of datatype numeric?
Next
From: Alvaro Herrera
Date:
Subject: Re: Is it necessary to rewrite table while increasing the scale of datatype numeric?