diff options
| author | Alessandro Gatti <a.gatti@frob.it> | 2025-11-21 09:26:23 +0100 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2026-01-09 14:46:52 +1100 |
| commit | 0fd084363a81c369a1487acd62f41f69199a7dae (patch) | |
| tree | 0340d812f337fa229dff1efc1095d8ff3ed0beb1 /tests/import/pkg7 | |
| parent | 21e4c036afc2798871f1d61331e639140f6f5e95 (diff) | |
tools/mpy_ld.py: Optimise MPY trampoline sizes if possible.HEADorigin/masterorigin/HEADmaster
This commit changes the way native modules' trampoline code sequence is
emitted, generating an optimised code sequence to jump to the entry
symbol.
Turns out the address of the entry point is known even before the
segments are built and the address of the entry point doesn't change
when processing the module on anything but Xtensa. This means that the
jump trampoline doesn't have to be a dummy fixed-size block to be filled
in later, but it can be the final trampoline being used in the module.
On Xtensa the address of the symbol is offset by the length of the
literals pool, but since the trampoline being generated is always the
shortest one said platform is left alone (handling distances greater than
128KiB would require more extensive changes).
Signed-off-by: Alessandro Gatti <a.gatti@frob.it>
Diffstat (limited to 'tests/import/pkg7')
0 files changed, 0 insertions, 0 deletions
