Compilation became incredibly slow

Well, I replaced the winavr toolkit so another option is to debug the problem yourself with Process Monitor. Filter arduino related events and check what is the one that takes a lot of time (maybe even the File summary can give you a hint)

Are you running out of hard drive space on the drive where windows is installed or getting short on memory when the IDE is running that causes page swapping to HD?

Problem solved! It was ^%^$#%& ZoneAlarm!

I checked it based on a hunch and indeed, it somehow decided Arduino isn't trustworthy enough and bogged it down behind the curtains. Killing ZoneAlarm, or even setting the Arduino trust level there to the highest manually, brought speed back like magic.

Riva - thank you too, I forgot to mention that the slow compiling did not seem to affect anything else in the system, so it wasn't a resource problem.

Well, 'till the next mystery, folks! Have a great week! :slight_smile:

I am having the same problem
the compilation process became very slow
can please help me to fix it?

Me too, high compilation speed with Windows-XP but on my laptop with Windows 7extremely slow speed!!!
Installed already latest Java, switched off McAfee etc however no improvements. What is the solution?

pieterpos:
Me too, high compilation speed with Windows-XP but on my laptop with Windows 7extremely slow speed!!!
Installed already latest Java, switched off McAfee etc however no improvements. What is the solution?

Arduino IDE has Java built in to it's distribution, someone here suggested that if you have Java console installed then that may be used instead of the internal version. Have you tried un-installing Java, re-booting and then trying to compile a sketch using the IDE?

Same problem.
I set compiling to verbose and see lots of these lines

warning: this is the location of the previous definition

and these kinds

warning: "BIN" redefined
In file included from c:/documents and settings/jacques/my documents/arduino/arduino-1.0.4-windows/arduino-1.0.4/hardware/tools/avr/lib/gcc/../../avr/include/avr/iotn45.h:38,

and these kind of things, I guess referring to a problem within libraries etc. that came with Arduino.

C:\Documents and Settings\JACQUES\My Documents\Arduino\arduino-1.0.4-windows\arduino-1.0.4\hardware\tiny\cores\tiny\wiring_pulse.c:53: warning: cast to pointer from integer of different size

And even these kinds

c:/documents and settings/jacques/my documents/arduino/arduino-1.0.4-windows/arduino-1.0.4/hardware/tools/avr/lib/gcc/../../avr/include/avr/delay.h:36:2: warning: #warning "This file has been moved to <util/delay.h>."

Is that what is making my code so slow? I am using stock standard IDE 1.0.4.

Bergie:
Same problem.
...

Is that what is making my code so slow? I am using stock standard IDE 1.0.4.

Slow to compile or slow to execute? Is this an installation problem?

Execution is normal. When I click compile, it becomes slow. The same sketch that took a few seconds to compile now take several minutes. I did re-install Jave, unblocked Arduino in my Firewall etc, But since two weeks ago, prior to upgrading from 1.0.1 to 1.0.4 compiling takes much longer than usual.
Thank you

What kind of CPU and how much RAM? Can you watch task manager while compiling?

Bergie:
I did re-install Jave, unblocked Arduino in my Firewall etc

Have you tried uninstalling Java completely and trying? The Arduino IDE package includes it's own Java runtimes and I wonder if updating the full version of Java some how breaks these.

I have been fighting this for months and finally found MY problem: ESET Smart Security was apparently constantly checking USB ports and the Virtual com port etc.

My solution:

ESET Smart Security

  • Realtime File system protection
  • Advanced Setup
  • Additonal Threatsense Parameters..
    [x] Advanced heuristics on executable files from removeable media
    [exceptions]
    (Mark ALL USB PORTS AND CONTROLLERS)

IDE 1.04 and 1.05 BLINK went from 2 minutes to 15 seconds to Verify! (FIRST Verify can take a long time.. 60 seconds or so...)

*** UPDATE: Still having slowness problems; see following post..

Hi Everyone,

I really need to track this to the root cause.

I have 3 machines I often use:

  1. Win7 64 bit Athlon 4 cores 12GB... BLINK takes 90 to 100 seconds to verify (after first verify which is longer)
  2. Win7 64 bit AMD sempron 2GB Blink verifies in 2 SECONDS OR LESS!!!
  3. WinXP 32 bit INTEL Quad core 2 GB BLINK takes 70 to 90 seconds to verify

On machine 2, more complex examples take less than 3 SECONDS!

Versions 0023, 1.02 1.05 behave the same....

So. WTF?? Really!

This is a really serious problem. If I encounter this in workshops with students this may be a killer to the whole Arduino thing.

Has anyone heard anything recent about this?? I really have to dig into this. it is intolerable.

I just tested verify on blink with my Core 2 Duo E6700. ~3 GB RAM

I took 15 seconds the first verify and 3 seconds on the next one. Alittle slow but not super bad.

terryking228:

  1. Win7 64 bit Athlon 4 cores 12GB... BLINK takes 90 to 100 seconds to verify (after first verify which is longer)
  2. Win7 64 bit AMD sempron 2GB Blink verifies in 2 SECONDS OR LESS!!!
  3. WinXP 32 bit INTEL Quad core 2 GB BLINK takes 70 to 90 seconds to verify

On machine 2, more complex examples take less than 3 SECONDS!

The general consensus normally points to anti-virus software being the culprit. What's different about the Sempron machine compared to the other 2. Do the machines have Java Console installed? From other peoples descriptions I wondered if the IDE's "built-in" Java does not get used if the full Java console is available and changes in the full console is slowing the game down.

Hi and thanks for the responses.

The main difference on the Fast machine is I have NOT responded to the invitation to update JAVA.

I have removed Java (using Add-Remove programs) on the other machines with no effect.

IsThere another way to remove "Java Console" etc??

I have disabled ESET AntiVirus and realtime file protection with no effect (but configuring ESET to not check USB did help a little).

Any pointers greatly appreciated! I am doing lots of examples for http://ArduinoInfo.Info and this is really Slooowwiing me down.

terryking228:
The main difference on the Fast machine is I have NOT responded to the invitation to update JAVA.

I have removed Java (using Add-Remove programs) on the other machines with no effect.

IsThere another way to remove "Java Console" etc??

There is a java removal tool that looks like it deletes older versions of Java but not the current one. Maybe running that will clean up any files left by old versions of java and the uninstall tool would remove the latest.
I wonder if java updates scan the PC looking for old libraries etc and updates them. Maybe worth trying the java uninstaller and then removing/ re-downloading arduino IDE in case it's internal java files have been somehow updated.

If you think Java might be the problem, you can see which version of Java is being used by running this from a command line in your arduino directory:

arduino --l4j-debug

This will create a launch4j.log file in your arduino directory.

It should look something like this:

CmdLine:	C:\arduino\arduino-1.0.4\arduino.exe --l4j-debug
WOW64:		yes
Working dir:	C:\arduino\arduino-1.0.4\.
Bundled JRE:	java
Check launcher:	C:\arduino\arduino-1.0.4\java\bin\javaw.exe (OK)
Add classpath:	lib\pde.jar
Add classpath:	lib\core.jar
Add classpath:	lib\jna.jar
Add classpath:	lib\ecj.jar
Add classpath:	lib\RXTXcomm.jar
Launcher:	C:\arduino\arduino-1.0.4\java\bin\javaw.exe
Launcher args:	-Xms128m -Xmx128m -classpath "lib;C:\arduino\arduino-1.0.4\java\lib\tools.jar;lib\pde.jar;lib\core.jar;lib\jna.jar;lib\ecj.jar;lib\RXTXcomm.jar" processing.app.Base
Args length:	164/32768 chars
Exit code:	259

Look for the lines that start with:
Bundled JRE:
Check launcher:
Launcher:

This will help indicate if you are using the Arduino bundled Java or your installed Java.

Hi Louis,
Thanks for the pointer. Here's what I see:

CmdLine:	C:\Users\TerryKing\Desktop\ArduinoDev\arduino-1.0.5\arduino.exe --l4j-debug
WOW64:		yes
Working dir:	C:\Users\TerryKing\Desktop\ArduinoDev\arduino-1.0.5\.
Bundled JRE:	java
Check launcher:	C:\Users\TerryKing\Desktop\ArduinoDev\arduino-1.0.5\java\bin\javaw.exe (OK)
Add classpath:	lib\pde.jar
Add classpath:	lib\core.jar
Add classpath:	lib\jna.jar
Add classpath:	lib\ecj.jar
Add classpath:	lib\RXTXcomm.jar
Launcher:	C:\Users\TerryKing\Desktop\ArduinoDev\arduino-1.0.5\java\bin\javaw.exe
Launcher args:	-Xms128m -Xmx128m -classpath "lib;C:\Users\TerryKing\Desktop\ArduinoDev\arduino-1.0.5\java\lib\tools.jar;lib\pde.jar;lib\core.jar;lib\jna.jar;lib\ecj.jar;lib\RXTXcomm.jar" processing.app.Base
Args length:	191/32768 chars
Exit code:	259

I DO now have Java installed (did not before)...

What does this tell me???
Thanks!

You are using the java that is bundled with the IDE.

I don't think that is the cause of your problem.

I know that doesn't help much, but at least you can rule that out.