From eab6cf4fc5720b330ba89c38e9e6119a8a6fabfa Mon Sep 17 00:00:00 2001 From: Pavel Pisa Date: Thu, 31 Jan 2019 11:02:03 +0100 Subject: Initial support for JAL. The JR, BEQ, BNE are most probably incorrect still. There is missing forwarding for pipelined execution. Signed-off-by: Pavel Pisa --- qtmips_machine/alu.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'qtmips_machine/alu.cpp') diff --git a/qtmips_machine/alu.cpp b/qtmips_machine/alu.cpp index 2e36d4c..36b1ac7 100644 --- a/qtmips_machine/alu.cpp +++ b/qtmips_machine/alu.cpp @@ -71,6 +71,8 @@ std::uint32_t machine::alu_operate(enum AluOp operation, std::uint32_t s, std::u return (s < t) ? 1 : 0; case ALU_OP_LUI: return t << 16; + case ALU_OP_PASS_S: // Pass s argument without change for JAL + return s; default: throw QTMIPS_EXCEPTION(UnsupportedAluOperation, "Unknown ALU operation", QString::number(operation, 16)); } -- cgit v1.2.3