Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 354696 - Eclipse indigo frequently hangs on OS X
Summary: Eclipse indigo frequently hangs on OS X
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.7   Edit
Hardware: Macintosh Mac OS X
: P3 normal with 7 votes (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-13 21:18 EDT by Talin CLA
Modified: 2020-04-03 17:44 EDT (History)
13 users (show)

See Also:


Attachments
Stack dump from Apple's 'force quit' dialog. (221.19 KB, text/plain)
2011-08-13 21:19 EDT, Talin CLA
no flags Details
VisualVM Tread tab on lock-up (Thread Dump failing) (186.85 KB, image/png)
2011-08-17 08:15 EDT, Fred CLA
no flags Details
Same problem experienced when using Helios. (237.05 KB, text/plain)
2011-09-09 10:00 EDT, Fred CLA
no flags Details
Stack dump from Apple's 'force quit' dialog, under OpenJDK (235.90 KB, text/plain)
2011-10-16 00:29 EDT, Talin CLA
no flags Details
Stack dump from Apple's 'force quit' dialog, rename variable. (207.80 KB, text/plain)
2011-10-19 03:42 EDT, Talin CLA
no flags Details
Another dump from force quit dialog (232.29 KB, text/plain)
2011-10-23 23:55 EDT, Talin CLA
no flags Details
.log file showing some codan errors (3.92 KB, text/plain)
2012-01-19 12:53 EST, Fred CLA
no flags Details
VisualVM thread dump (24.63 KB, text/plain)
2012-01-27 12:44 EST, Jeremy Gustie CLA
no flags Details
The stack from the Apple force quite dialog. (27.70 KB, text/plain)
2012-03-12 18:52 EDT, Joseph Pachod CLA
no flags Details
The stack trace from jstack (19.44 KB, text/plain)
2012-03-12 18:52 EDT, Joseph Pachod CLA
no flags Details
crash on relaunch after freeze (2.25 KB, text/plain)
2012-08-21 04:19 EDT, Maxime Beranger CLA
no flags Details
apple stack after kill when using WindowBuilder (331.21 KB, text/plain)
2012-08-21 04:24 EDT, Maxime Beranger CLA
no flags Details
Apple crash report on hung Eclipse (386.62 KB, text/plain)
2013-05-07 11:49 EDT, arthur CLA
no flags Details
Eclipse (Not responding) Activity Monitor (83.88 KB, image/png)
2013-05-07 11:56 EDT, arthur CLA
no flags Details
eclipse.ini (509 bytes, text/plain)
2013-05-07 12:46 EDT, arthur CLA
no flags Details
Eclipse configuration (233.71 KB, text/plain)
2013-05-07 12:47 EDT, arthur CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Talin CLA 2011-08-13 21:18:26 EDT
Build Identifier: 20110615-0604

I'm seeing the UI lock up (Spinner icon) about once every 1-2 hours, especially when attempting to use refactoring to rename a variable. This is under OS X Snow Leopard.

I attempted to debug the problem by running Eclipse under the Eclipse debugger as suggested in the FAQ. However, once the problem occurred the debugger was not able to communicated with the child process - any attempt to pause the running program gave an error message about packets timing out.

I have an error dump produced by the OS X "Force Quit" dialog, which I will attach.

Reproducible: Sometimes
Comment 1 Talin CLA 2011-08-13 21:19:21 EDT
Created attachment 201466 [details]
Stack dump from Apple's 'force quit' dialog.
Comment 2 Remy Suen CLA 2011-08-13 21:52:50 EDT
Please get a thread dump from VisualVM when Eclipse is locked up.
Comment 3 Remy Suen CLA 2011-08-16 08:59:32 EDT
(In reply to comment #1)
> Created attachment 201466 [details]
> Stack dump from Apple's 'force quit' dialog.

Actually, it looks to be stuck in some UI work.
Comment 4 Fred CLA 2011-08-17 08:15:34 EDT
Created attachment 201637 [details]
VisualVM Tread tab on lock-up (Thread Dump failing)

OS: Snow Leopard 10.6.8
Eclipse IDE for C/C++ Developers
Version: Indigo Release
Build id: 20110615-0604

java.version=1.6.0_26
java.vendor=Apple Inc.

Eclipse locked-up (beachballing). Attempting a VM thread dump but failing.
Comment 5 Fred CLA 2011-08-17 08:17:44 EDT
I am experiencing what I believe is the same bug, my args: 

-vmargs
-Dosgi.requiredJavaVersion=1.6.0
-XstartOnFirstThread
-Dorg.eclipse.swt.internal.carbon.smallFonts
-XX:MaxPermSize=384m
-Xms128m
-Xmx1024m
-Xdock:icon=../Resources/Eclipse.icns
-XstartOnFirstThread
-Dorg.eclipse.swt.internal.carbon.smallFonts
-XX:+HeapDumpOnOutOfMemoryError
-Dcom.sun.management.jmxremote

Also seems to beachball after 1-2 hours, usually after UI updates e.g. auto-complete proposal / syntax error highlighting etc. Force quit required.

No errors apparent in eclipse error log.

No heap dump written.

Have tried a VM thread dump when it occurs but it fails, please see screenshot.
Comment 6 Fred CLA 2011-09-09 10:00:04 EDT
Created attachment 203062 [details]
Same problem experienced when using Helios.

I have tried downgrading to Helios and the same problem occurs, which suggests that it's probably not an Eclipse bug. Nonetheless any suggestions would be welcomed. 

Apple crash report for Helios attached.
Comment 7 Talin CLA 2011-09-10 13:52:43 EDT
OK so I was finally able to reproduce the lockup when running under VisualVM.

Unfortunately, attempting to get a thread dump did not work. VisualVM is still responsive to user interaction, but it's been 10 minutes and the "Getting Thread Dump..." progress bar has not moved.
Comment 8 Talin CLA 2011-09-25 18:03:57 EDT
By the way, this is still happening for me - eclipse locks up about once an hour. And as mentioned in the previous note, running under visualvm did not provide any useful information.
Comment 9 yani.ioannou CLA 2011-09-26 10:58:15 EDT
I too am experiencing what appears to be the same bug, and it makes eclipse virtually unusable in OS X..
Comment 10 Talin CLA 2011-10-07 22:47:41 EDT
GIven the lack of good data on this bug - is there some alternate JVM that I could perhaps try running Eclipse under to see if I can get better data?
Comment 11 Talin CLA 2011-10-11 23:51:07 EDT
I went ahead and installed OpenJDK and updated my eclipse.ini file with the -vm arg to use it. I've been using that for 3 days and so far only one lockup, which is a tremendous improvement from before - previously I was getting 1-2 lockups per hour of us. The one lockup I did get was during a multi-file rename.
Comment 12 Talin CLA 2011-10-16 00:29:31 EDT
Created attachment 205271 [details]
Stack dump from Apple's 'force quit' dialog, under OpenJDK

Here's a new stack dump taken from the "force quit" dialog. The difference between this stack dump and the previous one is that this one was taken while running Eclipse under OpenJDK instead of the default JDK that comes with Snow Leopard. I'm hoping that this may help to shed some additional light on the problem.

Note that I'm still experiencing what I reported in the previous message - under OpenJDK, the lockups occur much less frequently, about once every 3-4 days, as opposed to 1-2 times per hour with the default JDK - but they still occur.
Comment 13 Talin CLA 2011-10-19 03:42:59 EDT
Created attachment 205479 [details]
Stack dump from Apple's 'force quit' dialog, rename variable.

Here's another thread dump taken from the "force quit" dialog. This was taken after Eclipse froze when attempting to rename a variable using the "Rename" refactoring command.

As I mentioned, Eclipse seems to freeze ("spinning beach ball") about once per day when running under OpenJDK, and much more frequently when running under the default JDK. This is with normal usage, i.e. typing, saving, running "make", etc.

However, the "Rename..." menu seems to lock up virtually 100% of the time. This may be a different bug, which is why I'm submitting this stack dump in addition to the others.

I'm also curious to know if there is a more recent version of Eclipse that I should be trying. The version that I am currently running is build ID  20110615-0604, which is several months old at least. This was downloaded from the Eclipse Indigo download page - I generally only install pre-built binary packages, as attempting to build from source is way too complex and time-consuming for me.

Unfortunately, the Eclipse Indigo download page gives absolutely no indication what version is being downloaded - in other words, there's no way to determine if the version available from the download page is different than the version that I am currently running, other than actually downloading and installing it. And I'm loathe to re-install Eclipse unless there's some compelling reason to do so, since reinstalling and reconfiguring all of my plugins is a pain.

Mainly, I'd like to know if there is some other version that I should be testing in order to provide better data about this problem.
Comment 14 Lakshmi P Shanmugam CLA 2011-10-19 09:06:23 EDT
(In reply to comment #13)
You need not build from source. You can try a more recent build (either 3.7.1 or 3.8M2) from here --> http://download.eclipse.org/eclipse/downloads/eclipse3x.php and see if the problem still happens.
Comment 15 Talin CLA 2011-10-22 01:43:33 EDT
I installed 3.7.1 and I have not had a crash since then, even when doing refactoring operations.
Comment 16 Talin CLA 2011-10-23 23:55:39 EDT
Created attachment 205778 [details]
Another dump from force quit dialog

I got another freeze with 3.7.1, this was after about a week's worth of use (say, around 25 hours of use doing normal editing of C++ code and various refactoring.) I've attached the dump again.
Comment 17 Fred CLA 2012-01-19 12:53:40 EST
Created attachment 209767 [details]
.log file showing some codan errors

Just wondering if anyone has had any progress with this bug, I'm still suffering a three or four crashes daily. 

I've tried the latest version of Indigo, also tried reverting to Helios which was marginally better but still crashed once a day.
Tried different Java updates (0_26 and 0_29), tried increasing the virtual memory, tried adding the "-UseCompressedOops", tried to get a VisualVM thread dump but it fails to get anything. Tried switching Applications > Utilities > JavaPreferences to 32bit preferred but none of these things made any improvements really (some made things worse).

Tried disabling "EclipsePrefs > Code Analysis > Launching > As you type", no luck.

I have a hunch that one of the Code Analysis / Checker tools is involved the issues, as the log file indicates (attached). It shows errors around start-up, but not any from around the time of the crash (I assume that maybe in its frozen state it is unable to write to the log file).

Just don't know what to try next! Any suggestions welcome. Thanks
Comment 18 Jeremy Gustie CLA 2012-01-27 12:44:18 EST
Created attachment 210207 [details]
VisualVM thread dump

Thread dump from VisualVM while getting beachball (switching to non-visable editor tabs)
Comment 19 Joseph Pachod CLA 2012-03-12 18:50:11 EDT
Hi

I'm facing the same issue, which mostly happens when launching a Java application: eclipse get stuck in preparing the launch. Waiting for a few minutes doesn't help, eclipse remains stuck. I've to force quit and restart it. Very painful.

I use the following eclipse:
Eclipse Java EE IDE for Web Developers.

Version: Indigo Service Release 2
Build id: 20120216-1857

My java -version is the following:
java version "1.6.0_29"
Java(TM) SE Runtime Environment (build 1.6.0_29-b11-402-11D50b)
Java HotSpot(TM) 64-Bit Server VM (build 20.4-b02-402, mixed mode)

My ini file is the following:
-clean
-startup
../../../plugins/org.eclipse.equinox.launcher_1.2.0.v20110502.jar
--launcher.library
../../../plugins/org.eclipse.equinox.launcher.cocoa.macosx.x86_64_1.1.101.v20120109-1504
-product
org.eclipse.epp.package.jee.product
--launcher.defaultAction
openFile
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Dorg.eclipse.swt.internal.carbon.smallFonts
-XX:MaxPermSize=128m
-XX:PermSize=128m
-Xms1024m
-Xmx1024m
-Xdock:icon=../Resources/Eclipse.icns
-XstartOnFirstThread

I join the apple dump and a jstack done on the eclipse process.

Would be very nice to have a solution for this issue.

best
Comment 20 Joseph Pachod CLA 2012-03-12 18:52:16 EDT
Created attachment 212510 [details]
The stack from the Apple force quite dialog.
Comment 21 Joseph Pachod CLA 2012-03-12 18:52:44 EDT
Created attachment 212511 [details]
The stack trace from jstack
Comment 22 Joseph Pachod CLA 2012-03-12 19:00:30 EDT
Oh, last additions:
Mac OS X version 10.7.3
When stuck, eclipse was using 100% of CPU (out of 4 cores).
Comment 23 Maxime Beranger CLA 2012-08-21 04:10:19 EDT
I'm getting the same symptoms under Juno.
Juno freeze to death sometimes when I perform some operations like rename, refactor, move, delete projects, open or change views and crash 100% when I try to parse something with WindowBuilder.
I first ran Java 1.7u6 then moved to Java 1.7u8 beta.

I tried to dump with VisualVM but as Eclipse take 100%, it wouldn't work.
Comment 24 Maxime Beranger CLA 2012-08-21 04:19:27 EDT
Created attachment 220091 [details]
crash on relaunch after freeze

Sometime (about 10-20%), when I relaunch Eclipse after it freezes, Eclipse crashes and I get this in the logs.
It may be completly unrelated or just a side effect, but so far I never got it on a "normal" launch (though I had only a few "normal" launches).
Comment 25 Maxime Beranger CLA 2012-08-21 04:21:17 EDT
posted stacktrace of a crash I sometime get on relaunch after freeze, maybe unrelated.
also, often my preferences are wiped when I relaunch.
Comment 26 Maxime Beranger CLA 2012-08-21 04:24:53 EDT
Created attachment 220092 [details]
apple stack after kill when using WindowBuilder

The Apple stack I get after killing Eclipse when it freezes after trying to parse some class with WindowBuilder
Comment 27 Nathan S CLA 2012-10-12 02:35:12 EDT
I don't know if this is the same issue, but I am on Snow Leopard (10.6.8 running as i386) with Juno (4.2.0) and have been experiencing hangs with Java development for a long time, including with previous Eclipse releases.

The problem definitely seems to be Java-specific (e.g. when editing Python files with PyDev it does not occur).

It also seems to be related to code analysis. In fact, I can nearly always reproduce by making a change that adds or removes a syntax error, and immediately entering Cmd+S to save the file. (I have learned to wait a second or two after editing the code before saving.) Various attempts to muck with eclipse.ini options have no effect.

The only refactoring command I use is Rename, which has caused problems on occasion as well.

Current Java version information:

java version "1.6.0_35"
Java(TM) SE Runtime Environment (build 1.6.0_35-b10-428-10M3811)
Java HotSpot(TM) 64-Bit Server VM (build 20.10-b01-428, mixed mode)
Comment 28 arthur CLA 2013-05-07 11:49:34 EDT
Created attachment 230590 [details]
Apple crash report on hung Eclipse

Note that the crash report says:
Command:         Eclipse
Path:            /Applications/eclipse/Eclipse.app/Contents/MacOS/eclipse
Version:         3.8 (3.8)

whereas the actual Eclipse version is
Eclipse SDK

Version: 4.2.2
Build id: M20130204-1200
Comment 29 arthur CLA 2013-05-07 11:56:25 EDT
Created attachment 230592 [details]
Eclipse (Not responding) Activity Monitor
Comment 30 arthur CLA 2013-05-07 12:01:21 EDT
Hangs with 100% cpu for me frequently too. Renders Eclipse completely useless.
Only plug-in is PyDev. 

See "Apple crash report on hung Eclipse", "Eclipse (Not responding) Activity Monitor"

MacBook Pro
System Software Overview:
  System Version:	Mac OS X 10.7.5 (11G63)
  Kernel Version:	Darwin 11.4.2
Processor  2.8 GHz Intel Core i7

$ java -version
java version "1.6.0_45"
Java(TM) SE Runtime Environment (build 1.6.0_45-b06-451-11M4406)
Java HotSpot(TM) 64-Bit Server VM (build 20.45-b01-451, mixed mode)

Eclipse SDK
Version: 4.2.2
Build id: M20130204-1200
Comment 31 arthur CLA 2013-05-07 12:46:25 EDT
Created attachment 230598 [details]
eclipse.ini
Comment 32 arthur CLA 2013-05-07 12:47:08 EDT
Created attachment 230599 [details]
Eclipse configuration
Comment 33 arthur CLA 2013-05-07 12:52:24 EDT
Also tried to use Oracle's Java 7:
$ "/Library/Java/JavaVirtualMachines/JDK 1.7.0 Developer Preview.jdk/Contents/Home/bin/java" -version
openjdk version "1.7.0-ea"
OpenJDK Runtime Environment (build 1.7.0-ea-b222)
OpenJDK 64-Bit Server VM (build 21.0-b17, mixed mode)

According to http://wiki.eclipse.org/Eclipse.ini, to specify the java VM, one says:

-vm
<java execution path>

like this:

-vm
/Library/Java/JavaVirtualMachines/JDK 1.7.0 Developer Preview.jdk/Contents/Home/bin/java

Although Eclipse starts with this (see https://bugs.eclipse.org/bugs/attachment.cgi?id=230598) the configuration remains java.version=1.6.0_45 (see https://bugs.eclipse.org/bugs/attachment.cgi?id=230599).

Perhaps a distinct bug.
Comment 34 arthur CLA 2013-05-17 09:35:58 EDT
Any ideas folks? It doesn't look like anyone is working on this. I'd hate to abandon Eclipse, but can't use it when it freezes this frequently.
Comment 35 Eclipse Genie CLA 2020-04-03 17:44:03 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.