Suppress MSVC warning C4702: unreachable code
This commit is contained in:
parent
b1953c1cd4
commit
605a43d23e
2 changed files with 12 additions and 11 deletions
|
@ -261,10 +261,11 @@ struct PairedLowerIndexer {
|
||||||
return std::make_tuple(a[0], b[0]);
|
return std::make_tuple(a[0], b[0]);
|
||||||
}
|
}
|
||||||
return std::make_tuple(0, 0);
|
return std::make_tuple(0, 0);
|
||||||
}
|
} else {
|
||||||
UNREACHABLE();
|
UNREACHABLE();
|
||||||
return {};
|
return {};
|
||||||
}
|
}
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
template<size_t fsize, template<typename> class Indexer, typename Function>
|
template<size_t fsize, template<typename> class Indexer, typename Function>
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
namespace Dynarmic::FP {
|
namespace Dynarmic::FP {
|
||||||
|
|
||||||
template<typename FPT>
|
template<typename FPT>
|
||||||
std::tuple<FPType, bool, FPUnpacked> FPUnpackBase(FPT op, FPCR fpcr, FPSR& fpsr) {
|
std::tuple<FPType, bool, FPUnpacked> FPUnpackBase(FPT op, FPCR fpcr, [[maybe_unused]] FPSR& fpsr) {
|
||||||
constexpr size_t sign_bit = FPInfo<FPT>::exponent_width + FPInfo<FPT>::explicit_mantissa_width;
|
constexpr size_t sign_bit = FPInfo<FPT>::exponent_width + FPInfo<FPT>::explicit_mantissa_width;
|
||||||
constexpr size_t exponent_high_bit = FPInfo<FPT>::exponent_width + FPInfo<FPT>::explicit_mantissa_width - 1;
|
constexpr size_t exponent_high_bit = FPInfo<FPT>::exponent_width + FPInfo<FPT>::explicit_mantissa_width - 1;
|
||||||
constexpr size_t exponent_low_bit = FPInfo<FPT>::explicit_mantissa_width;
|
constexpr size_t exponent_low_bit = FPInfo<FPT>::explicit_mantissa_width;
|
||||||
|
@ -34,8 +34,7 @@ std::tuple<FPType, bool, FPUnpacked> FPUnpackBase(FPT op, FPCR fpcr, FPSR& fpsr)
|
||||||
return {FPType::Zero, sign, {sign, 0, 0}};
|
return {FPType::Zero, sign, {sign, 0, 0}};
|
||||||
}
|
}
|
||||||
return {FPType::Nonzero, sign, ToNormalized(sign, denormal_exponent, frac_raw)};
|
return {FPType::Nonzero, sign, ToNormalized(sign, denormal_exponent, frac_raw)};
|
||||||
}
|
} else {
|
||||||
|
|
||||||
if (frac_raw == 0 || fpcr.FZ()) {
|
if (frac_raw == 0 || fpcr.FZ()) {
|
||||||
if (frac_raw != 0) {
|
if (frac_raw != 0) {
|
||||||
FPProcessException(FPExc::InputDenorm, fpcr, fpsr);
|
FPProcessException(FPExc::InputDenorm, fpcr, fpsr);
|
||||||
|
@ -45,6 +44,7 @@ std::tuple<FPType, bool, FPUnpacked> FPUnpackBase(FPT op, FPCR fpcr, FPSR& fpsr)
|
||||||
|
|
||||||
return {FPType::Nonzero, sign, ToNormalized(sign, denormal_exponent, frac_raw)};
|
return {FPType::Nonzero, sign, ToNormalized(sign, denormal_exponent, frac_raw)};
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const bool exp_all_ones = exp_raw == Common::Ones<FPT>(FPInfo<FPT>::exponent_width);
|
const bool exp_all_ones = exp_raw == Common::Ones<FPT>(FPInfo<FPT>::exponent_width);
|
||||||
const bool ahp_disabled = is_half_precision && !fpcr.AHP();
|
const bool ahp_disabled = is_half_precision && !fpcr.AHP();
|
||||||
|
|
Loading…
Add table
Reference in a new issue