diff options
author | Nelson Chu <nelson.chu@sifive.com> | 2021-05-13 11:48:26 +0800 |
---|---|---|
committer | Nelson Chu <nelson.chu@sifive.com> | 2021-05-13 15:21:38 +0800 |
commit | 7671eff8f08de314d8c9837225eba95ed5ea053b (patch) | |
tree | 4bfdac07f53e9d347866344421f5a85c2e7d8e6e /bfd/ChangeLog | |
parent | cf893b0ef7482ec11df3787772f35e820ef2592a (diff) | |
download | gdb-7671eff8f08de314d8c9837225eba95ed5ea053b.zip gdb-7671eff8f08de314d8c9837225eba95ed5ea053b.tar.gz gdb-7671eff8f08de314d8c9837225eba95ed5ea053b.tar.bz2 |
RISC-V: Record implicit subsets in a table, to avoid repeated codes.
Add a new table, riscv_implicit_subsets, to record all implicit information.
So that we add all implicit subsets according to the table, to avoid too
many repeated codes in the riscv_parse_add_implicit_subsets. Besides, the
check_func is used to check whether we should add this implicit subset.
For example, check_implicit_for_i checks the version of i, and we only add
zicsr and zifencei implicitly only when the version less than 2.1.
bfd/
* elfxx-riscv.c (check_implicit_always): The check_func, always add
the implicit subset without checking.
(check_implicit_for_i): The check_func for i, only add zicsr and
zifencei when the version of i less than 2.1.
(struct riscv_implicit_subset): Record the subsets and their
corresponding implicit subsets.
(riscv_implicit_subsets): Table records all implicit informations.
(riscv_parse_add_implicit_subsets): Updated and add implicit subsets
according to riscv_implicit_subsets. Remove the redundant codes.
Diffstat (limited to 'bfd/ChangeLog')
-rw-r--r-- | bfd/ChangeLog | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index fcb692b..8dbe40c 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,15 @@ +2021-05-13 Nelson Chu <nelson.chu@sifive.com> + + * elfxx-riscv.c (check_implicit_always): The check_func, always add + the implicit subset without checking. + (check_implicit_for_i): The check_func for i, only add zicsr and + zifencei when the version of i less than 2.1. + (struct riscv_implicit_subset): Record the subsets and their + corresponding implicit subsets. + (riscv_implicit_subsets): Table records all implicit informations. + (riscv_parse_add_implicit_subsets): Updated and add implicit subsets + according to riscv_implicit_subsets. Remove the redundant codes. + 2021-05-13 Alan Modra <amodra@gmail.com> PR 27858 |