-march=native no longer documented in cc1 help message and the help output is buggy and inconsistent (missing on aarch64, given twice on arm) ON X86-64 --------- The cc1 help message when invalid -march= values are passed omits "native" as an option on x86-64. This is happening on at least 8.0 snapshots and 7.2 branch. /usr/local/gcc/bin/gcc -march=fdsfks -E - < /dev/null # 1 "<stdin>" cc1: error: bad value (‘fdsfks’) for ‘-march=’ switch cc1: note: valid arguments to ‘-march=’ switch are: nocona core2 nehalem corei7 westmere sandybridge corei7-avx ivybridge core-avx-i haswell core-avx2 broadwell skylake skylake-avx512 cannonlake bonnell atom silvermont slm knl knm x86-64 eden-x2 nano nano-1000 nano-2000 nano-3000 nano-x2 eden-x4 nano-x4 k8 k8-sse3 opteron opteron-sse3 athlon64 athlon64-sse3 athlon-fx amdfam10 barcelona bdver1 bdver2 bdver3 bdver4 znver1 btver1 btver2 /usr/local/gcc/bin/gcc -v Using built-in specs. COLLECT_GCC=/usr/local/gcc/bin/gcc COLLECT_LTO_WRAPPER=/usr/local/gcc-8.0.0/libexec/gcc/x86_64-unknown-linux-gnu/8.0.0/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ../gcc-8.0.0/configure --prefix=/usr/local/gcc-8.0.0 --program-suffix= --disable-werror --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --with-linker-hash-style=gnu --enable-plugin --enable-initfini-array --enable-gnu-indirect-function --with-isl --enable-languages=c,c++,fortran,lto --disable-libgcj --enable-lto --enable-multilib --with-tune=generic --with-arch_32=i686 --host=x86_64-unknown-linux-gnu --build=x86_64-unknown-linux-gnu --disable-bootstrap Thread model: posix gcc version 8.0.0 20171126 (experimental) (GCC) ON ARM ------ On arm native it was included in the list as of 7.x, now it is also missing, AND THE INFO IS DISPLAYED TWICE: /usr/local/gcc/bin/gcc -march=fdsfks -E - < /dev/null gcc: error: unrecognized -march target: fdsfks gcc: note: valid arguments are: armv2 armv2a armv3 armv3m armv4 armv4t armv5 armv5t armv5e armv5te armv5tej armv6 armv6j armv6k armv6z armv6kz armv6zk armv6t2 armv6-m armv6s-m armv7 armv7-a armv7ve armv7-r armv7-m armv7e-m armv8-a armv8.1-a armv8.2-a armv8.3-a armv8-m.base armv8-m.main armv8-r iwmmxt iwmmxt2 gcc: error: unrecognized -march target: fdsfks gcc: note: valid arguments are: armv2 armv2a armv3 armv3m armv4 armv4t armv5 armv5t armv5e armv5te armv5tej armv6 armv6j armv6k armv6z armv6kz armv6zk armv6t2 armv6-m armv6s-m armv7 armv7-a armv7ve armv7-r armv7-m armv7e-m armv8-a armv8.1-a armv8.2-a armv8.3-a armv8-m.base armv8-m.main armv8-r iwmmxt iwmmxt2 gcc: error: missing argument to ‘-march=’ /usr/local/gcc/bin/gcc -v Using built-in specs. COLLECT_GCC=/usr/local/gcc/bin/gcc COLLECT_LTO_WRAPPER=/usr/local/gcc-8.0.0/libexec/gcc/armv7l-unknown-linux-gnueabihf/8.0.0/lto-wrapper Target: armv7l-unknown-linux-gnueabihf Configured with: ../gcc-8.0.0/configure --prefix=/usr/local/gcc-8.0.0 --program-suffix= --disable-werror --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --with-linker-hash-style=gnu --enable-plugin --enable-gnu-indirect-function --enable-lto --with-isl --enable-languages=c,c++,fortran,lto --disable-libgcj --enable-clocale=gnu --disable-libstdcxx-pch --enable-install-libiberty --disable-multilib --disable-libssp --enable-default-pie --enable-default-ssp --host=armv7l-unknown-linux-gnueabihf --build=armv7l-unknown-linux-gnueabihf --with-arch=armv7-a --with-float=hard --with-fpu=vfpv3-d16 --disable-bootstrap Thread model: posix gcc version 8.0.0 20171126 (experimental) (GCC) ON AARCH64 ---------- On aarch64 no help is given: /usr/local/gcc/bin/gcc -march=fdsfks -E - < /dev/null # 1 "<stdin>" cc1: error: unknown value ‘fdsfks’ for -march /usr/local/gcc/bin/gcc -v Using built-in specs. COLLECT_GCC=/usr/local/gcc/bin/gcc COLLECT_LTO_WRAPPER=/usr/local/gcc-8.0.0/libexec/gcc/aarch64-unknown-linux-gnu/8.0.0/lto-wrapper Target: aarch64-unknown-linux-gnu Configured with: ../gcc-8.0.0/configure --prefix=/usr/local/gcc-8.0.0 --program-suffix= --disable-werror --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --with-linker-hash-style=gnu --enable-plugin --enable-gnu-indirect-function --enable-lto --with-isl --enable-languages=c,c++,fortran,lto --disable-libgcj --enable-clocale=gnu --disable-libstdcxx-pch --enable-install-libiberty --disable-multilib --enable-shared --with-arch-directory=aarch64 --enable-multiarch --disable-libssp --enable-default-pie --enable-default-ssp --host=aarch64-unknown-linux-gnu --build=aarch64-unknown-linux-gnu --with-arch=armv8-a --disable-bootstrap Thread model: posix gcc version 8.0.0 20171126 (experimental) (GCC)
The same comments also apply to the -mcpu and -mtune options as well. Double output on arm for -mcpu, and missing help for native. also: gcc -Q --help=target used to document the allowable -mcpu/-mtune options, but now only documents the allowable -mfpu/-mfpmath= options (across ARM, AARCH64 and X86-64). This was really helpful. And on aarch64 the -Q --help-target option doesn't properly display -march, -mcpu -mtune, it displays -march=ARCH, -mcpu=CPU, -mtune=CPU, rather than -march=, -mcpu=, -mtune= as other systems do. AARCH64 /usr/local/gcc/bin/gcc -Q --help=target The following options are target specific: ... -march=ARCH armv8-a ... -mcpu=CPU ... -mtune=CPU ARM /usr/local/gcc/bin/gcc -Q --help=target The following options are target specific: ... -march= armv7-a+fp ... -mcpu= ... -mtune= X86-64 /usr/local/gcc/bin/gcc -Q --help=target The following options are target specific: ... -march= x86-64 ... -mcpu= ... -mtune= generic Sorry to be so pedantic.
Let me take a look.
Confirmed, by '-march=native no longer documented in cc1 help message and the help output' you mean adding 'native' as one possible option value for -march and -mtune. Am I right?
Correct, it does not show native in the list of valid options presented to the user.
Author: marxin Date: Tue Feb 20 12:18:07 2018 New Revision: 257844 URL: https://gcc.gnu.org/viewcvs?rev=257844&root=gcc&view=rev Log: Fix missing info for -march and -mtune wrong values on aarch64 (PR driver/83193). 2018-02-20 Martin Liska <mliska@suse.cz> PR driver/83193 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print possible values if we don't have a hint. Modified: trunk/gcc/ChangeLog trunk/gcc/config/aarch64/aarch64.c
So thank you Andrew for spotting quite many issue. Let me make a summary which we can then fix: 1) x86_64 1a) missing 'native' as a possible value - I'll prepare patch for that - hope it can be accepted in GCC 8 1b) Missing list of possible values in --help=target: that's caused by fact that possible values are not an option enum and it's defined in i386.c. Can be done in GCC 9. 2) ARM 2a) missing 'native' as a possible value - I'll prepare patch for that - hope it can be accepted in GCC 8 2b) error info is displayed twice: Breakpoint 1, inform (location=0, gmsgid=0x4f3893 "valid arguments are: %s") at ../../gcc/diagnostic.c:1158 1158 va_start (ap, gmsgid); (gdb) bt #0 inform (location=0, gmsgid=0x4f3893 "valid arguments are: %s") at ../../gcc/diagnostic.c:1158 #1 0x0000000000419b9c in arm_print_hint_for_arch_option (target=0x7a75c0 "sparta", list=0x4f2780 <all_architectures+7776>) at ../../gcc/common/config/arm/arm-common.c:362 #2 0x0000000000419c90 in arm_parse_arch_option_name (list=0x4f0920 <all_architectures>, optname=0x4df5a8 "-march", target=0x7a75c0 "sparta") at ../../gcc/common/config/arm/arm-common.c:387 #3 0x00000000004198bb in arm_target_thumb_only (argc=0, argv=0x7accd8) at ../../gcc/common/config/arm/arm-common.c:282 #4 0x000000000040dd45 in eval_spec_function (func=0x7acb30 "target_mode_check", args=0x7acc90 "%{march=*:arch %*;mcpu=*:cpu %*;:}") at ../../gcc/gcc.c:6080 #5 0x000000000040dfd8 in handle_spec_function (p=0x7acc87 "", retval_nonnull=0x0) at ../../gcc/gcc.c:6157 #6 0x000000000040d5b0 in do_spec_1 (spec=0x7acc50 "%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})", inswitch=0, soft_matched_part=0x0) at ../../gcc/gcc.c:5862 #7 0x000000000040ec94 in process_brace_body (p=0x7acc41 "}", atom=0x7acc03 "mthumb:%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}", end_atom=0x7acc09 ":%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}", starred=0, matched=1) at ../../gcc/gcc.c:6525 #8 0x000000000040ea9b in handle_braces (p=0x7acc09 ":%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}") at ../../gcc/gcc.c:6432 #9 0x000000000040d586 in do_spec_1 (spec=0x7acc00 "%{!mthumb:%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}", inswitch=0, soft_matched_part=0x0) at ../../gcc/gcc.c:5856 #10 0x000000000040ec94 in process_brace_body (p=0x4daa5b "}", atom=0x4daa14 "marm:%{!mthumb:%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}}", end_atom=0x4daa18 ":%{!mthumb:%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}}", starred=0, matched=1) at ../../gcc/gcc.c:6525 #11 0x000000000040ea9b in handle_braces (p=0x4daa18 ":%{!mthumb:%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}}") at ../../gcc/gcc.c:6432 #12 0x000000000040d586 in do_spec_1 (spec=0x4daa10 " %{!marm:%{!mthumb:%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}}", inswitch=0, soft_matched_part=0x0) at ../../gcc/gcc.c:5856 #13 0x000000000040a9c5 in do_spec_2 (spec=0x4daa10 " %{!marm:%{!mthumb:%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}}") at ../../gcc/gcc.c:4894 #14 0x000000000040abc8 in do_self_spec (spec=0x4daa10 " %{!marm:%{!mthumb:%:target_mode_check(%{march=*:arch %*;mcpu=*:cpu %*;:})}}") at ../../gcc/gcc.c:4959 #15 0x0000000000411a2c in driver::set_up_specs (this=0x7fffffffdaf0) at ../../gcc/gcc.c:7533 #16 0x00000000004109a7 in driver::main (this=0x7fffffffdaf0, argc=4, argv=0x7fffffffdc08) at ../../gcc/gcc.c:7297 #17 0x0000000000418e38 in main (argc=4, argv=0x7fffffffdc08) at ../../gcc/gcc-main.c:46 and Breakpoint 1, inform (location=0, gmsgid=0x4f3893 "valid arguments are: %s") at ../../gcc/diagnostic.c:1158 1158 va_start (ap, gmsgid); (gdb) bt #0 inform (location=0, gmsgid=0x4f3893 "valid arguments are: %s") at ../../gcc/diagnostic.c:1158 #1 0x0000000000419b9c in arm_print_hint_for_arch_option (target=0x7a7600 "sparta", list=0x4f2780 <all_architectures+7776>) at ../../gcc/common/config/arm/arm-common.c:362 #2 0x0000000000419c90 in arm_parse_arch_option_name (list=0x4f0920 <all_architectures>, optname=0x4df5a8 "-march", target=0x7a7600 "sparta") at ../../gcc/common/config/arm/arm-common.c:387 #3 0x000000000041a38b in arm_canon_arch_option (argc=0, argv=0x7accd8) at ../../gcc/common/config/arm/arm-common.c:620 #4 0x000000000040dd45 in eval_spec_function (func=0x7acb30 "canon_arch", args=0x7a39c0 "%{mcpu=*: cpu %*}", ' ' <repeats 22 times>, "%{march=*: arch %*}", ' ' <repeats 22 times>, "%{mfpu=*: fpu %*}", ' ' <repeats 22 times>, "%{mfloat-abi=*: abi %*}", ' ' <repeats 21 times>, "%<march=*") at ../../gcc/gcc.c:6080 #5 0x000000000040dfd8 in handle_spec_function (p=0x4dab22 " ", retval_nonnull=0x0) at ../../gcc/gcc.c:6157 #6 0x000000000040d5b0 in do_spec_1 ( spec=0x4daa60 " -march=%:canon_arch(%{mcpu=*: cpu %*}", ' ' <repeats 22 times>, "%{march=*: arch %*}", ' ' <repeats 22 times>, "%{mfpu=*: fpu %*}", ' ' <repeats 22 times>, "%{mfloat-abi=*: abi %*}", ' ' <repeats 21 times>, "%<march=*) ", inswitch=0, soft_matched_part=0x0) at ../../gcc/gcc.c:5862 #7 0x000000000040a9c5 in do_spec_2 ( spec=0x4daa60 " -march=%:canon_arch(%{mcpu=*: cpu %*}", ' ' <repeats 22 times>, "%{march=*: arch %*}", ' ' <repeats 22 times>, "%{mfpu=*: fpu %*}", ' ' <repeats 22 times>, "%{mfloat-abi=*: abi %*}", ' ' <repeats 21 times>, "%<march=*) ") at ../../gcc/gcc.c:4894 #8 0x000000000040abc8 in do_self_spec ( spec=0x4daa60 " -march=%:canon_arch(%{mcpu=*: cpu %*}", ' ' <repeats 22 times>, "%{march=*: arch %*}", ' ' <repeats 22 times>, "%{mfpu=*: fpu %*}", ' ' <repeats 22 times>, "%{mfloat-abi=*: abi %*}", ' ' <repeats 21 times>, "%<march=*) ") at ../../gcc/gcc.c:4959 #9 0x0000000000411a2c in driver::set_up_specs (this=0x7fffffffdaf0) at ../../gcc/gcc.c:7533 #10 0x00000000004109a7 in driver::main (this=0x7fffffffdaf0, argc=4, argv=0x7fffffffdc08) at ../../gcc/gcc.c:7297 #11 0x0000000000418e38 in main (argc=4, argv=0x7fffffffdc08) at ../../gcc/gcc-main.c:46 First time it's called for thumb only, note this is regression from GCC 7. We should fix it in GCC 8. Can please any arm maintainer take a look? 2c) Missing list of possible values in --help=target: here we have the proper enum Enum(processor_type), but it's not used directly by -march and -mtune options. Thus we need to force print. I have patch for that. It's GCC 9 material. 3) aarch64 3a) missing 'native' as a possible value - I'll prepare patch for that - hope it can be accepted in GCC 8 3b) Missing list of possible values in --help=target: Similar to i386, there's not enum defined. There are constants defined in *.def file. 3c) Default values are not seen with --help=target -Q. I've got patch for that, let me send it for GCC 8. 3d) Empty hint for -march, fixed in r257844 3e) There's no hint provided for extension hint, I have patch for that. It's GCC 9 material I guess.
Created attachment 43468 [details] 2c) patch candidate
Created attachment 43469 [details] 3e) patch candidate
Created attachment 43470 [details] 3c) patch candidate
Author: marxin Date: Wed Feb 21 14:05:17 2018 New Revision: 257873 URL: https://gcc.gnu.org/viewcvs?rev=257873&root=gcc&view=rev Log: Add "native" as a valid option value for -march= on arm (PR driver/83193). 2018-02-21 Martin Liska <mliska@suse.cz> PR driver/83193 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option): Add "native" as a possible value. * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro when native cpu detection is available. Modified: trunk/gcc/ChangeLog trunk/gcc/common/config/arm/arm-common.c trunk/gcc/config/arm/arm.h
Author: marxin Date: Wed Feb 21 14:05:45 2018 New Revision: 257874 URL: https://gcc.gnu.org/viewcvs?rev=257874&root=gcc&view=rev Log: Add "native" as a valid option value for -march= on aarch64 (PR driver/83193). 2018-02-21 Martin Liska <mliska@suse.cz> PR driver/83193 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Add "native" as a possible value. * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define the macro when native cpu detection is available. Modified: trunk/gcc/ChangeLog trunk/gcc/config/aarch64/aarch64.c trunk/gcc/config/aarch64/aarch64.h
Author: marxin Date: Thu Feb 22 08:50:41 2018 New Revision: 257893 URL: https://gcc.gnu.org/viewcvs?rev=257893&root=gcc&view=rev Log: Add "native" as a valid option value for -march= on i386 (PR driver/83193). 2018-02-22 Martin Liska <mliska@suse.cz> PR driver/83193 * config/i386/i386.c (ix86_option_override_internal): Add "native" as a possible value for -march and -mtune. Modified: trunk/gcc/ChangeLog trunk/gcc/config/i386/i386.c
Author: marxin Date: Thu Feb 22 12:16:58 2018 New Revision: 257900 URL: https://gcc.gnu.org/viewcvs?rev=257900&root=gcc&view=rev Log: Add "native" as a valid option value for -mcpu/-mtune= on arm (PR driver/83193). 2018-02-22 Martin Liska <mliska@suse.cz> PR driver/83193 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option): Add "native" as a possible value. Modified: trunk/gcc/ChangeLog trunk/gcc/common/config/arm/arm-common.c
I'm testing a patch for issue 2b) from https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83193#c6 . Thanks for Andrew for the report and thanks Martin for the analysis!
Author: ktkachov Date: Fri Mar 9 15:42:10 2018 New Revision: 258389 URL: https://gcc.gnu.org/viewcvs?rev=258389&root=gcc&view=rev Log: [arm] PR target/83193: Do not print arch/cpu hints twice on invalid -march/-mcpu Currently when handling an invalid -march or -mcpu option on a toolchain without an explicit --with-mode configuration and compiling without an explicit -mthumb or -marm the arm specs end up calling arm_target_thumb_only to determine the "thumbness" of the target, which involves parsing the architecture or cpu name. But the functions doing that parsing also emit error messages and hints on invalid arguments. Later when we parse the architecture or cpu string to as part of the canonicalisation process (arm_canon_arch_option) we end up emitting the errors again. The solution in this patch is to silence the errors during the arm_target_thumb_only processing so that they are not emitted twice. arm_canon_arch_option is guaranteed to run as well, so it can emit the errors and hints that it needs. Bootstrapped and tested on arm-none-linux-gnueabihf. Checked that we emit the arch/cpu hints for invalid -march/-mcpu options only once when no "thumbness" options were specified during configuration or invocation. PR target/83193 * common/config/arm/arm-common.c (arm_parse_arch_option_name): Accept complain bool parameter. Only emit errors if it is true. (arm_parse_cpu_option_name): Likewise. (arm_target_thumb_only): Adjust callers of the above. * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust prototype to take a default true bool parameter. (arm_parse_arch_option_name): Likewise. Modified: trunk/gcc/ChangeLog trunk/gcc/common/config/arm/arm-common.c trunk/gcc/config/arm/arm-protos.h
Author: marxin Date: Mon Aug 27 08:01:14 2018 New Revision: 263870 URL: https://gcc.gnu.org/viewcvs?rev=263870&root=gcc&view=rev Log: Print default options selection for -march,-mcpu and -mtune for aarch64 (PR driver/83193). 2018-08-27 Martin Liska <mliska@suse.cz> PR driver/83193 * config/aarch64/aarch64.c (aarch64_override_options_internal): Set default values for x_aarch64_*_string strings. * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}== prefix. For -mabi do not print '=ABI' in help and use <option_value> format for -msve-vector-bits and -moverride options. Modified: trunk/gcc/ChangeLog trunk/gcc/config/aarch64/aarch64.c trunk/gcc/config/aarch64/aarch64.opt
Author: marxin Date: Mon Sep 3 08:16:27 2018 New Revision: 264052 URL: https://gcc.gnu.org/viewcvs?rev=264052&root=gcc&view=rev Log: Come up with TARGET_GET_VALID_OPTION_VALUES option hook (PR driver/83193). 2018-09-03 Martin Liska <mliska@suse.cz> PR driver/83193 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES. * common/common-targhooks.c (default_get_valid_option_values): New function. * common/common-targhooks.h (default_get_valid_option_values): Likewise. * common/config/i386/i386-common.c: Move processor_target_table from i386.c. (ix86_get_valid_option_values): New function. (TARGET_GET_VALID_OPTION_VALUES): New macro. * config/i386/i386.c (struct ptt): Move to i386-common.c. (PTA_*): Move all defined masks into i386-common.c. (ix86_function_specific_restore): Use new processor_cost_table. * config/i386/i386.h (struct ptt): Moved from i386.c. (struct pta): Likewise. * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES. * doc/tm.texi.in: Likewise. * opt-suggestions.c (option_proposer::suggest_option): Pass prefix to build_option_suggestions. (option_proposer::get_completions): Likewise. (option_proposer::build_option_suggestions): Use the new target hook. * opts.c (struct option_help_tuple): New struct. (print_filtered_help): Use the new target hook. 2018-09-03 Martin Liska <mliska@suse.cz> PR driver/83193 * gcc.dg/completion-4.c: New test. Added: trunk/gcc/testsuite/gcc.dg/completion-4.c Modified: trunk/gcc/ChangeLog trunk/gcc/common/common-target.def trunk/gcc/common/common-targhooks.c trunk/gcc/common/common-targhooks.h trunk/gcc/common/config/i386/i386-common.c trunk/gcc/config/i386/i386.c trunk/gcc/config/i386/i386.h trunk/gcc/doc/tm.texi trunk/gcc/doc/tm.texi.in trunk/gcc/opt-suggestions.c trunk/gcc/opt-suggestions.h trunk/gcc/opts.c trunk/gcc/testsuite/ChangeLog
Author: marxin Date: Wed Oct 31 14:46:17 2018 New Revision: 265686 URL: https://gcc.gnu.org/viewcvs?rev=265686&root=gcc&view=rev Log: Provide extension hint for aarch64 target (PR driver/83193). 2018-10-31 Martin Liska <mliska@suse.cz> PR driver/83193 * common/config/aarch64/aarch64-common.c (aarch64_parse_extension): Add new argument invalid_extension. (aarch64_get_all_extension_candidates): New function. (aarch64_rewrite_selected_cpu): Add NULL to function call. * config/aarch64/aarch64-protos.h (aarch64_parse_extension): Add new argument. (aarch64_get_all_extension_candidates): New function. * config/aarch64/aarch64.c (aarch64_parse_arch): Add new argument invalid_extension. (aarch64_parse_cpu): Likewise. (aarch64_print_hint_for_extensions): New function. (aarch64_validate_mcpu): Provide hint about invalid extension. (aarch64_validate_march): Likewise. (aarch64_handle_attr_arch): Pass new argument. (aarch64_handle_attr_cpu): Provide hint about invalid extension. (aarch64_handle_attr_isa_flags): Likewise. 2018-10-31 Martin Liska <mliska@suse.cz> PR driver/83193 * gcc.target/aarch64/spellcheck_7.c: New test. * gcc.target/aarch64/spellcheck_8.c: New test. * gcc.target/aarch64/spellcheck_9.c: New test. Added: trunk/gcc/testsuite/gcc.target/aarch64/spellcheck_7.c trunk/gcc/testsuite/gcc.target/aarch64/spellcheck_8.c trunk/gcc/testsuite/gcc.target/aarch64/spellcheck_9.c Modified: trunk/gcc/ChangeLog trunk/gcc/common/config/aarch64/aarch64-common.c trunk/gcc/config/aarch64/aarch64-protos.h trunk/gcc/config/aarch64/aarch64.c trunk/gcc/testsuite/ChangeLog
The only missing pieces are 2c) and 3b). Which should leverage the new target hook targetm_common.get_valid_option_values and provide list of possible values. I'm leaving that to ARM and aarch64 folks.
GCC 9.1 has been released.
GCC 9.2 has been released.
GCC 9.3.0 has been released, adjusting target milestone.
GCC 9.4 is being released, retargeting bugs to GCC 9.5.