Commit d745a1e3 authored by Zhao Jiazhong's avatar Zhao Jiazhong Committed by Commit Bot

[mips][wasm] Fix FpRegister size in WasmDebugBreakFrameConstants.

The FpRegister size was miswritten as kSimd128Size like x64, while it
should be kDoubleSize on mips.

Change-Id: Iac4c5687e398a87ec0508fb99042a487c41ddf8c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2110891
Auto-Submit: Zhao Jiazhong <zhaojiazhong-hf@loongson.cn>
Reviewed-by: 's avatarDan Elphick <delphick@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#66804}
parent 6fffffce
......@@ -55,7 +55,7 @@ class WasmDebugBreakFrameConstants : public TypedFrameConstants {
static constexpr int kLastPushedGpRegisterOffset =
-kFixedFrameSizeFromFp - kNumPushedGpRegisters * kSystemPointerSize;
static constexpr int kLastPushedFpRegisterOffset =
kLastPushedGpRegisterOffset - kNumPushedFpRegisters * kSimd128Size;
kLastPushedGpRegisterOffset - kNumPushedFpRegisters * kDoubleSize;
// Offsets are fp-relative.
static int GetPushedGpRegisterOffset(int reg_code) {
......@@ -69,7 +69,7 @@ class WasmDebugBreakFrameConstants : public TypedFrameConstants {
DCHECK_NE(0, kPushedFpRegs & (1 << reg_code));
uint32_t lower_regs = kPushedFpRegs & ((uint32_t{1} << reg_code) - 1);
return kLastPushedFpRegisterOffset +
base::bits::CountPopulation(lower_regs) * kSimd128Size;
base::bits::CountPopulation(lower_regs) * kDoubleSize;
}
};
......
......@@ -51,7 +51,7 @@ class WasmDebugBreakFrameConstants : public TypedFrameConstants {
static constexpr int kLastPushedGpRegisterOffset =
-kFixedFrameSizeFromFp - kNumPushedGpRegisters * kSystemPointerSize;
static constexpr int kLastPushedFpRegisterOffset =
kLastPushedGpRegisterOffset - kNumPushedFpRegisters * kSimd128Size;
kLastPushedGpRegisterOffset - kNumPushedFpRegisters * kDoubleSize;
// Offsets are fp-relative.
static int GetPushedGpRegisterOffset(int reg_code) {
......@@ -65,7 +65,7 @@ class WasmDebugBreakFrameConstants : public TypedFrameConstants {
DCHECK_NE(0, kPushedFpRegs & (1 << reg_code));
uint32_t lower_regs = kPushedFpRegs & ((uint32_t{1} << reg_code) - 1);
return kLastPushedFpRegisterOffset +
base::bits::CountPopulation(lower_regs) * kSimd128Size;
base::bits::CountPopulation(lower_regs) * kDoubleSize;
}
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment