Commit fef939d6 by James Bowman Committed by James Bowman

FT32 target added. Approved by Jeff Law [law@redhat.com]

From-SVN: r223261
parent 9261aa43
2015-05-16 James Bowman <james.bowman@ftdichip.com>
* configure.ac: FT32 target added.
* libgcc/config.host: FT32 target added.
* gcc/config/ft32/: FT32 target added.
* libgcc/config/ft32/: FT32 target added.
* gcc/doc/install.texi, invoke.texi, md.texi: FT32 details added.
* gcc/doc/contrib.texi: self added.
* contrib/config-list.mk: FT32 target added.
* configure: Regenerated.
2015-05-16 Iain Buclaw <ibuclaw@gdcproject.org>
* MAINTAINERS (Write After Approval): Add myself.
......
......@@ -3363,6 +3363,9 @@ if test "${ENABLE_LIBSTDCXX}" = "default" ; then
avr-*-*)
noconfigdirs="$noconfigdirs target-libstdc++-v3"
;;
ft32-*-*)
noconfigdirs="$noconfigdirs target-libstdc++-v3"
;;
esac
fi
......
......@@ -710,6 +710,9 @@ if test "${ENABLE_LIBSTDCXX}" = "default" ; then
avr-*-*)
noconfigdirs="$noconfigdirs target-libstdc++-v3"
;;
ft32-*-*)
noconfigdirs="$noconfigdirs target-libstdc++-v3"
;;
esac
fi
......
......@@ -22,7 +22,7 @@ LIST = aarch64-elf aarch64-linux-gnu \
bfin-elf bfin-uclinux bfin-linux-uclibc bfin-rtems bfin-openbsd \
c6x-elf c6x-uclinux cr16-elf cris-elf cris-linux crisv32-elf crisv32-linux \
epiphany-elf epiphany-elfOPT-with-stack-offset=16 fido-elf \
fr30-elf frv-elf frv-linux h8300-elf h8300-rtems hppa-linux-gnu \
fr30-elf frv-elf frv-linux ft32-elf h8300-elf h8300-rtems hppa-linux-gnu \
hppa-linux-gnuOPT-enable-sjlj-exceptions=yes hppa64-linux-gnu \
hppa2.0-hpux10.1 hppa64-hpux11.3 \
hppa64-hpux11.0OPT-enable-sjlj-exceptions=yes hppa2.0-hpux11.9 \
......
......@@ -340,6 +340,9 @@ crisv32-*)
frv*) cpu_type=frv
extra_options="${extra_options} g.opt"
;;
ft32*) cpu_type=ft32
target_has_targetm_common=no
;;
moxie*) cpu_type=moxie
target_has_targetm_common=no
;;
......@@ -1194,6 +1197,12 @@ frv-*-*linux*)
gnu-user.h linux.h glibc-stdint.h frv/linux.h"
tmake_file="${tmake_file} frv/t-frv frv/t-linux"
;;
ft32-*-elf)
gas=yes
gnu_ld=yes
tm_file="dbxelf.h elfos.h newlib-stdint.h ${tm_file}"
tmake_file="${tmake_file} ft32/t-ft32"
;;
moxie-*-elf)
gas=yes
gnu_ld=yes
......
;; Constraint definitions for FT32
;; Copyright (C) 2015 Free Software Foundation, Inc.
;; Contributed by FTDI <support@ftdi.com>
;; This file is part of GCC.
;; GCC is free software; you can redistribute it and/or modify it
;; under the terms of the GNU General Public License as published
;; by the Free Software Foundation; either version 3, or (at your
;; option) any later version.
;; GCC is distributed in the hope that it will be useful, but WITHOUT
;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
;; or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
;; License for more details.
;; You should have received a copy of the GNU General Public License
;; along with GCC; see the file COPYING3. If not see
;; <http://www.gnu.org/licenses/>.
;; -------------------------------------------------------------------------
;; Constraints
;; -------------------------------------------------------------------------
(define_memory_constraint "A"
"An absolute address."
(and (match_code "mem")
(match_test "(!ft32_is_mem_pm(op))")
(ior (match_test "GET_CODE (XEXP (op, 0)) == SYMBOL_REF")
(match_test "GET_CODE (XEXP (op, 0)) == LABEL_REF")
(match_test "GET_CODE (XEXP (op, 0)) == CONST_INT")
(and (match_test "(GET_CODE (XEXP (op, 0)) == PLUS)")
(ior (match_test "GET_CODE (XEXP (XEXP (op, 0), 0)) == SYMBOL_REF")
(match_test "GET_CODE (XEXP (XEXP (op, 0), 0)) == LABEL_REF")
(match_test "GET_CODE (XEXP (XEXP (op, 0), 0)) == CONST_INT"))
(ior (match_test "GET_CODE (XEXP (XEXP (op, 0), 1)) == SYMBOL_REF")
(match_test "GET_CODE (XEXP (XEXP (op, 0), 1)) == LABEL_REF")
(match_test "GET_CODE (XEXP (XEXP (op, 0), 1)) == CONST_INT"))))))
(define_memory_constraint "B"
"An offset address."
(and (match_code "mem")
(match_test "(!ft32_is_mem_pm(op))")
(match_test "(GET_CODE (XEXP (op, 0)) == PLUS)")))
(define_memory_constraint "W"
"A register indirect memory operand."
(and (match_code "mem")
(match_test "!ft32_is_mem_pm(op)
&& REG_P (XEXP (op, 0))
&& REGNO_OK_FOR_BASE_P (REGNO (XEXP (op, 0)))")))
(define_memory_constraint "e"
"An offset address."
(and (match_code "mem")
(match_test "ft32_is_mem_pm(op) && (
(GET_CODE (XEXP (op, 0)) == SYMBOL_REF) ||
(GET_CODE (XEXP (op, 0)) == LABEL_REF) ||
(GET_CODE (XEXP (op, 0)) == CONST_INT) ||
(GET_CODE (XEXP (op, 0)) == CONST))"
)))
(define_memory_constraint "f"
"An offset address."
(and (match_code "mem")
(match_test "ft32_is_mem_pm(op) && (
((GET_CODE (XEXP (op, 0)) == PLUS)) ||
(GET_CODE (XEXP (op, 0)) == REG))"
)))
(define_constraint "O"
"The constant zero or one"
(and (match_code "const_int")
(match_test "((ival == 0) || (ival == 1))")))
(define_constraint "I"
"A 16-bit signed constant (-32768..32767)"
(and (match_code "const_int")
(match_test "ival >= -32768 && ival <= 32767")))
(define_constraint "w"
"A bitfield mask suitable for bext or bins"
(and (match_code "const_int")
(match_test "ft32_as_bitfield(ival) != -1")))
(define_constraint "x"
"An inverted bitfield mask suitable for bext or bins"
(and (match_code "const_int")
(match_test "ft32_as_bitfield(0xffffffff ^ ival) != -1")))
(define_constraint "L"
"A 16-bit unsigned constant, multiple of 4 (-65532..0)"
(and (match_code "const_int")
(match_test "-65532 <= ival && ival <= 0 && (ival & 3) == 0")))
(define_constraint "S"
"A 20-bit signed constant (-524288..524287)"
(ior
(and (match_code "const_int")
(match_test "ival >= -524288 && ival <= 524287"))
(match_test "GET_CODE (op) == LABEL_REF")
(match_test "GET_CODE (op) == SYMBOL_REF")
(match_test "GET_CODE (op) == CONST")))
(define_constraint "b"
"A constant for a bitfield width (1..16)"
(and (match_code "const_int")
(match_test "1 <= ival && ival <= 16")))
(define_constraint "KA"
"A 10-bit signed constant (-512..511)"
(and (match_code "const_int")
(match_test "-512 <= ival && ival <= 511")))
/* Prototypes for ft32.c functions used in the md file & elsewhere.
Copyright (C) 2015 Free Software Foundation, Inc.
This file is part of GCC.
GCC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3, or (at your option)
any later version.
GCC is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GCC; see the file COPYING3. If not see
<http://www.gnu.org/licenses/>. */
extern void ft32_expand_prologue (void);
extern void ft32_expand_epilogue (void);
extern int ft32_initial_elimination_offset (int, int);
extern void ft32_print_operand (FILE *, rtx, int);
extern void ft32_print_operand_address (FILE *, rtx);
extern const char* ft32_load_immediate(rtx, int32_t i);
extern int ft32_as_bitfield(unsigned int x);
; Options for the FT32 port of the compiler.
; Copyright (C) 2015 Free Software Foundation, Inc.
;
; This file is part of GCC.
;
; GCC is free software; you can redistribute it and/or modify it under
; the terms of the GNU General Public License as published by the Free
; Software Foundation; either version 3, or (at your option) any later
; version.
;
; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
; WARRANTY; without even the implied warranty of MERCHANTABILITY or
; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
; for more details.
;
; You should have received a copy of the GNU General Public License
; along with GCC; see the file COPYING3. If not see
; <http://www.gnu.org/licenses/>.
msim
Target Report Mask(SIM)
target the software simulator
mlra
Target Report Var(ft32_lra_flag) Init(0) Save
Use LRA instead of reload
;; Predicate definitions for FT32
;; Copyright (C) 2015 Free Software Foundation, Inc.
;; Contributed by FTDI <support@ftdi.com>
;; This file is part of GCC.
;; GCC is free software; you can redistribute it and/or modify it
;; under the terms of the GNU General Public License as published
;; by the Free Software Foundation; either version 3, or (at your
;; option) any later version.
;; GCC is distributed in the hope that it will be useful, but WITHOUT
;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
;; or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
;; License for more details.
;; You should have received a copy of the GNU General Public License
;; along with GCC; see the file COPYING3. If not see
;; <http://www.gnu.org/licenses/>.
;; -------------------------------------------------------------------------
;; Predicates
;; -------------------------------------------------------------------------
;; Nonzero if OP can be source of a simple move operation.
(define_predicate "ft32_general_movsrc_operand"
(match_code "mem,const_int,reg,subreg,symbol_ref,label_ref,const")
{
/* Any (MEM LABEL_REF) is OK. That is a pc-relative load. */
if (MEM_P (op) && GET_CODE (XEXP (op, 0)) == LABEL_REF)
return 1;
if (MEM_P (op)
&& GET_CODE (XEXP (op, 0)) == PLUS
&& GET_CODE (XEXP (XEXP (op, 0), 0)) == REG
&& GET_CODE (XEXP (XEXP (op, 0), 1)) == CONST)
return 1;
return general_operand (op, mode);
})
(define_predicate "ft32_general_movdst_operand"
(match_code "mem,const_int,reg,subreg,symbol_ref,label_ref,const")
{
if (MEM_P (op)
&& GET_CODE (XEXP (op, 0)) == PLUS
&& GET_CODE (XEXP (XEXP (op, 0), 0)) == REG
&& CONST_INT_P (XEXP (XEXP (op, 0), 1)))
return 1;
if (MEM_P (op) && GET_CODE (XEXP (op, 0)) == SYMBOL_REF)
return 1;
return REG_P(op) ||
(MEM_P(op) && REG_P(XEXP (op, 0)));
})
(define_predicate "reg_indirect"
(match_code "mem")
{
return (MEM_P(op) && REG_P(XEXP (op, 0)));
})
;; Nonzero if OP can be an operand to an add/inc/dec instruction.
(define_predicate "ft32_add_operand"
(ior (match_code "reg")
(and (match_code "const_int")
(match_test "IN_RANGE (INTVAL (op), -32768, 32767)"))))
;; Nonzero if OP can be an operand to an sub/dec instruction.
(define_predicate "ft32_sub_operand"
(ior (match_code "reg")
(and (match_code "const_int")
(match_test "IN_RANGE (INTVAL (op), -32767, 32768)"))))
(define_predicate "ft32_rimm_operand"
(ior (match_code "reg")
(and (match_code "const_int")
(match_test "IN_RANGE (INTVAL (op), -512, 511)"))))
(define_predicate "ft32_bwidth_operand"
(and (match_code "const_int")
(match_test "IN_RANGE (INTVAL (op), 1, 16)")))
# Target Makefile Fragment for ft32
# Copyright (C) 2015 Free Software Foundation, Inc.
# Contributed by FTDI <support@ftdi.com>
#
# This file is part of GCC.
#
# GCC is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published
# by the Free Software Foundation; either version 3, or (at your
# option) any later version.
#
# GCC is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
# License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GCC; see the file COPYING3. If not see
# <http://www.gnu.org/licenses/>.
......@@ -113,6 +113,9 @@ Devon Bowen helped port GCC to the Tahoe.
Don Bowman for mips-vxworks contributions.
@item
James Bowman for the FT32 port.
@item
Dave Brolley for work on cpplib and Chill.
@item
......
......@@ -3665,6 +3665,14 @@ the FreeBSD 7.0 release with GNU binutils after 2.16.1.
@html
<hr />
@end html
@anchor{ft32-x-elf}
@heading ft32-*-elf
The FT32 processor.
This configuration is intended for embedded systems.
@html
<hr />
@end html
@anchor{h8300-hms}
@heading h8300-hms
Renesas H8/300 series of processors.
......
......@@ -651,6 +651,9 @@ Objective-C and Objective-C++ Dialects}.
@emph{FR30 Options}
@gccoptlist{-msmall-model -mno-lsim}
@emph{FT32 Options}
@gccoptlist{-msim -mlra}
@emph{FRV Options}
@gccoptlist{-mgpr-32 -mgpr-64 -mfpr-32 -mfpr-64 @gol
-mhard-float -msoft-float @gol
......@@ -12278,6 +12281,7 @@ platform.
* Darwin Options::
* DEC Alpha Options::
* FR30 Options::
* FT32 Options::
* FRV Options::
* GNU/Linux Options::
* H8/300 Options::
......@@ -15111,6 +15115,29 @@ command line.
@end table
@node FT32 Options
@subsection FT32 Options
@cindex FT32 Options
These options are defined specifically for the FT32 port.
@table @gcctabopt
@item -msim
@opindex msim
Specifies that the program will be run on the simulator. This causes
an alternate runtime startup and library to be linked.
You must not use this option when generating programs that will run on
real hardware; you must provide your own runtime library for whatever
I/O functions are needed.
@item -mlra
@opindex mlra
Enable Local Register Allocation. This is still experimental for FT32,
so by default the compiler uses standard reload.
@end table
@node FRV Options
@subsection FRV Options
@cindex FRV Options
......
......@@ -2247,6 +2247,49 @@ range of 1 to 2047.
@end table
@item FT32---@file{config/ft32/constraints.md}
@table @code
@item A
An absolute address
@item B
An offset address
@item W
A register indirect memory operand
@item e
An offset address.
@item f
An offset address.
@item O
The constant zero or one
@item I
A 16-bit signed constant (@minus{}32768 @dots{} 32767)
@item w
A bitfield mask suitable for bext or bins
@item x
An inverted bitfield mask suitable for bext or bins
@item L
A 16-bit unsigned constant, multiple of 4 (0 @dots{} 65532)
@item S
A 20-bit signed constant (@minus{}524288 @dots{} 524287)
@item b
A constant for a bitfield width (1 @dots{} 16)
@item KA
A 10-bit signed constant (@minus{}512 @dots{} 511)
@end table
@item Hewlett-Packard PA-RISC---@file{config/pa/pa.h}
@table @code
@item a
......
......@@ -113,6 +113,8 @@ fido-*-*)
;;
frv*) cpu_type=frv
;;
ft32*) cpu_type=ft32
;;
moxie*) cpu_type=moxie
;;
i[34567]86-*-*)
......@@ -478,6 +480,10 @@ frv-*-*linux*)
tmake_file="$tmake_file frv/t-frv frv/t-linux t-fdpbit"
tm_file="$tm_file frv/elf-lib.h frv/frv-abi.h"
;;
ft32-*-elf)
tmake_file="ft32/t-ft32 t-softfp-sfdf t-softfp-excl t-softfp"
extra_parts="$extra_parts crti.o crti-hw.o crtn.o"
;;
h8300-*-rtems*)
tmake_file="$tmake_file h8300/t-h8300 t-fpbit"
tm_file="$tm_file h8300/h8300-lib.h"
......
.equ SYS_REGMSC0CFG_B3 , 0x1001b
.equ SYS_REGIRQCTL_B3 , 0x100e3
.global _start
_start:
# START Interrupt Vector Table [[
jmp 0x3fffc # RESET Vector
jmp _watchdog_isr # WATCHDOG Vector # TODO: Change me to reset the chip proper
jmp interrupt_0
jmp interrupt_1
jmp interrupt_2
jmp interrupt_3
jmp interrupt_4
jmp interrupt_5
jmp interrupt_6
jmp interrupt_7
jmp interrupt_8
jmp interrupt_9
jmp interrupt_10
jmp interrupt_11
jmp interrupt_12
jmp interrupt_13
jmp interrupt_14
jmp interrupt_15
jmp interrupt_16
jmp interrupt_17
jmp interrupt_18
jmp interrupt_19
jmp interrupt_20
jmp interrupt_21
jmp interrupt_22
jmp interrupt_23
jmp interrupt_24
jmp interrupt_25
jmp interrupt_26
jmp interrupt_27
jmp interrupt_28
jmp interrupt_29
jmp interrupt_30
jmp interrupt_31
jmp 0x3fff8
# ]] END Interrupt Vector Table
codestart:
jmp init
.global _exithook
_exithook: # Debugger uses '_exithook' at 0x90 to catch program exit
return
init:
# Disable all interrupts
ldk $r0,0x80
sta.b 0x100e3,$r0
# Reset all peripherals
# lda.l $r0, 0x10018
# bins.l $r0, $r0, 0x23F # Set bit 31
# sta.l 0x10018, $r0
# Initialize DATA by copying from program memory
ldk.l $r0,__data_load_start
ldk.l $r1,__data_load_end
ldk.l $r2,0 # Will use __data after binutils patch
jmp .dscopy
.dsloop:
# Copy PM[$r0] to RAM $r2
lpmi.l $r3,$r0,0
sti.l $r2,0,$r3
add.l $r0,$r0,4
add.l $r2,$r2,4
.dscopy:
cmp.l $r0,$r1
jmpc lt,.dsloop
# Zero BSS
ldk.l $r0,_bss_start
ldk.l $r2,_end
sub.l $r2,$r2,$r0
ldk.l $r1,0
memset.l $r0,$r1,$r2
sub.l $sp,$sp,24 # Space for the caller argument frame
call main
.equ EXITEXIT , 0x1fffc
.global _exit
_exit:
sta.l EXITEXIT,$r0 # simulator end of test
jmp _exithook
_watchdog_isr:
ldk.l $sp, 0x80FFFF # Reset the stack pointer so it doesn't grow to a huge size
jmp 0
# Macro to construct the interrupt stub code.
# it just saves r0, loads r0 with the int vector
# and branches to interrupt_common.
.macro inth i=0
interrupt_\i:
push $r0 # {
lda $r0,(vector_table + 4 * \i)
jmp interrupt_common
.endm
inth 0
inth 1
inth 2
inth 3
inth 4
inth 5
inth 6
inth 7
inth 8
inth 9
inth 10
inth 11
inth 12
inth 13
inth 14
inth 15
inth 16
inth 17
inth 18
inth 19
inth 20
inth 21
inth 22
inth 23
inth 24
inth 25
inth 26
inth 27
inth 28
inth 29
inth 30
inth 31
inth 32
# On entry: r0, already saved, holds the handler function
interrupt_common:
push $r1 # {
push $r2 # {
push $r3 # {
push $r4 # {
push $r5 # {
push $r6 # {
push $r7 # {
push $r8 # {
push $r9 # {
push $r10 # {
push $r11 # {
push $r12 # {
push $cc # {
calli $r0
pop $cc # }
pop $r12 # }
pop $r11 # }
pop $r10 # }
pop $r9 # }
pop $r8 # }
pop $r7 # }
pop $r6 # }
pop $r5 # }
pop $r4 # }
pop $r3 # }
pop $r2 # }
pop $r1 # }
pop $r0 # } matching push in interrupt_0-31 above
reti
# Null function for unassigned interrupt to point at
.global nullvector
nullvector:
return
.section .data
.global vector_table
vector_table:
.rept 33
.long nullvector
.endr
.section .text
.global __gxx_personality_sj0
__gxx_personality_sj0:
# crti.S for FT32
#
# Copyright (C) 2009-2013 Free Software Foundation, Inc.
#
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation; either version 3, or (at your option) any
# later version.
#
# This file is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# Under Section 7 of GPL version 3, you are granted additional
# permissions described in the GCC Runtime Library Exception, version
# 3.1, as published by the Free Software Foundation.
#
# You should have received a copy of the GNU General Public License and
# a copy of the GCC Runtime Library Exception along with this program;
# see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
# <http://www.gnu.org/licenses/>.
# This file just make a stack frame for the contents of the .fini and
# .init sections. Users may put any desired instructions in those
# sections.
.file "crti.S"
.section ".init"
.global _init
.type _init, @function
.p2align 2
_init:
.section ".fini"
.global _fini
.type _fini,@function
.p2align 2
_fini:
# crtn.S for FT32
#
# Copyright (C) 2009-2013 Free Software Foundation, Inc.
#
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation; either version 3, or (at your option) any
# later version.
#
# This file is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# Under Section 7 of GPL version 3, you are granted additional
# permissions described in the GCC Runtime Library Exception, version
# 3.1, as published by the Free Software Foundation.
#
# You should have received a copy of the GNU General Public License and
# a copy of the GCC Runtime Library Exception along with this program;
# see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
# <http://www.gnu.org/licenses/>.
# This file just makes sure that the .fini and .init sections do in
# fact return. Users may put any desired instructions in those sections.
# This file is the last thing linked into any executable.
.file "crtn.S"
.section ".init"
return
.section ".fini"
return
.macro e r=0
.global __epilog_$r\r
__epilog_$r\r:
pop $r\r
.endm
e 28
e 27
e 26
e 25
e 24
e 23
e 22
e 21
e 20
e 19
e 18
e 17
e 16
e 15
e 14
e 13
return
.global __epilog24
__epilog24:
add $sp,$sp,24
return
.macro f r=0
.global __epilog24_$r\r
__epilog24_$r\r:
add $sp,$sp,24
jmp __epilog_$r\r
.endm
f 13
f 14
f 15
f 16
f 17
f 18
f 19
f 20
f 21
f 22
f 23
f 24
f 25
f 26
f 27
f 28
.global __prolog_$r13
__prolog_$r13:
exi $r13,$sp,0
jmpi $r13
.global __prolog_$r14
__prolog_$r14:
exi $r13,$sp,0
push $r14
jmpi $r13
.global __prolog_$r15
__prolog_$r15:
exi $r13,$sp,0
push $r14
push $r15
jmpi $r13
.global __prolog_$r16
__prolog_$r16:
exi $r13,$sp,0
push $r14
push $r15
push $r16
jmpi $r13
.global __prolog_$r17
__prolog_$r17:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
jmpi $r13
.global __prolog_$r18
__prolog_$r18:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
jmpi $r13
.global __prolog_$r19
__prolog_$r19:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
jmpi $r13
.global __prolog_$r20
__prolog_$r20:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
jmpi $r13
.global __prolog_$r21
__prolog_$r21:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
push $r21
jmpi $r13
.global __prolog_$r22
__prolog_$r22:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
push $r21
push $r22
jmpi $r13
.global __prolog_$r23
__prolog_$r23:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
push $r21
push $r22
push $r23
jmpi $r13
.global __prolog_$r24
__prolog_$r24:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
push $r21
push $r22
push $r23
push $r24
jmpi $r13
.global __prolog_$r25
__prolog_$r25:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
push $r21
push $r22
push $r23
push $r24
push $r25
jmpi $r13
.global __prolog_$r26
__prolog_$r26:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
push $r21
push $r22
push $r23
push $r24
push $r25
push $r26
jmpi $r13
.global __prolog_$r27
__prolog_$r27:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
push $r21
push $r22
push $r23
push $r24
push $r25
push $r26
push $r27
jmpi $r13
.global __prolog_$r28
__prolog_$r28:
exi $r13,$sp,0
push $r14
push $r15
push $r16
push $r17
push $r18
push $r19
push $r20
push $r21
push $r22
push $r23
push $r24
push $r25
push $r26
push $r27
push $r28
jmpi $r13
#define _FP_W_TYPE_SIZE 32
#define _FP_W_TYPE unsigned long
#define _FP_WS_TYPE signed long
#define _FP_I_TYPE long
/* The type of the result of a floating point comparison. This must
match `__libgcc_cmp_return__' in GCC for the target. */
typedef int __gcc_CMPtype __attribute__ ((mode (__libgcc_cmp_return__)));
#define CMPtype __gcc_CMPtype
#define _FP_MUL_MEAT_S(R,X,Y) \
_FP_MUL_MEAT_1_wide(_FP_WFRACBITS_S,R,X,Y,umul_ppmm)
#define _FP_MUL_MEAT_D(R,X,Y) \
_FP_MUL_MEAT_2_wide(_FP_WFRACBITS_D,R,X,Y,umul_ppmm)
#define _FP_MUL_MEAT_Q(R,X,Y) \
_FP_MUL_MEAT_4_wide(_FP_WFRACBITS_Q,R,X,Y,umul_ppmm)
#define _FP_DIV_MEAT_S(R,X,Y) _FP_DIV_MEAT_1_loop(S,R,X,Y)
#define _FP_DIV_MEAT_D(R,X,Y) _FP_DIV_MEAT_2_udiv(D,R,X,Y)
#define _FP_DIV_MEAT_Q(R,X,Y) _FP_DIV_MEAT_4_udiv(Q,R,X,Y)
#define _FP_NANFRAC_S ((_FP_QNANBIT_S << 1) - 1)
#define _FP_NANFRAC_D ((_FP_QNANBIT_D << 1) - 1), -1
#define _FP_NANFRAC_Q ((_FP_QNANBIT_Q << 1) - 1), -1, -1, -1
#define _FP_NANSIGN_S 0
#define _FP_NANSIGN_D 0
#define _FP_NANSIGN_Q 0
#define _FP_KEEPNANFRACP 1
#define _FP_QNANNEGATEDP 0
/* Someone please check this. */
#define _FP_CHOOSENAN(fs, wc, R, X, Y, OP) \
do { \
if ((_FP_FRAC_HIGH_RAW_##fs(X) & _FP_QNANBIT_##fs) \
&& !(_FP_FRAC_HIGH_RAW_##fs(Y) & _FP_QNANBIT_##fs)) \
{ \
R##_s = Y##_s; \
_FP_FRAC_COPY_##wc(R,Y); \
} \
else \
{ \
R##_s = X##_s; \
_FP_FRAC_COPY_##wc(R,X); \
} \
R##_c = FP_CLS_NAN; \
} while (0)
/* Not checked. */
#define _FP_TININESS_AFTER_ROUNDING 0
#define __LITTLE_ENDIAN 1234
#define __BIG_ENDIAN 4321
# define __BYTE_ORDER __LITTLE_ENDIAN
/* Define ALIASNAME as a strong alias for NAME. */
# define strong_alias(name, aliasname) _strong_alias(name, aliasname)
# define _strong_alias(name, aliasname) \
extern __typeof (name) aliasname __attribute__ ((alias (#name)));
LIB2ADD = $(srcdir)/config/ft32/epilog.S $(srcdir)/config/ft32/prolog.S
crti-hw.o: $(srcdir)/config/ft32/crti-hw.S
$(crt_compile) -c -x assembler-with-cpp $<
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment