Introduce MBEDTLS_OPTIMIZE_ALWAYS
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
This commit is contained in:
parent
7fdfd70b19
commit
b055f75c3d
1 changed files with 7 additions and 0 deletions
|
@ -201,4 +201,11 @@ inline void mbedtls_xor(unsigned char *r, const unsigned char *a, const unsigned
|
|||
#define MBEDTLS_COMPILER_IS_GCC
|
||||
#endif
|
||||
|
||||
/* If -Os is specified, override with -O2 for a given function */
|
||||
#if defined(MBEDTLS_COMPILER_IS_GCC) && defined(__OPTIMIZE_SIZE__)
|
||||
#define MBEDTLS_OPTIMIZE_ALWAYS __attribute__((optimize("-O2")))
|
||||
#else
|
||||
#define MBEDTLS_OPTIMIZE_ALWAYS
|
||||
#endif
|
||||
|
||||
#endif /* MBEDTLS_LIBRARY_COMMON_H */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue