From 946c31ab9afab746b99c7a5bf24602c92fd9c3c6 Mon Sep 17 00:00:00 2001 From: Markus Wegmann Date: Thu, 12 Jan 2017 19:16:27 +0100 Subject: [PATCH] Fix deadlock --- id_stage.sv | 2 +- include/riscv_config.sv | 21 ++++++++++----------- 2 files changed, 11 insertions(+), 12 deletions(-) diff --git a/id_stage.sv b/id_stage.sv index 89b00af8..4848ddcb 100644 --- a/id_stage.sv +++ b/id_stage.sv @@ -1796,7 +1796,7 @@ module riscv_id_stage `ifdef ONLY_ALIGNED assign id_ready_o = ((~jr_stall) & (~load_stall) & ex_ready_i); `else - assign id_ready_o = ((~misaligned_stall & first_cycle_misaligned_i) & (~jr_stall) & (~load_stall) & ex_ready_i); + assign id_ready_o = ((~first_cycle_misaligned_i) & (~jr_stall) & (~load_stall) & ex_ready_i); `endif // ONLY_ALIGNED `else `ifdef ONLY_ALIGNED diff --git a/include/riscv_config.sv b/include/riscv_config.sv index 170c72a6..f343b363 100644 --- a/include/riscv_config.sv +++ b/include/riscv_config.sv @@ -58,6 +58,14 @@ // will enable bit manipulation and counting support. //`define BIT_SUPPORT +// CONFIG: MATH_SPECIAL_SUPPORT +// will enable clip, min and max operations support. +//`define MATH_SPECIAL_SUPPORT + +// CONFIG: JUMP_IN_ID +// will enable direct jump in ID. Might increase critical path of jump target. +`define JUMP_IN_ID + // CONFIG: LSU_ADDER_SUPPORT // will enable an additional adder in the LSU for better timings. //`define LSU_ADDER_SUPPORT @@ -70,14 +78,6 @@ `endif // LSU_ADDER_SUPPORT -// CONFIG: MATH_SPECIAL_SUPPORT -// will enable clip, min and max operations support. -//`define MATH_SPECIAL_SUPPORT - -// CONFIG: JUMP_IN_ID -// will enable direct jump in ID. Might increase critical path of jump target -`define JUMP_IN_ID - // Dependent definitions @@ -103,17 +103,16 @@ // CONFIG: RV32E // will reduce the register file to 16 words -`define RV32E +//`define RV32E // CONFIG: ONLY_ALIGNED // will only allow aligned memory accesses and therefore overlapping mustn't occur -`define ONLY_ALIGNED +//`define ONLY_ALIGNED // CONFIG: SPLITTED_ADDER // will split ALU Adder in half and use two cycles to add operands //`define SPLITTED_ADDER - `ifndef SPLITTED_ADDER `ifdef JUMP_IN_ID // CONFIG: MERGE_ID_EX