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

fix CompareI test, #630 #679

Merged
merged 1 commit into from
Jun 21, 2022
Merged
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: 5 additions & 5 deletions test/cctest/test-macro-assembler-riscv32.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1047,7 +1047,7 @@ static bool CompareF(T input1, T input2, FPUCondition cond) {
}
}

static bool CompareU(uint64_t input1, uint64_t input2, Condition cond) {
static bool CompareU(uint32_t input1, uint32_t input2, Condition cond) {
switch (cond) {
case eq:
return (input1 == input2);
Expand All @@ -1064,13 +1064,13 @@ static bool CompareU(uint64_t input1, uint64_t input2, Condition cond) {
return (input1 >= input2);

case less:
return (static_cast<int64_t>(input1) < static_cast<int64_t>(input2));
return (static_cast<int32_t>(input1) < static_cast<int32_t>(input2));
case less_equal:
return (static_cast<int64_t>(input1) <= static_cast<int64_t>(input2));
return (static_cast<int32_t>(input1) <= static_cast<int32_t>(input2));
case greater:
return (static_cast<int64_t>(input1) > static_cast<int64_t>(input2));
return (static_cast<int32_t>(input1) > static_cast<int32_t>(input2));
case greater_equal:
return (static_cast<int64_t>(input1) >= static_cast<int64_t>(input2));
return (static_cast<int32_t>(input1) >= static_cast<int32_t>(input2));

default:
UNREACHABLE();
Expand Down