Olof Kindgren
c2cdd44f73
Expose and document PRE_REGISTER
2021-06-05 22:56:37 +02:00
Sylvain Munaut
259d5a10ed
decode: Add option to pre or post register during decoding
...
Either the input from instruction bus is registered and the
outputs are generated combinatorially (PRE_REGISTER mode), or
the input from the instruction bus is decoded combinatorially
and the result of decoding is registered (POST_REGISTER mode).
First is smaller because it allows synthesis to optimize decoding
logic with its users, but is slow. The second one is faster but
slightly bigger.
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2021-05-28 21:26:54 +02:00
Olof Kindgren
f373d7bcb6
Reuse immediate regs for RF addresses
2021-05-16 00:09:18 +02:00
Olof Kindgren
14262bfc30
Rewrite logic expression of alu bool operations
2021-05-15 23:07:55 +02:00
Olof Kindgren
a5c1c8ddc4
Kill off serv_params.vh
2021-04-26 17:04:18 +02:00
Olof Kindgren
1c11365ae8
Simulator-friendly cleanup of misalign_trap_sync
2021-04-22 15:44:18 +02:00
Olof Kindgren
82c808aa1e
Implement byte_valid in a more efficient way
2021-04-18 22:48:55 +02:00
Olof Kindgren
62d5d5f8fb
Remove unused wire cnt4
2021-04-18 22:01:32 +02:00
Olof Kindgren
0c601f0872
Fix RF we gating for RF width > 2
2021-04-18 00:13:47 +02:00
Olof Kindgren
079a5c4250
Remove unused wgo register
2021-04-08 15:36:11 +02:00
Olof Kindgren
548b7fbb41
remove redundant ALU control signal
2021-03-14 23:22:50 +01:00
Olof Kindgren
727bb40a87
Simplify control logic for bool ops
2021-03-14 00:12:29 +01:00
Olof Kindgren
7624466ddd
Optimize serv_rf_ram_if
2021-02-15 08:50:24 +01:00
Olof Kindgren
9a0b0e877c
Move shifter to mem_if
...
This allows reusing the data bus registers for shift amount
2021-02-06 23:24:23 +01:00
Olof Kindgren
f70b79fd8f
Combine lt and eq regs to cmp_r in serv_alu
2021-02-01 22:37:45 +01:00
Olof Kindgren
6fbdea58d6
Optimize trap handling
2021-01-23 22:42:26 +01:00
Olof Kindgren
8d5dd77a26
Optimize csr address handling
2021-01-23 22:42:26 +01:00
Olof Kindgren
e4b773c17b
Syntax fixes
2021-01-18 22:47:28 +01:00
Olof Kindgren
5e4181d204
Optimize shift operations
2021-01-18 22:46:51 +01:00
Olof Kindgren
d5febe8f63
Simplify and document trap handling
2021-01-18 22:38:07 +01:00
Olof Kindgren
17103dd1f5
Merge LSB registers into bufreg
2021-01-11 21:40:45 +01:00
Olof Kindgren
fe6c9b0f83
Optimize bufreg lsb signal and clean up bufreg interface
2021-01-06 22:19:40 +01:00
Olof Kindgren
0bc19ef13c
Clean up serv_alu interface
2021-01-06 22:02:13 +01:00
Olof Kindgren
ace7b8ef44
Explain and optimize state counter
2021-01-03 00:01:09 +01:00
Olof Kindgren
25fa6fa83b
Clean up and document serv_mem_if
2021-01-02 00:02:23 +01:00
Olof Kindgren
ca1a07f684
Document and clean up interface of serv_immdec
2020-12-29 23:35:17 +01:00
Olof Kindgren
a960fd768b
Remove redundant bufreg_loop control signal
2020-12-22 22:13:57 +01:00
Olof Kindgren
c9f41b54e8
Optimize init signal
2020-12-22 22:13:57 +01:00
Olof Kindgren
d6445b95a6
Clean up serv_ctrl
2020-12-06 22:39:04 +01:00
Olof Kindgren
116e370589
Reverse polarity of bufreg_hold signal
2020-12-06 22:39:04 +01:00
Olof Kindgren
aa16bc40b6
Move ibus_cyc handling to serv_state
2020-12-02 16:19:34 +01:00
Olof Kindgren
fd79a2ea0c
Use cnt0 in serv_ctrl
2020-12-01 22:40:52 +01:00
Olof Kindgren
bbe3e56ab2
Decouple ibus_cyc and ibus_ack
2020-11-30 23:13:11 +01:00
Olof Kindgren
90ce4ff1af
Syntax and reset fixes for ModelSim
2020-11-10 15:16:19 +01:00
Olof Kindgren
c1b8471678
Add reset_strategy parameter
...
The reset_strategy parameter controls how much reset to apply to
SERV. It can be set to MINI for the default behaviour, or NONE to
only apply reset where absolutely needed and rely on POR to clear
FFs
2020-11-10 15:16:19 +01:00
Olof Kindgren
44287ed244
Remove unused reset input from serv_alu
2020-11-10 15:16:19 +01:00
Olof Kindgren
6aeb39c7ac
Clean up port maps in serv_top
2020-11-10 15:16:19 +01:00
Olof Kindgren
3751b58253
Clean up serv_csr interface
2020-11-10 15:16:19 +01:00
Olof Kindgren
554bdccba0
Silence some warnings
2020-11-10 15:16:19 +01:00
Olof Kindgren
cc42437e0f
Prepare for alternative immediate decoder
2020-11-10 15:16:19 +01:00
Olof Kindgren
3f81f07db3
Clarify immdec_ctrl[1]
2020-11-10 15:16:19 +01:00
Olof Kindgren
8faf0cf33b
Simplify and explain csr_imm_en
2020-11-10 15:16:19 +01:00
Olof Kindgren
ee6a86705d
Set size of WITH_CSR to avoid Quartus warning
2020-09-29 17:52:02 +02:00
Olof Kindgren
f10cb89ae4
Fix double-defined result_lt wire
2020-09-29 14:12:57 +02:00
Olof Kindgren
25e86fdd3c
Small optimization of instruction fetching logic
2020-08-26 16:45:40 +02:00
Olof Kindgren
3aa1a2c6e5
Simplify and document mstatus/mcause assignments
2020-08-26 16:45:40 +02:00
Olof Kindgren
fa6c420b10
Remove redundant mstatus register
2020-08-26 16:45:40 +02:00
Olof Kindgren
915cdf7933
Move RF address decoding to serv_immdec
2020-08-17 13:00:29 +02:00
Olof Kindgren
88a1a43438
Refactor and Use ALU subtractor for comparisons
2020-08-13 23:37:11 +02:00
Olof Kindgren
1c4e793885
Move CSR immediate decoder to immdec
2020-08-13 23:37:11 +02:00