Using -fno-unind-tables in conjunction with -fno-exceptions

What is the advantage of using -fno-unwind-tablesin addition to -fno-exceptions- especially on C ++ embedded systems?

According to Bare Metal C ++ Practical Guide - § Exceptions must be both:

You can prevent the use of throw statements by providing certain parameters to the compiler. For the GNU compiler (gcc), use -fno-exceptionsin conjunction with parameters -fno-unwind-tables.

However, there is no explanation of what it does -fno-unwind-tables.

+4
source share
1 answer

Per GCC, ( ), , , - . , , backtrace (, C-).

, , , , , -fno-exceptions, , , . , , , , .


make - ++ ( -fno-exceptions), 3 , , :

default                        : 576KB
CPPFLAGS += -fno-unwind-tables : 576KB
CPPFLAGS += -funwind-tables    : 580KB

.ARM.extab ELF - , script, , .

+2

Source: https://habr.com/ru/post/1654364/


All Articles