Bug 90913 - OSX - very poor performance when first opening Finder dialog
Summary: OSX - very poor performance when first opening Finder dialog
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
4.5.0.0.alpha0+ Master
Hardware: x86-64 (AMD64) macOS (All)
: highest critical
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: notBibisectable, perf, regression
Depends on:
Blocks: Find-Search
  Show dependency treegraph
 
Reported: 2015-04-28 12:46 UTC by Alex Thurgood
Modified: 2016-11-03 10:46 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Profile of Cmd-O (8.71 KB, image/png)
2015-04-28 15:15 UTC, Alex Thurgood
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Thurgood 2015-04-28 12:46:43 UTC
How to test :

1) Start LO
2) Close StartCenter
3) Cmd-O to open Finder dialog

Version: 4.4.2.2
Build ID: c4c7d32d0d49397cad38d62472b0bc8acff48dd6
Locale : fr_

0.01 seconds


Version: 5.0.0.0.alpha1+
Build ID: 950055bcb06c8edcd9062c71184f02bf8e0604e6
Locale : fr_

58.2 seconds

OSX 10.10.3
Mac mini Server (mid-2010)
2,66 GHz Intel Core 2 Duo
4 Gb 1067 MHz DDR3
NVIDIA GeForce 320M 256 Mo
Comment 1 Alex Thurgood 2015-04-28 12:52:19 UTC
Note that subsequent openings of the Finder dialog are quasi-instantaneous
Comment 2 Alex Thurgood 2015-04-28 12:53:25 UTC
An alternative test, e.g. when invoking the File Save dialog for the first time, leads to the same poor performance
Comment 3 Alex Thurgood 2015-04-28 13:22:54 UTC
Build switches, fwiw :

--with-ant-home=/Volumes/BUILDHD/Shared/packages/apache-ant-1.9.2
--without-junit
--enable-64-bit
--with-extra-buildid
--enable-ext-nlpsolver
--enable-ext-google-docs
--enable-ext-languagetool
--enable-ext-diagram
--enable-ext-typo
--enable-ext-validator
--enable-ext-watch-window
--enable-extra-template
--enable-extra-gallery
--enable-ext-wiki-publisher
--enable-extension-integration
--with-lang=fr
--with-help
--enable-epm
--with-package-format=dmg
--enable-ext-mariadb-connector
--with-system-mariadb
--enable-bundle-mariadb
--with-myspell-dicts
Comment 4 Alex Thurgood 2015-04-28 14:25:05 UTC
Tested on nightly build :

Version: 5.0.0.0.alpha1+
Build ID: 38992b419a4655eba9b85d337edbb208fd2fff95
TinderBox: MacOSX-10.10@61, Branch:master, Time: 2015-04-27_23:59:04


Time to display of Finder dialog : 48.3 seconds
Comment 5 Alex Thurgood 2015-04-28 15:15:04 UTC
Created attachment 115163 [details]
Profile of Cmd-O
Comment 6 Alex Thurgood 2015-04-28 15:16:58 UTC
Attached a screen capture of Profile with OSX profiling tool. Thr first spike appears when CMd-O is released and then nothing happens, literally until the next group of spikes which is when the Finder dialog gets displayed.
Comment 7 Adolfo Jayme Barrientos 2015-04-28 18:04:35 UTC
This doesn’t qualify “critical” importance.
Comment 8 Alex Thurgood 2015-04-28 18:44:21 UTC
(In reply to Adolfo Jayme from comment #7)
> This doesn’t qualify “critical” importance.

Whatever. I'm quite sure someone in the communication department will be able to spin something positive out of it.

I read this :

https://wiki.documentfoundation.org/images/0/06/Prioritizing_Bugs_Flowchart.jpg

and set to high/major instead.
Comment 9 steve 2015-04-30 08:51:39 UTC
Confirming this. Imo has been going on in the nightly for a while and is very annoying because it is a basic function you almost always use whenever you use LO. → NEW
Comment 10 Alex Thurgood 2015-06-02 16:32:04 UTC
Gets better and better :

Version: 5.1.0.0.alpha1+
Build ID: 55431a84c264a8bcca593b9207aae0ad81d10f30
Locale : fr-FR (fr.UTF-8)

Time to open Finder dialog from fresh start : 2 minutes 3 seconds
Comment 11 Alex Thurgood 2015-06-02 16:35:41 UTC
2 minutes to open a ******* dialog, if that isn't critical, I don't know what is.

I am declaring this critical. We have more than doubled the time to open the dialog on the same hardware in the space of a month.
Comment 12 Robinson Tryon (qubit) 2015-12-03 10:34:45 UTC
(In reply to Alex Thurgood from comment #11)
> 2 minutes to open a ******* dialog, if that isn't critical, I don't know
> what is.

Hi Alex,
This does look like a serious perf regression.
Whiteboard -> perf

Are you able to reproduce with current master or 5.1 beta 1 builds?  Thanks!
Comment 13 steve 2015-12-03 12:57:29 UTC
"Current" master builds for osx are not available. cloph has been busy trying to fix and sounds like they should be coming back fairly soon.

keep an eye on: http://dev-builds.libreoffice.org/daily/master/MacOSX-x86_64@49-TDF/

@Robinson: I can confirm that with
Version: 5.1.0.0.alpha1+
Build ID: 7565f3c3b1ed189265a85c301e9483cddde32483
TinderBox: MacOSX-x86_64@49-TDF, Branch:master, Time: 2015-11-19_06:19:57
Locale: de-DE (de.UTF-8)
this is no longer a problem. (which is very confusing, because I think I ran into this exact bug with this version).

Sorry, no exact info but still wanted to add my findings.

@Alex: what's the status of this bug on your machine with latest nightlies?
Comment 14 Alex Thurgood 2015-12-03 14:12:56 UTC
(In reply to Robinson Tryon (qubit) from comment #12)

 
> Are you able to reproduce with current master or 5.1 beta 1 builds?  Thanks!

Yep.

Version: 5.2.0.0.alpha0+
Build ID: 098e9dc376346ad13c63fdef292ab640d89c6a21
Threads 2; Ver: -; Render: default; 


2 min 05 s
Comment 15 steve 2015-12-04 09:29:54 UTC
Reproduced w
10.11.1 + LO Version: 5.2.0.0.alpha0+
Build ID: 1fd41f43eb73c373cb94d32d82c5fb7a7e243367
Threads 4; Ver: -; Render: default; 

TinderBox: MacOSX-x86_64@49-TDF, Branch:master, Time: 2015-12-03_23:48:44
Locale: de-DE (de.UTF-8)

1) Start LO
2) Close StartCenter
3) Cmd-O to open Finder dialog

26 seconds.

@Robinson: please escalated to dev department.
Comment 16 Iandol 2015-12-04 11:15:23 UTC
Cannot reproduce on 10.11.2 public beta 15C48a and:

Version: 5.2.0.0.alpha0+
Build ID: 1fd41f43eb73c373cb94d32d82c5fb7a7e243367
Threads 8; Ver: -; Render: GL; 

Close StartCenter and ⌘o opens the file dialog instantly for me.
Comment 17 Robinson Tryon (qubit) 2015-12-04 17:46:25 UTC
(In reply to steve -_- from comment #15)
> Reproduced w
> 10.11.1 + LO Version: 5.2.0.0.alpha0+
> ... 
> @Robinson: please escalated to dev department.

Done: I brought this up during ESC on Thurs.

(In reply to Iandol from comment #16)
> Cannot reproduce on 10.11.2 public beta 15C48a and:
> 
> Version: 5.2.0.0.alpha0+
> Build ID: 1fd41f43eb73c373cb94d32d82c5fb7a7e243367
> Threads 8; Ver: -; Render: GL; 
> 
> Close StartCenter and ⌘o opens the file dialog instantly for me.

Hmm... let's compare that with steve's repro environment:

> 10.11.1 + LO Version: 5.2.0.0.alpha0+
> Build ID: 1fd41f43eb73c373cb94d32d82c5fb7a7e243367
> Threads 4; Ver: -; Render: default;

* Same version of OSX (modulo a micro-point-version bump).
* Same LibreOffice (exact same Build ID)
* Render: default vs. GL

Iandol/Steve: Can each of you try switching to use other render, and then report results? Thanks!
Comment 18 steve 2015-12-07 11:13:59 UTC
Version: 5.2.0.0.alpha0+
Build ID: 8a086a2c08efe2037957b959109e72b8bb3e27b7
Threads 4; Ver: -; Render: GL; 

TinderBox: MacOSX-x86_64@49-TDF, Branch:master, Time: 2015-12-07_08:16:55
Locale: de-DE (de.UTF-8)



OpenGL enabled → save as dialog instantly shows
OpenGL disabled → save as dialog instantly shows

Sorry, those results are contradictory to my previous statement (where I also ran into the spinning beachball and long wait time for the save dialog).
Comment 19 Alex Thurgood 2015-12-10 08:40:14 UTC
The Use OpenGL switch makes no difference to me with regard to opening time of the dialog.
Comment 20 Alex Thurgood 2015-12-10 08:43:24 UTC
(In reply to Alex Thurgood from comment #19)
> The Use OpenGL switch makes no difference to me with regard to opening time
> of the dialog.

Version: 5.2.0.0.alpha0+
Build ID: eb38493c4101d8777052267ee83a5d4f883dd9ac
Threads 2; Ver: -; Render: default; 

Locale: fr-FR (fr.UTF-8)
Comment 21 Alex Thurgood 2015-12-10 08:45:11 UTC
(In reply to Alex Thurgood from comment #20)
> (In reply to Alex Thurgood from comment #19)
> > The Use OpenGL switch makes no difference to me with regard to opening time
> > of the dialog.
> 
> Version: 5.2.0.0.alpha0+
> Build ID: eb38493c4101d8777052267ee83a5d4f883dd9ac
> Threads 2; Ver: -; Render: default; 
> 
> Locale: fr-FR (fr.UTF-8)

I would add that activating OpenGL causes LO to instantly crash and restart if I call up the About dialog (another new bug report in the offing)
Comment 22 Alex Thurgood 2015-12-10 08:55:56 UTC
It would be good if we could compare physical machine specs. I notice coincidentally that :

- in my case, I only have 2 threads running
- in Steve's case, he has 4 threads running
- and in Iandol's case, he has 8 threads running


Could it be that we have a thread race condition which is dependent on the hardware ? For example, I only have 2 cores (2,66 GHz Intel Core 2 Duo) - how does LO use the available cores on a machine ?
Comment 23 Alex Thurgood 2015-12-10 09:22:40 UTC
Tetsesd on 

MacBook Pro (Retina, 15 pouces, fin 2013)
2,6 GHz Intel Core i7
16 Go 1600 MHz DDR3
NVIDIA GeForce GT 750M 2048 Mo



with 

Version: 5.2.0.0.alpha0+
Build ID: 4754afddc3030347ef49b401a9b798cea8fe523c
Threads 8; Ver: -; Render: default; 

TinderBox: MacOSX-x86_64@49-TDF, Branch:master, Time: 2015-12-09_07:17:31
Locale: fr-FR (fr.UTF-8)



Time to open dialog : 3.6 seconds
Comment 24 Alex Thurgood 2015-12-10 09:38:45 UTC
(In reply to Alex Thurgood from comment #23)
> Tetsesd on 
> 
> MacBook Pro (Retina, 15 pouces, fin 2013)
> 2,6 GHz Intel Core i7
> 16 Go 1600 MHz DDR3
> NVIDIA GeForce GT 750M 2048 Mo
> 


Compare that with my own master build (built on Macmini) from last night on same test machine :

Version: 5.2.0.0.alpha0+
Build ID: eb38493c4101d8777052267ee83a5d4f883dd9ac
Threads 8; Ver: -; Render: default; 

Locale: fr-FR (fr.UTF-8)

Time to open dialog : 20.4 seconds
Comment 25 Alex Thurgood 2015-12-10 09:50:22 UTC
(In reply to Alex Thurgood from comment #24)

OSX 10.11.1
Mac mini Server (mid-2010)
2,66 GHz Intel Core 2 Duo
4 Gb 1067 MHz DDR3
NVIDIA GeForce 320M 256 Mo


TDF Nightly build 
Version: 5.2.0.0.alpha0+
Build ID: 4754afddc3030347ef49b401a9b798cea8fe523c
Threads 2; Ver: -; Render: default; 

TinderBox: MacOSX-x86_64@49-TDF, Branch:master, Time: 2015-12-09_07:17:31
Locale: fr-FR (fr.UTF-8)

Time to open dialog : 1 min 37.2 seconds
Comment 26 Robinson Tryon (qubit) 2015-12-10 10:36:18 UTC Comment hidden (obsolete)
Comment 27 Alex Thurgood 2016-06-13 20:35:23 UTC
With latest master dbgutil, the initial Finder window opens more quickly, but first selection of any file takes so long that OSX considers the app to be not responding.

By first selection of any file, I mean that when one selects a file with the mouse in the Finder dialog list of files, the Open button is not activated for more than a minute.
Comment 28 Telesto 2016-10-25 18:37:30 UTC
No repro with 10.12.1 Final Build (16B2555) on a Macbook Air6.1, Intel Core i5 Dual Core with:
Version: 5.2.2.2
Build ID: 8f96e87c890bf8fa77463cd4b640a2312823f3ad
CPU Threads: 4; OS Version: Mac OS X 10.12.1; UI Render: default; 

Close StartCenter and ⌘O opens instantly a responsive file dialog.
Comment 29 steve 2016-10-26 19:18:28 UTC
same here w latest master on 10.12.1
Comment 30 Alex Thurgood 2016-11-03 10:46:08 UTC
OK, so let's close this as WFM. I still get a ca. 30s delay between activating Cmd-O and obtaining a responsive Finder dialog where I can open a file, on first start of LibreOffice on my test platform (macmini 2010). Further successive startups are much quicker (2-5s).