I've been programming for about 2 years, and so far Java is all I know.

When I made the switch from BlueJ to eclipse I noticed my old projects ran much faster. What would be the reason for this, as far as I knew the executing of java byte code is handled by the JVM and I still had the same JVM after I switched. Other than that does eclipse have had a different compiler? That's the only other thing I could think of.


I timed it, the average runtime for, we'll call it A(100), in blueJ was 1 Minutes; 8 Seconds; 846 Milliseconds. In eclipse A(100) only took 8 Seconds; 459 Milliseconds. I've also noticed the increase for all my other programs too. I haven't measured those yet but the difference is definitely noticeable.

A() is a function that does alot of computation than prints of a chart of information based on what it found, fyi.

  • 1
    Did you measure this or is just a subjective impression?
    – Vitor Py
    Jul 10, 2011 at 1:25
  • Eclipse uses it's own compiler, though I don't know how much of a difference it would actually make.
    – Roman
    Jul 10, 2011 at 1:30
  • 1
    Yes, Eclipse has its own compiler and it could optimize particular things for you quite well. It also runs the program in its own console. What you're experiencing might just be the speed of the console, as you didn't specify what kind of program you're running.
    – Macneil
    Jul 10, 2011 at 1:34
  • 4
    Could be that since BlueJ is a teaching environment and not just a Java development studio it's doing a lot of extra things behind your back, too. Jul 10, 2011 at 1:35

1 Answer 1


I think the main reason is that BlueJ runs your code in a VM with a debugger attached. BlueJ actually has two VMs running: the main one, and the one with your code inside (the user VM, aka the debug VM). The main VM has a debugger attached to the user VM, which allows it to do things like pause user code, inspect the state of objects and all sorts. I imagine this probably adds a fair bit of overhead (perhaps inhibiting the JIT compilation?); the speed that code executes is not a major concern for a learning environment like BlueJ, as long as it's reasonable.

  • Does eclipse do the same thing? You can debug you code in eclipse as well.
    – Ryan Stull
    Jul 11, 2011 at 15:51
  • Eclipse lets you run in either normal or debug mode. I've noticed that the debug mode can be a bit slower in some cases.
    – mikera
    Jul 11, 2011 at 17:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.