/arkcompiler/ets_runtime/test/fuzztest/typedarrayref_fuzzer/ |
H A D | typedarrayref_fuzzer.cpp | 34 constexpr int byteOffset = 5; in TypedArrayrefArrayLengthFuzzerTest() local 37 Local<Int8ArrayRef> typedArray = Int8ArrayRef::New(vm, arrayBuffer, byteOffset, length); in TypedArrayrefArrayLengthFuzzerTest() 51 constexpr int byteOffset = 5; in TypedArrayrefByteOffSetFuzzerTest() local 54 Local<Int8ArrayRef> typedArray = Int8ArrayRef::New(vm, arrayBuffer, byteOffset, length); in TypedArrayrefByteOffSetFuzzerTest() 68 constexpr int byteOffset = 5; in TypedArrayrefGetArrayBufferFuzzerTest() local 71 Local<Int8ArrayRef> typedArray = Int8ArrayRef::New(vm, arrayBuffer, byteOffset, length); in TypedArrayrefGetArrayBufferFuzzerTest()
|
/arkcompiler/ets_runtime/test/fuzztest/dataviewref_fuzzer/ |
H A D | dataviewref_fuzzer.cpp | 32 const uint32_t byteOffset = 5; in DataViewRefByteOffSetFuzzTest() local 34 Local<DataViewRef> dataView = DataViewRef::New(vm, arrayBuffer, byteOffset, byteLength); in DataViewRefByteOffSetFuzzTest() 50 const uint32_t byteOffset = 5; in DataViewRefByteLengthFuzzTest() local 52 Local<DataViewRef> dataView = DataViewRef::New(vm, arrayBuffer, byteOffset, byteLength); in DataViewRefByteLengthFuzzTest() 68 const uint32_t byteOffset = 5; in DataViewRefGetArrayBufferFuzzTest() local 70 Local<DataViewRef> dataView = DataViewRef::New(vm, arrayBuffer, byteOffset, byteLength); in DataViewRefGetArrayBufferFuzzTest()
|
/arkcompiler/ets_runtime/ecmascript/base/tests/ |
H A D | atomic_helper_test.cpp | 53 uint32_t byteOffset = 7; in HWTEST_F_L0() local 62 array->SetByteOffset(byteOffset); in HWTEST_F_L0() 71 EXPECT_EQ(index0, 0 * sizeof(int8_t) + byteOffset); in HWTEST_F_L0() 72 EXPECT_EQ(index1, 1 * sizeof(int8_t) + byteOffset); in HWTEST_F_L0() 73 EXPECT_EQ(index2, 2 * sizeof(int8_t) + byteOffset); in HWTEST_F_L0() 83 uint32_t byteOffset = 7; in HWTEST_F_L0() local 92 array->SetByteOffset(byteOffset); in HWTEST_F_L0()
|
/arkcompiler/runtime_core/static_core/plugins/ets/runtime/types/ |
H A D | ets_shared_memory.cpp | 148 EtsSharedMemory::WaitResult Wait(EtsSharedMemory *mem, uint32_t byteOffset, IntegerType expectedValue, in Wait() argument 159 auto witnessedValue = AssembleFromBytes<IntegerType, UIntegerType>(*(thisHandle.GetPtr()), byteOffset); in Wait() 165 auto waiter = EtsSharedMemory::Waiter(byteOffset); in Wait() 192 EtsSharedMemory::WaitResult EtsSharedMemory::WaitI32(uint32_t byteOffset, int32_t expectedValue, in WaitI32() argument 195 return Wait<int32_t, uint32_t>(this, byteOffset, expectedValue, timeout); in WaitI32() 198 EtsSharedMemory::WaitResult EtsSharedMemory::WaitI64(uint32_t byteOffset, int64_t expectedValue, in WaitI64() argument 201 return Wait<int64_t, uint64_t>(this, byteOffset, expectedValue, timeout); in WaitI64() 204 int32_t EtsSharedMemory::NotifyI32(uint32_t byteOffset, std::optional<uint32_t> count) in NotifyI32() argument 220 if (waiter->GetOffset() == byteOffset) { in NotifyI32()
|
/arkcompiler/runtime_core/static_core/plugins/ets/runtime/intrinsics/ |
H A D | escompat_Atomics.cpp | 222 extern "C" int32_t SharedMemoryWaitI32(EtsSharedMemory *mem, int32_t byteOffset, int32_t expectedValue) in SharedMemoryWaitI32() argument 224 auto result = mem->WaitI32(byteOffset, expectedValue, std::nullopt); in SharedMemoryWaitI32() 228 extern "C" int32_t SharedMemoryWaitI64(EtsSharedMemory *mem, int32_t byteOffset, int64_t expectedValue) in SharedMemoryWaitI64() argument 230 auto result = mem->WaitI64(byteOffset, expectedValue, std::nullopt); in SharedMemoryWaitI64() 234 extern "C" int32_t SharedMemoryTimedWaitI32(EtsSharedMemory *mem, int32_t byteOffset, int32_t expectedValue, int64_t ms) in SharedMemoryTimedWaitI32() argument 238 auto result = mem->WaitI32(byteOffset, expectedValue, std::optional(uMs)); in SharedMemoryTimedWaitI32() 242 extern "C" int32_t SharedMemoryTimedWaitI64(EtsSharedMemory *mem, int32_t byteOffset, int64_t expectedValue, int64_t ms) in SharedMemoryTimedWaitI64() argument 252 auto result = hmem->WaitI64(byteOffset, expectedValue, std::optional(uMs)); in SharedMemoryTimedWaitI64() 256 extern "C" int32_t SharedMemoryNotify(EtsSharedMemory *mem, int32_t byteOffset) in SharedMemoryNotify() argument 258 return mem->NotifyI32(byteOffset, st in SharedMemoryNotify() 261 SharedMemoryBoundedNotify(EtsSharedMemory *mem, int32_t byteOffset, int32_t count) SharedMemoryBoundedNotify() argument [all...] |
/arkcompiler/runtime_core/static_core/libpandafile/ |
H A D | bytecode_emitter.cpp | 78 size_t byteOffset = offset / BIT_8; in EmitImpl() local 83 buf[byteOffset] |= static_cast<uint8_t>(static_cast<uint8_t>(val & BITMASK_4) << bitOffset); in EmitImpl() 88 buf[byteOffset] = val; in EmitImpl() 93 buf[byteOffset] = val & BYTEMASK; in EmitImpl() 94 buf[byteOffset + 1] = val >> BIT_8; in EmitImpl() 100 buf[byteOffset + i] = (val >> (i * BIT_8)) & BYTEMASK; in EmitImpl() 107 buf[byteOffset + i] = (val >> (i * BIT_8)) & BYTEMASK; in EmitImpl()
|
/arkcompiler/ets_runtime/ecmascript/napi/include/ |
H A D | jsnapi_expo.h | 621 size_t *byteOffset); 1132 static Local<Int8ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length); 1138 int32_t byteOffset, int32_t length); 1143 static Local<Uint8ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length); 1149 int32_t byteOffset, int32_t length); 1154 static Local<Uint8ClampedArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, 1160 static Local<Int16ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length); 1166 int32_t byteOffset, int32_t length); 1171 static Local<Uint16ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, 1178 int32_t byteOffset, int32_ [all...] |
/arkcompiler/ets_runtime/ecmascript/napi/ |
H A D | jsnapi.cpp | 148 const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length) \ 161 info->SetCallArg(arrayBuffer.GetTaggedValue(), JSTaggedValue(byteOffset), JSTaggedValue(length)); \ 174 const EcmaVM *vm, Local<SendableArrayBufferRef> buffer, int32_t byteOffset, int32_t length) \ 187 info->SetCallArg(arrayBuffer.GetTaggedValue(), JSTaggedValue(byteOffset), JSTaggedValue(length)); \
|
H A D | jsnapi_expo.cpp | 1120 size_t *byteOffset) in GetDataViewInfo() 1147 if (byteOffset) { in GetDataViewInfo() 1148 *byteOffset = dataView->GetByteOffset(); in GetDataViewInfo() 1169 const EcmaVM *vm, Local<ArrayBufferRef> arrayBuffer, uint32_t byteOffset, uint32_t byteLength) in New() 1176 JSHandle<JSDataView> dataView = factory->NewJSDataView(buffer, byteOffset, byteLength); in New() 1115 GetDataViewInfo(const EcmaVM *vm, bool &isDataView, size_t *byteLength, void **data, JSValueRef **arrayBuffer, size_t *byteOffset) GetDataViewInfo() argument 1168 New( const EcmaVM *vm, Local<ArrayBufferRef> arrayBuffer, uint32_t byteOffset, uint32_t byteLength) New() argument
|
/arkcompiler/ets_runtime/ecmascript/builtins/ |
H A D | builtins_sendable_arraybuffer.cpp | 332 void *BuiltinsSendableArrayBuffer::GetDataPointFromBuffer(JSTaggedValue arrBuf, uint32_t byteOffset) in GetDataPointFromBuffer() argument 335 return reinterpret_cast<void *>(ToUintPtr(ByteArray::Cast(arrBuf.GetTaggedObject())->GetData()) + byteOffset); in GetDataPointFromBuffer() 345 ->GetExternalPointer()) + byteOffset); in GetDataPointFromBuffer()
|
H A D | builtins_sendable_arraybuffer.h | 84 static void *GetDataPointFromBuffer(JSTaggedValue arrBuf, uint32_t byteOffset = 0);
|
H A D | builtins_arraybuffer.h | 114 static void *GetDataPointFromBuffer(JSTaggedValue arrBuf, uint32_t byteOffset = 0);
|
H A D | builtins_arraybuffer.cpp | 775 void *BuiltinsArrayBuffer::GetDataPointFromBuffer(JSTaggedValue arrBuf, uint32_t byteOffset) in GetDataPointFromBuffer() argument 778 return reinterpret_cast<void *>(ToUintPtr(ByteArray::Cast(arrBuf.GetTaggedObject())->GetData()) + byteOffset); in GetDataPointFromBuffer() 793 ->GetExternalPointer()) + byteOffset); in GetDataPointFromBuffer()
|
/arkcompiler/ets_runtime/ecmascript/napi/test/ |
H A D | jsnapi_sample.cpp | 1837 int32_t byteOffset = 5; // byte offset = 5 in HWTEST_F_L0() local 1839 Local<Int8ArrayRef> typedArray = Int8ArrayRef::New(vm_, arrayBuffer, byteOffset, int8ArrayLength); in HWTEST_F_L0() 1862 int32_t byteOffset = 5; // byte offset = 5 in HWTEST_F_L0() local 1864 Local<Uint8ArrayRef> typedArray = Uint8ArrayRef::New(vm_, arrayBuffer, byteOffset, Uint8ArrayLength); in HWTEST_F_L0() 1887 int32_t byteOffset = 5; // byte offset = 5 in HWTEST_F_L0() local 1889 Local<Uint8ClampedArrayRef> typedArray = Uint8ClampedArrayRef::New(vm_, arrayBuffer, byteOffset, uint8ArrLength); in HWTEST_F_L0() 1912 int32_t byteOffset = 4; // byte offset = 4 in HWTEST_F_L0() local 1914 Local<Int16ArrayRef> typedArray = Int16ArrayRef::New(vm_, arrayBuffer, byteOffset, int16ArrayLength); in HWTEST_F_L0() 1937 int32_t byteOffset = 4; // byte offset = 4 in HWTEST_F_L0() local 1939 Local<Uint16ArrayRef> typedArray = Uint16ArrayRef::New(vm_, arrayBuffer, byteOffset, uint16ArrayLengt in HWTEST_F_L0() 1962 int32_t byteOffset = 4; // byte offset = 4 HWTEST_F_L0() local 1987 int32_t byteOffset = 4; // byte offset = 4 HWTEST_F_L0() local 2012 int32_t byteOffset = 4; // byte offset = 4 HWTEST_F_L0() local 2037 int32_t byteOffset = 8; // byte offset = 8 HWTEST_F_L0() local 2062 int32_t byteOffset = 8; // byte offset = 8 HWTEST_F_L0() local 2087 int32_t byteOffset = 8; // byte offset = 8 HWTEST_F_L0() local 2106 int32_t byteOffset = 5; // byte offset = 5 HWTEST_F_L0() local [all...] |
H A D | ffi_workload.cpp | 1921 int32_t byteOffset = 4; in HWTEST_F_L0() local 1925 Float32ArrayRef::New(vm_, buffer, byteOffset, length); in HWTEST_F_L0() 1937 int32_t byteOffset = 4; in HWTEST_F_L0() local 1941 Float64ArrayRef::New(vm_, buffer, byteOffset, length); in HWTEST_F_L0() 1953 int32_t byteOffset = 4; in HWTEST_F_L0() local 1957 BigInt64ArrayRef::New(vm_, buffer, byteOffset, length); in HWTEST_F_L0() 1969 int32_t byteOffset = 4; in HWTEST_F_L0() local 1973 BigUint64ArrayRef::New(vm_, buffer, byteOffset, length); in HWTEST_F_L0() 3632 int32_t byteOffset = 0; // 0 = length in HWTEST_F_L0() local 3634 Local<Uint8ClampedArrayRef> object = Uint8ClampedArrayRef::New(vm_, buffer, byteOffset, lengt in HWTEST_F_L0() 3662 int32_t byteOffset = 4; // 4 = offset HWTEST_F_L0() local 5666 int32_t byteOffset = 4; // 4 = Offset HWTEST_F_L0() local 5696 int32_t byteOffset = 4; // 4 = Offset HWTEST_F_L0() local [all...] |
/arkcompiler/ets_runtime/test/moduletest/typearray/ |
H A D | typearray.js | 1105 print(typedd3.byteOffset); 1150 print(typedd10.byteOffset); 1201 print(target15.byteOffset);
|
/arkcompiler/ets_runtime/ecmascript/base/ |
H A D | typed_array_helper.cpp | 710 // es11 22.2.4.5 TypedArray ( buffer [ , byteOffset [ , length ] ] ) 718 // 6. Let offset be ? ToIndex(byteOffset). in CreateFromArrayBuffer() 720 JSHandle<JSTaggedValue> byteOffset = BuiltinsBase::GetCallArg(argv, 1); in CreateFromArrayBuffer() local 721 JSTaggedNumber index = JSTaggedValue::ToIndex(thread, byteOffset); in CreateFromArrayBuffer() 776 // es11 22.2.4.5 TypedArray ( buffer [ , byteOffset [ , length ] ] ) 785 // 6. Let offset be ? ToIndex(byteOffset). in CreateFromSendableArrayBuffer() 787 JSHandle<JSTaggedValue> byteOffset = BuiltinsBase::GetCallArg(argv, 1); in CreateFromSendableArrayBuffer() local 788 JSTaggedNumber index = JSTaggedValue::ToIndex(thread, byteOffset); in CreateFromSendableArrayBuffer()
|
/arkcompiler/ets_runtime/ecmascript/serializer/tests/ |
H A D | serializer_test.cpp | 720 uint32_t byteOffset = resJSInt8Array->GetByteOffset(); in TypedArrayTest1() local 729 EXPECT_EQ(byteOffset, 0) << "Not Same ByteOffset"; in TypedArrayTest1() 759 uint32_t byteOffset = resJSInt8Array->GetByteOffset(); in TypedArrayTest2() local 768 EXPECT_EQ(byteOffset, 0) << "Not Same ByteOffset"; in TypedArrayTest2() 2128 int byteOffset = 0; in HWTEST_F_L0() local 2129 int arrayLength = (byteLength - byteOffset) / (sizeof(int8_t)); in HWTEST_F_L0() 2131 int8Array->SetByteOffset(byteOffset); in HWTEST_F_L0() 2165 int byteOffset = 0; in HWTEST_F_L0() local 2166 int arrayLength = (byteLength - byteOffset) / (sizeof(int8_t)); in HWTEST_F_L0() 2168 int8Array->SetByteOffset(byteOffset); in HWTEST_F_L0() [all...] |
/arkcompiler/ets_runtime/ecmascript/builtins/tests/ |
H A D | builtins_dataview_test.cpp | 227 // new DataView(new ArrayBuffer(10), 1).byteOffset 228 HWTEST_F_L0(BuiltinsDataViewTest, byteOffset) in HWTEST_F_L0()
|
/arkcompiler/ets_runtime/ecmascript/compiler/ |
H A D | typed_hcr_lowering.cpp | 1188 GateRef byteOffset = in BuildNotOnHeapTypedArrayLoadElement() local 1190 GateRef result = builder_.Load(type, block, builder_.PtrAdd(offset, byteOffset)); in BuildNotOnHeapTypedArrayLoadElement() 1215 GateRef byteOffset = in BuildTypedArrayLoadElement() local 1217 result = builder_.Load(type, block, builder_.PtrAdd(offset, byteOffset)); in BuildTypedArrayLoadElement() 1373 GateRef byteOffset = in BuildNotOnHeapTypedArrayStoreElement() local 1376 builder_.PtrAdd(offset, byteOffset), value); in BuildNotOnHeapTypedArrayStoreElement() 1398 GateRef byteOffset = in BuildTypedArrayStoreElement() local 1401 builder_.PtrAdd(offset, byteOffset), value); in BuildTypedArrayStoreElement()
|
H A D | stub_builder-inl.h | 3132 inline void StubBuilder::SetByteOffset(GateRef glue, GateRef typedArray, GateRef byteOffset) in SetByteOffset() argument 3135 Store(VariableType::INT8(), glue, typedArray, offset, byteOffset, MemoryAttribute::NoBarrier()); in SetByteOffset() local
|
H A D | typed_native_inline_lowering.cpp | 1365 GateRef byteOffset = builder_.IntPtr(JSDataView::BYTE_OFFSET_OFFSET); in LowerDataViewProtoFunc() local 1366 GateRef offset = builder_.Load(VariableType::INT32(), thisobj, byteOffset); in LowerDataViewProtoFunc()
|
/arkcompiler/toolchain/tooling/agent/ |
H A D | runtime_impl.cpp | 757 int32_t byteOffset = static_cast<int32_t>(dataViewRef->ByteOffset()); in GetDataViewValue() local 762 jsValueRef = NumberRef::New(vm_, byteOffset); in GetDataViewValue() 763 SetKeyValue(jsValueRef, outPropertyDesc, "byteOffset"); in GetDataViewValue()
|
/arkcompiler/ets_runtime/ecmascript/compiler/builtins/ |
H A D | builtins_typedarray_stub_builder.cpp | 3330 GateRef byteOffset = GetArgFromArgv(IntPtr(base::BuiltinsBase::ArgsPosition::SECOND), numArgs, true);
in CreateFromArrayBuffer() local 3331 GateRef index = ToIndex(glue, byteOffset);
in CreateFromArrayBuffer()
|
/arkcompiler/ets_frontend/es2panda/test/compiler/js/ |
H A D | cocos_worker_test.js | 24069 const e = new DataView(t.buffer, t.byteOffset, t.byteLength); 24077 const r = new Uint8Array(e.buffer, s + e.byteOffset, n); 24083 return e.from(t.buffer, t.byteOffset, t.byteLength).toString(); 24100 l.push(new Uint8Array(e.buffer, s + e.byteOffset, t)); 24237 return new globalThis[s](this._mainBinChunk.buffer, this._mainBinChunk.byteOffset + e, i); 25587 const s = new DataView(i.buffer, i.byteOffset, i.byteLength); 25975 const s = new DataView(i.buffer, i.byteOffset, i.byteLength); [all...] |