diff options
author | YunQiang Su <yunqiang.su@cipunited.com> | 2021-05-08 05:45:54 -0400 |
---|---|---|
committer | YunQiang Su <yunqiang.su@cipunited.com> | 2022-10-25 16:44:12 +0800 |
commit | 593632051f48a20bdc685d00d168f064d808bd7b (patch) | |
tree | 4aaffe625878597857fca7e1431aabd2a9457560 /gcc/config.gcc | |
parent | 4479f1dc79fc4f1b5e0fed209df35f405bc94589 (diff) | |
download | gcc-593632051f48a20bdc685d00d168f064d808bd7b.tar.gz |
MIPS: add builtime option for -mcompact-branches
For R6+ target, it allows to configure gcc to use compact branches only
if avaiable.
gcc/ChangeLog:
* config.gcc: add -with-compact-branches=policy build option.
* doc/install.texi: Likewise.
* config/mips/mips.h: Likewise.
Diffstat (limited to 'gcc/config.gcc')
-rw-r--r-- | gcc/config.gcc | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/gcc/config.gcc b/gcc/config.gcc index 160c52c5429..52f9e988bf6 100644 --- a/gcc/config.gcc +++ b/gcc/config.gcc @@ -4675,7 +4675,7 @@ case "${target}" in ;; mips*-*-*) - supported_defaults="abi arch arch_32 arch_64 float fpu nan fp_32 odd_spreg_32 tune tune_32 tune_64 divide llsc mips-plt synci lxc1-sxc1 madd4" + supported_defaults="abi arch arch_32 arch_64 float fpu nan fp_32 odd_spreg_32 tune tune_32 tune_64 divide llsc mips-plt synci lxc1-sxc1 madd4 compact-branches" case ${with_float} in "" | soft | hard) @@ -4828,6 +4828,15 @@ case "${target}" in exit 1 ;; esac + + case ${with_compact_branches} in + "" | never | always | optimal) + ;; + *) + echo "Unknown compact-branches policy used in --with-compact-branches" 1>&2 + exit 1 + ;; + esac ;; loongarch*-*-*) @@ -5772,7 +5781,7 @@ case ${target} in esac t= -all_defaults="abi cpu cpu_32 cpu_64 arch arch_32 arch_64 tune tune_32 tune_64 schedule float mode fpu nan fp_32 odd_spreg_32 divide llsc mips-plt synci tls lxc1-sxc1 madd4 isa_spec" +all_defaults="abi cpu cpu_32 cpu_64 arch arch_32 arch_64 tune tune_32 tune_64 schedule float mode fpu nan fp_32 odd_spreg_32 divide llsc mips-plt synci tls lxc1-sxc1 madd4 isa_spec compact-branches" for option in $all_defaults do eval "val=\$with_"`echo $option | sed s/-/_/g` |