diff options
author | Jim Wilson <jimw@sifive.com> | 2018-01-04 14:17:53 -0800 |
---|---|---|
committer | Jim Wilson <jimw@sifive.com> | 2018-01-04 14:17:53 -0800 |
commit | 645a2c5b46e18013ac9cb16b66ba7b6b97cd01c5 (patch) | |
tree | 5c9e503894feb151373cf23d3a52693577fb6f26 /gas | |
parent | 7365ec2ff4a7028503f39655bd2628d54418106c (diff) | |
download | fsf-binutils-gdb-645a2c5b46e18013ac9cb16b66ba7b6b97cd01c5.zip fsf-binutils-gdb-645a2c5b46e18013ac9cb16b66ba7b6b97cd01c5.tar.gz fsf-binutils-gdb-645a2c5b46e18013ac9cb16b66ba7b6b97cd01c5.tar.bz2 |
RISC-V: Add 2 missing privileged registers.
gas/
* testsuite/gas/riscv/priv-reg.s: Add missing stval and mtval.
* testsuite/gas/riscv/priv-reg.d: Likewise.
include/
* opcode/riscv-opc.h (CSR_SBADADDR): Rename to CSR_STVAL. Rename
DECLARE_CSR entry. Add alias to map sbadaddr to CSR_STVAL.
(CSR_MBADADDR): Rename to CSR_MTVAL. Rename DECLARE_CSR entry.
Add alias to map mbadaddr to CSR_MTVAL.
Diffstat (limited to 'gas')
-rw-r--r-- | gas/ChangeLog | 5 | ||||
-rw-r--r-- | gas/testsuite/gas/riscv/priv-reg.d | 50 | ||||
-rw-r--r-- | gas/testsuite/gas/riscv/priv-reg.s | 2 |
3 files changed, 33 insertions, 24 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index cf0ac65..85ced2f 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,8 @@ +2018-01-04 Jim Wilson <jimw@sifive.com> + + * testsuite/gas/riscv/priv-reg.s: Add missing stval and mtval. + * testsuite/gas/riscv/priv-reg.d: Likewise. + 2018-01-03 Alan Modra <amodra@gmail.com> Update year range in copyright notice of all files. diff --git a/gas/testsuite/gas/riscv/priv-reg.d b/gas/testsuite/gas/riscv/priv-reg.d index 2a650df..9ec5d97 100644 --- a/gas/testsuite/gas/riscv/priv-reg.d +++ b/gas/testsuite/gas/riscv/priv-reg.d @@ -90,7 +90,7 @@ Disassembly of section .text: [ ]+140:[ ]+14002573[ ]+csrr[ ]+a0,sscratch [ ]+144:[ ]+14102573[ ]+csrr[ ]+a0,sepc [ ]+148:[ ]+14202573[ ]+csrr[ ]+a0,scause -[ ]+14c:[ ]+14302573[ ]+csrr[ ]+a0,sbadaddr +[ ]+14c:[ ]+14302573[ ]+csrr[ ]+a0,stval [ ]+150:[ ]+14402573[ ]+csrr[ ]+a0,sip [ ]+154:[ ]+18002573[ ]+csrr[ ]+a0,satp [ ]+158:[ ]+20002573[ ]+csrr[ ]+a0,hstatus @@ -116,7 +116,7 @@ Disassembly of section .text: [ ]+1a8:[ ]+34002573[ ]+csrr[ ]+a0,mscratch [ ]+1ac:[ ]+34102573[ ]+csrr[ ]+a0,mepc [ ]+1b0:[ ]+34202573[ ]+csrr[ ]+a0,mcause -[ ]+1b4:[ ]+34302573[ ]+csrr[ ]+a0,mbadaddr +[ ]+1b4:[ ]+34302573[ ]+csrr[ ]+a0,mtval [ ]+1b8:[ ]+34402573[ ]+csrr[ ]+a0,mip [ ]+1bc:[ ]+38002573[ ]+csrr[ ]+a0,mbase [ ]+1c0:[ ]+38102573[ ]+csrr[ ]+a0,mbound @@ -227,25 +227,27 @@ Disassembly of section .text: [ ]+364:[ ]+7b202573[ ]+csrr[ ]+a0,dscratch [ ]+368:[ ]+04302573[ ]+csrr[ ]+a0,utval [ ]+36c:[ ]+10602573[ ]+csrr[ ]+a0,scounteren -[ ]+370:[ ]+18002573[ ]+csrr[ ]+a0,satp -[ ]+374:[ ]+30602573[ ]+csrr[ ]+a0,mcounteren -[ ]+378:[ ]+3a002573[ ]+csrr[ ]+a0,pmpcfg0 -[ ]+37c:[ ]+3a102573[ ]+csrr[ ]+a0,pmpcfg1 -[ ]+380:[ ]+3a202573[ ]+csrr[ ]+a0,pmpcfg2 -[ ]+384:[ ]+3a302573[ ]+csrr[ ]+a0,pmpcfg3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mpaddr0 +[ ]+394:[ ]+3b102573[ ]+csrr[ ]+a0,pmpaddr1 +[ ]+398:[ ]+3b202573[ ]+csrr[ ]+a0,pmpaddr2 +[ ]+39c:[ ]+3b302573[ ]+csrr[ ]+a0,pmpaddr3 +[ ]+3a0:[ ]+3b402573[ ]+csrr[ ]+a0,pmpaddr4 +[ ]+3a4:[ ]+3b502573[ ]+csrr[ ]+a0,pmpaddr5 +[ ]+3a8:[ ]+3b602573[ ]+csrr[ ]+a0,pmpaddr6 +[ ]+3ac:[ ]+3b702573[ ]+csrr[ ]+a0,pmpaddr7 +[ ]+3b0:[ ]+3b802573[ ]+csrr[ ]+a0,pmpaddr8 +[ ]+3b4:[ ]+3b902573[ ]+csrr[ ]+a0,pmpaddr9 +[ ]+3b8:[ ]+3ba02573[ ]+csrr[ ]+a0,pmpaddr10 +[ ]+3bc:[ ]+3bb02573[ ]+csrr[ ]+a0,pmpaddr11 +[ ]+3c0:[ ]+3bc02573[ ]+csrr[ ]+a0,pmpaddr12 +[ ]+3c4:[ ]+3bd02573[ ]+csrr[ ]+a0,pmpaddr13 +[ ]+3c8:[ ]+3be02573[ ]+csrr[ ]+a0,pmpaddr14 +[ ]+3cc:[ ]+3bf02573[ ]+csrr[ ]+a0,pmpaddr15 diff --git a/gas/testsuite/gas/riscv/priv-reg.s b/gas/testsuite/gas/riscv/priv-reg.s index 4774f36..72d97f9 100644 --- a/gas/testsuite/gas/riscv/priv-reg.s +++ b/gas/testsuite/gas/riscv/priv-reg.s @@ -241,9 +241,11 @@ csr utval csr scounteren + csr stval csr satp csr mcounteren + csr mtval csr pmpcfg0 csr pmpcfg1 |