Open
Conversation
a85e8f9 to
f91fa2f
Compare
f15c64c to
16eb8bc
Compare
Smcsrind and SscsrindSmcsrind and Sscsrind
3837b09 to
5967639
Compare
206eb3b to
17f23c1
Compare
This commit adds template for complex CSR error handling (such like multiple extensions involved). gas/ChangeLog: * config/tc-riscv.c (riscv_csr_address): Add complex CSR error handling.
This commit adds indirect CSR access extensions (Smcsrind / Sscsrind) and their CSRs based on the latest documentation (version 1.0.0-rc2). <https://github.com/riscv/riscv-indirect-csr-access/releases/tag/v1.0.0-rc2> Because six CSRs are duplicates of 'Smaia' / 'Ssaia' extensions, it adds complex CSR handling for those. bfd/ChangeLog: * elfxx-riscv.c (riscv_implicit_subsets): Add implications 'Smcsrind' / 'Sscsrind' -> 'Zicsr'. (riscv_supported_std_s_ext): Add 'Smcsrind' and 'Sscsrind' extensions to the valid 'S' extension list. gas/ChangeLog: * config/tc-riscv.c (enum riscv_csr_class): Add CSR classes for the 'S[ms]csrind' extensions. (riscv_csr_address): Add handling for new CSR classes. * testsuite/gas/riscv/csr-dw-regnums.s: Add new CSRs. * testsuite/gas/riscv/csr-dw-regnums.d: Likewise. * testsuite/gas/riscv/csr.s: Add new CSRs. * testsuite/gas/riscv/csr-version-1p9p1.d: Likewise. * testsuite/gas/riscv/csr-version-1p10.d: Likewise. * testsuite/gas/riscv/csr-version-1p11.d: Likewise. * testsuite/gas/riscv/csr-version-1p12.d: Likewise. * testsuite/gas/riscv/csr-version-1p9p1.l: Likewise but also change the expected error message to reflect 'S[ms]csrind' extensions. * testsuite/gas/riscv/csr-version-1p10.l: Ditto. * testsuite/gas/riscv/csr-version-1p11.l: Ditto. * testsuite/gas/riscv/csr-version-1p12.l: Ditto. include/ChangeLog: * opcode/riscv-opc.h: Recategory miselect, mireg, siselect, sireg, vsiselect and vsireg CSRs. (CSR_MIREG2, CSR_MIREG3, CSR_MIREG4, CSR_MIREG5, CSR_MIREG6, CSR_SIREG2, CSR_SIREG3, CSR_SIREG4, CSR_SIREG5, CSR_SIREG6, CSR_VSIREG2, CSR_VSIREG3, CSR_VSIREG3, CSR_VSIREG5, CSR_VSIREG6): Add new.
This commit tests whether the miselect CSR is unlocked by either 'Smaia' or 'Smcsrind' extension. gas/ChangeLog: * testsuite/gas/riscv/csr-complex.s: New test. * testsuite/gas/riscv/csr-complex-1.d: Likewise. * testsuite/gas/riscv/csr-complex-1.l: Likewise. * testsuite/gas/riscv/csr-complex-2.d: Likewise. * testsuite/gas/riscv/csr-complex-3.d: Likewise.
17f23c1 to
3b3d2a5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Wiki Page (details): https://github.com/a4lg/binutils-gdb/wiki/riscv_smcsrind_sscsrind