From 5d3ad3b123b7c121d7a6eac27fb13016171e27bc Mon Sep 17 00:00:00 2001 From: Igor Venevtsev Date: Thu, 31 Mar 2016 12:12:00 +0300 Subject: Add Intel MCU target Intel MCU System V ABI are incompartible with i386 System V ABI: o Minimum instruction set is Intel Pentium ISA minus x87 instructions o No x87 or vector registers o First three args are passed in %eax, %edx and %ecx o Full specification available here: https://github.com/hjl-tools/x86-psABI/wiki/iamcu-psABI-0.7.pdf newlib/ * configure.host: Add new ix86-*-elfiamcu target newlib/libc/include/ * setjmp.h: Change _JBLEN for Intel MCU target newlib/libc/machine/i386/ * memchr.S: (memchr) Target-specific size-optimized version * memcmp.S: (memcmp) Likewise * memcpy.S: (memcpy) Likewise * memmove.S: (memmove) Likewise * memset.S: (memset) Likewise * setjmp.S: (setjmp) Likewise * strchr.S: (strchr) Likewise * strlen.S: (strlen) Likewise newlib/libc/stdlib/ * srtold.c: (__flt_rounds) Disable for Intel MCU --- newlib/configure.host | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'newlib/configure.host') diff --git a/newlib/configure.host b/newlib/configure.host index 8b0846e43..bb163ecc3 100644 --- a/newlib/configure.host +++ b/newlib/configure.host @@ -696,6 +696,15 @@ case "${host}" in i[34567]86-*-netware*) newlib_cflags="${newlib_cflags} -DMISSING_SYSCALL_NAMES -DNO_EXEC -DABORT_PROVIDED -DCLOCK_PROVIDED -DMALLOC_PROVIDED -DHAVE_FCNTL" ;; + i[3-7]86-*-elfiamcu) + newlib_cflags="${newlib_cflags} -Os -DPREFER_SIZE_OVER_SPEED -ffunction-sections -fomit-frame-pointer -DREENTRANT_SYSCALL_PROVIDED" + if [ "${newlib_multithread}" = "no" ] ; then + newlib_cflags="${newlib_cflags} -DMISSING_SYSCALL_NAMES" + else + syscall_dir=syscalls + newlib_cflags="${newlib_cflags} -D__DYNAMIC_REENT__" + fi + ;; iq2000*) syscall_dir=syscalls default_newlib_io_long_long="yes" -- cgit v1.2.3