Bug 49246 - keyboard hangs/ mouse icon shape won't change
Summary: keyboard hangs/ mouse icon shape won't change
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows XP
: P2 major (vote)
Target Milestone: 3.0 M7   Edit
Assignee: Dani Megert CLA
QA Contact:
URL:
Whiteboard:
Keywords: performance
Depends on:
Blocks:
 
Reported: 2003-12-21 09:01 EST by martin.alley CLA
Modified: 2006-01-23 22:36 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description martin.alley CLA 2003-12-21 09:01:35 EST
I'm using Eclipse 3.0 M5 with JDT on XP.


This seems to be associated with when a syntax error is made, and various 
views get updated, when memory is low.

Are there any logs I can look at to report more information?

I recall a thread about a similar problem, and I believe the solution for M5 
was to program a delay in somewhere - as someone else mentioned at the time - 
this was not a good solution - and so it has proved to be.

Sorry if this has been reported in another form else where - I looked and 
couldn't see anything like this now.  The bug could be in the platform instead 
of the JDT - I have no way of knowing.

Martin
Comment 1 martin.alley CLA 2003-12-21 09:08:37 EST
Bug could also be in the jvm, I guess - I'm using Sun's jdk 1.4.2_02, but I 
also had this problem in Eclipse 2.1.1 and jdk 1.4.1_05
Comment 2 Dirk Baeumer CLA 2003-12-21 10:31:10 EST
Can you please be a little bit more specific. What do you mean with "keyboard 
hangs". 

Do you have any background activity like CVS actions or build running (e.g is 
there a little progress bar in the bottom right corner) ?
Comment 3 martin.alley CLA 2003-12-21 14:22:07 EST
By keyboard hanging I mean, I can't type in the main editor window, or scroll 
it with the arrow keys.  I can switch away from Eclipse with alt tab. There 
aren't any background activities in Eclipse that I am aware of, certainly 
nothing that I have set off.  But it does tend to happen once my machine has 
been running for a while, and there is general memory paging going on.

My impression is that there is a memory leak somewhere, as it works to start 
with.

The behaviour usually starts off with the mouse failing to work in Eclipse - 
it will move, but not change shape or respond to clicks.  I can workaround 
this by changing to another app and then back again, but it will only buy me a 
few more mouse clicks before the mouse becomes inoperable again.

I hope this helps.
Please let me know if I can provide any more info once it happens again.

Comment 4 Dirk Baeumer CLA 2003-12-21 16:31:39 EST
How do you start the Java VM. We recommend that you increase the default heap. 
This can be done by passing the -vmargs to the eclipse.exe (something like -
vmargs -Xms30M -Xmx200M).

We did a memory leak pass for M6 and fixed several leaks. Can you give M6 a 
try.
Comment 5 martin.alley CLA 2003-12-21 17:38:18 EST
okay - I'll try that.  I'm not familiar with the vmargs.  I will let you know 
once I have tried M6.  This may be a few days.

Thanks
Martin
Comment 6 martin.alley CLA 2003-12-26 08:37:07 EST
I had the problem again with M6, where I wasn't using the suggested vmargs.  
This occured just after I had openned a few more projects in my workspace.

I'm now trying M6 with the suggested vmargs.  I hope I've got the syntax 
right - I cut and paste from the message here.
Comment 7 Martin Erzberger CLA 2004-01-15 07:37:32 EST
Hello

I observe the same (or a similar) behaviour:

- The mouse is "caught" in the editor window. While I can move the cursor
  outside, the shape doesn't change, and the clicks go into the editor
  window (if I click say on the Package Explorer at the left of the editor
  window, then the text insertion point in the editor pane moves to the
  start of the line which is at the right of the mouse).
- Number and Character keys work, "Enter" key works, "Insert" key works, but
  cursor and backspace keys have no effect.
- Bringing another Windows to the focus, and switching back to Eclipse rescues
  the mouse. As soon as I press a key (any key, not just the ones that don't
  work) the problem reappears.  
- Stopping and restarting Eclipse doesn't help for long (if at all). A full
  reboot of the machine is required.
- Other applications (outside Eclipse) don't seem to be affected    
- Started with -vmargs -Xmx384M -Xms64M
- jdk 1.4.2_02, Win32, on Windows 2000, on IBM Thinkpad T40
- Eclipse 2.1.2 with several plugins (Modeling Framework 1.1.0, UML Plugin
  1.2.1, GEF 2.1.2, JFaceDbc 2.1.1)

Regards, Martin
  
Comment 8 Dani Megert CLA 2004-01-16 11:59:56 EST
Can you please try with I20040113 and report whether the situation has improved.
Comment 9 Dani Megert CLA 2004-01-19 09:32:12 EST
Regarding comment 6: since you did not use the vmargs it is very likely that you
run out of memory. Did you now try with a newer build (we fixed some memory
problems) and the listed VM arguments? Do you use plain Eclipse install or did
you add additional plug-ins?

Regarding comment 7: how much RAM does your machine have? can you reproduce this
on plain Eclipse 2.1.2 i.e. without other plug-ins being installed?

Reducing severity since we cannot reproduce on plain 2.1.2 Win XP.
Comment 10 Dani Megert CLA 2004-01-19 13:07:29 EST
Ignore comment 8.
Bug has been fixed now in HEAD.

Please reopen if you see this problem in builds > > 20040119.
Comment 11 Larry West CLA 2006-01-04 20:29:20 EST
As per my comments on Bug 83451 (https://bugs.eclipse.org/bugs/show_bug.cgi?id=83451#c35), this bug seems to have reappeared in eclipse 3.1 (and 3.1.1), even with -vmargs -Xmx512m -Xms192m.  Windows XP SP2.  JRE 1.50.0_06-b5.  Plug-ins: CDT 3.0.1, Perforce.

Martin Erzberger's comments here (https://bugs.eclipse.org/bugs/show_bug.cgi?id=49246#c7) seem to describe exactly the problem I'm seeing (and more succinctly).

So perhaps the fix to 49246 got undone by some other work.
Comment 12 Dani Megert CLA 2006-01-05 02:37:23 EST
Do you also see this using only Eclipse SDK and a fresh workspace? Please also try a 1.4 JRE.
Comment 13 Larry West CLA 2006-01-05 04:24:12 EST
I will try those conditions (1.4, SDK-only, fresh workspace) next week... I'm a little pressed for time the next couple days.

BTW, I never use the "workspace" per se, or at least not the default workspace: I always use existing projects, or create projects on a network drive (NFS drives mounted via Windows Services for UNIX, to be specific).

My plan: I will [next week] delete the project directories I have open now, refresh from the Perforce repository, and point [a brand new SDK-only, 1.4.2-jre] Eclipse at those projects and see how long it takes for the problem to resurface.   Let me know if you were thinking of something different.

If it works for a few days, I'll repeat that with a 1.5 jre.
Comment 14 Larry West CLA 2006-01-23 22:36:12 EST
(In reply to comment #13)
> I will try those conditions (1.4, SDK-only, fresh workspace) next week... 

(FYI: I've been in a situation where I'm only using Eclipse maybe an hour a day and the problem hasn't recurred using the original setup [post-reboot].  Will continue trying.)