Scott Johnson
4af2ceeff2
Convert mtinst to csr_t
5 years ago
Scott Johnson
bf8578c046
Convert mtval2 to csr_t
5 years ago
Andrew Waterman
b4b23c2906
Merge pull request #804 from scottj97/minstret
Convert minstret and friends to new CSR format
5 years ago
Andrew Waterman
af4beca4da
Actually fix SRET clearing MPRV
Reverts 12131ba08c
5 years ago
Andrew Waterman
12131ba08c
Fix SRET clearing MPRV
Attempting to clear MPRV via sstatus is fruitless. Use mstatus instead.
5 years ago
Andrew Waterman
c8aff0ebfe
Clear MPV on MRET and (when V=0) clear SPV on SRET
5 years ago
Andrew Waterman
7dbb7c353f
Update README
5 years ago
John Fang
ce42f1b55a
Fix torture signature ( #808 )
5 years ago
Scott Johnson
a0baa4bb26
Fix logged value of minstret
It was off by 1.
5 years ago
Scott Johnson
19a1d6f028
Provide mechanism (not yet used) for the logged value to be different from read()
I will need this soon for minstret.
5 years ago
Scott Johnson
b3b61bd0fb
Convert mcountinhibit to csr_t
5 years ago
Scott Johnson
4526550db3
Simplify logic and eliminate cpp macros
5 years ago
Scott Johnson
55a272562e
Convert unprivileged counter shadows to csr_t
Soon I will simplify some of these cpp macros.
5 years ago
marcfedorow
6827b74222
Added "Zk" to isa parser ( #806 )
5 years ago
Andrew Waterman
b29f4c2149
Fix handling of xdummy
@marcfedorow the logic wasn't quite right; xdummy was causing the
"single 'X' is not a proper name" message to be printed.
5 years ago
Andrew Waterman
2a5181d913
Fix memory leak
5 years ago
Andrew Waterman
3c3c0eaa86
Don't use "using"
5 years ago
Andrew Waterman
22affb92b7
Use RIAA pattern in manipulating ostream flags
sout is renamed to sout_ to reduce likelihood programmers accidentally use it.
5 years ago
Andrew Waterman
b4f76106d2
Fix parsing of isa string for H extension
Closes #805
5 years ago
marcfedorow
6684cfc5bb
Parse isa_string as in spec ( #802 )
See: 27.11 Subset Naming Convention (Table 27.1)
5 years ago
Scott Johnson
3092501627
Convert mhpmcounter, mhpmevents to csr_t
5 years ago
Scott Johnson
b23d9d5b1d
Convert mcycle[h] (which is a mirror of minstret[h]) to csr_t
5 years ago
Scott Johnson
d0a3e77608
Convert minstreth to csr_t
5 years ago
Scott Johnson
f19f39f0c1
Convert minstret to csr_t
This is a little messy in RV32 since it's accessed via two different
CSRs (upper and lower halves).
This changes logging of mcycle[h] to log a change to minstret[h],
since that's how it's always been implemented in Spike. There is no
separate mcycle register.
5 years ago
Scott Johnson
056fc389d2
Add new method csr_t::log_special_write()
For use by minstreth next.
5 years ago
Andrew Waterman
734745a1d5
Fix signed/unsigned warnings
The easiest solution was to make xlen a constant, rather than signed
or unsigned, since it's used in both contexts.
5 years ago
Elmar Melcher
9a4465e67f
add option --cmd to read commands from file ( #772 )
5 years ago
marcfedorow
7fe7ba8419
Added insn overlapping (bitmanip / krypto) ( #801 )
5 years ago
Mark Fedorov
1afbe648b8
Small fix: parse isa string scans lowercase
5 years ago
Mark Fedorov
bd93d29025
Splitted K-ext to zeds
5 years ago
Scott Johnson
07ae07ff01
Fix segfault when executing 'csrw pmpaddr15' when n_pmp==16
Off-by-one error introduced in 69008075a1
5 years ago
Scott Johnson
83502ad4af
Remove class logged_csr_t
5 years ago
Scott Johnson
629b1e6ff3
Move logging functionality into root class
So I can remove logged_csr_t next.
5 years ago
Scott Johnson
5cccd79681
Implement mip_proxy_csr_t as child of logged_csr_t
5 years ago
Scott Johnson
ab38a47582
Implement mie_proxy_csr_t as child of logged_csr_t
5 years ago
Scott Johnson
d57230e51e
Implement virtualized_csr_t as logged_csr_t
Goal is to eventually fold logged_csr_t back up into csr_t.
5 years ago
Scott Johnson
f2868bc734
Let compute_new_satp call read() himself
5 years ago
Scott Johnson
321f7d0fda
Move satp methods into satp classes
5 years ago
Scott Johnson
4009d54609
Give virtualized_satp_csr_t a handle to satp
Parent class has orig_csr but it's generic csr_t_p, and I will need to
call methods on satp_csr_t next.
5 years ago
Scott Johnson
55316421a3
Move satp methods to csrs.cc
Since they are soon to move classes.
5 years ago
Scott Johnson
1421945315
Use virtualized_csr_t for satp and vsatp
This was much more complicated than the others because of the
mstatus.TVM and hstatus.VTVM bits, and because of the special
WARL-ness of satp that doesn't apply to vsatp.
It appears (based on reading the code) that the commitlog for these
two was problematic. CSRW to satp when V=1 was reporting a write to
satp instead of vsatp which was actually written. Also a CSRW to
vsatp looks like it was not being logged at all. Both problems
should be fixed now.
5 years ago
Scott Johnson
4f008be2f7
Convert hcounteren to csr_t
5 years ago
Scott Johnson
3cf6ad3e87
Convert scounteren to csr_t
5 years ago
Scott Johnson
1ece34fd31
Convert mcounteren to csr_t
5 years ago
Scott Johnson
6b591e6197
Remove nonvirtual_sstatus from processor_t class
Since it's no longer needed there.
5 years ago
Scott Johnson
5662134bc1
Localize & constantize variables
5 years ago
Scott Johnson
dc43e0d5f5
Share variable for sstatus.sie
5 years ago
Scott Johnson
975c860459
Make these variables all const
Because why not?
5 years ago
Scott Johnson
1c8362fcb6
Split up unnecessarily reused variable
5 years ago
Scott Johnson
6891390665
Reduce variable scope
5 years ago