/arkcompiler/runtime_core/static_core/plugins/ets/stdlib/escompat/ |
D | DataView.ets | 24 public readonly byteOffset: int 37 * @param byteOffset offset to start from 40 public constructor(buffer: Buffer, byteOffset: int) { 41 this(buffer, byteOffset, buffer.getByteLength() - byteOffset) 47 * @param byteOffset offset to start from 50 public constructor(buffer: ArrayBuffer, byteOffset: number) { 51 this(buffer, byteOffset as int) 57 * @param byteOffset offset to start from 61 public constructor(buffer: ArrayBuffer, byteOffset: number, byteLength: number) { 62 this(buffer, byteOffset as int, byteLength as int) [all …]
|
D | Atomics.ets | 61 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 75 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 89 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 104 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 117 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 128 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 142 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 154 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 168 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int8Array.BYTES_P… 263 …let indexedPosition = Atomics.validateAtomicAccess(typedArray.byteOffset as int, Int32Array.BYTES_… [all …]
|
D | ArrayBuffer.ets | 238 internal native atomicWaitI32(byteOffset: int, value: int): int; 240 internal native atomicWaitI64(byteOffset: int, value: long): int; 242 internal native atomicTimedWaitI32(byteOffset: int, value: int, timeout: long): int; 244 internal native atomicTimedWaitI64(byteOffset: int, value: long, timeout: long): int; 246 internal native atomicNotify(byteOffset: int): int; 248 internal native atomicBoundedNotify(byteOffset: int, count: int): int;
|
D | TypedUArrays.ets | 32 this.byteOffset = 0 37 * Creates an Uint8ClampedArray with respect to data, byteOffset and length. 41 * @param byteOffset byte offset from begin of the buf 45 public constructor(buf: ArrayBuffer, byteOffset: number, length: number) { 46 this(buf, byteOffset as int, length as int) 50 * Creates an Uint8ClampedArray with respect to data, byteOffset and length. 54 * @param byteOffset byte offset from begin of the buf 58 /* public */ internal constructor(buf: ArrayBuffer, byteOffset: int, length: int) { 62 if (byteOffset % Uint8ClampedArray.BYTES_PER_ELEMENT != 0) { 63 … throw new RangeError("byteOffset should be multiple of 1 as Uint8ClampedArray.BYTES_PER_ELEMENT") [all …]
|
D | TypedArrays.ets | 34 * Creates an Int8Array with respect to data, byteOffset and length. 38 * @param byteOffset byte offset from begin of the buf 42 public constructor(buf: Buffer, byteOffset: number, length: number) { 43 this(buf, byteOffset as int, length as int) 47 * Creates an Int8Array with respect to data, byteOffset and length. 51 * @param byteOffset byte offset from begin of the buf 55 public constructor(buf: Buffer, byteOffset: int, length: int) { 59 if (byteOffset % Int8Array.BYTES_PER_ELEMENT as int != 0) { 60 … throw new RangeError("byteOffset should be multiple of 1 as Int8Array.BYTES_PER_ELEMENT") 66 this.byteLength = buf.getByteLength() - byteOffset [all …]
|
/arkcompiler/runtime_core/static_core/plugins/ets/templates/stdlib/ |
D | DataView.ets.j2 | 24 public readonly byteOffset: int 37 * @param byteOffset offset to start from 40 public constructor(buffer: Buffer, byteOffset: int) { 41 this(buffer, byteOffset, buffer.getByteLength() - byteOffset) 47 * @param byteOffset offset to start from 50 public constructor(buffer: ArrayBuffer, byteOffset: number) { 51 this(buffer, byteOffset as int) 57 * @param byteOffset offset to start from 61 public constructor(buffer: ArrayBuffer, byteOffset: number, byteLength: number) { 62 this(buffer, byteOffset as int, byteLength as int) [all …]
|
D | typedArray.ets.j2 | 47 * Creates an {{N}}Array with respect to data, byteOffset and length. 51 * @param byteOffset byte offset from begin of the buf 55 public constructor(buf: Buffer, byteOffset: number, length: number) { 56 this(buf, byteOffset as int, length as int) 60 * Creates an {{N}}Array with respect to data, byteOffset and length. 64 * @param byteOffset byte offset from begin of the buf 68 public constructor(buf: Buffer, byteOffset: int, length: int) { 73 if (byteOffset % {{N}}Array.BYTES_PER_ELEMENT as int != 0) { 74 … throw new RangeError("byteOffset should be multiple of {{S}} as {{N}}Array.BYTES_PER_ELEMENT") 80 this.byteLength = buf.getByteLength() - byteOffset [all …]
|
D | typedUArray.ets.j2 | 39 this.byteOffset = 0 44 * Creates an {{N}}Array with respect to data, byteOffset and length. 48 * @param byteOffset byte offset from begin of the buf 52 public constructor(buf: ArrayBuffer, byteOffset: number, length: number) { 53 this(buf, byteOffset as int, length as int) 57 * Creates an {{N}}Array with respect to data, byteOffset and length. 61 * @param byteOffset byte offset from begin of the buf 65 {{isNonCompat}} constructor(buf: ArrayBuffer, byteOffset: int, length: int) { 70 if (byteOffset % {{N}}Array.BYTES_PER_ELEMENT != 0) { 71 … throw new RangeError("byteOffset should be multiple of {{S}} as {{N}}Array.BYTES_PER_ELEMENT") [all …]
|
/arkcompiler/runtime_core/static_core/plugins/ets/runtime/intrinsics/ |
D | escompat_Atomics.cpp | 139 extern "C" int32_t SharedMemoryWaitI32(EtsSharedMemory *mem, int32_t byteOffset, int32_t expectedVa… in SharedMemoryWaitI32() argument 141 auto result = mem->WaitI32(byteOffset, expectedValue, std::nullopt); in SharedMemoryWaitI32() 145 extern "C" int32_t SharedMemoryWaitI64(EtsSharedMemory *mem, int32_t byteOffset, int64_t expectedVa… in SharedMemoryWaitI64() argument 147 auto result = mem->WaitI64(byteOffset, expectedValue, std::nullopt); in SharedMemoryWaitI64() 151 extern "C" int32_t SharedMemoryTimedWaitI32(EtsSharedMemory *mem, int32_t byteOffset, int32_t expec… in SharedMemoryTimedWaitI32() argument 155 auto result = mem->WaitI32(byteOffset, expectedValue, std::optional(uMs)); in SharedMemoryTimedWaitI32() 159 extern "C" int32_t SharedMemoryTimedWaitI64(EtsSharedMemory *mem, int32_t byteOffset, int64_t expec… in SharedMemoryTimedWaitI64() argument 169 auto result = hmem->WaitI64(byteOffset, expectedValue, std::optional(uMs)); in SharedMemoryTimedWaitI64() 173 extern "C" int32_t SharedMemoryNotify(EtsSharedMemory *mem, int32_t byteOffset) in SharedMemoryNotify() argument 175 return mem->NotifyI32(byteOffset, std::nullopt); in SharedMemoryNotify() [all …]
|
/arkcompiler/ets_runtime/test/fuzztest/dataviewref_fuzzer/ |
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/test/fuzztest/typedarrayref_fuzzer/ |
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/ecmascript/ts_types/ |
D | lib_ark_builtins.d.ts | 738 byteOffset: number; 748 constructor(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint8ClampedArray; 826 byteOffset: number; 836 constructor(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint8Array; 914 byteOffset: number; 924 constructor(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Int8Array; 1002 byteOffset: number; 1012 constructor(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint16Array; 1090 byteOffset: number; 1100 constructor(buffer: ArrayBufferLike, byteOffset?: number, length?: number): Uint32Array; [all …]
|
/arkcompiler/runtime_core/static_core/plugins/ets/runtime/types/ |
D | ets_shared_memory.cpp | 165 EtsSharedMemory::WaitResult Wait(EtsSharedMemory *mem, uint32_t byteOffset, IntegerType expectedVal… in Wait() argument 176 … witnessedValue = AssembleFromBytes<IntegerType, UIntegerType>(*(thisHandle.GetPtr()), byteOffset); in Wait() 182 auto waiter = EtsSharedMemory::Waiter(byteOffset); in Wait() 209 EtsSharedMemory::WaitResult EtsSharedMemory::WaitI32(uint32_t byteOffset, int32_t expectedValue, in WaitI32() argument 212 return Wait<int32_t, uint32_t>(this, byteOffset, expectedValue, timeout); in WaitI32() 215 EtsSharedMemory::WaitResult EtsSharedMemory::WaitI64(uint32_t byteOffset, int64_t expectedValue, in WaitI64() argument 218 return Wait<int64_t, uint64_t>(this, byteOffset, expectedValue, timeout); in WaitI64() 221 int32_t EtsSharedMemory::NotifyI32(uint32_t byteOffset, std::optional<uint32_t> count) in NotifyI32() argument 237 if (waiter->GetOffset() == byteOffset) { in NotifyI32()
|
/arkcompiler/ets_runtime/ecmascript/base/tests/ |
D | atomic_helper_test.cpp | 76 uint32_t byteOffset = 7; in HWTEST_F_L0() local 85 array->SetByteOffset(byteOffset); in HWTEST_F_L0() 94 EXPECT_EQ(index0, 0 * sizeof(int8_t) + byteOffset); in HWTEST_F_L0() 95 EXPECT_EQ(index1, 1 * sizeof(int8_t) + byteOffset); in HWTEST_F_L0() 96 EXPECT_EQ(index2, 2 * sizeof(int8_t) + byteOffset); in HWTEST_F_L0() 106 uint32_t byteOffset = 7; in HWTEST_F_L0() local 115 array->SetByteOffset(byteOffset); in HWTEST_F_L0()
|
/arkcompiler/runtime_core/static_core/libpandafile/ |
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/runtime_core/static_core/plugins/ets/tests/stdlib-templates/utils/ |
D | test_core_typeduarray.j2 | 75 if(target.length as int == 0 && target.byteOffset as int == 0) return 0; 88 if(target.length as int == 0 && target.byteOffset as int == 0) return 0; 101 …if(target.byteLength as int == 5*{{.item.primitiveSizeBytes}} && target.byteOffset as int == 0) re… 116 if(target.length as int == 0 && target.byteOffset as int == 0) return 0; 129 …if(target.byteLength as int == 5*{{.item.primitiveSizeBytes}} && target.byteOffset as int == 0) re… 144 …if(target.byteLength as int == 5*{{.item.primitiveSizeBytes}} && target.byteOffset as int == 2*{{.… 146 console.println("Error: Actual bytes offset: " + target.byteOffset); 160 …if(target.byteLength as int == 5*{{.item.primitiveSizeBytes}} && target.byteOffset as int == 2*{{.… 162 console.println("Error: Actual bytes offset: " + target.byteOffset); 177 if(target.length as int == 0 && target.byteOffset as int == 0) return 0; [all …]
|
D | test_core_typedarray.j2 | 75 if(target.length as int == 0 && target.byteOffset as int == 0) return 0; 88 if(target.length as int == 0 && target.byteOffset as int == 0) return 0; 101 …if(target.byteLength as int == 5*{{.item.primitiveSizeBytes}} && target.byteOffset as int == 0) re… 116 if(target.length as int == 0 && target.byteOffset as int == 0) return 0; 129 …if(target.byteLength as int == 5*{{.item.primitiveSizeBytes}} && target.byteOffset as int == 0) re… 144 …if(target.byteLength as int == 5*{{.item.primitiveSizeBytes}} && target.byteOffset as int == 2*{{.… 146 console.println("Error: Actual bytes offset: " + target.byteOffset); 160 …if(target.byteLength as int == 5*{{.item.primitiveSizeBytes}} && target.byteOffset as int == 2*{{.… 162 console.println("Error: Actual bytes offset: " + target.byteOffset); 177 if(target.length as int == 0 && target.byteOffset as int == 0) return 0; [all …]
|
/arkcompiler/ets_frontend/ets2panda/linter/test/ |
D | d_ts.ts | 74 byteOffset: 2
|
/arkcompiler/ets_runtime/ecmascript/napi/include/ |
D | jsnapi_expo.h | 891 …8ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length); 896 …8ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length); 901 …Local<Uint8ClampedArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, 907 …6ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length); 912 …tatic Local<Uint16ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, 918 …2ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length); 923 …tatic Local<Uint32ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, 929 …atic Local<Float32ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, 935 …atic Local<Float64ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, 941 …tic Local<BigInt64ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, [all …]
|
/arkcompiler/ets_runtime/ecmascript/napi/ |
D | JSNapi接口说明.md | 314 …Ref> New(const EcmaVM *vm, Local<ArrayBufferRef> arrayBuffer, uint32_t byteOffset,uint32_t byteLen… 324 | byteOffset | uint32_t | �� | �ӵڼ����ֽڿ�ʼд�����ݡ� | 4374 uint32_t byteOffset = obj->ByteOffset(vm); 4406 uint32_t byteOffset = obj->ArrayLength(vm); 4441 Local<ArrayBufferRef> byteOffset = obj->GetArrayBuffer(vm); 5067 static Local<Uint32ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset… 5077 | byteOffset | int32_t | �� | ArrayBuffer�����ָ��λ��ƫ���� | 5101 static Local<Uint8ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset,… 5111 | byteOffset | int32_t | �� | ArrayBuffer�����ָ��λ��ƫ���� | 5642 …4ArrayRef> New(const EcmaVM *vm, Local<ArrayBufferRef> buffer, int32_t byteOffset, int32_t length)… [all …]
|
/arkcompiler/ets_runtime/ecmascript/napi/test/ |
D | jsnapi_sample.cpp | 1851 int32_t byteOffset = 5; // byte offset = 5 in HWTEST_F_L0() local 1853 … Local<Int8ArrayRef> typedArray = Int8ArrayRef::New(vm_, arrayBuffer, byteOffset, int8ArrayLength); in HWTEST_F_L0() 1876 int32_t byteOffset = 5; // byte offset = 5 in HWTEST_F_L0() local 1878 …Local<Uint8ArrayRef> typedArray = Uint8ArrayRef::New(vm_, arrayBuffer, byteOffset, Uint8ArrayLengt… in HWTEST_F_L0() 1901 int32_t byteOffset = 5; // byte offset = 5 in HWTEST_F_L0() local 1903 …Local<Uint8ClampedArrayRef> typedArray = Uint8ClampedArrayRef::New(vm_, arrayBuffer, byteOffset, u… in HWTEST_F_L0() 1926 int32_t byteOffset = 4; // byte offset = 4 in HWTEST_F_L0() local 1928 …Local<Int16ArrayRef> typedArray = Int16ArrayRef::New(vm_, arrayBuffer, byteOffset, int16ArrayLengt… in HWTEST_F_L0() 1951 int32_t byteOffset = 4; // byte offset = 4 in HWTEST_F_L0() local 1953 …Local<Uint16ArrayRef> typedArray = Uint16ArrayRef::New(vm_, arrayBuffer, byteOffset, uint16ArrayLe… in HWTEST_F_L0() [all …]
|
/arkcompiler/runtime_core/static_core/plugins/ets/doc/stdlib/packages/ |
D | escompat.rst | 2269 …ended by the Atomics.wait() calls at the given index. (index = typedArray.byteOffset + offset \* 4) 2309 …ended by the Atomics.wait() calls at the given index. (index = typedArray.byteOffset + offset \* 8) 3377 |nbsp| byteOffset\: :kw:`number`, 3381 | Creates an BigInt64Array with respect to data, byteOffset and length. 3386 - byteOffset\: :kw:`number` byte offset from begin of the buf 3395 …constructor(buf\: :ref:`ArrayBuffer<LeLsLcLoLmLpLaLt.UALrLrLaLyUBLuLfLfLeLr>`, byteOffset\: :kw:`n… 3397 | Creates an BigInt64Array with respect to buf and byteOffset. 3402 - byteOffset\: :kw:`number` byte offset from begin of the buf 4598 - byteOffset\: :kw:`number` 4653 |nbsp| byteOffset\: :kw:`number`, [all …]
|
/arkcompiler/ets_runtime/ecmascript/builtins/ |
D | builtins_arraybuffer.h | 98 static void *GetDataPointFromBuffer(JSTaggedValue arrBuf, uint32_t byteOffset = 0);
|
/arkcompiler/ets_runtime/ecmascript/tests/ |
D | js_serializer_test.cpp | 642 uint32_t byteOffset = resJSInt8Array->GetByteOffset(); in TypedArrayTest1() local 651 EXPECT_EQ(byteOffset, 0) << "Not Same ByteOffset"; in TypedArrayTest1() 681 uint32_t byteOffset = resJSInt8Array->GetByteOffset(); in TypedArrayTest2() local 690 EXPECT_EQ(byteOffset, 0) << "Not Same ByteOffset"; in TypedArrayTest2() 958 uint32_t byteOffset = resJSInt8Array->GetByteOffset(); in TransferJSArrayBufferTest5() local 963 EXPECT_EQ(byteOffset, 0) << "Not Same ByteOffset"; in TransferJSArrayBufferTest5() 1786 int byteOffset = 0; in HWTEST_F_L0() local 1787 int arrayLength = (byteLength - byteOffset) / (sizeof(int8_t)); in HWTEST_F_L0() 1789 int8Array->SetByteOffset(byteOffset); in HWTEST_F_L0() 1819 int byteOffset = 0; in HWTEST_F_L0() local [all …]
|
/arkcompiler/ets_runtime/ecmascript/ |
D | js_serializer.cpp | 768 JSTaggedValue byteOffset(typedArray->GetByteOffset()); in WriteJSTypedArray() local 769 if (!WriteRawData(&byteOffset, sizeof(JSTaggedValue))) { in WriteJSTypedArray() 1734 JSTaggedValue byteOffset; in ReadJSTypedArray() local 1735 if (!ReadJSTaggedValue(&byteOffset) || !byteOffset.IsNumber()) { in ReadJSTypedArray() 1738 typedArray->SetByteOffset(byteOffset.GetNumber()); in ReadJSTypedArray() 1741 if (!ReadJSTaggedValue(&arrayLength) || !byteOffset.IsNumber()) { in ReadJSTypedArray()
|