Bug 65911 - out of memory
Summary: out of memory
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.0 RC2   Edit
Assignee: Kent Johnson CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 65912 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-06-06 16:14 EDT by Xavier Méhaut CLA
Modified: 2006-04-10 10:04 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Xavier Méhaut CLA 2004-06-06 16:14:31 EDT
Hello,
I've an application with more than  1000 classes. The jdt doesn't complete the
build process to its term. It ends systematically with an out of memory warning
(and even several times my pc shut down without warning :-( ). I've tried to
augment the heap size, I've disabled many options, and so on... without success.
I can't arrive to build my program at all . My configuration is :
* eclipse 3RC1
* winxp home edition
* 512MB memory
* Athlon 2500+

regards
Xavier
ps : the build process is very long too...maybe swapping
Comment 1 Philipe Mulet CLA 2004-06-06 18:26:49 EDT
You may grant the Java VM with more memory using command: -Xmx 256M (or 
better).
Comment 2 Xavier Méhaut CLA 2004-06-07 02:09:02 EDT
I did this up to 400MB :-( with the same result.
Comment 3 Philipe Mulet CLA 2004-06-07 05:26:55 EDT
Then something seems clearly wrong. Please provide steps to reproduce.
Comment 4 Frederic Fusier CLA 2004-06-07 06:24:09 EDT
*** Bug 65912 has been marked as a duplicate of this bug. ***
Comment 5 Olivier Thomann CLA 2004-06-07 09:27:19 EDT
Do you have anything in the .log file?
Comment 6 Xavier Méhaut CLA 2004-06-07 17:12:20 EDT
!SESSION juin 06, 2004 10:30:45.163 --------------------------------------------
eclipse.buildId=I200405290105
java.version=1.4.2_04
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=fr_FR
!ENTRY org.eclipse.ui 4 4 juin 06, 2004 10:30:45.163
!MESSAGE Unhandled event loop exception
!ENTRY org.eclipse.ui 4 0 juin 06, 2004 10:30:46.765
!MESSAGE Failed to execute runnable (java.lang.OutOfMemoryError)
!STACK 0
org.eclipse.swt.SWTException: Failed to execute runnable
(java.lang.OutOfMemoryError)
	at org.eclipse.swt.SWT.error(SWT.java:2691)
	at org.eclipse.swt.SWT.error(SWT.java:2616)
	at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:109)
	at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:2693)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2385)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1363)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1334)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:253)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141)
	at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:96)
	at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:334)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:273)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:128)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:185)
	at org.eclipse.core.launcher.Main.run(Main.java:638)
	at org.eclipse.core.launcher.Main.main(Main.java:622)
!ENTRY org.eclipse.ui 4 4 juin 06, 2004 10:30:46.765
!MESSAGE *** SWT nested exception
!ENTRY org.eclipse.ui 4 0 juin 06, 2004 10:30:46.765
!MESSAGE java.lang.OutOfMemoryError
!STACK 0
java.lang.OutOfMemoryError
!ENTRY org.eclipse.core.runtime 4 2 juin 06, 2004 10:30:47.937
!MESSAGE An internal error occurred during: "Building workspace".
!STACK 0
java.lang.OutOfMemoryError
!ENTRY org.eclipse.ui 4 4 juin 06, 2004 10:30:47.937
!MESSAGE Unhandled event loop exception
!ENTRY org.eclipse.ui 4 0 juin 06, 2004 10:30:47.947
!MESSAGE java.lang.OutOfMemoryError
!STACK 0
java.lang.OutOfMemoryError
!SESSION juin 06, 2004 13:58:29.24 ---------------------------------------------
eclipse.buildId=I200405290105
java.version=1.4.2_04
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=fr_FR
!ENTRY org.eclipse.ui 4 4 juin 06, 2004 13:58:29.24
!MESSAGE Unhandled event loop exception
!ENTRY org.eclipse.core.runtime 4 2 juin 06, 2004 13:58:30.656
!MESSAGE An internal error occurred during: "Building Workspace".
!STACK 0
java.lang.OutOfMemoryError
!ENTRY org.eclipse.ui 4 0 juin 06, 2004 13:58:30.656
!MESSAGE Failed to execute runnable (java.lang.OutOfMemoryError)
!STACK 0
org.eclipse.swt.SWTException: Failed to execute runnable
(java.lang.OutOfMemoryError)
	at org.eclipse.swt.SWT.error(SWT.java:2691)
	at org.eclipse.swt.SWT.error(SWT.java:2616)
	at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:109)
	at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:2693)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2385)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1363)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1334)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:253)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141)
	at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:96)
	at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:334)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:273)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:128)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:185)
	at org.eclipse.core.launcher.Main.run(Main.java:638)
	at org.eclipse.core.launcher.Main.main(Main.java:622)
!ENTRY org.eclipse.ui 4 4 juin 06, 2004 13:58:30.666
!MESSAGE *** SWT nested exception
!ENTRY org.eclipse.ui 4 0 juin 06, 2004 13:58:30.666
!MESSAGE java.lang.OutOfMemoryError
!STACK 0
java.lang.OutOfMemoryError
!ENTRY org.eclipse.ui 4 4 juin 06, 2004 13:58:30.916
!MESSAGE Unhandled event loop exception
!ENTRY org.eclipse.ui 4 0 juin 06, 2004 13:58:30.916
!MESSAGE java.lang.OutOfMemoryError
!STACK 0
java.lang.OutOfMemoryError
!SESSION juin 06, 2004 21:51:30.55 ---------------------------------------------
eclipse.buildId=I200405290105
java.version=1.4.2_04
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=fr_FR
Command-line arguments: -Xmx256M
!ENTRY org.eclipse.jdt.core 4 4 juin 06, 2004 21:51:30.55
!MESSAGE Background Indexer Crash Recovery
!STACK 0
java.lang.OutOfMemoryError
!ENTRY org.eclipse.ui 4 4 juin 06, 2004 21:51:30.226
!MESSAGE Unhandled event loop exception
!ENTRY org.eclipse.ui 4 0 juin 06, 2004 21:51:30.226
!MESSAGE java.lang.OutOfMemoryError
!STACK 0
java.lang.OutOfMemoryError
!ENTRY org.eclipse.core.runtime 4 2 juin 06, 2004 21:51:30.346
!MESSAGE An internal error occurred during: "Building Workspace".
!STACK 0
java.lang.OutOfMemoryError
!SESSION juin 06, 2004 21:57:51.234 --------------------------------------------
eclipse.buildId=I200405290105
java.version=1.4.2_04
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=fr_FR
Command-line arguments: -Xmx256M
!ENTRY org.eclipse.jdt.core 4 4 juin 06, 2004 21:57:51.234
!MESSAGE Background Indexer Crash Recovery
!STACK 0
java.lang.OutOfMemoryError
!ENTRY org.eclipse.jdt.core 4 4 juin 06, 2004 22:00:33.527
!MESSAGE Background Indexer Crash Recovery
!STACK 0
java.lang.OutOfMemoryError
!ENTRY org.eclipse.jdt.core 4 4 juin 06, 2004 22:02:33.549
!MESSAGE Background Indexer Crash Recovery
!STACK 0
java.lang.OutOfMemoryError
Comment 7 Xavier Méhaut CLA 2004-06-07 17:17:40 EDT
!SESSION juin 06, 2004 09:53:14.256 --------------------------------------------
eclipse.buildId=I200405290105
java.version=1.4.2_04
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=fr_FR
!ENTRY org.eclipse.search 4 1 juin 06, 2004 09:53:14.256
!MESSAGE Internal Error
!STACK 0
java.lang.reflect.InvocationTargetException
	at
org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.java:315)
	at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:252)
	at
org.eclipse.search.internal.ui.util.ExtendedDialogWindow.run(ExtendedDialogWindow.java:185)
	at org.eclipse.ui.internal.progress.ProgressManager$5.run(ProgressManager.java:980)
	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69)
	at
org.eclipse.ui.internal.progress.ProgressManager.runInUI(ProgressManager.java:976)
	at org.eclipse.search.internal.ui.text.ReplaceDialog2.run(ReplaceDialog2.java:312)
	at
org.eclipse.search.internal.ui.text.ReplaceDialog2.buttonPressed(ReplaceDialog2.java:278)
	at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:506)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:89)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:82)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:796)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:2716)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2382)
	at org.eclipse.jface.window.Window.runEventLoop(Window.java:668)
	at org.eclipse.jface.window.Window.open(Window.java:648)
	at org.eclipse.search.internal.ui.text.ReplaceAction2.run(ReplaceAction2.java:152)
	at
org.eclipse.search.internal.ui.text.TextSearchPage$1.run(TextSearchPage.java:238)
	at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
	at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:106)
	at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:2693)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2385)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1363)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1334)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:253)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141)
	at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:96)
	at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:334)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:273)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:128)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:185)
	at org.eclipse.core.launcher.Main.run(Main.java:638)
	at org.eclipse.core.launcher.Main.main(Main.java:622)
Caused by: java.lang.OutOfMemoryError
Root exception:
java.lang.OutOfMemoryError
!SESSION juin 06, 2004 09:56:23.829 --------------------------------------------
eclipse.buildId=I200405290105
java.version=1.4.2_04
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=fr_FR
!ENTRY org.eclipse.core.resources 4 567 juin 06, 2004 09:56:23.829
!MESSAGE Could not read snapshot file.
!STACK 0
java.io.EOFException
	at java.io.DataInputStream.readInt(Unknown Source)
	at
org.eclipse.core.internal.resources.SaveManager.restoreSnapshots(SaveManager.java:707)
	at org.eclipse.core.internal.resources.SaveManager.restore(SaveManager.java:533)
	at org.eclipse.core.internal.resources.SaveManager.startup(SaveManager.java:1082)
	at org.eclipse.core.internal.resources.Workspace.startup(Workspace.java:1821)
	at org.eclipse.core.internal.resources.Workspace.open(Workspace.java:1602)
	at org.eclipse.core.resources.ResourcesPlugin.startup(ResourcesPlugin.java:325)
	at
org.eclipse.core.internal.compatibility.PluginActivator.start(PluginActivator.java:50)
	at
org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:958)
	at java.security.AccessController.doPrivileged(Native Method)
	at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:954)
	at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:937)
	at
org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:421)
	at
org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:293)
	at
org.eclipse.core.runtime.adaptor.EclipseClassLoader.findLocalClass(EclipseClassLoader.java:107)
	at
org.eclipse.osgi.framework.internal.core.BundleLoader.findLocalClass(BundleLoader.java:371)
	at
org.eclipse.osgi.framework.internal.core.BundleLoader.requireClass(BundleLoader.java:336)
	at
org.eclipse.osgi.framework.internal.core.BundleLoader.findRequiredClass(BundleLoader.java:914)
	at
org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:399)
	at
org.eclipse.osgi.framework.adaptor.core.AbstractClassLoader.loadClass(AbstractClassLoader.java:93)
	at java.lang.ClassLoader.loadClass(Unknown Source)
	at java.lang.ClassLoader.loadClassInternal(Unknown Source)
	at
org.eclipse.ui.internal.ide.model.WorkbenchAdapterFactory.<init>(WorkbenchAdapterFactory.java:26)
	at
org.eclipse.ui.internal.ide.model.WorkbenchAdapterBuilder.registerAdapters(WorkbenchAdapterBuilder.java:33)
	at
org.eclipse.ui.internal.ide.IDEWorkbenchAdvisor.initialize(IDEWorkbenchAdvisor.java:155)
	at
org.eclipse.ui.application.WorkbenchAdvisor.internalBasicInitialize(WorkbenchAdvisor.java:165)
	at org.eclipse.ui.internal.Workbench.init(Workbench.java:787)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1311)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:253)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141)
	at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:96)
	at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:334)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:273)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:128)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:185)
	at org.eclipse.core.launcher.Main.run(Main.java:638)
	at org.eclipse.core.launcher.Main.main(Main.java:622)
Comment 8 Kent Johnson CLA 2004-06-16 15:05:33 EDT
There is nothing in any of these traces that shows the builder is even running 
when you get an OOM exception.

Can you please paste in your command line arguments?
Comment 9 Xavier Méhaut CLA 2004-06-16 15:38:40 EDT
Hi,
I've tried with Eclipse 3RC2, and it works!!! It is quite long, but it works, in
contrary with RC1. I don't know what are the changes, but it is good ;)
regards
Xavier
Comment 10 Frederic Fusier CLA 2006-04-10 10:03:37 EDT
Reopen to set correct resolution
Comment 11 Frederic Fusier CLA 2006-04-10 10:04:39 EDT
Code hasn't been changed => close as WORKSFORME instead of FIXED