ESP32 compiling time is way too long!
-
- Posts: 42
- Joined: Fri Apr 12, 2019 4:25 pm
- Location: Canada
ESP32 compiling time is way too long!
Hello other developers.
ESP32 takes minutes to compile. How do you guys live with the long compiling time?
Every change takes minutes to verify.
I guess at the later stage in the development it is probably fine.
But at beginning it is really slowing things done!
Thanks
Paul
ESP32 takes minutes to compile. How do you guys live with the long compiling time?
Every change takes minutes to verify.
I guess at the later stage in the development it is probably fine.
But at beginning it is really slowing things done!
Thanks
Paul
Re: ESP32 compiling time is way too long!
The initial build takes a bit. On my system it takes 15 seconds. Once you make a change it will recompile just that file. So it sounds like you possibly got something messed up in your setup install.
Make sure you add the -jx option to make. I.E. make -jx. where x is how many cores your PC has.
Make sure you add the -jx option to make. I.E. make -jx. where x is how many cores your PC has.
Re: ESP32 compiling time is way too long!
I think -jx is x = 2 x cores because each core supports two threads. Also if you are running win10 you should disable defender from scanning your development directory.
John A
John A
Re: ESP32 compiling time is way too long!
Correct. My current system is a 8 core. so that would be: make -j16. I should have been more clear, just assumed people knew.I think -jx is x = 2 x cores because each core supports two threads.
Re: ESP32 compiling time is way too long!
Yes, after the initial build only changed source files should be compiled.
The only exception is if you edit the menuconfig. In this case all files need re-compilation with the new config settings.
If you're not seeing this, it may be a bug - please provide some more details so we can help you figure it out.
As others have said, running "make -jN" and (on Windows) disabling Defender or adding Defender exceptions for IDF paths & tools will improve performance a lot.
You can also get better Windows performance by moving to the new CMake build system, but Eclipse support for this is still pending. https://docs.espressif.com/projects/esp ... ted-cmake/
The only exception is if you edit the menuconfig. In this case all files need re-compilation with the new config settings.
If you're not seeing this, it may be a bug - please provide some more details so we can help you figure it out.
As others have said, running "make -jN" and (on Windows) disabling Defender or adding Defender exceptions for IDF paths & tools will improve performance a lot.
You can also get better Windows performance by moving to the new CMake build system, but Eclipse support for this is still pending. https://docs.espressif.com/projects/esp ... ted-cmake/
-
- Posts: 42
- Joined: Fri Apr 12, 2019 4:25 pm
- Location: Canada
Re: ESP32 compiling time is way too long!
I am running it on Windows 7.
This is the build output when I start build:
23:08:25 **** Incremental Build of configuration Default for project blink ****
make -j8 all
This is the build output when I start build:
23:08:25 **** Incremental Build of configuration Default for project blink ****
make -j8 all
-
- Posts: 42
- Joined: Fri Apr 12, 2019 4:25 pm
- Location: Canada
Re: ESP32 compiling time is way too long!
Output.txt attached.
I didn't change any code. Just compile, it always takes almost a minute to finish.
I didn't change any code. Just compile, it always takes almost a minute to finish.
- Attachments
-
- output.txt
- (35.38 KiB) Downloaded 1056 times
-
- Posts: 42
- Joined: Fri Apr 12, 2019 4:25 pm
- Location: Canada
Re: ESP32 compiling time is way too long!
I compiled the project in mingw32 command line.
It only compiles the changes. and much faster.
I attached the output.
So there much be some setting in Eclipse messed up the build?
Thanks
Paul
It only compiles the changes. and much faster.
I attached the output.
So there much be some setting in Eclipse messed up the build?
Thanks
Paul
- Attachments
-
- output in mingw32.txt
- (715 Bytes) Downloaded 997 times
Re: ESP32 compiling time is way too long!
Hi Paul,
There's more console output in the Eclipse log, but you'll probably get the same console output in MINGW with "make V=1" - verbose output.
48 seconds is a long time, as the Eclipse build log shows that nothing was actually compiled (it just looks at each component and says "nothing needs compiling here").
What ESP-IDF version do you have?
There's more console output in the Eclipse log, but you'll probably get the same console output in MINGW with "make V=1" - verbose output.
48 seconds is a long time, as the Eclipse build log shows that nothing was actually compiled (it just looks at each component and says "nothing needs compiling here").
What ESP-IDF version do you have?
-
- Posts: 42
- Joined: Fri Apr 12, 2019 4:25 pm
- Location: Canada
Re: ESP32 compiling time is way too long!
My ESP-IDF version:
Paul@W510 MINGW32 ~/esp/esp-idf
# git describe
v4.0-dev-311-g70eda3d22
Thanks
Paul
Paul@W510 MINGW32 ~/esp/esp-idf
# git describe
v4.0-dev-311-g70eda3d22
Thanks
Paul
Who is online
Users browsing this forum: No registered users and 105 guests