aboutsummaryrefslogtreecommitdiff
path: root/bfd/cpu-mips.c
diff options
context:
space:
mode:
authorNelson Chu <nelson.chu@sifive.com>2021-04-12 16:58:47 +0800
committerNelson Chu <nelson.chu@sifive.com>2021-04-12 17:51:07 +0800
commitf0bae2552db1dd4f1995608fbf6648fcee4e9e0c (patch)
treea0a6692a3a876f275e796099ea5291349716e1ed /bfd/cpu-mips.c
parentd5a71b1131778cf2a023855966831eb2457d50d6 (diff)
downloadbinutils-f0bae2552db1dd4f1995608fbf6648fcee4e9e0c.zip
binutils-f0bae2552db1dd4f1995608fbf6648fcee4e9e0c.tar.gz
binutils-f0bae2552db1dd4f1995608fbf6648fcee4e9e0c.tar.bz2
RISC-V: Add i-ext as the implicit extension when e-ext is set.
The linker does not care the default versions of the extensions, since it does not have the default ISA spec setting. Therefore, linker won't insert the implicit extensions for the input objects. But we used to insert the i-ext as the explicit extension, even if the e-ext is set. This causes linker to report "cannot find default versions of the ISA extension `i'" errors when linking the input objects with e-ext. This patch fixes the above linker problem, and also remove the confused riscv_ext_dont_care_version function. Unless these "dont care" extensions are set in the input architecture explicitly, otherwise we always insert them as the implicit ones. Afterwards, let riscv_arch_str1 surpress them not to output to the architecture string if their versions are RISCV_UNKNOWN_VERSION. bfd/ * elfxx-riscv.c (riscv_ext_dont_care_version): Removed. (riscv_parse_add_subset): Always add the implicit extensions, even if their versions are RISCV_UNKNOWN_VERSION. (riscv_parse_std_ext): Delay to add i-ext as the implicit extension in the riscv_parse_add_implicit_subsets. Besides, add g-ext as the implicit extension after it has been expanded. (riscv_parse_add_implicit_subsets): Updated.
Diffstat (limited to 'bfd/cpu-mips.c')
0 files changed, 0 insertions, 0 deletions