From: Richard Earnshaw Date: Tue, 3 Aug 2004 13:27:02 +0000 (+0000) Subject: gentune.sh: New file. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=2f71a20a3eacb437535ffe41d0c45516362ecb19;p=gcc.git gentune.sh: New file. * arm/gentune.sh: New file. * arm/t-arm: New file. * arm/arm-tune.md: New file (autogenerated). * config.gcc (arm*-*-*): Add t-arm to tmake_file for all variants. * arm.md (attribute tune): Delete. Include arm-tune.md. From-SVN: r85472 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 67ecf0b7b71..1bf347c1a96 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2004-08-03 Richard Earnshaw + + * arm/gentune.sh: New file. + * arm/t-arm: New file. + * arm/arm-tune.md: New file (autogenerated). + * config.gcc (arm*-*-*): Add t-arm to tmake_file for all variants. + * arm.md (attribute tune): Delete. Include arm-tune.md. + 2004-08-03 Paolo Bonzini * gcc.c (add_prefix, add_sysrooted_prefix): Remove diff --git a/gcc/config.gcc b/gcc/config.gcc index 1899bd90aa3..3d9a8844505 100644 --- a/gcc/config.gcc +++ b/gcc/config.gcc @@ -614,65 +614,65 @@ arc-*-elf*) ;; arm-*-coff* | armel-*-coff*) tm_file="arm/semi.h arm/aout.h arm/arm.h arm/coff.h dbxcoff.h" - tmake_file=arm/t-arm-coff + tmake_file=arm/t-arm arm/t-arm-coff ;; arm-semi-aof | armel-semi-aof) tm_file="arm/semiaof.h arm/aof.h arm/arm.h" - tmake_file=arm/t-semi + tmake_file=arm/t-arm arm/t-semi ;; arm-wrs-vxworks) tm_file="dbxelf.h elfos.h svr4.h vxworks.h arm/elf.h arm/aout.h arm/arm.h arm/vxworks.h" - tmake_file="${tmake_file} arm/t-vxworks" + tmake_file="${tmake_file} arm/t-arm arm/t-vxworks" ;; arm*-*-freebsd*|strongarm*-*-freebsd*) tm_file="dbxelf.h elfos.h ${fbsd_tm_file} arm/elf.h arm/aout.h arm/freebsd.h arm/arm.h" - tmake_file="${tmake_file} arm/t-strongarm-elf" + tmake_file="${tmake_file} arm/t-arm arm/t-strongarm-elf" ;; arm*-*-netbsdelf*) tm_file="dbxelf.h elfos.h netbsd.h netbsd-elf.h arm/elf.h arm/aout.h arm/arm.h arm/netbsd-elf.h" - tmake_file="${tmake_file} arm/t-netbsd" + tmake_file="${tmake_file} arm/t-arm arm/t-netbsd" ;; arm*-*-netbsd*) tm_file="arm/aout.h arm/arm.h netbsd.h netbsd-aout.h arm/netbsd.h" - tmake_file="t-netbsd arm/t-netbsd" + tmake_file="t-netbsd arm/t-arm arm/t-netbsd" extra_parts="" use_collect2=yes ;; arm*-*-linux*) # ARM GNU/Linux with ELF tm_file="dbxelf.h elfos.h linux.h arm/elf.h arm/linux-gas.h arm/linux-elf.h arm/aout.h arm/arm.h" - tmake_file="${tmake_file} arm/t-linux" + tmake_file="${tmake_file} arm/t-arm arm/t-linux" extra_parts="crtbegin.o crtbeginS.o crtend.o crtendS.o" gnu_ld=yes ;; arm*-*-uclinux*) # ARM ucLinux tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h arm/linux-gas.h arm/linux-elf.h arm/uclinux-elf.h" - tmake_file=arm/t-arm-elf + tmake_file="arm/t-arm arm/t-arm-elf" ;; arm*-*-ecos-elf) tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h arm/ecos-elf.h" - tmake_file=arm/t-arm-elf + tmake_file=arm/t-arm arm/t-arm-elf ;; arm*-*-rtems*) tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h arm/rtems-elf.h rtems.h" - tmake_file="arm/t-arm-elf t-rtems" + tmake_file="arm/t-arm arm/t-arm-elf t-rtems" ;; arm*-*-elf | ep9312-*-elf) tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h" - tmake_file=arm/t-arm-elf + tmake_file="arm/t-arm arm/t-arm-elf" ;; arm*-wince-pe*) tm_file="arm/semi.h arm/aout.h arm/arm.h arm/coff.h dbxcoff.h arm/pe.h arm/wince-pe.h" - tmake_file=arm/t-wince-pe + tmake_file="arm/t-arm arm/t-wince-pe" extra_objs="pe.o" ;; arm-*-pe*) tm_file="arm/semi.h arm/aout.h arm/arm.h arm/coff.h dbxcoff.h arm/pe.h" - tmake_file=arm/t-pe + tmake_file="arm/t-arm arm/t-pe" extra_objs="pe.o" ;; arm*-*-kaos*) tm_file="dbxelf.h elfos.h arm/unknown-elf.h arm/elf.h arm/aout.h arm/arm.h kaos.h arm/kaos-arm.h" - tmake_file=arm/t-arm-elf + tmake_file="arm/t-arm arm/t-arm-elf" ;; avr-*-*) tm_file="avr/avr.h dbxelf.h" diff --git a/gcc/config/arm/arm-tune.md b/gcc/config/arm/arm-tune.md new file mode 100644 index 00000000000..cd235875329 --- /dev/null +++ b/gcc/config/arm/arm-tune.md @@ -0,0 +1,5 @@ +;; -*- buffer-read-only: t -*- +;; Generated automatically by gentune.sh from arm-cores.def +(define_attr "tune" + "arm2,arm250,arm3,arm6,arm60,arm600,arm610,arm620,arm7,arm7m,arm7d,arm7dm,arm7di,arm7dmi,arm70,arm700,arm700i,arm710,arm720,arm710c,arm7100,arm7500,arm7500fe,arm7tdmi,arm710t,arm720t,arm740t,arm8,arm810,arm9,arm920,arm920t,arm940t,arm9tdmi,arm9e,ep9312,strongarm,strongarm110,strongarm1100,strongarm1110,arm10tdmi,arm1020t,arm926ejs,arm1026ejs,xscale,iwmmxt,arm1136js,arm1136jfs" + (const (symbol_ref "arm_tune"))) diff --git a/gcc/config/arm/arm.md b/gcc/config/arm/arm.md index d2d078b6dd9..54a3f1e09c6 100644 --- a/gcc/config/arm/arm.md +++ b/gcc/config/arm/arm.md @@ -287,11 +287,8 @@ ;;--------------------------------------------------------------------------- ;; Pipeline descriptions -;; Processor type. This attribute must exactly match the table in -;; arm-cores.def. -(define_attr "tune" - "arm2,arm250,arm3,arm6,arm60,arm600,arm610,arm620,arm7,arm7m,arm7d,arm7dm,arm7di,arm7dmi,arm70,arm700,arm700i,arm710,arm720,arm710c,arm7100,arm7500,arm7500fe,arm7tdmi,arm710t,arm720t,arm740t,arm8,arm810,arm9,arm920,arm920t,arm940t,arm9tdmi,arm9e,ep9312,strongarm,strongarm110,strongarm1100,strongarm1110,arm10tdmi,arm1020t,arm926ejs,arm1026ejs,xscale,iwmmxt,arm1136js,arm1136jfs" - (const (symbol_ref "arm_tune"))) +;; Processor type. This is created automatically from arm-cores.def. +(include "arm-tune.md") ;; True if the generic scheduling description should be used. diff --git a/gcc/config/arm/gentune.sh b/gcc/config/arm/gentune.sh new file mode 100755 index 00000000000..74cc8533a11 --- /dev/null +++ b/gcc/config/arm/gentune.sh @@ -0,0 +1,12 @@ +#!/bin/sh +# Generate arm-tune.md, a file containing the tune attribute from the list of +# CPUs in arm-cores.def + +echo ";; -*- buffer-read-only: t -*-" +echo ";; Generated automatically by gentune.sh from arm-cores.def" + +allcores=`awk -F'[(,]' '/^ARM_CORE/ { cores = cores$2"," } END { print cores } ' $1` + +echo "(define_attr \"tune\"" +echo " \"$allcores\"" | sed -e 's/,"$/"/' +echo " (const (symbol_ref \"arm_tune\")))" diff --git a/gcc/config/arm/t-arm b/gcc/config/arm/t-arm new file mode 100644 index 00000000000..4f801ce939a --- /dev/null +++ b/gcc/config/arm/t-arm @@ -0,0 +1,20 @@ +# Rules common to all arm targets + +MD_INCLUDES= $(srcdir)/config/arm/arm-tune.md \ + $(srcdir)/config/arm/arm-generic.md \ + $(srcdir)/config/arm/arm1026ejs.md \ + $(srcdir)/config/arm/arm1136jfs.md \ + $(srcdir)/config/arm/arm926ejs.md \ + $(srcdir)/config/arm/cirrus.md \ + $(srcdir)/config/arm/fpa.md \ + $(srcdir)/config/arm/iwmmxt.md \ + $(srcdir)/config/arm/vfp.md + +s-config s-conditions s-flags s-codes s-constants s-emit s-recog \ + s-opinit s-extract s-peep s-attr s-attrtab s-output: $(MD_INCLUDES) + +$(srcdir)/config/arm/arm-tune.md: $(srcdir)/config/arm/gentune.sh \ + $(srcdir)/config/arm/arm-cores.def + $(SHELL) $(srcdir)/config/arm/gentune.sh \ + $(srcdir)/config/arm/arm-cores.def > \ + $(srcdir)/config/arm/arm-tune.md