Espressif ESP32-S2 Programming Manual page 1093

Table of Contents

Advertisement

Chapter 2. API Reference
The "Performance"setting causes the compiled code to be larger and faster, but will be easier to
correlated code addresses to source file lines.
"None"with -O0 produces compiled code without optimization.
Note that custom optimization levels may be unsupported.
Compiler
optimization
LOADER_COMPILER_OPTIMIZATION setting.
Available options:
• Debug (-Og) (COMPILER_OPTIMIZATION_DEFAULT)
• Optimize for size (-Os) (COMPILER_OPTIMIZATION_SIZE)
• Optimize for performance (-O2) (COMPILER_OPTIMIZATION_PERF)
• Debug without optimization (-O0) (COMPILER_OPTIMIZATION_NONE)
CONFIG_COMPILER_OPTIMIZATION_ASSERTION_LEVEL
Assertion level
Found in:
Compiler options
Assertions can be:
• Enabled. Failure will print verbose assertion details. This is the default.
• Set to "silent"to save code size (failed assertions will abort() but user needs to use the aborting
address to find the line number with the failed assertion.)
• Disabled entirely (not recommended for most configurations.)
CPPFLAGS in this case.
Available options:
• Enabled (COMPILER_OPTIMIZATION_ASSERTIONS_ENABLE)
Enable assertions. Assertion content and line number will be printed on failure.
• Silent (saves code size) (COMPILER_OPTIMIZATION_ASSERTIONS_SILENT)
Enable silent assertions. Failed assertions will abort(), user needs to use the aborting address
to find the line number with the failed assertion.
• Disabled (sets -DNDEBUG) (COMPILER_OPTIMIZATION_ASSERTIONS_DISABLE)
If assertions are disabled, -DNDEBUG is added to CPPFLAGS.
CONFIG_COMPILER_OPTIMIZATION_CHECKS_SILENT
Disable messages in ESP_RETURN_ON_* and ESP_EXIT_ON_* macros
Found in:
Compiler options
If enabled,
the error messages will be discarded in following check macros:
ESP_RETURN_ON_ERROR
ESP_EXIT_ON_FALSE
Default value:
• No (disabled)
CONFIG_COMPILER_HIDE_PATHS_MACROS
Replace ESP-IDF and project paths in binaries
Found in:
Compiler options
When expanding the __FILE__ and __BASE_FILE__ macros, replace paths inside ESP-IDF with paths
relative to the placeholder string"IDF" , and convert paths inside the project directory to relative paths.
This allows building the project with assertions or other code that embeds file paths, without the binary
containing the exact path to the IDF or project directories.
Espressif Systems
for
the
IDF
bootloader
-
ESP_EXIT_ON_ERROR
1082
Submit Document Feedback
is
set
separately,
see
-DNDEBUG is added to
-
ESP_RETURN_ON_FALSE
the
BOOT-
-
-
Release v4.4

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the ESP32-S2 and is the answer not in the manual?

Table of Contents

Save PDF