From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 74203 invoked by alias); 17 Nov 2015 22:10:48 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 74129 invoked by uid 89); 17 Nov 2015 22:10:48 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 X-HELO: mail-io0-f178.google.com Received: from mail-io0-f178.google.com (HELO mail-io0-f178.google.com) (209.85.223.178) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Tue, 17 Nov 2015 22:10:43 +0000 Received: by ioir85 with SMTP id r85so34261291ioi.1 for ; Tue, 17 Nov 2015 14:10:41 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=937NlcgmNNgr3jzVTLV0Iddxjrz28dunJ3cQn05jVFg=; b=e52D4rPEHShEIO2bQjg6clUQPqJEXleT7oQEAXLAup4eMJ25971ssYKcn7Mc+KTmzw RgCxzsZVuWFlvEKoeggyqDtbe4D8ITi266yATenopSvxwgVj+Po9Jw+hlBLg/Frze6iq jkzbKLavrt67gTsHtR92dfciSlwFG6Cxc1z93wNgb3cnb2s6c10D8XY1l/hQFAB/Wa1h zOiDke/SIkdsX3Jq85jYQTaAmD2cKrhQstdTjVa4n8wA9o2xGiHBVdRxW7GWnNN4t//E ZbH5jwwktyUnOSUKjk8qXvuhCXTUniCqlCA5Uem3jw9fLNNEKl3nEm0dDnyowSLE35Is ItZQ== X-Gm-Message-State: ALoCoQnLQg2HdmftK+8dHmpAFy9owzCEtuA2WLraqPn5N0JeWmOg1LDMnCSbSrCLexfgLdldfREG X-Received: by 10.107.3.212 with SMTP id e81mr38849780ioi.101.1447798241128; Tue, 17 Nov 2015 14:10:41 -0800 (PST) Received: from localhost.localdomain ([64.2.3.194]) by smtp.gmail.com with ESMTPSA id 75sm52761ios.35.2015.11.17.14.10.40 (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 17 Nov 2015 14:10:40 -0800 (PST) Received: from localhost.localdomain (apinskidesktop [127.0.0.1]) by localhost.localdomain (8.14.3/8.14.3/Debian-9.4) with ESMTP id tAHMAdwp029644 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES256-SHA bits=256 verify=NO); Tue, 17 Nov 2015 14:10:39 -0800 Received: (from apinski@localhost) by localhost.localdomain (8.14.3/8.14.3/Submit) id tAHMAdvQ029643; Tue, 17 Nov 2015 14:10:39 -0800 From: Andrew Pinski To: gcc-patches@gcc.gnu.org Cc: Andrew Pinski Subject: [PATCH 1/5] [AARCH64]: Move #undef into .def files. Date: Tue, 17 Nov 2015 22:11:00 -0000 Message-Id: <1447798238-29608-2-git-send-email-apinski@cavium.com> In-Reply-To: <1447798238-29608-1-git-send-email-apinski@cavium.com> References: <1447798238-29608-1-git-send-email-apinski@cavium.com> X-SW-Source: 2015-11/txt/msg02149.txt.bz2 This moves the #undef from the header files to the .def files like was done for builtins.def (https://gcc.gnu.org/ml/gcc-patches/2015-11/msg00662.html). OK? Bootstrapped and tested on aarch64-linux-gnu with no regressions. Thanks, Andrew Pinski * config/aarch64/aarch64-arches.def (AARCH64_ARCH): #undef at the end. * config/aarch64/aarch64-cores.def (AARCH64_CORE): Likewise. * config/aarch64/aarch64-fusion-pairs.def (AARCH64_FUSION_PAIR): Likewise. * config/aarch64/aarch64-tuning-flags.def (AARCH64_EXTRA_TUNING_OPTION): Likewise. * config/aarch64/aarch64-opts.h (AARCH64_CORE): Don't #undef here. (AARCH64_ARCH): Likewise. * config/aarch64/aarch64-protos.h (AARCH64_FUSION_PAIR): Likewise. (AARCH64_EXTRA_TUNING_OPTION): Likewise. * config/aarch64/aarch64.c (AARCH64_FUION_PAIR): Likewise. (AARCH64_EXTRA_TUNING_OPTION): Likewise. (AARCH64_ARCH): Likewise. (AARCH64_CORE): Likewise. (AARCH64_OPT_EXTENSION): Likewise. * config/aarch64/aarch64.h (AARCH64_CORE): Likewise. * config/aarch64/driver-aarch64.c (AARCH64_OPT_EXTENSION): Likewise. (AARCH64_CORE): Likewise. (AARCH64_ARCH): Likewise. * common/config/aarch64/aarch64-common.c: Likewise. --- gcc/common/config/aarch64/aarch64-common.c | 3 --- gcc/config/aarch64/aarch64-arches.def | 1 + gcc/config/aarch64/aarch64-cores.def | 2 ++ gcc/config/aarch64/aarch64-fusion-pairs.def | 1 + gcc/config/aarch64/aarch64-option-extensions.def | 2 ++ gcc/config/aarch64/aarch64-opts.h | 2 -- gcc/config/aarch64/aarch64-protos.h | 4 ---- gcc/config/aarch64/aarch64-tuning-flags.def | 1 + gcc/config/aarch64/aarch64.c | 5 ----- gcc/config/aarch64/aarch64.h | 1 - gcc/config/aarch64/driver-aarch64.c | 3 --- 11 files changed, 7 insertions(+), 18 deletions(-) diff --git a/gcc/common/config/aarch64/aarch64-common.c b/gcc/common/config/aarch64/aarch64-common.c index 07c6bba..e312bbc 100644 --- a/gcc/common/config/aarch64/aarch64-common.c +++ b/gcc/common/config/aarch64/aarch64-common.c @@ -121,7 +121,6 @@ static const struct aarch64_option_extension all_extensions[] = #define AARCH64_OPT_EXTENSION(NAME, FLAGS_ON, FLAGS_OFF, FEATURE_STRING) \ {NAME, FLAGS_ON, FLAGS_OFF}, #include "config/aarch64/aarch64-option-extensions.def" -#undef AARCH64_OPT_EXTENSION {NULL, 0, 0} }; @@ -145,7 +144,6 @@ static const struct processor_name_to_arch all_cores[] = #define AARCH64_CORE(NAME, X, IDENT, ARCH_IDENT, FLAGS, COSTS, IMP, PART) \ {NAME, AARCH64_ARCH_##ARCH_IDENT, FLAGS}, #include "config/aarch64/aarch64-cores.def" -#undef AARCH64_CORE {"generic", AARCH64_ARCH_8A, AARCH64_FL_FOR_ARCH8}, {"", aarch64_no_arch, 0} }; @@ -156,7 +154,6 @@ static const struct arch_to_arch_name all_architectures[] = #define AARCH64_ARCH(NAME, CORE, ARCH_IDENT, ARCH, FLAGS) \ {AARCH64_ARCH_##ARCH_IDENT, NAME}, #include "config/aarch64/aarch64-arches.def" -#undef AARCH64_ARCH {aarch64_no_arch, ""} }; diff --git a/gcc/config/aarch64/aarch64-arches.def b/gcc/config/aarch64/aarch64-arches.def index 3b4fb73..542722d 100644 --- a/gcc/config/aarch64/aarch64-arches.def +++ b/gcc/config/aarch64/aarch64-arches.def @@ -33,3 +33,4 @@ AARCH64_ARCH("armv8-a", generic, 8A, 8, AARCH64_FL_FOR_ARCH8) AARCH64_ARCH("armv8.1-a", generic, 8_1A, 8, AARCH64_FL_FOR_ARCH8_1) +#undef AARCH64_ARCH diff --git a/gcc/config/aarch64/aarch64-cores.def b/gcc/config/aarch64/aarch64-cores.def index 4af70ca..0b456f7 100644 --- a/gcc/config/aarch64/aarch64-cores.def +++ b/gcc/config/aarch64/aarch64-cores.def @@ -53,3 +53,5 @@ AARCH64_CORE("xgene1", xgene1, xgene1, 8A, AARCH64_FL_FOR_ARCH8, xge AARCH64_CORE("cortex-a57.cortex-a53", cortexa57cortexa53, cortexa53, 8A, AARCH64_FL_FOR_ARCH8 | AARCH64_FL_CRC, cortexa57, "0x41", "0xd07.0xd03") AARCH64_CORE("cortex-a72.cortex-a53", cortexa72cortexa53, cortexa53, 8A, AARCH64_FL_FOR_ARCH8 | AARCH64_FL_CRC, cortexa72, "0x41", "0xd08.0xd03") + +#undef AARCH64_CORE diff --git a/gcc/config/aarch64/aarch64-fusion-pairs.def b/gcc/config/aarch64/aarch64-fusion-pairs.def index 53bbef4..a216422 100644 --- a/gcc/config/aarch64/aarch64-fusion-pairs.def +++ b/gcc/config/aarch64/aarch64-fusion-pairs.def @@ -34,3 +34,4 @@ AARCH64_FUSION_PAIR ("movk+movk", MOVK_MOVK) AARCH64_FUSION_PAIR ("adrp+ldr", ADRP_LDR) AARCH64_FUSION_PAIR ("cmp+branch", CMP_BRANCH) +#undef AARCH64_FUSION_PAIR diff --git a/gcc/config/aarch64/aarch64-option-extensions.def b/gcc/config/aarch64/aarch64-option-extensions.def index b261a0f..ea092f5 100644 --- a/gcc/config/aarch64/aarch64-option-extensions.def +++ b/gcc/config/aarch64/aarch64-option-extensions.def @@ -42,3 +42,5 @@ AARCH64_OPT_EXTENSION("lse", AARCH64_FL_LSE, AARCH64_FL_ AARCH64_OPT_EXTENSION("pan", AARCH64_FL_PAN, AARCH64_FL_PAN, "pan") AARCH64_OPT_EXTENSION("lor", AARCH64_FL_LOR, AARCH64_FL_LOR, "lor") AARCH64_OPT_EXTENSION("rdma", AARCH64_FL_RDMA | AARCH64_FL_FPSIMD, AARCH64_FL_RDMA, "rdma") + +#undef AARCH64_OPT_EXTENSION diff --git a/gcc/config/aarch64/aarch64-opts.h b/gcc/config/aarch64/aarch64-opts.h index bf6bb7b..5534867 100644 --- a/gcc/config/aarch64/aarch64-opts.h +++ b/gcc/config/aarch64/aarch64-opts.h @@ -28,7 +28,6 @@ enum aarch64_processor #define AARCH64_CORE(NAME, INTERNAL_IDENT, SCHED, ARCH, FLAGS, COSTS, IMP, PART) \ INTERNAL_IDENT, #include "aarch64-cores.def" -#undef AARCH64_CORE /* Used to indicate that no processor has been specified. */ generic, /* Used to mark the end of the processor table. */ @@ -40,7 +39,6 @@ enum aarch64_arch #define AARCH64_ARCH(NAME, CORE, ARCH_IDENT, ARCH_REV, FLAGS) \ AARCH64_ARCH_##ARCH_IDENT, #include "aarch64-arches.def" -#undef AARCH64_ARCH aarch64_no_arch }; diff --git a/gcc/config/aarch64/aarch64-protos.h b/gcc/config/aarch64/aarch64-protos.h index 9000d67..90ed0ef 100644 --- a/gcc/config/aarch64/aarch64-protos.h +++ b/gcc/config/aarch64/aarch64-protos.h @@ -227,7 +227,6 @@ enum aarch64_fusion_pairs_index #include "aarch64-fusion-pairs.def" AARCH64_FUSE_index_END }; -#undef AARCH64_FUSION_PAIR #define AARCH64_FUSION_PAIR(x, name) \ AARCH64_FUSE_##name = (1u << AARCH64_FUSE_##name##_index), @@ -238,7 +237,6 @@ enum aarch64_fusion_pairs #include "aarch64-fusion-pairs.def" AARCH64_FUSE_ALL = (1u << AARCH64_FUSE_index_END) - 1 }; -#undef AARCH64_FUSION_PAIR #define AARCH64_EXTRA_TUNING_OPTION(x, name) \ AARCH64_EXTRA_TUNE_##name##_index, @@ -248,7 +246,6 @@ enum aarch64_extra_tuning_flags_index #include "aarch64-tuning-flags.def" AARCH64_EXTRA_TUNE_index_END }; -#undef AARCH64_EXTRA_TUNING_OPTION #define AARCH64_EXTRA_TUNING_OPTION(x, name) \ @@ -260,7 +257,6 @@ enum aarch64_extra_tuning_flags #include "aarch64-tuning-flags.def" AARCH64_EXTRA_TUNE_ALL = (1u << AARCH64_EXTRA_TUNE_index_END) - 1 }; -#undef AARCH64_EXTRA_TUNING_OPTION extern struct tune_params aarch64_tune_params; diff --git a/gcc/config/aarch64/aarch64-tuning-flags.def b/gcc/config/aarch64/aarch64-tuning-flags.def index 6f7dbce..8677c20 100644 --- a/gcc/config/aarch64/aarch64-tuning-flags.def +++ b/gcc/config/aarch64/aarch64-tuning-flags.def @@ -31,3 +31,4 @@ AARCH64_EXTRA_TUNING_OPTION ("rename_fma_regs", RENAME_FMA_REGS) AARCH64_EXTRA_TUNING_OPTION ("recip_sqrt", RECIP_SQRT) +#undef AARCH64_EXTRA_TUNING_OPTION diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c index 5ec7f08..a5971a1 100644 --- a/gcc/config/aarch64/aarch64.c +++ b/gcc/config/aarch64/aarch64.c @@ -169,7 +169,6 @@ static const struct aarch64_flag_desc aarch64_fusible_pairs[] = { "all", AARCH64_FUSE_ALL }, { NULL, AARCH64_FUSE_NOTHING } }; -#undef AARCH64_FUION_PAIR #define AARCH64_EXTRA_TUNING_OPTION(name, internal_name) \ { name, AARCH64_EXTRA_TUNE_##internal_name }, @@ -180,7 +179,6 @@ static const struct aarch64_flag_desc aarch64_tuning_flags[] = { "all", AARCH64_EXTRA_TUNE_ALL }, { NULL, AARCH64_EXTRA_TUNE_NONE } }; -#undef AARCH64_EXTRA_TUNING_OPTION /* Tuning parameters. */ @@ -522,7 +520,6 @@ static const struct processor all_architectures[] = #define AARCH64_ARCH(NAME, CORE, ARCH_IDENT, ARCH_REV, FLAGS) \ {NAME, CORE, CORE, AARCH64_ARCH_##ARCH_IDENT, ARCH_REV, FLAGS, NULL}, #include "aarch64-arches.def" -#undef AARCH64_ARCH {NULL, aarch64_none, aarch64_none, aarch64_no_arch, 0, 0, NULL} }; @@ -534,7 +531,6 @@ static const struct processor all_cores[] = all_architectures[AARCH64_ARCH_##ARCH].architecture_version, \ FLAGS, &COSTS##_tunings}, #include "aarch64-cores.def" -#undef AARCH64_CORE {"generic", generic, cortexa53, AARCH64_ARCH_8A, 8, AARCH64_FL_FOR_ARCH8, &generic_tunings}, {NULL, aarch64_none, aarch64_none, aarch64_no_arch, 0, 0, NULL} @@ -566,7 +562,6 @@ static const struct aarch64_option_extension all_extensions[] = #define AARCH64_OPT_EXTENSION(NAME, FLAGS_ON, FLAGS_OFF, FEATURE_STRING) \ {NAME, FLAGS_ON, FLAGS_OFF}, #include "aarch64-option-extensions.def" -#undef AARCH64_OPT_EXTENSION {NULL, 0, 0} }; diff --git a/gcc/config/aarch64/aarch64.h b/gcc/config/aarch64/aarch64.h index 8834c9b..c6582a4 100644 --- a/gcc/config/aarch64/aarch64.h +++ b/gcc/config/aarch64/aarch64.h @@ -467,7 +467,6 @@ enum target_cpus #define AARCH64_CORE(NAME, INTERNAL_IDENT, SCHED, ARCH, FLAGS, COSTS, IMP, PART) \ TARGET_CPU_##INTERNAL_IDENT, #include "aarch64-cores.def" -#undef AARCH64_CORE TARGET_CPU_generic }; diff --git a/gcc/config/aarch64/driver-aarch64.c b/gcc/config/aarch64/driver-aarch64.c index ae4d5a0..d03654c 100644 --- a/gcc/config/aarch64/driver-aarch64.c +++ b/gcc/config/aarch64/driver-aarch64.c @@ -32,7 +32,6 @@ static struct arch_extension ext_to_feat_string[] = { #include "aarch64-option-extensions.def" }; -#undef AARCH64_OPT_EXTENSION struct aarch64_core_data @@ -52,7 +51,6 @@ static struct aarch64_core_data cpu_data [] = { NULL, NULL, NULL, NULL } }; -#undef AARCH64_CORE struct aarch64_arch_driver_info { @@ -69,7 +67,6 @@ static struct aarch64_arch_driver_info aarch64_arches [] = {NULL, NULL} }; -#undef AARCH64_ARCH /* Return the full architecture name string corresponding to the identifier ID. */ -- 1.9.1