Commit 50061652 by Richard Earnshaw Committed by Richard Earnshaw

[arm] Move some generated files out of the source tree

When I originally started work on the new options framework for ARM
I'd worked on the assumption that AWK might not be available on every
build machine (only on developer's machines).  However, looking again
I notice that all the options framework relies on it being present for
every build.  This means that some of the generated files that come
from running parsecpu.awk do not need to be kept under revision
control.

Unfortunately, it's not _all_ generated files.  The build
infrastructure assumes that all .md fragments are in the source tree
and similarly that all .opt fragments are there as well.

Still, eliminating the very big .h files is a step forward as they are
very regular in structure and diff/patch/merge tools can sometimes
make mistakes when resolving conflicts.

So this patch removes the generated .h files from the source tree and
tweaks the make rules accordingly.  I've also changed the build rules
to use the stamp technique to eliminate some false dependencies in a
rebuild.

Top-level:

* contrib/gcc_update (files_and_dependencies): Remove stamp rules for
arm-specific auto-generated header files.

gcc:
* common/config/arm/arm-common.c: Adjust include path for
arm-cpu-cdata.h
* t-arm (TM_H): Adjust path for arm-cpu.h.
(arm-cpu.h): Create in build directory.  Adjust dependency rules.
(arm-cpu-data.h): Likewise.
(arm-cpu-cdata.h): Likewise.
* config/arm/arm-cpu.h: Delete.
* config/arm/arm-cpu-cdata.h: Delete.
* config/arm/arm-cpu-data.h: Delete.

From-SVN: r249971
parent 1d79dcb8
2017-07-04 Richard Earnshaw <rearnsha@arm.com>
* contrib/gcc_update (files_and_dependencies): Remove stamp rules for
arm-specific auto-generated header files.
2017-07-03 Nathan Sidwell <nathan@acm.org>
* configure.ac: Set srcdir when sourcing config-lang.in fragments.
......
......@@ -82,9 +82,6 @@ gcc/fixinc/fixincl.x: gcc/fixinc/fixincl.tpl gcc/fixinc/inclhack.def
gcc/config/aarch64/aarch64-tune.md: gcc/config/aarch64/aarch64-cores.def gcc/config/aarch64/gentune.sh
gcc/config/arm/arm-tune.md: gcc/config/arm/arm-cpus.in gcc/config/arm/parsecpu.awk
gcc/config/arm/arm-tables.opt: gcc/config/arm/arm-cpus.in gcc/config/arm/parsecpu.awk
gcc/config/arm/arm-cpu.h: gcc/config/arm/arm-cpus.in gcc/config/arm/parsecpu.awk
gcc/config/arm/arm-cpu-data.h: gcc/config/arm/arm-cpus.in gcc/config/arm/parsecpu.awk
gcc/config/arm/arm-cpu-cdata.h: gcc/config/arm/arm-cpus.in gcc/config/arm/parsecpu.awk
gcc/config/avr/avr-tables.opt: gcc/config/avr/avr-mcus.def gcc/config/avr/genopt.sh
gcc/config/avr/t-multilib: gcc/config/avr/avr-mcus.def gcc/config/avr/genmultilib.awk
gcc/config/c6x/c6x-tables.opt: gcc/config/c6x/c6x-isas.def gcc/config/c6x/genopt.sh
......
2017-07-04 Richard Earnshaw <rearnsha@arm.com>
* common/config/arm/arm-common.c: Adjust include path for
arm-cpu-cdata.h
* config/arm/t-arm (TM_H): Adjust path for arm-cpu.h.
(arm-cpu.h): Create in build directory. Adjust dependency rules.
(arm-cpu-data.h): Likewise.
(arm-cpu-cdata.h): Likewise.
* config/arm/arm-cpu.h: Delete.
* config/arm/arm-cpu-cdata.h: Delete.
* config/arm/arm-cpu-data.h: Delete.
2017-07-04 James Greenhalgh <james.greenhalgh@arm.com>
* config/arm/arm-cpus.in (cortex-a55): New.
......
......@@ -144,7 +144,7 @@ arm_rewrite_march (int argc, const char **argv)
return arm_rewrite_selected_arch (argv[argc - 1]);
}
#include "config/arm/arm-cpu-cdata.h"
#include "arm-cpu-cdata.h"
/* Scan over a raw feature array BITS checking for BIT being present.
This is slower than the normal bitmask checks, but we would spend longer
......
/* -*- buffer-read-only: t -*-
Generated automatically by parsecpu.awk from arm-cpus.in.
Do not edit.
Copyright (C) 2011-2017 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/>. */
enum processor_type
{
TARGET_CPU_arm2,
TARGET_CPU_arm250,
TARGET_CPU_arm3,
TARGET_CPU_arm6,
TARGET_CPU_arm60,
TARGET_CPU_arm600,
TARGET_CPU_arm610,
TARGET_CPU_arm620,
TARGET_CPU_arm7,
TARGET_CPU_arm7d,
TARGET_CPU_arm7di,
TARGET_CPU_arm70,
TARGET_CPU_arm700,
TARGET_CPU_arm700i,
TARGET_CPU_arm710,
TARGET_CPU_arm720,
TARGET_CPU_arm710c,
TARGET_CPU_arm7100,
TARGET_CPU_arm7500,
TARGET_CPU_arm7500fe,
TARGET_CPU_arm7m,
TARGET_CPU_arm7dm,
TARGET_CPU_arm7dmi,
TARGET_CPU_arm8,
TARGET_CPU_arm810,
TARGET_CPU_strongarm,
TARGET_CPU_strongarm110,
TARGET_CPU_strongarm1100,
TARGET_CPU_strongarm1110,
TARGET_CPU_fa526,
TARGET_CPU_fa626,
TARGET_CPU_arm7tdmi,
TARGET_CPU_arm7tdmis,
TARGET_CPU_arm710t,
TARGET_CPU_arm720t,
TARGET_CPU_arm740t,
TARGET_CPU_arm9,
TARGET_CPU_arm9tdmi,
TARGET_CPU_arm920,
TARGET_CPU_arm920t,
TARGET_CPU_arm922t,
TARGET_CPU_arm940t,
TARGET_CPU_ep9312,
TARGET_CPU_arm10tdmi,
TARGET_CPU_arm1020t,
TARGET_CPU_arm9e,
TARGET_CPU_arm946es,
TARGET_CPU_arm966es,
TARGET_CPU_arm968es,
TARGET_CPU_arm10e,
TARGET_CPU_arm1020e,
TARGET_CPU_arm1022e,
TARGET_CPU_xscale,
TARGET_CPU_iwmmxt,
TARGET_CPU_iwmmxt2,
TARGET_CPU_fa606te,
TARGET_CPU_fa626te,
TARGET_CPU_fmp626,
TARGET_CPU_fa726te,
TARGET_CPU_arm926ejs,
TARGET_CPU_arm1026ejs,
TARGET_CPU_arm1136js,
TARGET_CPU_arm1136jfs,
TARGET_CPU_arm1176jzs,
TARGET_CPU_arm1176jzfs,
TARGET_CPU_mpcorenovfp,
TARGET_CPU_mpcore,
TARGET_CPU_arm1156t2s,
TARGET_CPU_arm1156t2fs,
TARGET_CPU_cortexm1,
TARGET_CPU_cortexm0,
TARGET_CPU_cortexm0plus,
TARGET_CPU_cortexm1smallmultiply,
TARGET_CPU_cortexm0smallmultiply,
TARGET_CPU_cortexm0plussmallmultiply,
TARGET_CPU_genericv7a,
TARGET_CPU_cortexa5,
TARGET_CPU_cortexa7,
TARGET_CPU_cortexa8,
TARGET_CPU_cortexa9,
TARGET_CPU_cortexa12,
TARGET_CPU_cortexa15,
TARGET_CPU_cortexa17,
TARGET_CPU_cortexr4,
TARGET_CPU_cortexr4f,
TARGET_CPU_cortexr5,
TARGET_CPU_cortexr7,
TARGET_CPU_cortexr8,
TARGET_CPU_cortexm7,
TARGET_CPU_cortexm4,
TARGET_CPU_cortexm3,
TARGET_CPU_marvell_pj4,
TARGET_CPU_cortexa15cortexa7,
TARGET_CPU_cortexa17cortexa7,
TARGET_CPU_cortexa32,
TARGET_CPU_cortexa35,
TARGET_CPU_cortexa53,
TARGET_CPU_cortexa57,
TARGET_CPU_cortexa72,
TARGET_CPU_cortexa73,
TARGET_CPU_exynosm1,
TARGET_CPU_xgene1,
TARGET_CPU_cortexa57cortexa53,
TARGET_CPU_cortexa72cortexa53,
TARGET_CPU_cortexa73cortexa35,
TARGET_CPU_cortexa73cortexa53,
TARGET_CPU_cortexa55,
TARGET_CPU_cortexa75,
TARGET_CPU_cortexa75cortexa55,
TARGET_CPU_cortexm23,
TARGET_CPU_cortexm33,
TARGET_CPU_arm_none
};
enum arch_type
{
TARGET_ARCH_armv2,
TARGET_ARCH_armv2a,
TARGET_ARCH_armv3,
TARGET_ARCH_armv3m,
TARGET_ARCH_armv4,
TARGET_ARCH_armv4t,
TARGET_ARCH_armv5,
TARGET_ARCH_armv5t,
TARGET_ARCH_armv5e,
TARGET_ARCH_armv5te,
TARGET_ARCH_armv5tej,
TARGET_ARCH_armv6,
TARGET_ARCH_armv6j,
TARGET_ARCH_armv6k,
TARGET_ARCH_armv6z,
TARGET_ARCH_armv6kz,
TARGET_ARCH_armv6zk,
TARGET_ARCH_armv6t2,
TARGET_ARCH_armv6_m,
TARGET_ARCH_armv6s_m,
TARGET_ARCH_armv7,
TARGET_ARCH_armv7_a,
TARGET_ARCH_armv7ve,
TARGET_ARCH_armv7_r,
TARGET_ARCH_armv7_m,
TARGET_ARCH_armv7e_m,
TARGET_ARCH_armv8_a,
TARGET_ARCH_armv8_1_a,
TARGET_ARCH_armv8_2_a,
TARGET_ARCH_armv8_m_base,
TARGET_ARCH_armv8_m_main,
TARGET_ARCH_iwmmxt,
TARGET_ARCH_iwmmxt2,
TARGET_ARCH_arm_none
};
enum fpu_type
{
TARGET_FPU_vfp,
TARGET_FPU_vfpv2,
TARGET_FPU_vfpv3,
TARGET_FPU_vfpv3_fp16,
TARGET_FPU_vfpv3_d16,
TARGET_FPU_vfpv3_d16_fp16,
TARGET_FPU_vfpv3xd,
TARGET_FPU_vfpv3xd_fp16,
TARGET_FPU_neon,
TARGET_FPU_neon_vfpv3,
TARGET_FPU_neon_fp16,
TARGET_FPU_vfpv4,
TARGET_FPU_neon_vfpv4,
TARGET_FPU_vfpv4_d16,
TARGET_FPU_fpv4_sp_d16,
TARGET_FPU_fpv5_sp_d16,
TARGET_FPU_fpv5_d16,
TARGET_FPU_fp_armv8,
TARGET_FPU_neon_fp_armv8,
TARGET_FPU_crypto_neon_fp_armv8,
TARGET_FPU_vfp3,
TARGET_FPU_auto
};
......@@ -18,7 +18,7 @@
# along with GCC; see the file COPYING3. If not see
# <http://www.gnu.org/licenses/>.
TM_H += $(srcdir)/config/arm/arm-cpu.h
TM_H += arm-cpu.h
# All md files - except for arm.md.
# This list should be kept in alphabetical order and updated whenever an md
......@@ -75,26 +75,32 @@ $(srcdir)/config/arm/arm-tune.md: $(srcdir)/config/arm/parsecpu.awk \
$(srcdir)/config/arm/arm-tables.opt: $(srcdir)/config/arm/parsecpu.awk \
$(srcdir)/config/arm/arm-cpus.in
$(AWK) -f $(srcdir)/config/arm/parsecpu.awk -v cmd=opt \
$(srcdir)/config/arm/arm-cpus.in > \
$(srcdir)/config/arm/arm-tables.opt
$(srcdir)/config/arm/arm-cpus.in > arm-tables.new
mv arm-tables.new $(srcdir)/config/arm/arm-tables.opt
$(srcdir)/config/arm/arm-cpu.h: $(srcdir)/config/arm/parsecpu.awk \
arm-cpu.h: s-arm-cpu ; @true
s-arm-cpu: $(srcdir)/config/arm/parsecpu.awk \
$(srcdir)/config/arm/arm-cpus.in
$(AWK) -f $(srcdir)/config/arm/parsecpu.awk -v cmd=headers \
$(srcdir)/config/arm/arm-cpus.in > arm-cpu.new
mv arm-cpu.new $(srcdir)/config/arm/arm-cpu.h
$(srcdir)/config/arm/arm-cpus.in > tmp-arm-cpu.h
$(SHELL) $(srcdir)/../move-if-change tmp-arm-cpu.h arm-cpu.h
$(STAMP) s-arm-cpu
$(srcdir)/config/arm/arm-cpu-data.h: $(srcdir)/config/arm/parsecpu.awk \
arm-cpu-data.h: s-arm-data ; @true
s-arm-data: $(srcdir)/config/arm/parsecpu.awk \
$(srcdir)/config/arm/arm-cpus.in
$(AWK) -f $(srcdir)/config/arm/parsecpu.awk -v cmd=data \
$(srcdir)/config/arm/arm-cpus.in > arm-cpu-data.new
mv arm-cpu-data.new $(srcdir)/config/arm/arm-cpu-data.h
$(srcdir)/config/arm/arm-cpus.in > tmp-arm-cpu-data.h
$(SHELL) $(srcdir)/../move-if-change tmp-arm-cpu-data.h arm-cpu-data.h
$(STAMP) s-arm-data
$(srcdir)/config/arm/arm-cpu-cdata.h: $(srcdir)/config/arm/parsecpu.awk \
arm-cpu-cdata.h: s-arm-cdata ; @true
s-arm-cdata: $(srcdir)/config/arm/parsecpu.awk \
$(srcdir)/config/arm/arm-cpus.in
$(AWK) -f $(srcdir)/config/arm/parsecpu.awk -v cmd=common-data \
$(srcdir)/config/arm/arm-cpus.in > arm-cpu-cdata.new
mv arm-cpu-cdata.new $(srcdir)/config/arm/arm-cpu-cdata.h
$(srcdir)/config/arm/arm-cpus.in > tmp-arm-cpu-cdata.h
$(SHELL) $(srcdir)/../move-if-change tmp-arm-cpu-cdata.h arm-cpu-cdata.h
$(STAMP) s-arm-cdata
aarch-common.o: $(srcdir)/config/arm/aarch-common.c $(CONFIG_H) $(SYSTEM_H) \
coretypes.h $(TM_H) $(TM_P_H) $(RTL_H) $(TREE_H) output.h $(C_COMMON_H)
......@@ -109,7 +115,7 @@ arm.o: $(srcdir)/config/arm/arm.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TM_H) \
$(GGC_H) except.h $(C_PRAGMA_H) $(TM_P_H) \
$(TARGET_H) $(TARGET_DEF_H) debug.h langhooks.h $(DF_H) \
intl.h libfuncs.h $(PARAMS_H) $(OPTS_H) sched-int.h \
$(srcdir)/config/arm/arm-cpu-data.h \
arm-cpu-data.h \
$(srcdir)/config/arm/arm-protos.h \
$(srcdir)/config/arm/arm_neon_builtins.def \
$(srcdir)/config/arm/arm_vfp_builtins.def
......@@ -130,4 +136,4 @@ arm-c.o: $(srcdir)/config/arm/arm-c.c $(CONFIG_H) $(SYSTEM_H) \
$(COMPILER) -c $(ALL_COMPILERFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
$(srcdir)/config/arm/arm-c.c
arm-common.o: $(srcdir)/config/arm/arm-cpu-cdata.h
arm-common.o: arm-cpu-cdata.h
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