[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.newcomer] Re: problem with slow ant builds

Well, it's deep inside the Sun Java compiler, which I know nothing about. It looks like in this particular snippet it is performing classpath computations... one thing that can seriously affect compile performance is the location of the JARs on your classpath. I.e., are they on a network drive on a slow connection, on a local drive, etc. Compiling against a classpath that is entirely on your local disk is generally quite a lot faster than compiling against JARs located elsewhere. I don't know what else to suggest, other than trying to eliminate the variables between your machine and your colleague's machine to see what difference is causing the huge discrepancy in compile time.
--


Paul wrote:
Ok I figured out how to get it to run in the console in Windows
This is my heap dump: (Any help would be appreciated)

Full thread dump Java HotSpot(TM) Client VM (1.5.0_05-b05 mixed mode, sharing):

"Low Memory Detector" daemon prio=5 tid=0x00a6f2b8 nid=0x968 runnable [0x00000000..0x00000000]

"CompilerThread0" daemon prio=10 tid=0x00a6dfc0 nid=0x678 waiting on condition [0x00000000..0x02c0f84c]

"Signal Dispatcher" daemon prio=10 tid=0x00a6d128 nid=0x9d8 waiting on condition
[0x00000000..0x00000000]


"Finalizer" daemon prio=9 tid=0x00a48490 nid=0xa0c in Object.wait() [0x02b8f000..0x02b8fc68]
at java.lang.Object.wait(Native Method)
- waiting on <0x22f7cbf8> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:116)
- locked <0x22f7cbf8> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:132)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:159)


"Reference Handler" daemon prio=10 tid=0x00a47008 nid=0xec0 in Object.wait() [0x02b4f000..0x02b4fce8]
at java.lang.Object.wait(Native Method)
- waiting on <0x22f7cc78> (a java.lang.ref.Reference$Lock)
at java.lang.Object.wait(Object.java:474)
at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:116)
- locked <0x22f7cc78> (a java.lang.ref.Reference$Lock)


"main" prio=5 tid=0x00036890 nid=0x104 runnable [0x0007e000..0x0007fc3c]
at java.util.zip.ZipFile.close(Native Method)
at java.util.zip.ZipFile.close(ZipFile.java:481)
- locked <0x22a83b40> (a java.util.jar.JarFile)
at com.sun.tools.javac.util.Paths$Path.addJarClassPath(Paths.java:254)
at com.sun.tools.javac.util.Paths$Path.addFile(Paths.java:223)
at com.sun.tools.javac.util.Paths$Path.addFiles(Paths.java:205)
at com.sun.tools.javac.util.Paths$Path.addFiles(Paths.java:210)
at com.sun.tools.javac.util.Paths.computeUserClassPath(Paths.java:307)
at com.sun.tools.javac.util.Paths.lazy(Paths.java:78)
at com.sun.tools.javac.util.Paths.bootClassPath(Paths.java:91)
at com.sun.tools.javac.jvm.ClassReader.fillIn(ClassReader.java:1901)
at com.sun.tools.javac.jvm.ClassReader.complete(ClassReader.java:1538)
at com.sun.tools.javac.code.Symbol.complete(Symbol.java:355)
at com.sun.tools.javac.comp.Enter.visitTopLevel(Enter.java:249)
at com.sun.tools.javac.tree.Tree$TopLevel.accept(Tree.java:382)
at com.sun.tools.javac.comp.Enter.classEnter(Enter.java:214)
at com.sun.tools.javac.comp.Enter.classEnter(Enter.java:228)
at com.sun.tools.javac.comp.Enter.complete(Enter.java:441)
at com.sun.tools.javac.comp.Enter.main(Enter.java:426)
at com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:413)
at com.sun.tools.javac.main.Main.compile(Main.java:592)
at com.sun.tools.javac.main.Main.compile(Main.java:544)
at com.sun.tools.javac.Main.compile(Main.java:67)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.tools.ant.taskdefs.compilers.Javac13.execute(Javac13.java:55)
at org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:931)
at org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:757)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
at org.apache.tools.ant.Task.perform(Task.java:364)
at org.apache.tools.ant.Target.execute(Target.java:341)
at org.apache.tools.ant.Target.performTasks(Target.java:369)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:37)
at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:382)
at org.apache.tools.ant.taskdefs.CallTarget.execute(CallTarget.java:107)


at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
at org.apache.tools.ant.Task.perform(Task.java:364)
at org.apache.tools.ant.Target.execute(Target.java:341)
at org.apache.tools.ant.Target.performTasks(Target.java:369)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:40)
at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
at org.apache.tools.ant.Main.runBuild(Main.java:668)
at org.apache.tools.ant.Main.startAnt(Main.java:187)
at org.apache.tools.ant.launch.Launcher.run(Launcher.java:246)
at org.apache.tools.ant.launch.Launcher.main(Launcher.java:67)


"VM Thread" prio=10 tid=0x00a686f8 nid=0x5cc runnable

"VM Periodic Task Thread" prio=10 tid=0x00a70638 nid=0xa14 waiting on condition

"John Arthorne" <john@xxxxxxxxxxxxxx> wrote in message news:djj1bq$q4f$3@xxxxxxxxxxxxxxxxxxx

You can try getting a heap dump from Java to see where the time is going. Ctrl+Break on the Java console in Windows, or kill -3 to the java process on *nix platforms. Without this kind of information it is hard to give further advice.
--


Paul wrote:

Hi,

I am trying to build my project with ant and it works very slow. For instance my co-worker can do the build of the project in 30 seconds whereas it takes me 10 minutes. Does anyone have any ideas on what the problem could be?

Thanks