Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Editor performance issue since revision d98df4092e16 #1064

Closed
spyder-bot opened this issue Feb 17, 2015 · 15 comments
Closed

Editor performance issue since revision d98df4092e16 #1064

spyder-bot opened this issue Feb 17, 2015 · 15 comments

Comments

@spyder-bot
Copy link
Collaborator

From pierre.raybaut on 2012-05-28T08:01:47Z

Anatoly, I think you have done some things lately regarding the code editor syntax highlighting features. I don't know if it's related, but I'm experiencing a significative difference of loading time between v2.1.10 and v2.2.0dev editors.

It may be worth doing some benchmark test. It's becoming annoying: I'm currently developping on a slow machine which had no problem running Spyder v2.1 but it is struggling to run v2.2...

Any idea?

Original issue: http://code.google.com/p/spyderlib/issues/detail?id=1064

@spyder-bot
Copy link
Collaborator Author

From pierre.raybaut on 2012-05-28T06:03:23Z

For example, if I have a dozen files opened and I try to split the editor window or to create a new window, it takes more than 8 seconds to process my request.

@spyder-bot
Copy link
Collaborator Author

From pierre.raybaut on 2012-05-28T06:13:58Z

Apparently, this is not the "load" feature that takes time because I ran the same benchmark in v2.2 and v2.1 and obtained the same results (see revision 847f8f3312da and https://code.google.com/p/spyderlib/source/detail?r=267c2476df62a8df4b4906fea6887651e7a5b103&repo=v21 ).

@spyder-bot
Copy link
Collaborator Author

From techtonik@gmail.com on 2012-05-28T06:18:32Z

It doesn't happen on my machine with 12+ tabs, although splitting does take about 3 seconds. It may happen that editor.rehighlight() is being called twice at some point - it is rather hard to backtrace all execution paths for it.

I guess the fastest way is to update to r5e0657290a9bc02b4b48e41044623896ac9d0b6a to see if the loading time differs?

@spyder-bot
Copy link
Collaborator Author

From pierre.raybaut on 2012-05-28T06:20:01Z

I just ran the following test:

  1. open only these files in Spyder:

spyderlib/widgets/sourcecode/base.py
spyderlib/widgets/sourcecode/codeeditor.py
spyderlib/widgets/editor.py
spyderlib/widgets/ipython.py
spyderlib/widgets/shell.py

  1. Split the editor window vertically:

v2.1.10: it takes 6.6 seconds on my [slow] machine here -- it's very long but that's what it is
v2.2.0dev: it takes 13.8 seconds! that's unbearable....

@spyder-bot
Copy link
Collaborator Author

From pierre.raybaut on 2012-05-28T06:21:36Z

(I'm developping with a Pentium M 1.7Ghz... it's slow but I never found a more effective way to optimize code!)

@spyder-bot
Copy link
Collaborator Author

From pierre.raybaut on 2012-05-28T06:48:27Z

As I mentionned in comment #2, I think it may be related to something else Spyder is doing after loading the selected file.

Curiously I can't reproduce the bad results of comment #4 after restarting Spyder... but here are new benchs with a lot more files opened at the same time (time necessary to split the editor window in two):

v2.1.10: 6.7s Revision 5e0657290a9b : 6.3s (i.e. a little bit faster) Revision 18abcf679c95 : 6.5s (i.e. no difference) Revision 28923a99b1d5 : 11.3s (i.e. almost two times slower) Revision 847f8f3312da : 11.4s (i.e. no difference)

So, apparently between v2.1.10 and revision 18abcf679c95 , there is no significative change. But after revision 28923a99b1d5 , it is two times slower than before.
It seems that revision d98df4092e16 is the one responsible! (I've checked with the revision just before)

Before trying to fix this bug, please try to do a benchmark to show this performance difference between revision 0240fa73feed and revision d98df4092e16 .

Thanks!

Summary: Editor performance issue since revision d98df4092e16
Owner: techtonik@gmail.com
Cc: -techtonik@gmail.com pierre.raybaut

@spyder-bot
Copy link
Collaborator Author

From pierre.raybaut on 2012-09-23T05:35:49Z

Labels: -Priority-High Priority-Critical

@spyder-bot
Copy link
Collaborator Author

From pierre.raybaut on 2012-09-23T06:57:12Z

Fixed with the following changesets: Revision 3b1ca9223a3e Revision 7676ebbd8446 Revision 856622499480 Revision c53255bbefc4 I have simply backed out changesets because this performance issue was introduced with revision d98df4092e16 , a revision which should never have been commited to the main branch, at least not without some debugging afterwards (nothing has been done for 4 months now). Something needed to be done: I'm tired of waiting a few seconds each time I'm splitting editor widget in two.

Status: Fixed

@spyder-bot
Copy link
Collaborator Author

From techtonik@gmail.com on 2012-09-29T05:23:10Z

Assigning this to myself to investigate why refactoring slowed down the performance.

Status: New
Labels: -Priority-Critical Priority-Low Performance

@spyder-bot
Copy link
Collaborator Author

From ccordoba12 on 2013-02-11T08:50:19Z

Anatoly, do you plan to check this for 2.2? If not, please move it to 2.3

@spyder-bot
Copy link
Collaborator Author

From techtonik@gmail.com on 2013-02-11T09:56:09Z

I am not using Spyder actively anymore since PySide development stalled. Reverted changesets will still be useful for refactoring highlighting code, but for now I don't have enough energy to proceed. Closing.

Thanks for the care.

Status: Fixed

@spyder-bot
Copy link
Collaborator Author

From ccordoba12 on 2013-02-11T10:13:48Z

I'm very sorry to hear that. Hope to see you soon, when PySide continues development.

@spyder-bot
Copy link
Collaborator Author

From techtonik@gmail.com on 2013-02-11T10:26:25Z

I might pop up earlier that PySide restores. =)

@spyder-bot
Copy link
Collaborator Author

From ccordoba12 on 2013-02-11T10:40:15Z

How's so? I thought PySide had a great group of Brazilian devs behind it.

@spyder-bot
Copy link
Collaborator Author

From techtonik@gmail.com on 2013-02-11T10:59:53Z

Nokia seized project financing after the deal with MS.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant