Home
last modified time | relevance | path

Searched refs:oldValue (Results 1 - 25 of 41) sorted by relevance

12

/arkcompiler/runtime_core/static_core/plugins/ets/runtime/intrinsics/
H A Descompat_Atomics.cpp51 auto add = [value](type oldValue) { return oldValue + value; }; \
60 auto bitwiseAnd = [value](type oldValue) { \
62 return static_cast<type>((bit_cast<u##type>(oldValue)) & (bit_cast<u##type>(value))); \
72 auto bitwiseAnd = [value](type oldValue) { return static_cast<type>((oldValue) & (value)); }; \
82 auto compareExchange = [expectedValue, replacementValue](type oldValue) { \
84 return oldValue == expectedValue ? replacementValue : oldValue; \
94 auto exchange = [value]([[maybe_unused]] type oldValue) { retur
[all...]
/arkcompiler/ets_runtime/ecmascript/mem/
H A Dgc_bitset.h221 auto oldValue = word->load(std::memory_order_relaxed);
224 if ((oldValue & mask) == 0) {
227 oldValueBeforeCAS = oldValue;
228 std::atomic_compare_exchange_strong_explicit(word, &oldValue, oldValue & (~mask),
230 } while (oldValue != oldValueBeforeCAS);
259 auto oldValue = word->load(std::memory_order_relaxed);
262 if (oldValue & mask) {
265 oldValueBeforeCAS = oldValue;
266 std::atomic_compare_exchange_strong_explicit(word, &oldValue, oldValu
[all...]
H A Dbarriers.h40 static inline T AtomicSetPrimitive(volatile void *obj, size_t offset, T oldValue, T value) in AtomicSetPrimitive() argument
43 std::atomic_compare_exchange_strong_explicit(atomicField, &oldValue, value, std::memory_order_release, in AtomicSetPrimitive()
45 return oldValue; in AtomicSetPrimitive()
H A Dparallel_marker-inl.h413 auto oldValue = markWord.GetValue(); in EvacuateObject() local
414 auto result = Barriers::AtomicSetPrimitive(object, 0, oldValue, in EvacuateObject()
416 if (result == oldValue) { in EvacuateObject()
507 auto oldValue = markWord.GetValue(); in EvacuateObject() local
508 auto result = Barriers::AtomicSetPrimitive(object, 0, oldValue, in EvacuateObject()
510 if (result == oldValue) { in EvacuateObject()
/arkcompiler/ets_runtime/ecmascript/
H A Dtagged_hash_array.cpp112 JSMutableHandle<JSTaggedValue> oldValue(thread, JSTaggedValue::Undefined()); in Resize()
114 oldValue.Update(oldTab->Get(j)); in Resize()
115 if (oldValue->IsHole()) { in Resize()
117 } else if (oldValue->IsRBTreeNode()) { in Resize()
118 RBTreeNode::Divide(thread, newTab, oldValue, j, oldCapacity); in Resize()
119 } else if (oldValue->IsLinkedNode()) { in Resize()
120 LinkedNode *node = LinkedNode::Cast(oldValue.GetTaggedValue().GetTaggedObject()); in Resize()
125 NodeDisperse(thread, newTab, oldValue.GetTaggedValue(), j, oldCapacity); in Resize()
246 JSTaggedValue oldValue = JSTaggedValue::Hole(); in RemoveNode() local
247 JSTaggedValue rootTreeNodeVa = RBTreeNode::Delete(thread, node, hash, key, oldValue); in RemoveNode()
[all...]
H A Dglobal_env.h114 JSTaggedValue oldValue(Barriers::GetValue<JSTaggedType>(this, offset)); in RemoveValueFromSnapshotEnv()
115 if (oldValue == value) { in RemoveValueFromSnapshotEnv()
118 if (oldValue.IsHeapObject() && !oldValue.IsInternalAccessor()) { in RemoveValueFromSnapshotEnv()
120 snapshotEnv->Remove(oldValue.GetRawData()); in RemoveValueFromSnapshotEnv()
H A Dglobal_dictionary-inl.h215 JSHandle<JSTaggedValue> oldValue(thread, box->GetValue()); in InvalidatePropertyBox()
216 GlobalDictionary::InvalidateAndReplaceEntry(thread, dictHandle, entry, oldValue); in InvalidatePropertyBox()
220 int entry, const JSHandle<JSTaggedValue> &oldValue) in InvalidateAndReplaceEntry()
227 JSHandle<PropertyBox> newBox = factory->NewPropertyBox(oldValue); in InvalidateAndReplaceEntry()
219 InvalidateAndReplaceEntry(JSThread *thread, const JSHandle<GlobalDictionary> &dictHandle, int entry, const JSHandle<JSTaggedValue> &oldValue) InvalidateAndReplaceEntry() argument
H A Dtagged_node.cpp340 const JSTaggedValue &key, JSTaggedValue &oldValue) in Delete()
355 JSTaggedValue leftValue = Delete(thread, leftChildVa, hash, key, oldValue); in Delete()
364 oldValue = treeNode->GetValue(); in Delete()
381 oldValue = treeNode->GetValue(); in Delete()
388 JSTaggedValue tmpValue = Delete(thread, rightChildVa, hash, key, oldValue); in Delete()
339 Delete(JSThread *thread, const JSTaggedValue &treeNodeVa, int hash, const JSTaggedValue &key, JSTaggedValue &oldValue) Delete() argument
H A Dglobal_dictionary.h55 int entry, const JSHandle<JSTaggedValue> &oldValue);
/arkcompiler/runtime_core/static_core/runtime/include/
H A Dobject_header-inl.h146 inline bool ObjectHeader::CompareAndSetFieldPrimitive(size_t offset, T oldValue, T newValue, in CompareAndSetFieldPrimitive() argument
149 return ObjectAccessor::CompareAndSetFieldPrimitive(this, offset, oldValue, newValue, memoryOrder, strong).first; in CompareAndSetFieldPrimitive()
154 inline bool ObjectHeader::CompareAndSetFieldObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue, in CompareAndSetFieldObject() argument
157 return ObjectAccessor::CompareAndSetFieldObject<NEED_WRITE_BARRIER, IS_DYN>(this, offset, oldValue, newValue, in CompareAndSetFieldObject()
163 inline T ObjectHeader::CompareAndExchangeFieldPrimitive(size_t offset, T oldValue, T newValue, in CompareAndExchangeFieldPrimitive() argument
166 return ObjectAccessor::CompareAndSetFieldPrimitive(this, offset, oldValue, newValue, memoryOrder, strong).second; in CompareAndExchangeFieldPrimitive()
171 inline ObjectHeader *ObjectHeader::CompareAndExchangeFieldObject(size_t offset, ObjectHeader *oldValue, in CompareAndExchangeFieldObject() argument
175 return ObjectAccessor::CompareAndSetFieldObject<NEED_WRITE_BARRIER, IS_DYN>(this, offset, oldValue, newValue, in CompareAndExchangeFieldObject()
H A Dobject_accessor-inl.h249 inline std::pair<bool, T> ObjectAccessor::CompareAndSetFieldPrimitive(void *obj, size_t offset, T oldValue, T newValue, in CompareAndSetFieldPrimitive() argument
256 return {atomicAddr->compare_exchange_strong(oldValue, newValue, memoryOrder), oldValue}; in CompareAndSetFieldPrimitive()
258 return {atomicAddr->compare_exchange_weak(oldValue, newValue, memoryOrder), oldValue}; in CompareAndSetFieldPrimitive()
265 ObjectHeader *oldValue, in CompareAndSetFieldObject()
275 CompareAndSetFieldPrimitive<ObjectHeader *>(obj, offset, oldValue, newValue, memoryOrder, strong); in CompareAndSetFieldObject()
279 auto value = CompareAndSetFieldPrimitive<ObjectPointerType>(obj, offset, ToObjPtrType(oldValue), in CompareAndSetFieldObject()
357 T oldValue = atomicAddr->load(memoryOrder); in GetAndAddFieldPrimitive() local
360 newValue = oldValue in GetAndAddFieldPrimitive()
264 CompareAndSetFieldObject(void *obj, size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue, std::memory_order memoryOrder, bool strong) CompareAndSetFieldObject() argument
[all...]
H A Dobject_header.h252 bool CompareAndSetFieldPrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder, bool strong);
255 bool CompareAndSetFieldObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue,
259 T CompareAndExchangeFieldPrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder,
263 ObjectHeader *CompareAndExchangeFieldObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue,
H A Dmethod.h432 uint32_t oldValue = accessFlags_.load(std::memory_order_acquire); in AtomicSetCompilationStatus() local
433 while (GetCompilationStatus(oldValue) == oldStatus) { in AtomicSetCompilationStatus()
434 uint32_t newValue = MakeCompilationStatusValue(oldValue, newStatus); in AtomicSetCompilationStatus()
435 if (accessFlags_.compare_exchange_strong(oldValue, newValue)) { in AtomicSetCompilationStatus()
853 uint32_t oldValue = accessFlags_.load(std::memory_order_acquire); in SetVerificationStage() local
854 uint32_t newValue = MakeVerificationStageValue(oldValue, newStage); in SetVerificationStage()
855 while (!accessFlags_.compare_exchange_weak(oldValue, newValue, std::memory_order_acq_rel)) { in SetVerificationStage()
856 newValue = MakeVerificationStageValue(oldValue, newStage); in SetVerificationStage()
H A Dclass-inl.h754 inline bool Class::CompareAndSetFieldPrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder,
757 return ObjectAccessor::CompareAndSetFieldPrimitive(this, offset, oldValue, newValue, memoryOrder, strong).first;
762 inline bool Class::CompareAndSetFieldObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue,
768 return ObjectAccessor::CompareAndSetFieldObject<NEED_WRITE_BARRIER>(object, newOffset, oldValue, newValue,
774 inline T Class::CompareAndExchangeFieldPrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder,
777 return ObjectAccessor::CompareAndSetFieldPrimitive(this, offset, oldValue, newValue, memoryOrder, strong).second;
782 inline ObjectHeader *Class::CompareAndExchangeFieldObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue,
788 return ObjectAccessor::CompareAndSetFieldObject<NEED_WRITE_BARRIER>(object, newOffset, oldValue, newValue,
/arkcompiler/ets_runtime/ecmascript/compiler/base/
H A Dbit_set.h105 auto oldValue = data_.inlineWord_; in UnionWithChanged() local
107 return data_.inlineWord_ != oldValue; in UnionWithChanged()
111 auto oldValue = data_.words_[i]; in UnionWithChanged() local
113 if (!changed && data_.words_[i] != oldValue) { in UnionWithChanged()
/arkcompiler/ets_runtime/ecmascript/compiler/codegen/maple/maple_ir/include/
H A Dfunc_desc.h188 auto oldValue = static_cast<size_t>(funcInfo); in SetFuncInfoNoBetterThan() local
190 if (newValue < oldValue) { in SetFuncInfoNoBetterThan()
210 size_t oldValue = static_cast<size_t>(paramInfo[idx]); in SetParamInfoNoBetterThan() local
212 if (newValue < oldValue) { in SetParamInfoNoBetterThan()
/arkcompiler/runtime_core/static_core/libpandabase/mem/
H A Dbase_mem_stats.cpp43 uint64_t oldValue = allocated_[index].fetch_sub(size, std::memory_order_acq_rel); in RecordMoved() local
44 (void)oldValue; in RecordMoved()
45 ASSERT(oldValue >= size); in RecordMoved()
/arkcompiler/runtime_core/static_core/runtime/include/coretypes/
H A Darray-inl.h83 inline bool Array::CompareAndSetPrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder, in CompareAndSetPrimitive() argument
86 return ObjectAccessor::CompareAndSetFieldPrimitive(this, GetDataOffset() + offset, oldValue, newValue, memoryOrder, in CompareAndSetPrimitive()
93 inline bool Array::CompareAndSetObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue, in CompareAndSetObject() argument
97 return ObjectAccessor::CompareAndSetFieldObject<NEED_WRITE_BARRIER, IS_DYN>(this, fieldOffset, oldValue, newValue, in CompareAndSetObject()
103 inline T Array::CompareAndExchangePrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder, in CompareAndExchangePrimitive() argument
106 return ObjectAccessor::CompareAndSetFieldPrimitive(this, GetDataOffset() + offset, oldValue, newValue, memoryOrder, in CompareAndExchangePrimitive()
113 inline ObjectHeader *Array::CompareAndExchangeObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue, in CompareAndExchangeObject() argument
117 return ObjectAccessor::CompareAndSetFieldObject<NEED_WRITE_BARRIER, IS_DYN>(this, fieldOffset, oldValue, newValue, in CompareAndExchangeObject()
H A Darray.h130 bool CompareAndSetPrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder, bool strong);
133 bool CompareAndSetObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue,
137 T CompareAndExchangePrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder, bool strong);
140 ObjectHeader *CompareAndExchangeObject(size_t offset, ObjectHeader *oldValue, ObjectHeader *newValue,
/arkcompiler/ets_runtime/ecmascript/compiler/
H A Descape_analysis.cpp133 GateRef oldValue = oldState.GetFieldValue(field); in MergeState() local
134 if (oldValue != Circuit::NullGate() && in MergeState()
135 acc_.GetOpCode(oldValue) == OpCode::DEPEND_SELECTOR && in MergeState()
136 acc_.GetState(oldValue) == acc_.GetState(gate)) { in MergeState()
139 if (acc_.GetValueIn(oldValue, i) != input[i + 1]) { in MergeState()
140 acc_.ReplaceValueIn(oldValue, input[i + 1], i); in MergeState()
141 escapeAnalysis_->RevisitGate(oldValue); in MergeState()
144 result.SetFieldValue(field, oldValue); in MergeState()
/arkcompiler/ets_runtime/ecmascript/base/
H A Dstring_helper.h54 static inline CString ReplaceAll(CString str, const CString &oldValue, in ReplaceAll() argument
57 if (oldValue.empty() || oldValue == newValue) { in ReplaceAll()
61 while ((pos = str.find(oldValue, pos)) != CString::npos) { in ReplaceAll()
62 str.replace(pos, oldValue.length(), newValue); in ReplaceAll()
68 static inline CString Replace(CString str, const CString &oldValue, in Replace() argument
71 if (oldValue.empty() || oldValue == newValue) { in Replace()
75 if ((pos = str.find(oldValue, pos)) != CString::npos) { in Replace()
76 str.replace(pos, oldValue in Replace()
[all...]
/arkcompiler/runtime_core/static_core/plugins/ets/runtime/types/
H A Dets_object.h150 bool CompareAndSetFieldPrimitive(size_t offset, T oldValue, T newValue, std::memory_order memoryOrder, bool strong) in CompareAndSetFieldPrimitive() argument
152 return GetCoreType()->CompareAndSetFieldPrimitive(offset, oldValue, newValue, memoryOrder, strong); in CompareAndSetFieldPrimitive()
155 bool CompareAndSetFieldObject(size_t offset, EtsObject *oldValue, EtsObject *newValue, in CompareAndSetFieldObject() argument
158 return GetCoreType()->CompareAndSetFieldObject(offset, reinterpret_cast<ObjectHeader *>(oldValue), in CompareAndSetFieldObject()
H A Dets_shared_memory-inl.h91 auto oldValue = thisHandle->GetElement<T>(index);
92 auto newValue = f(oldValue);
95 return std::pair(oldValue, newValue);
/arkcompiler/runtime_core/static_core/libpandabase/utils/
H A Dbit_field.h127 static constexpr uint64_t Update(uint64_t oldValue, T value)
129 return (oldValue & ~Mask()) | Encode(value);
/arkcompiler/ets_runtime/ecmascript/compiler/builtins/
H A Dbuiltins_proxy_stub_builder.h60 GateRef oldValue = ZExtInt1ToInt32(value); in SetIsRevoked() local
67 Int32LSL(oldValue, Int32(JSProxy::IsRevokedBits::START_BIT))); in SetIsRevoked()

Completed in 17 milliseconds

12