https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84410
--- Comment #2 from Jim Wilson <wilson at gcc dot gnu.org> --- FYI There is a libffi port at https://github.com/riscv/riscv-libffi but it is for an old ABI. There are comments in issue 1 pointing at more up to date but still not complete ports.