diff options
| author | 2025-12-18 23:33:26 +0000 | |
|---|---|---|
| committer | 2026-02-16 19:11:24 +0000 | |
| commit | f386f2a1fcae885967278710fe997c56e2183476 (patch) | |
| tree | a00d8854a055640952c48890b452ac5ae1bf9ced /src/langext.h | |
| parent | 7a07c08abe46f97f2412f06c77204e9015f97a47 (diff) | |
| download | sst-f386f2a1fcae885967278710fe997c56e2183476.tar.gz sst-f386f2a1fcae885967278710fe997c56e2183476.zip | |
Size-optimise a few things
Saves multiple kilobytes, somehow. Unlikely to make much of a
performance difference since it's mostly init/shutdown stuff.
Diffstat (limited to 'src/langext.h')
| -rw-r--r-- | src/langext.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/langext.h b/src/langext.h index 0624b71..7e3cbdb 100644 --- a/src/langext.h +++ b/src/langext.h @@ -77,6 +77,14 @@ static inline _Noreturn void _invoke_ub() {} //#define tailcall // Can't use this without Clang. #endif +#if defined(__clang__) +#define opt_small __attribute((minsize)) +#elif defined(__GNUC__) +#define opt_small __attribute((optimize("Os"))) +#else +#define opt_small +#endif + #endif // vi: sw=4 ts=4 noet tw=80 cc=80 |
