mirror of
https://git.suyu.dev/suyu/dynarmic.git
synced 2026-03-26 13:02:57 +00:00
fp/unpacked: Implement FPRound
This commit is contained in:
@@ -40,4 +40,18 @@ inline bool operator==(const FPUnpacked<MantissaT>& a, const FPUnpacked<Mantissa
|
||||
template<typename FPT>
|
||||
std::tuple<FPType, bool, FPUnpacked<u64>> FPUnpack(FPT op, FPCR fpcr, FPSR& fpsr);
|
||||
|
||||
template<typename FPT, typename MantissaT>
|
||||
FPT FPRoundBase(FPUnpacked<MantissaT> op, FPCR fpcr, RoundingMode rounding, FPSR& fpsr);
|
||||
|
||||
template<typename FPT, typename MantissaT>
|
||||
FPT FPRound(FPUnpacked<MantissaT> op, FPCR fpcr, RoundingMode rounding, FPSR& fpsr) {
|
||||
fpcr.AHP(false);
|
||||
return FPRoundBase<FPT, MantissaT>(op, fpcr, rounding, fpsr);
|
||||
}
|
||||
|
||||
template<typename FPT, typename MantissaT>
|
||||
FPT FPRound(FPUnpacked<MantissaT> op, FPCR fpcr, FPSR& fpsr) {
|
||||
return FPRound<FPT, MantissaT>(op, fpcr, fpcr.RMode(), fpsr);
|
||||
}
|
||||
|
||||
} // namespace Dynarmic::FP
|
||||
|
||||
Reference in New Issue
Block a user