Home
last modified time | relevance | path

Searched refs:srcArray (Results 1 – 12 of 12) sorted by relevance

/arkcompiler/ets_runtime/ecmascript/
Dtagged_array.cpp166 void TaggedArray::RemoveElementByIndex(const JSThread *thread, JSHandle<TaggedArray> &srcArray, in RemoveElementByIndex() argument
174 auto *addr = reinterpret_cast<JSTaggedType *>(ToUintPtr(srcArray->GetData()) + offset); in RemoveElementByIndex()
182 srcArray->Set(thread, index, srcArray->Get(index + 1)); in RemoveElementByIndex()
186 srcArray->Set(thread, effectiveLength - 1, JSTaggedValue::Hole()); in RemoveElementByIndex()
189 void TaggedArray::InsertElementByIndex(const JSThread *thread, JSHandle<TaggedArray> &srcArray, in InsertElementByIndex() argument
193 ASSERT(effectiveLength < srcArray->GetLength()); in InsertElementByIndex()
195 JSTaggedValue oldValue = srcArray->Get(effectiveLength - 1); in InsertElementByIndex()
196 srcArray->Set(thread, effectiveLength, oldValue); in InsertElementByIndex()
199 srcArray->Set(thread, index, value.GetTaggedValue()); in InsertElementByIndex()
Dtagged_array.h80 static void RemoveElementByIndex(const JSThread *thread, JSHandle<TaggedArray> &srcArray,
82 static void InsertElementByIndex(const JSThread *thread, JSHandle<TaggedArray> &srcArray,
/arkcompiler/ets_runtime/ecmascript/js_api/
Djs_api_plain_array.cpp81 void JSAPIPlainArray::AdjustPrimitiveArray(TaggedArray *srcArray, int32_t fromIndex, int32_t toInde… in AdjustPrimitiveArray() argument
85 … ToUintPtr(srcArray->GetData()) + fromIndex * JSTaggedValue::TaggedTypeSize()); in AdjustPrimitiveArray()
87 … ToUintPtr(srcArray->GetData()) + toIndex * JSTaggedValue::TaggedTypeSize()); in AdjustPrimitiveArray()
100 void JSAPIPlainArray::AdjustArray(JSThread *thread, TaggedArray *srcArray, int32_t fromIndex, in AdjustArray() argument
108 JSTaggedValue value = srcArray->Get(idx); in AdjustArray()
109 srcArray->Set(thread, idx + 1, value); in AdjustArray()
114 if (srcArray->IsGeneralNewAndNotMarking(thread)) { in AdjustArray()
115 AdjustPrimitiveArray(srcArray, fromIndex, toIndex); in AdjustArray()
118 … ToUintPtr(srcArray->GetData()) + fromIndex * JSTaggedValue::TaggedTypeSize()); in AdjustArray()
121 srcArray->Set(thread, dstIndex, JSTaggedValue(*srcPtr)); in AdjustArray()
[all …]
Djs_api_plain_array.h63 void AdjustArray(JSThread *thread, TaggedArray *srcArray, int32_t fromIndex, int32_t toIndex,
65 void AdjustPrimitiveArray(TaggedArray *srcArray, int32_t fromIndex, int32_t toIndex);
Djs_api_lightweightset.cpp385 void JSAPILightWeightSet::AdjustArray(JSThread *thread, JSHandle<TaggedArray> srcArray, uint32_t fr… in AdjustArray() argument
392 JSTaggedValue value = srcArray->Get(idx); in AdjustArray()
393 srcArray->Set(thread, idx + 1, value); in AdjustArray()
401 JSTaggedValue value = srcArray->Get(fromIndex + i); in AdjustArray()
402 srcArray->Set(thread, toIndex + i, value); in AdjustArray()
404 srcArray->Set(thread, toIndex + i, JSTaggedValue::Hole()); in AdjustArray()
Djs_api_lightweightset.h48 …void AdjustArray(JSThread *thread, JSHandle<TaggedArray> srcArray, uint32_t fromIndex, uint32_t to…
/arkcompiler/runtime_core/static_core/plugins/ets/runtime/types/
Dets_string_builder.cpp131 coretypes::Array *srcArray = reinterpret_cast<EtsArray *>(obj)->GetCoreType(); in ReconstructStringAsMUtf8() local
132 uint32_t n = srcArray->GetLength(); in ReconstructStringAsMUtf8()
135 dstData[j] = srcArray->GetPrimitive<uint16_t>(sizeof(uint16_t) * j); in ReconstructStringAsMUtf8()
157 coretypes::Array *srcArray = reinterpret_cast<EtsCharArray *>(obj)->GetCoreType(); in ReconstructStringAsUtf16() local
158 auto *srcData = reinterpret_cast<EtsChar *>(srcArray->GetData()); in ReconstructStringAsUtf16()
159 uint32_t n = srcArray->GetLength(); in ReconstructStringAsUtf16()
/arkcompiler/ets_runtime/ecmascript/base/
Dtyped_array_helper.cpp390 JSHandle<JSTaggedValue> srcArray = BuiltinsBase::GetCallArg(argv, 0); in CreateFromTypedArray() local
391 JSHandle<JSTypedArray> srcObj(srcArray); in CreateFromTypedArray()
442 ContentType srcArrayContentType = JSHandle<JSTypedArray>::Cast(srcArray)->GetContentType(); in CreateFromTypedArray()
506 JSHandle<JSTaggedValue> srcArray) in CheckBufferAndType() argument
519 ContentType srcArrayContentType = JSHandle<JSTypedArray>::Cast(srcArray)->GetContentType(); in CheckBufferAndType()
573 JSHandle<JSTaggedValue> srcArray = BuiltinsBase::GetCallArg(argv, 0); in CreateSharedFromTypedArray() local
574 JSHandle<JSTypedArray> srcObj(srcArray); in CreateSharedFromTypedArray()
575 JSTaggedValue buffer = GetTypedArrayBuffer(argv, srcObj, srcArray->IsSharedTypedArray()); in CreateSharedFromTypedArray()
604 if (arrayType == srcType && srcArray->IsSharedTypedArray()) { in CreateSharedFromTypedArray()
612 … JSTaggedValue checkResult = CheckBufferAndType(srcData.GetTaggedValue(), thread, obj, srcArray); in CreateSharedFromTypedArray()
/arkcompiler/ets_runtime/ecmascript/containers/
Dcontainers_lightweightset.cpp530 JSHandle<TaggedArray> srcArray(thread, lightweightset->GetValues()); in ToArray() local
532 if (srcArray.GetTaggedValue().IsCOWArray()) { in ToArray()
533 array->SetElements(thread, srcArray.GetTaggedValue()); in ToArray()
537 auto newElements = factory->CopyArray(srcArray, srcArray->GetLength(), srcArray->GetLength(), in ToArray()
/arkcompiler/ets_runtime/ecmascript/compiler/builtins/
Dbuiltins_typedarray_stub_builder.cpp2216 GateRef srcArray = GetCallArg0(numArgs); in Set() local
2217 BRANCH(IsEcmaObject(srcArray), &srcArrayIsEcmaObj, slowPath); in Set()
2219 BRANCH(IsTypedArray(srcArray), &srcArrayIsTypedArray, slowPath); in Set()
2222 GateRef srcType = GetObjectType(LoadHClass(srcArray)); in Set()
2228 GateRef srcBuffer = GetViewedArrayBuffer(srcArray); in Set()
2232 GateRef srcLen = ZExtInt32ToInt64(GetArrayLength(srcArray)); in Set()
2243 … { srcArray, thisValue, Int32(0), TruncInt64ToInt32(*realOffset), TruncInt64ToInt32(srcLen), in Set()
2259 … GateRef srcValue = FastGetPropertyByIndex(glue, srcArray, TruncInt64ToInt32(*startIndex), in Set()
2260 GetObjectType(LoadHClass(srcArray))); in Set()
/arkcompiler/ets_runtime/ecmascript/stubs/
Druntime_stubs.h158 …static void CopyTypedArrayBuffer(JSTypedArray *srcArray, JSTypedArray *targetArray, int32_t srcSta…
Druntime_stubs.cpp223 void RuntimeStubs::CopyTypedArrayBuffer(JSTypedArray *srcArray, JSTypedArray *targetArray, int32_t … in CopyTypedArrayBuffer() argument
227 JSTaggedValue srcBuffer = srcArray->GetViewedArrayBufferOrByteArray(); in CopyTypedArrayBuffer()
229 …uint32_t srcByteIndex = static_cast<uint32_t>(srcStartPos * elementSize) + srcArray->GetByteOffset… in CopyTypedArrayBuffer()