Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-07-07 Thread Nyall Dawson via QGIS-Developer
On Tue, 28 Jun 2022 at 23:30, David Marteau via QGIS-Developer wrote: > > Hi, > > From bisect-like analysis, I have found the commit that introduces the loss > of loading performance: > > https://github.com/qgis/QGIS/commit/c6beb62216fcfbfe3ca64283c09117da53800a98 > > We need more investigation

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-28 Thread David Marteau via QGIS-Developer
Hi, From bisect-like analysis, I have found the commit that introduces the loss of loading performance: https://github.com/qgis/QGIS/commit/c6beb62216fcfbfe3ca64283c09117da53800a98 We need more investigation to understand exactly what is causing that regression. David Marteau www.3liz.com

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-21 Thread David Marteau via QGIS-Developer
I Wonder why we have `Creating auxiliary storage` that takes 65.0 ms in Qgis 3.26 and it does not appears in Qgis 3.24: I need to figure how auxiliary layers are loaded in Qgis 3.24 (are they loaded lazily ?). I happends that loading auxiliary layer is negligible in 3.24 : >> projectload,

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-21 Thread David Marteau via QGIS-Developer
Hi, Here is a first analysis using QgsRuntimeProfiler outputs The project is the same in all tests and has been saved with Qgis 3.26. This is a first load in each case just after qgis init, so there should be no caching involved. Output has been filtered to `projectload` profiler group and

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-21 Thread David Marteau via QGIS-Developer
May be I could use QgsRuntimeProfiler output in first place ? Le 20/06/2022 à 18:55, Even Rouault a écrit : Use sysprof or just run under a debugger and interrupt regularly should help you spot in which method(s) most time is spent Le 20/06/2022 à 18:48, David Marteau via QGIS-Developer a

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-20 Thread Even Rouault via QGIS-Developer
Use sysprof or just run under a debugger and interrupt regularly should help you spot in which method(s) most time is spent Le 20/06/2022 à 18:48, David Marteau via QGIS-Developer a écrit : I used the following test: readflags = Qgis.ProjectReadFlags() readflags |=

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-20 Thread Nyall Dawson via QGIS-Developer
On Tue, 21 June 2022, 2:48 am David Marteau, wrote: > I used the following test: > > readflags = Qgis.ProjectReadFlags()readflags |= > Qgis.ProjectReadFlag.TrustLayerMetadata|Qgis.ProjectReadFlag.DontLoad3DViews|Qgis.ProjectReadFlag.DontLoadProjectStyles > prj = QgsProject() > %timeit -n 1

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-20 Thread David Marteau via QGIS-Developer
I used the following test: readflags = Qgis.ProjectReadFlags() readflags |= Qgis.ProjectReadFlag.TrustLayerMetadata|Qgis.ProjectReadFlag.DontLoad3DViews|Qgis.ProjectReadFlag.DontLoadProjectStyles prj = QgsProject()%timeit -n 1 prj.read(f"{datapath}/france_parts3_26.qgs",readflags) 105 ms ±

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-20 Thread David Marteau via QGIS-Developer
Hi, > You should set the other new read optimisation flags here -- see https://github.com/qgis/QGIS/blob/88ebb3f2f513dbce5a775f50e51ea0117f859c65/src/core/qgis.h#L1962 These are already available also in 3.24 and we use the   `TrustLayerMetadata` in the above test. For server,  the other

Re: [QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-20 Thread Nyall Dawson via QGIS-Developer
On Mon, 20 June 2022, 9:37 pm David Marteau via QGIS-Developer, < qgis-developer@lists.osgeo.org> wrote: > Hi, > > I have noticed a huge drop of performance while testing Qgis server with > Qgis 3.26, from 10x to 30x slower as usual. > > Trying to reduce the problem I have found a huge increase

[QGIS-Developer] Qgis server: terrible performance with Qgis 3.26

2022-06-20 Thread David Marteau via QGIS-Developer
Hi, I have noticed a huge drop of performance while testing Qgis server with Qgis 3.26, from 10x to 30x slower as usual. Trying to reduce the problem I have found a huge increase of time spend reading the project in 3.26 compared to 3.24. Here some benchmark with very simple project from