Commit 0a8fae41 authored by Liu Yu's avatar Liu Yu Committed by V8 LUCI CQ

[wasm] Use unaligned store in StoreArgsInStackSlot

StoreArgsInStackSlot sometimes does unaligned store.

Relate to commit 18469ec4.
In MemoryFill, size is an 8-byte integer, but is stored into a
4-byte aligned memory;

Bug: v8:10949, chromium:1281995
Change-Id: I9f18a0168432cdd6d27eacc98b980fa5b6d57d79
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3447932Reviewed-by: 's avatarThibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Yu Liu <liuyu@loongson.cn>
Cr-Commit-Position: refs/heads/main@{#79019}
parent ca443726
......@@ -5461,8 +5461,7 @@ Node* WasmGraphBuilder::StoreArgsInStackSlot(
for (auto arg : args) {
MachineRepresentation type = arg.first;
Node* value = arg.second;
gasm_->Store(StoreRepresentation(type, kNoWriteBarrier), stack_slot,
Int32Constant(offset), value);
gasm_->StoreUnaligned(type, stack_slot, Int32Constant(offset), value);
offset += ElementSizeInBytes(type);
}
return stack_slot;
......
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