Commit 1ccd8493 by Tamar Christina Committed by Tamar Christina

AArch64: Make every option in options.def one line

Due to config.gcc all the options need to be on one line because of the grep
lines which would select only the first line of the option.

This causes it not to select the right bits on options that are spread over
multiple lines when the --with-arch configure option is used.  The issue happens
silently and you just get a compiler with an incorrect set of default flags.

This solution just collapses everything back to one line as they were in GCC7.
Unfortunately this does make some lines quite long.

I do have an alternate patch which used the pre-processors to first flatten the
file in config.gcc.  I will send that one out for GCC 10.

gcc/ChangeLog:

	PR target/89517
	* config/aarch64/aarch64-option-extensions.def (fp, simd, crypto, fp16,
	rdma, dotprod, sha2, sha3, sm4, fp16fml, sve): Collapse line.

From-SVN: r269309
parent f2d040ab
2019-03-01 Tamar Christina <tamar.christina@arm.com>
PR target/89517
* config/aarch64/aarch64-option-extensions.def (fp, simd, crypto, fp16,
rdma, dotprod, sha2, sha3, sm4, fp16fml, sve): Collapse line.
2019-03-01 Richard Sandiford <richard.sandiford@arm.com> 2019-03-01 Richard Sandiford <richard.sandiford@arm.com>
PR tree-optimization/89535 PR tree-optimization/89535
......
...@@ -47,29 +47,27 @@ ...@@ -47,29 +47,27 @@
that are required. Their order is not important. An empty string means that are required. Their order is not important. An empty string means
do not detect this feature during auto detection. */ do not detect this feature during auto detection. */
/* NOTE: This file is being parsed by config.gcc and so the
AARCH64_OPT_EXTENSION must adhere to a strict format:
1) No space between the AARCH64_OPT_EXTENSION and the opening (.
2) No space between the opening ( and the extension name.
3) No space after the extension name before the ,.
4) Spaces are only allowed after a , and around |.
5) Everything must be on one line. */
/* Enabling "fp" just enables "fp". /* Enabling "fp" just enables "fp".
Disabling "fp" also disables "simd", "crypto", "fp16", "aes", "sha2", Disabling "fp" also disables "simd", "crypto", "fp16", "aes", "sha2",
"sha3", sm3/sm4 and "sve". */ "sha3", sm3/sm4 and "sve". */
AARCH64_OPT_EXTENSION("fp", AARCH64_FL_FP, 0, AARCH64_FL_SIMD | AARCH64_FL_CRYPTO |\ AARCH64_OPT_EXTENSION("fp", AARCH64_FL_FP, 0, AARCH64_FL_SIMD | AARCH64_FL_CRYPTO | AARCH64_FL_F16 | AARCH64_FL_AES | AARCH64_FL_SHA2 | AARCH64_FL_SHA3 | AARCH64_FL_SM4 | AARCH64_FL_SVE, false, "fp")
AARCH64_FL_F16 | AARCH64_FL_AES | AARCH64_FL_SHA2 |\
AARCH64_FL_SHA3 | AARCH64_FL_SM4 | AARCH64_FL_SVE, \
false, "fp")
/* Enabling "simd" also enables "fp". /* Enabling "simd" also enables "fp".
Disabling "simd" also disables "crypto", "dotprod", "aes", "sha2", "sha3", Disabling "simd" also disables "crypto", "dotprod", "aes", "sha2", "sha3",
"sm3/sm4" and "sve". */ "sm3/sm4" and "sve". */
AARCH64_OPT_EXTENSION("simd", AARCH64_FL_SIMD, AARCH64_FL_FP, AARCH64_FL_CRYPTO |\ AARCH64_OPT_EXTENSION("simd", AARCH64_FL_SIMD, AARCH64_FL_FP, AARCH64_FL_CRYPTO | AARCH64_FL_DOTPROD | AARCH64_FL_AES | AARCH64_FL_SHA2 | AARCH64_FL_SHA3 | AARCH64_FL_SM4 | AARCH64_FL_SVE, false, "asimd")
AARCH64_FL_DOTPROD | AARCH64_FL_AES | AARCH64_FL_SHA2 |\
AARCH64_FL_SHA3 | AARCH64_FL_SM4 | AARCH64_FL_SVE,
false, "asimd")
/* Enabling "crypto" also enables "fp", "simd", "aes" and "sha2". /* Enabling "crypto" also enables "fp", "simd", "aes" and "sha2".
Disabling "crypto" disables "crypto", "aes", "sha2", "sha3" and "sm3/sm4". */ Disabling "crypto" disables "crypto", "aes", "sha2", "sha3" and "sm3/sm4". */
AARCH64_OPT_EXTENSION("crypto", AARCH64_FL_CRYPTO, AARCH64_OPT_EXTENSION("crypto", AARCH64_FL_CRYPTO, AARCH64_FL_FP | AARCH64_FL_SIMD | AARCH64_FL_AES | AARCH64_FL_SHA2, AARCH64_FL_AES | AARCH64_FL_SHA2 |AARCH64_FL_SHA3 | AARCH64_FL_SM4, true, "aes pmull sha1 sha2")
AARCH64_FL_FP | AARCH64_FL_SIMD | AARCH64_FL_AES |\
AARCH64_FL_SHA2,\
AARCH64_FL_AES | AARCH64_FL_SHA2 |AARCH64_FL_SHA3 | AARCH64_FL_SM4,\
true, "aes pmull sha1 sha2")
/* Enabling or disabling "crc" only changes "crc". */ /* Enabling or disabling "crc" only changes "crc". */
AARCH64_OPT_EXTENSION("crc", AARCH64_FL_CRC, 0, 0, false, "crc32") AARCH64_OPT_EXTENSION("crc", AARCH64_FL_CRC, 0, 0, false, "crc32")
...@@ -79,21 +77,18 @@ AARCH64_OPT_EXTENSION("lse", AARCH64_FL_LSE, 0, 0, false, "atomics") ...@@ -79,21 +77,18 @@ AARCH64_OPT_EXTENSION("lse", AARCH64_FL_LSE, 0, 0, false, "atomics")
/* Enabling "fp16" also enables "fp". /* Enabling "fp16" also enables "fp".
Disabling "fp16" disables "fp16", "fp16fml" and "sve". */ Disabling "fp16" disables "fp16", "fp16fml" and "sve". */
AARCH64_OPT_EXTENSION("fp16", AARCH64_FL_F16, AARCH64_FL_FP, AARCH64_OPT_EXTENSION("fp16", AARCH64_FL_F16, AARCH64_FL_FP, AARCH64_FL_F16FML | AARCH64_FL_SVE, false, "fphp asimdhp")
AARCH64_FL_F16FML | AARCH64_FL_SVE, false, "fphp asimdhp")
/* Enabling or disabling "rcpc" only changes "rcpc". */ /* Enabling or disabling "rcpc" only changes "rcpc". */
AARCH64_OPT_EXTENSION("rcpc", AARCH64_FL_RCPC, 0, 0, false, "lrcpc") AARCH64_OPT_EXTENSION("rcpc", AARCH64_FL_RCPC, 0, 0, false, "lrcpc")
/* Enabling "rdma" also enables "fp", "simd". /* Enabling "rdma" also enables "fp", "simd".
Disabling "rdma" just disables "rdma". */ Disabling "rdma" just disables "rdma". */
AARCH64_OPT_EXTENSION("rdma", AARCH64_FL_RDMA, \ AARCH64_OPT_EXTENSION("rdma", AARCH64_FL_RDMA, AARCH64_FL_FP | AARCH64_FL_SIMD, 0, false, "asimdrdm")
AARCH64_FL_FP | AARCH64_FL_SIMD, 0, false, "asimdrdm")
/* Enabling "dotprod" also enables "simd". /* Enabling "dotprod" also enables "simd".
Disabling "dotprod" only disables "dotprod". */ Disabling "dotprod" only disables "dotprod". */
AARCH64_OPT_EXTENSION("dotprod", AARCH64_FL_DOTPROD, AARCH64_FL_SIMD, 0, \ AARCH64_OPT_EXTENSION("dotprod", AARCH64_FL_DOTPROD, AARCH64_FL_SIMD, 0, false, "asimddp")
false, "asimddp")
/* Enabling "aes" also enables "simd". /* Enabling "aes" also enables "simd".
Disabling "aes" just disables "aes". */ Disabling "aes" just disables "aes". */
...@@ -101,29 +96,23 @@ AARCH64_OPT_EXTENSION("aes", AARCH64_FL_AES, AARCH64_FL_SIMD, 0, false, "aes") ...@@ -101,29 +96,23 @@ AARCH64_OPT_EXTENSION("aes", AARCH64_FL_AES, AARCH64_FL_SIMD, 0, false, "aes")
/* Enabling "sha2" also enables "simd". /* Enabling "sha2" also enables "simd".
Disabling "sha2" just disables "sha2". */ Disabling "sha2" just disables "sha2". */
AARCH64_OPT_EXTENSION("sha2", AARCH64_FL_SHA2, AARCH64_FL_SIMD, 0, false, \ AARCH64_OPT_EXTENSION("sha2", AARCH64_FL_SHA2, AARCH64_FL_SIMD, 0, false, "sha1 sha2")
"sha1 sha2")
/* Enabling "sha3" enables "simd" and "sha2". /* Enabling "sha3" enables "simd" and "sha2".
Disabling "sha3" just disables "sha3". */ Disabling "sha3" just disables "sha3". */
AARCH64_OPT_EXTENSION("sha3", AARCH64_FL_SHA3, \ AARCH64_OPT_EXTENSION("sha3", AARCH64_FL_SHA3, AARCH64_FL_SIMD | AARCH64_FL_SHA2, 0, false, "sha3 sha512")
AARCH64_FL_SIMD | AARCH64_FL_SHA2, 0, false, \
"sha3 sha512")
/* Enabling "sm4" also enables "simd". /* Enabling "sm4" also enables "simd".
Disabling "sm4" just disables "sm4". */ Disabling "sm4" just disables "sm4". */
AARCH64_OPT_EXTENSION("sm4", AARCH64_FL_SM4, AARCH64_FL_SIMD, 0, false, \ AARCH64_OPT_EXTENSION("sm4", AARCH64_FL_SM4, AARCH64_FL_SIMD, 0, false, "sm3 sm4")
"sm3 sm4")
/* Enabling "fp16fml" also enables "fp" and "fp16". /* Enabling "fp16fml" also enables "fp" and "fp16".
Disabling "fp16fml" just disables "fp16fml". */ Disabling "fp16fml" just disables "fp16fml". */
AARCH64_OPT_EXTENSION("fp16fml", AARCH64_FL_F16FML, \ AARCH64_OPT_EXTENSION("fp16fml", AARCH64_FL_F16FML, AARCH64_FL_FP | AARCH64_FL_F16, 0, false, "asimdfml")
AARCH64_FL_FP | AARCH64_FL_F16, 0, false, "asimdfml")
/* Enabling "sve" also enables "fp16", "fp" and "simd". /* Enabling "sve" also enables "fp16", "fp" and "simd".
Disabling "sve" just disables "sve". */ Disabling "sve" just disables "sve". */
AARCH64_OPT_EXTENSION("sve", AARCH64_FL_SVE, AARCH64_FL_FP | AARCH64_FL_SIMD | \ AARCH64_OPT_EXTENSION("sve", AARCH64_FL_SVE, AARCH64_FL_FP | AARCH64_FL_SIMD | AARCH64_FL_F16, 0, false, "sve")
AARCH64_FL_F16, 0, false, "sve")
/* Enabling/Disabling "profile" does not enable/disable any other feature. */ /* Enabling/Disabling "profile" does not enable/disable any other feature. */
AARCH64_OPT_EXTENSION("profile", AARCH64_FL_PROFILE, 0, 0, false, "") AARCH64_OPT_EXTENSION("profile", AARCH64_FL_PROFILE, 0, 0, false, "")
......
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