aboutsummaryrefslogtreecommitdiff
path: root/gcc/config/riscv
diff options
context:
space:
mode:
authorSiYu Wu <siyu@isrc.iscas.ac.cn>2021-11-22 16:19:10 +0800
committerKito Cheng <kito.cheng@sifive.com>2021-12-04 00:10:35 +0800
commit0962bff477a3d5134cb1ac23852da694529725e0 (patch)
tree9bb8e3212593ade4dbd93fddfcf9ec0df3c091ba /gcc/config/riscv
parentadd31efdc7b0aa869cb9d83f40e274e864072b25 (diff)
downloadgcc-0962bff477a3d5134cb1ac23852da694529725e0.zip
gcc-0962bff477a3d5134cb1ac23852da694529725e0.tar.gz
gcc-0962bff477a3d5134cb1ac23852da694529725e0.tar.bz2
RISC-V: Add implied defines of Zk, Zkn and Zks
gcc/ChangeLog: 2021-11-22 SiYu Wu <siyu@isrc.iscas.ac.cn> * common/config/riscv/riscv-common.c (riscv_implied_info): Add K-ext related entry. (riscv_supported_std_ext): Add 'k'. * config/riscv/arch-canonicalize (CANONICAL_ORDER): Add 'k'. (IMPLIED_EXT): Add K-ext related entry.
Diffstat (limited to 'gcc/config/riscv')
-rwxr-xr-xgcc/config/riscv/arch-canonicalize16
1 files changed, 15 insertions, 1 deletions
diff --git a/gcc/config/riscv/arch-canonicalize b/gcc/config/riscv/arch-canonicalize
index c7df3c8..90dbd19 100755
--- a/gcc/config/riscv/arch-canonicalize
+++ b/gcc/config/riscv/arch-canonicalize
@@ -28,7 +28,7 @@ import itertools
from functools import reduce
-CANONICAL_ORDER = "imafdgqlcbjtpvn"
+CANONICAL_ORDER = "imafdgqlcbjktpvn"
LONG_EXT_PREFIXES = ['z', 's', 'h', 'x']
#
@@ -36,6 +36,20 @@ LONG_EXT_PREFIXES = ['z', 's', 'h', 'x']
#
IMPLIED_EXT = {
"d" : ["f"],
+ "zk" : ["zkn"],
+ "zk" : ["zkr"],
+ "zk" : ["zkt"],
+ "zkn" : ["zbkb"],
+ "zkn" : ["zbkc"],
+ "zkn" : ["zbkx"],
+ "zkn" : ["zkne"],
+ "zkn" : ["zknd"],
+ "zkn" : ["zknh"],
+ "zks" : ["zbkb"],
+ "zks" : ["zbkc"],
+ "zks" : ["zbkx"],
+ "zks" : ["zksed"],
+ "zks" : ["zksh"],
}
def arch_canonicalize(arch):