Skip to content

Commit

Permalink
Decode AMOXOR (and others) instructions only in 64 bits
Browse files Browse the repository at this point in the history
it (should) fixes #1352
  • Loading branch information
JeanRochCoulon authored Aug 31, 2023
1 parent 434e55c commit 11630c1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/decoder.sv
Original file line number Diff line number Diff line change
Expand Up @@ -1073,7 +1073,7 @@ module decoder import ariane_pkg::*; #(
instruction_o.rd[4:0] = instr.atype.rd;
// TODO(zarubaf): Ordering
// words
if (CVA6Cfg.RVA && instr.stype.funct3 == 3'h2) begin
if (riscv::IS_XLEN64 && CVA6Cfg.RVA && instr.stype.funct3 == 3'h2) begin
unique case (instr.instr[31:27])
5'h0: instruction_o.op = ariane_pkg::AMO_ADDW;
5'h1: instruction_o.op = ariane_pkg::AMO_SWAPW;
Expand Down

0 comments on commit 11630c1

Please sign in to comment.