src/arm


Log

Author Commit Date CI Message
Jeremy Huddleston Sequoia 032b3cd6 2020-10-27T07:06:21 Support building x86 and arm64 without FFI_GO_CLOSURES (#586) * x86: Support building without FFI_GO_CLOSURES Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * arm: Support building without FFI_GO_CLOSURES Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Niclas Zeising 8276f812 2020-08-07T21:05:23 Upstream local FreeBSD patches (#567) * Add support for FreeBSD mips Add support for FreeBSD mips, this has been a local patch in the FreeBSD ports tree for quite some time. Originally submitted by sson, and committed by sbruno AT FreeBSD DOT org See https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=191909 for background details. Signed-off-by: Niclas Zeising <zeising@daemonic.se> * Add support for FreeBSD powerpcspe Add support for powerpcspe on FreeBSD This has been in the FreeBSD ports tree for some time. Originally submitted by jhibbits AT FreeBSD DOT org. Signed-off-by: Niclas Zeising <zeising@daemonic.se> * Fix abort() on FreeBSD arm related to __clear_cache() This patch has been in the FreeBSD ports tree for a number of years. Original commit by koobs AT FreeBSD DOT org Original commit message: > devel/libffi: Fix abort() on ARM related to __clear_cache() > > The current FreeBSD/ARM __clear_cache() implementation does nothing #if > __i386__ || __x86_64__ #else abort(); > > cognet@ advises this is an issue for anything !Apple that is using the > libcompiler_rt provided by Clang on ARM, and requires upstreaming. See https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=149167 for some background details. Signed-off-by: Niclas Zeising <zeising@daemonic.se>
Martin Storsjö 053b04c5 2020-04-26T05:02:14 arm: Fix the clang specific version of the assembly (#556) Also fix the same error in the comment for the non-clang case. That typo there seems to have existed since the code was written in that form, in e7f15f60e86 - and when the clang specific codepath was added in e3d2812ce43, the typo in the comment made it into the actual code.
Paul Monson db5706ff 2019-04-26T04:58:58 add support for 32-bit ARM on Windows (#477) * add support for 32-bit ARM on Windows * fix mismatched brace in appveyor.yml * remove arm platform from appveyor.yml for now * fix arm build * fix typo * fix assembler names * try Visual Studio 2017 * add windows arm32 to .appveyor.yml * update README.md
Jeremy Huddleston Sequoia 05a17964 2019-02-19T04:11:28 Cleanup symbol exports on darwin and add architecture preprocessor checks to assist in building fat binaries (eg: i386+x86_64 on macOS or arm+aarch64 on iOS) (#450) * x86: Ensure _efi64 suffixed symbols are not exported * x86: Ensure we do not export ffi_prep_cif_machdep Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * x86: Ensure we don't export ffi_call_win64, ffi_closure_win64, or ffi_go_closure_win64 Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * closures: Silence a semantic warning libffi/src/closures.c:175:23: This function declaration is not a prototype Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * aarch64: Ensure we don't export ffi_prep_cif_machdep Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * arm: Ensure we don't export ffi_prep_cif_machdep Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * aarch64, arm, x86: Add architecture preprocessor checks to support easier fat builds (eg: iOS) Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * x86: Silence some static analysis warnings libffi/src/x86/ffi64.c:286:21: The left operand of '!=' is a garbage value due to array index out of bounds libffi/src/x86/ffi64.c:297:22: The left operand of '!=' is a garbage value due to array index out of bounds Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * aarch: Use FFI_HIDDEN rather than .hidden Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> * ffi.h: Don't advertise ffi_java_rvalue_to_raw, ffi_prep_java_raw_closure, and ffi_prep_java_raw_closure_loc when FFI_NATIVE_RAW_API is 0 Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Jeremy Huddleston Sequoia ba73a671 2018-07-20T09:37:43 Update FFI_HIDDEN() to use .private_extern on Apple platforms and use the macro where appropriate Fix issue #439 Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@macports.org>
Jeremy Huddleston Sequoia 1d704051 2018-06-17T17:01:50 i386: Fix missing break; in case statement leading to incorrectly returned FFI_BAD_ABI (#437) * i386: Add missing break triggering dead store static analyzer checks. Register calling sequence is being reported as bad ABI instead of working as intended. Found-by: Clang Static Analysis Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@macports.org> * Mark ffi arm sysv entry points as private_extern. Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@macports.org> * x86_64: Add implementation of compact unwind for ffi_call_unix64. Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Saleem Abdulrasool 3c372c38 2017-10-24T13:53:56 arm: fix a level of indirection issue Rather than relying on the stack being 0'ed out always, do it manually. The stack generally happened to be zero, and because the compiler realizes that the tests are dealing with chars truncates the read value. However, the top 3 nibbles of the value are undefined and may be non-zero. The indirection level caused a null-pointer dereference. Explicitly scribbling on the stack during the allocation causes test failures without the original zexting behaviour.
Saleem Abdulrasool 7ad0ae7f 2017-10-10T11:44:05 arm: zext return value parameters The closure function (invoked as closure->fun in ffi_closure_XXX_inner) will only populate the actual number of bytes for the true return type, which may be a character. This leaves garbage on the stack when the assembly closure function (i.e. ffi_closure_XXX) reads the return value off of the stack into r0 as a 4-byte value. ffi_closure_XXX always leaves room for at least 4 bytes here, so we can safely set them to 0. Otherwise, if there is garbage in any of these bytes, these end up in r0 and in the returned value as well.
Anthony Green 02a5145a 2017-09-27T21:43:03 Merge pull request #263 from ksjogo/master fix ios builds
Anthony Green 10099d6c 2017-09-27T20:54:09 Merge pull request #271 from frida/fix/qnx-cache-flushing arm: Fix cache flushing on QNX
Gregory Pakosz bd72848c 2017-04-27T13:20:36 Prefix ALIGN macros with FFI_
Johannes Goslar 00406945 2016-07-12T16:08:42 Update Xcodeproj Include all currently relevent files. Call autogen is build script. Fix compiler settings. Fix mach include.
s1341 ed848834 2016-08-10T14:57:22 arm: Fix cache flushing on QNX Use `msync()` directly as `__clear_cache()` is broken in the qnx650_gcc4.8.3 toolchain.
Russell Keith-Magee bc4fc07a 2015-12-21T00:37:06 Fixed #181 -- Corrected problems with ARMv7 build under iOS. Based on a patch from @fealebenpae, with input from @SolaWing and @rth7680, and testing from @superdump.
Russell Keith-Magee e3d2812c 2015-04-25T19:03:03 Modified arm/sysv.S to remove directives not allowed by clang.
Richard Henderson ab83cbb9 2014-10-29T14:38:42 arm: Add support for Go closures
Richard Henderson 6fa617da 2014-10-21T11:27:11 arm: Add argument space for the hidden struct return pointer This should have been failing all along, but it's only exposed by the complex_int test case.
Richard Henderson a529bec2 2014-10-21T11:26:59 arm: Add support for complex types
Richard Henderson 5e88ebe6 2014-10-20T15:10:43 arm: Remove internal FFI_TYPE constants These have been replaced by the contents of internal.h.
Richard Henderson a4b785ea 2014-10-17T02:07:32 arm: Rewrite ffi_closure Move the push of the argument registers into ffi_closure_SYSV, reducing the size of the trampoline.
Richard Henderson e7f15f60 2014-10-17T01:27:16 arm: Rewrite ffi_call Use the trick to allocate the stack frame for ffi_call_SYSV within ffi_call itself.
Richard Henderson a74a3aad 2014-10-17T01:21:22 arm: Rewrite vfp_type_p Do not modify the ffi_type. Rearrange the tests so that we quickly eliminate structures that cannot match. Return an encoded value of element count and base type.
Richard Henderson 0d39b4bb 2014-10-17T01:02:52 arm: Deref ffi_put_arg arguments
Richard Henderson 57b24fb3 2014-10-17T00:53:21 arm: Deref ffi_align argument
Richard Henderson c129bea8 2014-10-15T17:28:53 arm: Reindent arm/ffi.c
Matthias Klose aaf3101b 2014-09-20T06:37:04 Fix -Werror=declaration-after-statement problem
Anthony Green 001aaf4b 2014-02-28T00:20:17 When no VFP arguments are present the IP register is used uninitialized. Initialize it to the value of FP. This fixes a number of testsuite failures when configured for armv7l-unknown-linux-gnueabihf
Zachary Waldowski 994be3a5 2013-12-30T15:27:14 Darwin/iOS: Fix mis-typing of vfp_reg_free
Zachary Waldowski 6eff9ff9 2013-12-30T17:48:10 Darwin/iOS: Improve unified syntax use for LLVM
Zachary Waldowski a8e0a835 2013-12-30T15:26:20 Darwin/ARM: Assert on NULL dereference This inhibits an analyzer warning by Clang on all platforms.
Zachary Waldowski 66469c38 2014-01-09T13:41:45 Darwin/ARM: Inhibit Clang previous prototype warnings
Anthony Green 3dc3f32c 2013-12-05T16:23:25 Undo iOS ARM64 changes.
Zachary Waldowski 953b6f14 2012-04-24T11:16:20 Darwin/iOS: More unified syntax support w/ Clang. Signed-off-by: Zachary Waldowski <zwaldowski@gmail.com>
Zachary Waldowski c713a553 2012-04-24T10:25:29 Darwin/iOS: Simplify RETLDM arguments for LLVM 3.1 Signed-off-by: Zachary Waldowski <zwaldowski@gmail.com>
Zachary Waldowski 16ba1b80 2012-04-11T23:26:04 Darwin: Silence Clang warnings.
Anthony Green 2f450822 2013-11-18T06:52:29 Clean up code to appease modern GCC compiler.
David Schneider 77f823e3 2013-11-13T14:26:57 stop trying to assing vfp regs once we are done with the registers
David Schneider 37067ec5 2013-11-12T19:49:01 mark all vfp registers as used when done. To avoid assigning registers the would fit, once arguments have been on the stack, we mark all registers as used once we do not find a free register for the first time.
Anthony Green c2422174 2013-11-02T14:08:23 Merge pull request #45 from foss-for-synopsys-dwc-arc-processors/arc_support arc: Fix build error
Anthony Green 128cd1d2 2013-10-08T06:45:51 Fix spelling errors
David Schneider 9708e7cf 2013-03-27T19:31:04 folow the ARM hard-float ABI in ffi_prep_incoming_args_VFP
David Schneider b4112098 2013-03-27T16:38:35 create separated versions of ffi_prep_incoming_args_* for SYSV and VFP ABIs. The different versions will be called depending on the value of cif->abi
David Schneider 3c160861 2013-03-26T19:24:47 extend ffi_prepare_args for FFI_VFP (hard-float ABI), fixing an issue with passing VFP arguments in VFP registers and the stack, while at the same time not using all core registers.
David Schneider 0f2ff2d4 2013-03-26T19:22:02 separate ARM ffi_prepare_args in a version implementing the simple SYSV calling convention and one for the hard-float calling convention
David Schneider 3a352b8a 2013-03-26T14:24:04 move the hardfloat specific argument copying code to the helper function
David Schneider 5df6b794 2013-03-26T14:02:21 extract setting of arguments to be passed to a helper function
David Schneider 7d1048c4 2013-03-26T11:33:33 extract code to align the argument storage pointer to a helper function
Zachary Waldowski 39e6a586 2012-04-11T22:39:46 More mac/ios build improvements
Zachary Waldowski 39dccddb 2012-04-05T12:32:41 Fix building with Clang for Darwin (OS X 10.6+ and iOS 4.0+)
Anthony Green e1539266 2012-03-30T00:40:18 ARM VFP fix for old toolchains
Anthony Green 8360bf1c 2012-02-23T07:01:13 Ensure that users don't include ffitarget.h directly
Anthony Green ff9454da 2011-11-12T17:18:51 Add David Gilbert's variadic function call support
Anthony Green 322052ce 2011-11-12T16:11:49 Fix arm wince alignment issue
Anthony Green 3d56106b 2011-11-12T07:20:24 Rebase
Anthony Green d992ac54 2011-07-29T17:32:53 Refresh from GCC
Anthony Green 09f8f310 2011-02-28T15:36:07 More AIX fixes. rc9.
Landon Fuller 3000dc23 2011-02-13T08:55:53 Merge remote branch 'upstream/master'
Anthony Green 1fbf9dc4 2011-02-13T08:06:39 Fix bad_abi test. rc5.
Landon Fuller 8195e0e1 2011-02-12T11:27:00 Fix symbol prefixes on Darwin.
Landon Fuller 28a00f61 2011-02-12T11:01:48 Apple assembler support; fixed most gas/ELF-isms.
Landon Fuller 7f2ea33a 2011-02-12T10:39:18 Replace RETLDM macro. The macro is incompatible with Apple's assembler; switch to a simple inline version.
Anthony Green 0cad4386 2011-02-09T06:11:46 Add ChangeLog entry. Fix copyright headers.
Anthony Green 1106229a 2011-02-08T19:20:09 Add iOS support
Anthony Green 0e584399 2011-02-08T07:52:40 Refresh from GCC
Anthony Green 2db72615 2010-11-21T10:50:56 Rebase
Landon Fuller f6ab3edc 2010-10-27T19:34:51 Include the license header in the generated output.
Landon Fuller cef61946 2010-10-27T13:59:30 Add missing copyright/license header.
Landon Fuller 83038cf2 2010-09-19T14:36:45 Implement FFI_EXEC_TRAMPOLINE_TABLE allocator for iOS/ARM. This provides working closure support on iOS/ARM devices where PROT_WRITE|PROT_EXEC is not permitted. The code passes basic smoke tests, but requires further review.
Landon Fuller b00ff3e9 2010-09-19T14:22:26 Rename the generated symbol
Landon Fuller 9e119644 2010-09-19T10:43:06 Add a hard-coded FFI_EXEC_TRAMPOLINE_TABLE arm implementation. This implements support for re-mapping a shared table of executable trampolines directly in front of a writable configuration page, working around PROT_WRITE restrictions for sandboxed applications on Apple's iOS. This implementation is for testing purposes; a proper allocator is still necessary, and ARM-specific code needs to be moved out of src/closures.c.
Landon Fuller f38364b3 2010-09-19T10:42:36 Fix symbol prefix for ffi_closure_SYSV_inner on Darwin.
Landon Fuller 36849e77 2010-09-19T09:35:04 Whitespace/comment fixes.
Landon Fuller 9af9291b 2010-09-19T08:52:33 Add the trampoline table generated by gentramp.sh
Landon Fuller 68ce0c38 2010-09-19T08:38:19 Add a shell script that generates the ARM trampoline page. This generates a page of 340 trampolines, aligned within one page. The trampolines use pc-relative addressing to reference config data (context, jump address) from a page placed directly prior to the trampoline page. This can be used on systems -- such as iOS -- that do not support writable, executable memory by remapping the executable page containing the trampolines directly above a newly allocated writable config page.
Landon Fuller 70150bdf 2010-09-18T16:38:03 Add missing UNWIND entry; disables .pad on non-EABI targets.
Landon Fuller 6b452baf 2010-09-18T16:21:32 Apple assembler support; fixed most gas/ELF-isms.
Landon Fuller 8ddac835 2010-09-18T15:38:06 Fix placement of the __APPLE__ macro.
Landon Fuller 69043d02 2010-09-18T15:32:08 Work-around libffi's FP ABI detection. On iOS, we must use the AAPCS floating point return value calling conventions. libffi's ARM implementation will only use these conventions if __SOFTFP__ is defined, which is not the case when GCC's -mfloat-abi defaults to 'softfp' instead of 'soft'. To work around this we manually define __SOFTFP__ for Apple platforms in the ARM-specific sysv.S. See also: http://developer.apple.com/library/ios/#documentation/Xcode/Conceptual/iPhoneOSABIReference/Introduction/Introduction.html http://infocenter.arm.com/help/topic/com.arm.doc.ihi0042d/IHI0042D_aapcs.pdf
Anthony Green d14178be 2010-07-23T09:14:00 FFI_LAST_ABI fix
Anthony Green 3f5b1375 2010-07-12T14:39:18 rebase
Anthony Green 9dc9a293 2010-04-13T10:33:52 Rebase to latest GCC sources
Anthony Green 7b7a42f2 2010-01-12T09:14:14 Rebase from GCC
Anthony Green c3042afa 2010-01-01T08:08:02 Reset quilt patches post 3.0.9 merge with GCC
Anthony Green 0cfe60e9 2009-12-29T10:06:04 3.0.9rc12
Anthony Green 9458d88f 2009-12-26T07:02:27 Rebase from GCC
Anthony Green da11bece 2009-12-24T05:34:46 Release 3.0.9rc5
Anthony Green 115ab36f 2009-12-24T00:22:00 Update missing changes for 3.0.9r4.
Anthony Green c6dddbd0 2009-10-04T08:11:33 Initial commit