Hi there, pg-Hackers!
Here I go with the patch which brings up the possibility to perform nearest-neighbour searches on SP-GiSTs (as of now includes implementation for quad and kd trees). Pre-reviewed by my GSoC mentor Alexander Korotkov.
Sample benchmarking script included in the attachment (dumps the current geonames archive and runs several searches on the (latitude, longitude) points), which demonstrates the dramatic improvements against plain searches and sorting. Regression tests included, compiles and runs successfully under both of my Ubuntu 12.04 Server and 08/2014 Arch Linux.
Vlad Sterzhanov / Quadrocube