From Dave Anglin:
authorAnthony Green <green@moxielogic.com>
Thu, 2 Feb 2023 12:04:55 +0000 (07:04 -0500)
committerAnthony Green <green@moxielogic.com>
Thu, 2 Feb 2023 12:04:55 +0000 (07:04 -0500)
commit222abd0c65babe2174b21753217145f5031a8b91
tree43c22a518137014ab9b47ff8c6e77e8d0e079d69
parente58e22b22386ed0e0a95e97eb8eed016e3f01b02
From Dave Anglin:

This patch is derived from the work done in implementing libffi for 64-bit hppa64-hpux target. Currently, the 32-bit hppa targets do a linear search for the return type of an ffi_call. This is slow and inefficient. A jump table can used to jump directly to the code used to process the return value. In most common cases, the return value can be processed in the jump table itself.

The patch also fixes return handling for FFI_TYPE_UINT8, FFI_TYPE_SINT8, FFI_TYPE_UINT16 and FFI_TYPE_SINT16.
src/pa/ffi.c
src/pa/ffitarget.h
src/pa/hpux32.S
src/pa/linux.S