diff options
| author | 2025-12-18 23:33:26 +0000 | |
|---|---|---|
| committer | 2026-02-16 19:11:24 +0000 | |
| commit | f386f2a1fcae885967278710fe997c56e2183476 (patch) | |
| tree | a00d8854a055640952c48890b452ac5ae1bf9ced /src/chunklets/x86.c | |
| 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/chunklets/x86.c')
| -rw-r--r-- | src/chunklets/x86.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/chunklets/x86.c b/src/chunklets/x86.c index 012cbb0..23d52ae 100644 --- a/src/chunklets/x86.c +++ b/src/chunklets/x86.c @@ -41,6 +41,13 @@ static int mrmsib(const unsigned char *p, int addrlen) { return 1; // note: include the mrm itself in the byte count } +#ifndef X86_DISABLE_SIZE_OPT +#if defined(__clang__) +__attribute((minsize)) +#elif defined(__GNUC__) +__attribute((optimize("Os"))) +#endif +#endif int x86_len(const unsigned char *insn) { #define CASES(name, _) case name: int pfxlen = 0, addrlen = 4, operandlen = 4; |
