diff options
author | Geng Qi <gengqi@linux.alibaba.com> | 2021-05-24 20:22:54 +0800 |
---|---|---|
committer | Xianmiao Qu <xianmiao_qu@c-sky.com> | 2021-05-25 14:07:20 +0800 |
commit | 62fa9cb24a8cfb197717c809c20e69161f464720 (patch) | |
tree | 32ed50a6a8c72c797576c4171df87cc4cfc0a662 | |
parent | b8a618539c26f19cb5753f0757848c0933f3ac7c (diff) | |
download | gcc-62fa9cb24a8cfb197717c809c20e69161f464720.zip gcc-62fa9cb24a8cfb197717c809c20e69161f464720.tar.gz gcc-62fa9cb24a8cfb197717c809c20e69161f464720.tar.bz2 |
C-SKY: Bug fix for bad setting of TARGET_DSP and TARGET_DIV.
gcc/ChangeLog:
* config/csky/csky.c (csky_option_override):
Init csky_arch_isa_features[] in advance, so TARGET_DSP
and TARGET_DIV can be set well.
-rw-r--r-- | gcc/config/csky/csky.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/gcc/config/csky/csky.c b/gcc/config/csky/csky.c index b2160b9..1a6cfd7 100644 --- a/gcc/config/csky/csky.c +++ b/gcc/config/csky/csky.c @@ -2680,6 +2680,18 @@ csky_option_override (void) TARGET_FDIVDU = 0; } + /* Initialize boolean versions of the architectural flags, for use + in the .md file. */ + +#undef CSKY_ISA +#define CSKY_ISA(IDENT, DESC) \ + { \ + csky_arch_isa_features[CSKY_ISA_FEATURE_GET (IDENT)] = \ + bitmap_bit_p (csky_active_target.isa, CSKY_ISA_FEATURE_GET (IDENT)); \ + } +#include "csky_isa.def" +#undef CSKY_ISA + /* Extended LRW instructions are enabled by default on CK801, disabled otherwise. */ if (TARGET_ELRW == -1) @@ -2752,18 +2764,6 @@ csky_option_override (void) TARGET_MULTIPLE_STLD = 0; } - /* Initialize boolean versions of the architectural flags, for use - in the .md file. */ - -#undef CSKY_ISA -#define CSKY_ISA(IDENT, DESC) \ - { \ - csky_arch_isa_features[CSKY_ISA_FEATURE_GET (IDENT)] = \ - bitmap_bit_p (csky_active_target.isa, CSKY_ISA_FEATURE_GET (IDENT)); \ - } -#include "csky_isa.def" -#undef CSKY_ISA - /* TODO */ /* Resynchronize the saved target options. */ |