summaryrefslogtreecommitdiff
path: root/rtl/core/decode/decode.sv
diff options
context:
space:
mode:
authorAlejandro Soto <alejandro@34project.org>2022-10-18 08:47:57 -0600
committerAlejandro Soto <alejandro@34project.org>2022-10-18 08:47:57 -0600
commit9162c76e3e6717b114190051e59eaf70205d9111 (patch)
tree041542ae6a2b0ce241c655e2e6a8ba294602f7a7 /rtl/core/decode/decode.sv
parent52f1f2f94bddfb1e73d2c094cfd693916750a467 (diff)
Implement branch with link
Diffstat (limited to '')
-rw-r--r--rtl/core/decode/decode.sv4
1 files changed, 3 insertions, 1 deletions
diff --git a/rtl/core/decode/decode.sv b/rtl/core/decode/decode.sv
index 2580701..9367e6d 100644
--- a/rtl/core/decode/decode.sv
+++ b/rtl/core/decode/decode.sv
@@ -143,9 +143,11 @@ module core_decode
`GROUP_B: begin
branch = 1;
if(branch_link) begin
+ data_ctrl.op = `ALU_SUB;
data_ctrl.rd = `R14;
+ data_ctrl.rn = `R15;
+ snd_ctrl.imm = 12'd4;
writeback = 1;
- //TODO: Valor de LR
end
end