[postgis-tickets] [PostGIS] #4372: PROJ 6: 4x slowdown over points (was: PROJ 6: 4x slowdown on indexes over ST_Transform)

PostGIS trac at osgeo.org
Mon Jun 17 07:17:41 PDT 2019


#4372: PROJ 6: 4x slowdown over points
-------------------------+---------------------------
  Reporter:  Algunenano  |      Owner:  Algunenano
      Type:  defect      |     Status:  assigned
  Priority:  high        |  Milestone:  PostGIS 3.0.0
 Component:  postgis     |    Version:  trunk
Resolution:              |   Keywords:
-------------------------+---------------------------

Comment (by Algunenano):

 Now testing without removing the invalid set_searchpath and caching
 proj_crs_is_swapped, ST_Transform has a similar performance between 5.2
 and 6.

 Once I've investigated further into the index issue, I've noticed that the
 slowdown isn't related to indexing / caching, but to ST_Buffer(geography):

 SQL:
 {{{
 explain analyze SELECT
  ST_Buffer(the_geom::geography, 50000) from
 analysis_2f13a3dbd7_9de00c87a82f0929cfc345d2d9f1d01e05811bc4;
 }}}

 PROJ 5.2: 640.939 ms
 PROJ 6.1: 2112.235 ms


 That seems to be related to the multiple projections created by
 `spheroid_init_from_srid`, which is called for every row. I'll dig deeper.

 Still pending: Check why removing the invalid set_searchpath makes some
 calls 10x slower with PROJ6.

-- 
Ticket URL: <https://trac.osgeo.org/postgis/ticket/4372#comment:9>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-tickets mailing list