diff options
author | Jim Wilson <jimw@sifive.com> | 2020-01-24 14:24:09 -0800 |
---|---|---|
committer | Jim Wilson <jimw@sifive.com> | 2020-01-24 14:24:09 -0800 |
commit | b5f998b2dd80e673b1506fbe5113e5e4834346bc (patch) | |
tree | c00d7a2a3df98e53dc187d17afb12379741689a7 /bfd | |
parent | 53af73bf5e9bad42a76bcc47cdf44d91bbbc4eb7 (diff) | |
download | fsf-binutils-gdb-b5f998b2dd80e673b1506fbe5113e5e4834346bc.zip fsf-binutils-gdb-b5f998b2dd80e673b1506fbe5113e5e4834346bc.tar.gz fsf-binutils-gdb-b5f998b2dd80e673b1506fbe5113e5e4834346bc.tar.bz2 |
RISC-V: Minor cleanup for s extension support.
Looking at older versions of the patch, I confirmed that the odd comment
I referred to earlier was indeed from the removal of the sx support. It
also explains an oddly formatted switch statement. This patch fixes both
minor problems.
bfd/
* elfxx-riscv.c (riscv_get_prefix_class): Format s case like others.
(riscv_parse_prefixed_ext): Fix s extension comment and reword to
avoid over long line.
Change-Id: I1cb62e4a16188270f029b6376e4b1684000d6c7a
Diffstat (limited to 'bfd')
-rw-r--r-- | bfd/ChangeLog | 6 | ||||
-rw-r--r-- | bfd/elfxx-riscv.c | 8 |
2 files changed, 9 insertions, 5 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 5d8d2cd..558e11e 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,9 @@ +2020-01-24 Jim Wilson <jimw@sifive.com> + + * elfxx-riscv.c (riscv_get_prefix_class): Format s case like others. + (riscv_parse_prefixed_ext): Fix s extension comment and reword to + avoid over long line. + 2020-01-24 Nick Clifton <nickc@redhat.com> PR 25447 diff --git a/bfd/elfxx-riscv.c b/bfd/elfxx-riscv.c index fdcf902..0a0711e 100644 --- a/bfd/elfxx-riscv.c +++ b/bfd/elfxx-riscv.c @@ -1244,9 +1244,7 @@ riscv_get_prefix_class (const char *arch) { switch (*arch) { - case 's': - return RV_ISA_CLASS_S; - + case 's': return RV_ISA_CLASS_S; case 'x': return RV_ISA_CLASS_X; case 'z': return RV_ISA_CLASS_Z; default: return RV_ISA_CLASS_UNKNOWN; @@ -1324,8 +1322,8 @@ riscv_parse_prefixed_ext (riscv_parse_subset_t *rps, /* Check that the name is valid. For 'x', anything goes but it cannot simply be 'x'. - For 'z', it must be known from a list and also cannot simply be 'z'. - For 's', it must be known from a list and also *can* simply be 's'. */ + For 's', it must be known from a list and cannot simply be 's'. + For 'z', it must be known from a list and cannot simply be 'z'. */ /* Check that the extension name is well-formed. */ if (!config->ext_valid_p (subset)) |