gecko-dev/config/external/ffi
Nathan Froyd 03e51146b9 Bug 1561088 - emit unwind information for libffi aarch64/win assembly; r=dmajor,gsvelto
The hand-written assembly for libffi on aarch64/windows doesn't emit
unwind information.  If we ever tried to unwind through these functions,
they'd look like leaf functions, which is decidedly not true and would
cause great pain.

For whatever reason, the original aarch64 libffi functions used
x21/x22/x23/x24 as their (callee-saved) scratch registers.  This
convention works on windows as well, but the unwind information on
windows mandates that we start saving callee-saved registers starting
from x19, rather than x21.  Rather than rewriting the assembly to use
x19/x20 instead of x21/x22, which would be a large change, we chose
instead to simply save/restore extra registers in the prolog/epilog.
This change does make the stack frame sizes slightly bigger, but an
extra 16 bytes in libffi stack frames should not matter.

The `-TC` change is necessary to make the compiler play nicely with .asm
file suffixes.

Differential Revision: https://phabricator.services.mozilla.com/D35714

--HG--
extra : moz-landing-system : lando
2019-06-27 13:36:48 +00:00
..
moz.build Bug 1561088 - emit unwind information for libffi aarch64/win assembly; r=dmajor,gsvelto 2019-06-27 13:36:48 +00:00
preprocess_libffi_asm.py Bug 1561088 - emit unwind information for libffi aarch64/win assembly; r=dmajor,gsvelto 2019-06-27 13:36:48 +00:00
subst_header.py bug 1463425 - Fix flake8/pep8 issue by hand in config/ r=gps 2018-05-22 06:22:46 -07:00