Commit ef94d230 authored by Manos Koukoutos's avatar Manos Koukoutos Committed by V8 LUCI CQ

[wasm][turbofan] Match operators to node representation

This fixes operators in wasm Turbofan that were mixing up integer sizes
and pointers with tagged pointers.

Additional changes:
- Remove unused (and non-compiling if V8_MAP_PACKING)
  GraphAssembler::StoreMap.
- Factor out WasmGraphBuilder::IsNull.

Change-Id: I9d99827e35507adc0af391bd39975d55371b98cf
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3306981Reviewed-by: 's avatarNico Hartmann <nicohartmann@chromium.org>
Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78196}
parent cb90b21f
......@@ -578,15 +578,6 @@ TNode<Map> GraphAssembler::LoadMap(Node* object) {
#endif
}
void GraphAssembler::StoreMap(Node* object, TNode<Map> map) {
#ifdef V8_MAP_PACKING
map = PackMapWord(map);
#endif
StoreRepresentation rep(MachineType::TaggedRepresentation(),
kMapWriteBarrier);
Store(rep, object, HeapObject::kMapOffset - kHeapObjectTag, map);
}
Node* JSGraphAssembler::StoreElement(ElementAccess const& access, Node* object,
Node* index, Node* value) {
return AddNode(graph()->NewNode(simplified()->StoreElement(access), object,
......
......@@ -278,7 +278,6 @@ class V8_EXPORT_PRIVATE GraphAssembler {
TNode<Map> UnpackMapWord(Node* map_word);
#endif
TNode<Map> LoadMap(Node* object);
void StoreMap(Node* object, TNode<Map> map);
Node* DebugBreak();
......
This diff is collapsed.
......@@ -691,6 +691,8 @@ class WasmGraphBuilder {
// generates {index > max ? Smi(max) : Smi(index)}
Node* BuildConvertUint32ToSmiWithSaturation(Node* index, uint32_t maxval);
Node* IsNull(Node* object);
using BranchBuilder = std::function<void(Node*, BranchHint)>;
struct Callbacks {
BranchBuilder succeed_if;
......
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