URL
https://opencores.org/ocsvn/thor/thor/trunk
Go to most recent revision |
Show entire file |
Details |
Blame |
View Log
Rev 53 |
Rev 55 |
Line 1112... |
Line 1112... |
// o[63:44] = PTR;
|
// o[63:44] = PTR;
|
end
|
end
|
`LUI:
|
`LUI:
|
begin
|
begin
|
if (instr[7:6]==2'b01)
|
if (instr[7:6]==2'b01)
|
o[63:0] = {instr[47:13],30'd0};
|
o = {instr[47:13],30'd0};
|
else
|
else
|
o[63:0] = {{15{instr[31]}},instr[31:13],30'd0};
|
o = {{15{instr[31]}},instr[31:13],30'd0};
|
end
|
end
|
`ADDI: o[63:0] = a + b;
|
`ADDI: o[63:0] = a + b;
|
`SLTI: o[63:0] = $signed(a) < $signed(b);
|
`SLTI: o[63:0] = $signed(a) < $signed(b);
|
`SLTUI: o[63:0] = a < b;
|
`SLTUI: o[63:0] = a < b;
|
`SGTI: o[63:0] = $signed(a) > $signed(b);
|
`SGTI: o[63:0] = $signed(a) > $signed(b);
|
Line 1141... |
Line 1141... |
default: o = a + {b[63:1],1'b0}; // LC / LCU / SC
|
default: o = a + {b[63:1],1'b0}; // LC / LCU / SC
|
endcase
|
endcase
|
end
|
end
|
`LWR,`SWC,`CAS:
|
`LWR,`SWC,`CAS:
|
begin
|
begin
|
o[63:0] = a + b;
|
o = a + b;
|
end
|
end
|
`LV,`SV: begin
|
`LV,`SV: begin
|
o[63:0] = a + b + {ven,3'b0};
|
o = a + b + {ven,3'b0};
|
end
|
end
|
`CSRRW: case(instr[27:18])
|
`CSRRW:
|
10'h044: o[63:0] = BIG ? csr | {thrd,24'h0} : 64'hDDDDDDDDDDDDDDDD;
|
case(instr[27:18])
|
default: o[63:0] = BIG ? csr : 64'hDDDDDDDDDDDDDDDD;
|
10'h044: o = BIG ? (csr | {39'd0,thrd,24'h0}) : 64'hDDDDDDDDDDDDDDDD;
|
|
default: o = BIG ? csr : 64'hDDDDDDDDDDDDDDDD;
|
endcase
|
endcase
|
`BITFIELD: o[63:0] = BIG ? bfout : 64'hCCCCCCCCCCCCCCCC;
|
`BITFIELD: o = BIG ? bfout : 64'hCCCCCCCCCCCCCCCC;
|
default: o[63:0] = 64'hDEADDEADDEADDEAD;
|
default: o = 64'hDEADDEADDEADDEAD;
|
endcase
|
endcase
|
end
|
end
|
|
|
always @(posedge clk)
|
always @(posedge clk)
|
if (ld)
|
if (ld)
|
© copyright 1999-2025
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.