Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[LINUX/CPU] Fixed MulHi in value.cc for Linux systems. #2231

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions src/xenia/cpu/hir/value.cc
Original file line number Diff line number Diff line change
Expand Up @@ -409,13 +409,15 @@ void Value::MulHi(Value* other, bool is_unsigned) {
}
#else
if (is_unsigned) {
constant.i64 = static_cast<uint64_t>(
constant.i64 = static_cast<uint64_t>((
static_cast<unsigned __int128>(constant.i64) *
static_cast<unsigned __int128>(other->constant.i64));
static_cast<unsigned __int128>(other->constant.i64))
>> 64);
} else {
constant.i64 =
static_cast<uint64_t>(static_cast<__int128>(constant.i64) *
static_cast<__int128>(other->constant.i64));
static_cast<uint64_t>((static_cast<__int128>(constant.i64) *
static_cast<__int128>(other->constant.i64))
>> 64);
}
#endif // XE_COMPILER_MSVC
break;
Expand Down