(uint64_t)lhs, (uint64_t)rhs, (uint64_t)result);
return result;
}
- uint64_t result = (vlhs * vrhs) >> std::min(bitwidth, (uint8_t)32);
+ uint8_t bw32 = std::min(bitwidth, (uint8_t)32);
+ uint64_t result = (vlhs * vrhs) >> bw32;
+ result = zext_bwid(result, bw32);
+ fprintf(stderr, "mulhu result %lx %lx %lx bw %d\n",
+ (uint64_t)lhs, (uint64_t)rhs, (uint64_t)(result), bitwidth);
return rv_int_op_finish(lhs, rhs, result, bitwidth);
}
bool sv_proc_t::rv_ne(sv_reg_t const & lhs, sv_reg_t const & rhs)
{
+ fprintf(stderr, "rv_ne %lx %lx %d\n",
+ (uint64_t)lhs, (uint64_t)rhs, (lhs != rhs));
return (lhs != rhs);
}