Home
last modified time | relevance | path

Searched refs:ArrayBuffer (Results 1 – 25 of 64) sorted by relevance

123

/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets_func_tests/escompat/
DArrayBufferTest2.ets19 failures += test(createArrayBufferOfVariousLengths(), "Create ArrayBuffer of Various lengths");
20 failures += test(sliceArrayBufferInt(), "Slice ArrayBuffer with various int parameters");
21 …failures += test(sliceArrayBufferNumberNegativeEnd(), "Slice ArrayBuffer with negative end number …
22 …failures += test(sliceArrayBufferNumberNegativeStart(), "Slice ArrayBuffer with negative start num…
23 …failures += test(sliceArrayBufferNumberStartExceedsLength(), "Slice ArrayBuffer with start number …
24 …failures += test(sliceArrayBufferNumberEndExceedsLength(), "Slice ArrayBuffer with end number para…
25 failures += test(resizeArrayBufferInt(), "Resize ArrayBuffer with various int parameters");
26 failures += test(isViewArrayBuffer(), "isView ArrayBuffer with various parameters");
30 * Check that created empty ArrayBuffer has zero byteLength
33 let a = new ArrayBuffer(0);
[all …]
DArrayBufferTest1.ets19 failures += test(createEmptyArrayBuffer(), "Create empty ArrayBuffer");
20 failures += test(createArrayBufferOfVariousLengths(), "Create ArrayBuffer of Various lengths");
21 failures += test(sliceArrayBufferInt(), "Slice ArrayBuffer with various int parameters");
22 failures += test(isViewArrayBuffer(), "isView ArrayBuffer with various parameters");
26 * Check that created empty ArrayBuffer has zero byteLength
29 let a = new ArrayBuffer(0);
34 * Check created ArrayBuffer with different lengths
37 let a = new ArrayBuffer(10);
43 a = new ArrayBuffer(-1);
55 * Check slice() method of ArrayBuffer with different int parameters
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/interop_js/tests/escompat/array_buffer_js_suites/
Dtest_is_view.js25 TestJSIsView(new ArrayBuffer(LENGTH));
30 ASSERT_TRUE(!ArrayBuffer.isView(arr));
31 ASSERT_TRUE(ArrayBuffer.isView(new Int8Array(arr)));
Dtest_length.js25 TestJSLength(new ArrayBuffer(LENGTH));
30 ASSERT_TRUE(arr instanceof ArrayBuffer);
Dtest_resize.js25 TestJSResize(new ArrayBuffer(LENGTH));
Dtest_slice.js25 TestJSSlice(new ArrayBuffer(LENGTH));
/arkcompiler/runtime_core/static_core/plugins/ets/stdlib/escompat/
DArrayBuffer.ets19 * Either ArrayBuffer or SharedArrayBuffer
31 * JS ArrayBuffer API-compatible class
33 export class ArrayBuffer extends Buffer
36 * Creates ArrayBuffer with size equal to length parameter
38 * @param length size of ArrayBuffer
47 * Creates ArrayBuffer with size equal to length parameter
49 * @param length size of ArrayBuffer
97 return new ArrayBuffer(0)
104 let res = new ArrayBuffer(len);
112 * Creates a new ArrayBuffer with copy of bytes in range [begin;end)
[all …]
DAtomics.ets40 if (buffer instanceof ArrayBuffer) {
63 if (buffer instanceof ArrayBuffer) {
77 if (buffer instanceof ArrayBuffer) {
91 if (buffer instanceof ArrayBuffer) {
106 if (buffer instanceof ArrayBuffer) {
119 if (buffer instanceof ArrayBuffer) {
130 if (buffer instanceof ArrayBuffer) {
144 if (buffer instanceof ArrayBuffer) {
156 if (buffer instanceof ArrayBuffer) {
170 if (buffer instanceof ArrayBuffer) {
[all …]
DTypedUArrays.ets33 this.buffer = new ArrayBuffer(0)
45 public constructor(buf: ArrayBuffer, byteOffset: number, length: number) {
58 /* public */ internal constructor(buf: ArrayBuffer, byteOffset: int, length: int) {
60 …throw new RangeError("ArrayBuffer.byteLength should be multiple of 1 as Uint8ClampedArray.BYTES_PE…
67 …ate Uint8ClampedArray where length * Uint8ClampedArray.BYTES_PER_ELEMENT > ArrayBuffer.byteLength")
82 /* public */ internal constructor(buf: ArrayBuffer, byteOffset: int) {
93 public constructor(buf: ArrayBuffer, byteOffset: number) {
102 public constructor(buf: ArrayBuffer)
117 this.buffer = new ArrayBuffer(this.byteLength)
682 return new Uint8ClampedArray(new ArrayBuffer(0))
[all …]
/arkcompiler/ets_runtime/test/moduletest/ictest/
Dictest.js37 const v2 = ("string").match(ArrayBuffer)
42 this.concat(ArrayBuffer, v2, ArrayBuffer);
/arkcompiler/ets_runtime/test/perform/dataview/
Ddataview.ts22 var buffer = new ArrayBuffer(8);
36 var buffer = new ArrayBuffer(8);
48 var buffer = new ArrayBuffer(8);
/arkcompiler/ets_runtime/test/moduletest/allocatearraybuffer/
Dallocatearraybuffer.js23 var arrayBuffer = Reflect.construct(ArrayBuffer, [16], newTarget);
32 const dataview = new DataView(new ArrayBuffer(64));
/arkcompiler/ets_runtime/test/moduletest/dataview/
Ddataview.js22 const buffer = new ArrayBuffer(16);
28 var buffer1 = new ArrayBuffer(64);
/arkcompiler/runtime_core/static_core/plugins/ets/tests/stdlib-templates/utils/
Dtest_core_typeduarray.j280 let ss = new ArrayBuffer(0); // Buffer 0-bytes length;
93 let ss = new ArrayBuffer(5*{{.item.primitiveSizeBytes}}); // Buffer 5-items length;
108 let ss = new ArrayBuffer(0);
121 let ss = new ArrayBuffer(5*{{.item.primitiveSizeBytes}}); // Buffer 5-items length;
135 let ss = new ArrayBuffer(7*{{.item.primitiveSizeBytes}}); // Buffer 7-items length;
151 let ss = new ArrayBuffer(7*{{.item.primitiveSizeBytes}}); // Buffer 7-items length;
169 let ss = new ArrayBuffer(0);
182 let ss = new ArrayBuffer(5 * {{.item.primitiveSizeBytes}}); // Buffer 5-items length;
198 let ss = new ArrayBuffer(source.length as int * {{.item.primitiveSizeBytes}});
229 let ss = new ArrayBuffer(source.length as int * {{.item.primitiveSizeBytes}});
[all …]
Dtest_core_typedarray.j280 let ss = new ArrayBuffer(0); // Buffer 0-bytes length;
93 let ss = new ArrayBuffer(5*{{.item.primitiveSizeBytes}}); // Buffer 5-items length;
108 let ss = new ArrayBuffer(0);
121 let ss = new ArrayBuffer(5*{{.item.primitiveSizeBytes}}); // Buffer 5-items length;
135 let ss = new ArrayBuffer(7*{{.item.primitiveSizeBytes}}); // Buffer 7-items length;
151 let ss = new ArrayBuffer(7*{{.item.primitiveSizeBytes}}); // Buffer 7-items length;
169 let ss = new ArrayBuffer(0);
182 let ss = new ArrayBuffer(5 * {{.item.primitiveSizeBytes}}); // Buffer 5-items length;
198 let ss = new ArrayBuffer(source.length as int * {{.item.primitiveSizeBytes}});
229 let ss = new ArrayBuffer(source.length as int * {{.item.primitiveSizeBytes}});
[all …]
/arkcompiler/toolchain/tooling/test/testcases/js/
Dexport_variable_second.js38 export var arraybuffer6 = new ArrayBuffer(24);
65 var arraybuffer8 = new ArrayBuffer(24);
/arkcompiler/ets_runtime/test/moduletest/typearray/
Dtypearray.js191 let a1 = new ArrayBuffer(1024*1024*8);
205 const a5 = new Uint8ClampedArray(new ArrayBuffer(1283053413), 9007199254740991);
229 const a8 = new Int8Array(new ArrayBuffer(0x40004141, {"maxByteLength": 0x40004141}));
261 new BigUint64Array(new ArrayBuffer(256), 256, 0x1fffffff)
/arkcompiler/ets_runtime/test/moduletest/hugearray/
Dhugearray_third.js22 let bytes = new Uint8Array(new ArrayBuffer(43584));
/arkcompiler/ets_runtime/test/aottest/tryldglobalbyname_global_object/
Dtryldglobalbyname_global_object.ts487 print(ArrayBuffer);
488 globalThis.ArrayBuffer = "ArrayBuffer";
489 print(ArrayBuffer);
490 delete globalThis.ArrayBuffer;
492 print(ArrayBuffer);
/arkcompiler/ets_frontend/ets2panda/linter/test/
Dlimited_stdlib_api.ts120 ArrayBuffer.isView({});
122 let b = new ArrayBuffer(1);
Dd_ts.ts72 buffer: new ArrayBuffer(0),
/arkcompiler/ets_runtime/test/moduletest/deleteobjproperty/
Ddeleteobjproperty.js23 var l = new ArrayBuffer(400);
/arkcompiler/ets_runtime/test/moduletest/typedarraynan/
Dtypedarraynan.js43 var buffer = new ArrayBuffer(8);
/arkcompiler/runtime_core/static_core/plugins/ets/templates/stdlib/
DtypedUArray.ets.j240 this.buffer = new ArrayBuffer(0)
52 public constructor(buf: ArrayBuffer, byteOffset: number, length: number) {
65 {{isNonCompat}} constructor(buf: ArrayBuffer, byteOffset: int, length: int) {
68 …throw new RangeError("ArrayBuffer.byteLength should be multiple of {{S}} as {{N}}Array.BYTES_PER_E…
75 …attempt to create {{N}}Array where length * {{N}}Array.BYTES_PER_ELEMENT > ArrayBuffer.byteLength")
90 {{isNonCompat}} constructor(buf: ArrayBuffer, byteOffset: int) {
101 public constructor(buf: ArrayBuffer, byteOffset: number) {
110 public constructor(buf: ArrayBuffer)
125 this.buffer = new ArrayBuffer(this.byteLength)
743 return new {{N}}Array(new ArrayBuffer(0))
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/interop_js/tests/escompat/
Descompat.ets345 function ArrayBuffer_TestJSLength(arr: ArrayBuffer): void {
346 assert (arr as Object) instanceof ArrayBuffer;
350 function ArrayBuffer_TestJSIsView(arr: ArrayBuffer): void {
351 assert !ArrayBuffer.isView(arr);
352 assert ArrayBuffer.isView(new Int8Array(arr));
355 function ArrayBuffer_TestJSSlice(arr: ArrayBuffer): void {
360 function ArrayBuffer_TestJSResize(arr: ArrayBuffer): void {
367 function ArrayBuffer_CreateEtsSample(): ArrayBuffer {
368 return new ArrayBuffer(32);

123