Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 294666 - The slow-typing monster is back!
Summary: The slow-typing monster is back!
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: PDT (show other bugs)
Version: unspecified   Edit
Hardware: Macintosh Mac OS X - Carbon (unsup.)
: P3 critical with 4 votes (vote)
Target Milestone: ---   Edit
Assignee: PHP UI CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-09 15:49 EST by Ken Stanley CLA
Modified: 2020-05-14 11:51 EDT (History)
8 users (show)

See Also:


Attachments
PHP/HTML template (13.90 KB, application/octet-stream)
2009-11-09 15:51 EST, Ken Stanley CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ken Stanley CLA 2009-11-09 15:49:10 EST
User-Agent:       Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5
Build Identifier: M20090917-0800

Similar to https://bugs.eclipse.org/bugs/show_bug.cgi?id=193309, when typing in a PHP document, typing is so slow that I can sit back and watch the buffer catch up to real time. This seems to happen only in PHP files that mix PHP and HTML/CSS/Javascript. If, for example, I rename the PHP file to .html, I can type as normal. 

I am using 64-bit Eclipse 3.5.1, with the Aptana Studio plugin (2.0.1) and the PDT (2.1.2). I have tried to increase the amount of memory available to Eclipse to no avail; I have tried both 512m and 1024m. I am running Snow Leopard 10.5.6, and my version of Java (java -version) is:

java version "1.6.0_15"
Java(TM) SE Runtime Environment (build 1.6.0_15-b03-219)
Java HotSpot(TM) 64-Bit Server VM (build 14.1-b02-90, mixed mode)

I am attaching the particular PHP file that I am trying to work on. When I try to add HTML (seems to occur when adding element attributes), the editor pegs the CPU and the application becomes unusable. I have also disabled code folding, which helped a little bit. 

Reproducible: Always
Comment 1 Ken Stanley CLA 2009-11-09 15:51:27 EST
Created attachment 151733 [details]
PHP/HTML template

Here is a PHP/HTML file that has been causing most of my headaches today. Renaming the file to have a .html extension seems to take out the problem altogether, as it no longer parses the file as PHP.
Comment 2 Michael Spector CLA 2009-12-03 04:08:00 EST
(In reply to comment #1)
> Created an attachment (id=151733) [details]
> PHP/HTML template
> 
> Here is a PHP/HTML file that has been causing most of my headaches today.
> Renaming the file to have a .html extension seems to take out the problem
> altogether, as it no longer parses the file as PHP.

Can you try with PDT 2.2?
Comment 3 Ken Stanley CLA 2009-12-03 11:45:39 EST
I was using PDT 2.2 until this bug forced me to revert: 295865
Comment 4 Toby Thain CLA 2009-12-10 13:22:22 EST
I seem to be seeing this problem in PDT 2.1.1, with the following differences:
 - I am on Linux, not OS X (Gentoo, 2.6.31, xorg, P4 3.2GHz HT w/ 2GB RAM)
 - not just on mixed files, but also on php-only files
 - Eclipse Platform 3.5.1

Keystroke latency is ~ 0.7 sec. Disabling Code Folding and Mark Occurrences has little or no effect.
Comment 5 Roy Ganor CLA 2010-02-11 10:30:26 EST
not sure why this bug was reopened.

A lot of work has been done for PDT 2.2 to make sure performance issues will not reoccur.
Comment 6 Gadi Goldbarg CLA 2010-05-11 06:45:21 EDT
Did not see this bad typing speed, and some another bad performance at PDT-2.2.0.v20100504

Closing this issue...

Verified by
Teodor Kirkov
teodor.k@zend.com
Comment 7 David Kirchner CLA 2010-06-28 13:07:52 EDT
(In reply to comment #6)
> Did not see this bad typing speed, and some another bad performance at
> PDT-2.2.0.v20100504

I didn't see this in previous versions of PDT but I see it in 2.2. It is incredibly slow, just as Ken Stanley described, except that it happens in pure-PHP files and not outside of the <?php ?> tags. I noticed it happens while typing text code and as well as comments.

You may not see this if you have a smaller project. The project I'm working on has thousands of files, but if I start a brand new project the editor is nice and fast.

I've tried increasing the memory available to Eclipse, and I've tried turning off all of the checkboxes under the PHP configuration (first one by one, then all at once) and I found no difference. I tried removing all templates under PHP -> Editor -> Templates as well.

I'm really surprised to see that it happens with comments. I would have guessed it was some sort of automatic code-completion stuff, but that shouldn't be triggering in comment blocks, eh? And besides, I believe I have that disabled.

Version: Helios Release
Build id: 20100617-1415
iMac 2.6Ghz i5, 8GB RAM

(In reply to comment #5)
> A lot of work has been done for PDT 2.2 to make sure performance issues will
not reoccur.

Are there any logs I can enable to help trace the slowness?
Comment 8 Chris CLA 2010-12-07 06:02:16 EST
Hi

I've noticed the same problem after installing Eclipse PDT version at work yesterday (eclipse 3.6.1, PDT 2.2.1) on iMac working in 32-bit environment with 4GB of RAM.

Actually it slows down typing speed with very long file over 6000 line (I didn't wrote that one) and works fine with short one. 

I've got a few months older installation at home on my Macbook and didn't noticed problem like this yet. I'm not sure if this is because of different version or maybe I just wrote shorter (modular ;-) files.

P.S.
Why this bug has still status closed???
Comment 9 Ben K CLA 2010-12-20 21:42:03 EST
have bad typing performance in between php tags

using 3.6.1 M20100909-0800
pdt 2.2.1.v20101001-2300
Comment 10 Ben K CLA 2010-12-20 21:53:44 EST
(In reply to comment #9)
> have bad typing performance in between php tags
> 
> using 3.6.1 M20100909-0800
> pdt 2.2.1.v20101001-2300

it gets better when i disable
"preferences->java->editor->advanced->pde api tools proposals"
(i don't use java, and autocomplete still seems to work)