Commit a50f54c1 authored by Santiago Aboy Solanes's avatar Santiago Aboy Solanes Committed by Commit Bot

[csa][cleanup] Partly TNodify SharedArrayBuffer's AssemblerFunction

As a drive-by, rename "sanity check" to "check" in sharedarraybuffer.

Bug: v8:6949, v8:10933
Change-Id: Ifa2eac381ed309a099b018de4033816ebe3d828d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2429410
Commit-Queue: Santiago Aboy Solanes <solanes@chromium.org>
Reviewed-by: 's avatarRoss McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#70307}
parent c7c8472d
......@@ -803,18 +803,20 @@ Node* CodeAssembler::AtomicStore(MachineRepresentation rep, Node* base,
}
#define ATOMIC_FUNCTION(name) \
Node* CodeAssembler::Atomic##name(MachineType type, Node* base, \
Node* offset, Node* value, \
Node* value_high) { \
Node* CodeAssembler::Atomic##name( \
MachineType type, TNode<RawPtrT> base, TNode<UintPtrT> offset, \
Node* value, base::Optional<TNode<UintPtrT>> value_high) { \
Node* value_high_node = nullptr; \
if (value_high) value_high_node = *value_high; \
return raw_assembler()->Atomic##name(type, base, offset, value, \
value_high); \
value_high_node); \
}
ATOMIC_FUNCTION(Exchange)
ATOMIC_FUNCTION(Add)
ATOMIC_FUNCTION(Sub)
ATOMIC_FUNCTION(And)
ATOMIC_FUNCTION(Or)
ATOMIC_FUNCTION(Xor)
ATOMIC_FUNCTION(Exchange)
#undef ATOMIC_FUNCTION
Node* CodeAssembler::AtomicCompareExchange(MachineType type, Node* base,
......
......@@ -783,31 +783,31 @@ class V8_EXPORT_PRIVATE CodeAssembler {
Node* AtomicStore(MachineRepresentation rep, Node* base, Node* offset,
Node* value, Node* value_high = nullptr);
Node* AtomicAdd(MachineType type, TNode<RawPtrT> base, TNode<UintPtrT> offset,
Node* value, base::Optional<TNode<UintPtrT>> value_high);
Node* AtomicSub(MachineType type, TNode<RawPtrT> base, TNode<UintPtrT> offset,
Node* value, base::Optional<TNode<UintPtrT>> value_high);
Node* AtomicAnd(MachineType type, TNode<RawPtrT> base, TNode<UintPtrT> offset,
Node* value, base::Optional<TNode<UintPtrT>> value_high);
Node* AtomicOr(MachineType type, TNode<RawPtrT> base, TNode<UintPtrT> offset,
Node* value, base::Optional<TNode<UintPtrT>> value_high);
Node* AtomicXor(MachineType type, TNode<RawPtrT> base, TNode<UintPtrT> offset,
Node* value, base::Optional<TNode<UintPtrT>> value_high);
// Exchange value at raw memory location
Node* AtomicExchange(MachineType type, Node* base, Node* offset, Node* value,
Node* value_high = nullptr);
Node* AtomicExchange(MachineType type, TNode<RawPtrT> base,
TNode<UintPtrT> offset, Node* value,
base::Optional<TNode<UintPtrT>> value_high);
// Compare and Exchange value at raw memory location
Node* AtomicCompareExchange(MachineType type, Node* base, Node* offset,
Node* old_value, Node* new_value,
Node* old_value_high = nullptr,
Node* new_value_high = nullptr);
Node* AtomicAdd(MachineType type, Node* base, Node* offset, Node* value,
Node* value_high = nullptr);
Node* AtomicSub(MachineType type, Node* base, Node* offset, Node* value,
Node* value_high = nullptr);
Node* AtomicAnd(MachineType type, Node* base, Node* offset, Node* value,
Node* value_high = nullptr);
Node* AtomicOr(MachineType type, Node* base, Node* offset, Node* value,
Node* value_high = nullptr);
Node* AtomicXor(MachineType type, Node* base, Node* offset, Node* value,
Node* value_high = nullptr);
// Store a value to the root array.
Node* StoreRoot(RootIndex root_index, Node* value);
......
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