Skip to content

Commit

Permalink
fixed outputs
Browse files Browse the repository at this point in the history
  • Loading branch information
ShinyMiraidon committed Feb 12, 2024
1 parent a5846f6 commit 208f44f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion dv/exmem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ std::uint32_t rs2d, bool reset) {
nyu::eval(exmem);
}

INFO("Testing rdn_in = " << rdn_in << ", alu_out_in = " << alu_out_in << ", and rs2d = " << rs2d);
INFO("Testing rdn_in = " << rdn_in << ", alu_out_in = " << alu_out_in << ", and rs2d = " << (int) rs2d);

if (reset) {
REQUIRE(exmem.rdn == 0);
Expand Down
6 changes: 3 additions & 3 deletions dv/gpr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ static void eval_rstn() {
gpr.rstn = 0;
nyu::eval(gpr);

for(std::uint8_t rs1n {0}; (std::string) rs1n < 32; ++rs1n) {
for(std::uint8_t rs1n {0}; rs1n < 32; ++rs1n) {
INFO("Testing Register " << (int) rs1n);
REQUIRE(read(gpr, rs1n, 0).first == 0);
}
Expand All @@ -68,9 +68,9 @@ static void eval(std::uint32_t reg_vals[32], bool test_wbe) {
for(std::uint8_t rs1n {0}; rs1n < 32; ++rs1n)
for(std::uint8_t rs2n {0}; rs2n < 32; ++rs2n) {
read_vals = read(gpr, rs1n, rs2n);
INFO("Testing rs1n = " << rs1n << ", rs2n = " << rs2n);
INFO("Testing rs1n = " << (int) rs1n << ", rs2n = " << (int) rs2n);
REQUIRE(read_vals.first == reg_vals[rs1n] * (bool) rs1n);
REQUIRE(read_vals.second == reg_vals[rs2n] * (bool) rs1n);
REQUIRE(read_vals.second == reg_vals[rs2n] * (bool) rs2n);
}
}

Expand Down
2 changes: 1 addition & 1 deletion dv/memwb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ static void eval_p(std::uint8_t wbs, std::uint8_t rdn_in,
memwb.mrd = mrd;
memwb.alu_out = alu_out;
nyu::eval(memwb);
INFO("Testing wbs + " << wbs << ", rdn_in = " << rdn_in << ", alu_out = " << alu_out << ", and mrd = " << mrd);
INFO("Testing wbs + " << wbs << ", rdn_in = " << (int) rdn_in << ", alu_out = " << alu_out << ", and mrd = " << mrd);
REQUIRE((uint8_t) memwb.rdn == (uint8_t) rdn_in);
}

Expand Down

0 comments on commit 208f44f

Please sign in to comment.