Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement SharedArrayBuffer #3384

Merged
merged 4 commits into from
Oct 15, 2023
Merged

Implement SharedArrayBuffer #3384

merged 4 commits into from
Oct 15, 2023

Conversation

jedel1043
Copy link
Member

I'll follow up this PR with some others implementing Atomics, adding the missing example/example docs and adding the missing agent object.

@jedel1043 jedel1043 added enhancement New feature or request builtins PRs and Issues related to builtins/intrinsics labels Oct 14, 2023
@jedel1043 jedel1043 added this to the v0.18.0 milestone Oct 14, 2023
@github-actions
Copy link

Test262 conformance changes

Test result main count PR count difference
Total 95,574 95,574 0
Passed 75,342 75,672 +330
Ignored 19,482 19,152 -330
Failed 750 750 0
Panics 0 0 0
Conformance 78.83% 79.18% +0.35%
Fixed tests (330):
test/language/statements/class/subclass-builtins/subclass-SharedArrayBuffer.js [strict mode] (previously Ignored)
test/language/statements/class/subclass-builtins/subclass-SharedArrayBuffer.js (previously Ignored)
test/language/expressions/class/subclass-builtins/subclass-SharedArrayBuffer.js [strict mode] (previously Ignored)
test/language/expressions/class/subclass-builtins/subclass-SharedArrayBuffer.js (previously Ignored)
test/built-ins/SharedArrayBuffer/negative-length-throws.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/negative-length-throws.js (previously Ignored)
test/built-ins/SharedArrayBuffer/undefined-newtarget-throws.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/undefined-newtarget-throws.js (previously Ignored)
test/built-ins/SharedArrayBuffer/return-abrupt-from-length.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/return-abrupt-from-length.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype-from-newtarget.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype-from-newtarget.js (previously Ignored)
test/built-ins/SharedArrayBuffer/data-allocation-after-object-creation.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/data-allocation-after-object-creation.js (previously Ignored)
test/built-ins/SharedArrayBuffer/length-is-too-large-throws.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/length-is-too-large-throws.js (previously Ignored)
test/built-ins/SharedArrayBuffer/init-zero.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/init-zero.js (previously Ignored)
test/built-ins/SharedArrayBuffer/length.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/length.js (previously Ignored)
test/built-ins/SharedArrayBuffer/toindex-length.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/toindex-length.js (previously Ignored)
test/built-ins/SharedArrayBuffer/allocation-limit.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/allocation-limit.js (previously Ignored)
test/built-ins/SharedArrayBuffer/proto-from-ctor-realm.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/proto-from-ctor-realm.js (previously Ignored)
test/built-ins/SharedArrayBuffer/zero-length.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/zero-length.js (previously Ignored)
test/built-ins/SharedArrayBuffer/newtarget-prototype-is-not-object.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/newtarget-prototype-is-not-object.js (previously Ignored)
test/built-ins/SharedArrayBuffer/is-a-constructor.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/is-a-constructor.js (previously Ignored)
test/built-ins/SharedArrayBuffer/return-abrupt-from-length-symbol.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/return-abrupt-from-length-symbol.js (previously Ignored)
test/built-ins/SharedArrayBuffer/length-is-absent.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/length-is-absent.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/prop-desc.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/prop-desc.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/Symbol.toStringTag.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/Symbol.toStringTag.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/constructor.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/constructor.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/start-default-if-absent.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/start-default-if-absent.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-is-not-object.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-is-not-object.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/descriptor.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/descriptor.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/not-a-constructor.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/not-a-constructor.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-is-undefined.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-is-undefined.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/name.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/name.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-constructor-is-not-object.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-constructor-is-not-object.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/number-conversion.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/number-conversion.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/context-is-not-object.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/context-is-not-object.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/negative-start.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/negative-start.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/end-default-if-absent.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/end-default-if-absent.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/negative-end.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/negative-end.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/tointeger-conversion-end.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/tointeger-conversion-end.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-returns-not-arraybuffer.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-returns-not-arraybuffer.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/start-default-if-undefined.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/start-default-if-undefined.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-is-null.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-is-null.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/length.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/length.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-returns-larger-arraybuffer.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-returns-larger-arraybuffer.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/context-is-not-arraybuffer-object.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/context-is-not-arraybuffer-object.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/nonconstructor.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/nonconstructor.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-constructor-is-undefined.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-constructor-is-undefined.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/start-exceeds-end.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/start-exceeds-end.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-returns-same-arraybuffer.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-returns-same-arraybuffer.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-is-not-constructor.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-is-not-constructor.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/this-is-arraybuffer.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/this-is-arraybuffer.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/extensible.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/extensible.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/end-default-if-undefined.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/end-default-if-undefined.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/start-exceeds-length.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/start-exceeds-length.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/tointeger-conversion-start.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/tointeger-conversion-start.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/end-exceeds-length.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/end-exceeds-length.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-returns-smaller-arraybuffer.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/slice/species-returns-smaller-arraybuffer.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/invoked-as-func.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/invoked-as-func.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/name.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/name.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/prop-desc.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/prop-desc.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/invoked-as-accessor.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/invoked-as-accessor.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/this-has-no-typedarrayname-internal.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/this-has-no-typedarrayname-internal.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/length.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/length.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/return-bytelength.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/return-bytelength.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/this-is-not-object.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/this-is-not-object.js (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/this-is-arraybuffer.js [strict mode] (previously Ignored)
test/built-ins/SharedArrayBuffer/prototype/byteLength/this-is-arraybuffer.js (previously Ignored)
test/built-ins/TypedArray/prototype/set/typedarray-arg-set-values-diff-buffer-other-type-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArray/prototype/set/typedarray-arg-set-values-diff-buffer-other-type-sab.js (previously Ignored)
test/built-ins/TypedArray/prototype/set/typedarray-arg-set-values-diff-buffer-other-type-conversions-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArray/prototype/set/typedarray-arg-set-values-diff-buffer-other-type-conversions-sab.js (previously Ignored)
test/built-ins/TypedArray/prototype/set/typedarray-arg-set-values-same-buffer-same-type-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArray/prototype/set/typedarray-arg-set-values-same-buffer-same-type-sab.js (previously Ignored)
test/built-ins/TypedArray/prototype/set/typedarray-arg-set-values-diff-buffer-same-type-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArray/prototype/set/typedarray-arg-set-values-diff-buffer-same-type-sab.js (previously Ignored)
test/built-ins/TypedArray/prototype/set/BigInt/typedarray-arg-set-values-diff-buffer-other-type-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArray/prototype/set/BigInt/typedarray-arg-set-values-diff-buffer-other-type-sab.js (previously Ignored)
test/built-ins/TypedArray/prototype/set/BigInt/typedarray-arg-set-values-same-buffer-same-type-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArray/prototype/set/BigInt/typedarray-arg-set-values-same-buffer-same-type-sab.js (previously Ignored)
test/built-ins/TypedArray/prototype/set/BigInt/typedarray-arg-set-values-diff-buffer-same-type-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArray/prototype/set/BigInt/typedarray-arg-set-values-diff-buffer-same-type-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/internals/Get/indexed-value-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/internals/Get/indexed-value-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/internals/Get/BigInt/indexed-value-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/internals/Get/BigInt/indexed-value-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/internals/Delete/indexed-value-sab-strict.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/internals/Delete/indexed-value-sab-non-strict.js (previously Ignored)
test/built-ins/TypedArrayConstructors/internals/Delete/BigInt/indexed-value-sab-strict.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/internals/Delete/BigInt/indexed-value-sab-non-strict.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/excessive-offset-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/excessive-offset-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/excessive-length-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/excessive-length-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/defined-length-and-offset-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/defined-length-and-offset-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/custom-proto-access-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/custom-proto-access-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-is-negative-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-is-negative-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/toindex-bytelength-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/toindex-bytelength-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/defined-offset-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/defined-offset-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/new-instance-extensibility-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/new-instance-extensibility-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/toindex-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/toindex-byteoffset-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-to-number-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-to-number-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/length-is-symbol-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/length-is-symbol-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-throws-from-modulo-element-size-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-throws-from-modulo-element-size-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/use-default-proto-if-custom-proto-is-not-object-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/use-default-proto-if-custom-proto-is-not-object-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-is-negative-zero-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-is-negative-zero-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/proto-from-ctor-realm-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/proto-from-ctor-realm-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/is-referenced-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/is-referenced-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/invoked-with-undefined-newtarget-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/invoked-with-undefined-newtarget-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/returns-new-instance-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/returns-new-instance-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/defined-length-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/defined-length-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/length-access-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/length-access-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/defined-negative-length-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/defined-negative-length-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/use-custom-proto-if-object-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/use-custom-proto-if-object-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/bufferbyteoffset-throws-from-modulo-element-size-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/bufferbyteoffset-throws-from-modulo-element-size-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/typedarray-backed-by-sharedarraybuffer.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/typedarray-backed-by-sharedarraybuffer.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-is-symbol-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors-bigint/buffer-arg/byteoffset-is-symbol-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/excessive-offset-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/excessive-offset-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/excessive-length-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/excessive-length-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/defined-length-and-offset-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/defined-length-and-offset-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/custom-proto-access-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/custom-proto-access-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-is-negative-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-is-negative-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/toindex-bytelength-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/toindex-bytelength-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/defined-offset-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/defined-offset-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/new-instance-extensibility-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/new-instance-extensibility-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/toindex-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/toindex-byteoffset-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-to-number-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-to-number-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/length-is-symbol-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/length-is-symbol-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-throws-from-modulo-element-size-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-throws-from-modulo-element-size-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/use-default-proto-if-custom-proto-is-not-object-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/use-default-proto-if-custom-proto-is-not-object-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-is-negative-zero-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-is-negative-zero-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/proto-from-ctor-realm-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/proto-from-ctor-realm-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/is-referenced-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/is-referenced-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/invoked-with-undefined-newtarget-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/invoked-with-undefined-newtarget-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/returns-new-instance-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/returns-new-instance-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/defined-length-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/defined-length-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/length-access-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/length-access-throws-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/defined-negative-length-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/defined-negative-length-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/use-custom-proto-if-object-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/use-custom-proto-if-object-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/bufferbyteoffset-throws-from-modulo-element-size-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/bufferbyteoffset-throws-from-modulo-element-size-sab.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/typedarray-backed-by-sharedarraybuffer.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/typedarray-backed-by-sharedarraybuffer.js (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-is-symbol-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/TypedArrayConstructors/ctors/buffer-arg/byteoffset-is-symbol-throws-sab.js (previously Ignored)
test/built-ins/ArrayBuffer/prototype/slice/this-is-sharedarraybuffer.js [strict mode] (previously Ignored)
test/built-ins/ArrayBuffer/prototype/slice/this-is-sharedarraybuffer.js (previously Ignored)
test/built-ins/ArrayBuffer/prototype/byteLength/this-is-sharedarraybuffer.js [strict mode] (previously Ignored)
test/built-ins/ArrayBuffer/prototype/byteLength/this-is-sharedarraybuffer.js (previously Ignored)
test/built-ins/DataView/custom-proto-access-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/custom-proto-access-throws-sab.js (previously Ignored)
test/built-ins/DataView/buffer-reference-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/buffer-reference-sab.js (previously Ignored)
test/built-ins/DataView/byteoffset-is-negative-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/byteoffset-is-negative-throws-sab.js (previously Ignored)
test/built-ins/DataView/toindex-bytelength-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/toindex-bytelength-sab.js (previously Ignored)
test/built-ins/DataView/defined-byteoffset-undefined-bytelength-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/defined-byteoffset-undefined-bytelength-sab.js (previously Ignored)
test/built-ins/DataView/toindex-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/toindex-byteoffset-sab.js (previously Ignored)
test/built-ins/DataView/return-instance-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/return-instance-sab.js (previously Ignored)
test/built-ins/DataView/buffer-does-not-have-arraybuffer-data-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/buffer-does-not-have-arraybuffer-data-throws-sab.js (previously Ignored)
test/built-ins/DataView/negative-byteoffset-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/negative-byteoffset-throws-sab.js (previously Ignored)
test/built-ins/DataView/defined-bytelength-and-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/defined-bytelength-and-byteoffset-sab.js (previously Ignored)
test/built-ins/DataView/custom-proto-if-object-is-used-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/custom-proto-if-object-is-used-sab.js (previously Ignored)
test/built-ins/DataView/return-abrupt-tonumber-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/return-abrupt-tonumber-byteoffset-sab.js (previously Ignored)
test/built-ins/DataView/proto-from-ctor-realm-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/proto-from-ctor-realm-sab.js (previously Ignored)
test/built-ins/DataView/return-abrupt-tonumber-bytelength-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/return-abrupt-tonumber-bytelength-sab.js (previously Ignored)
test/built-ins/DataView/excessive-byteoffset-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/excessive-byteoffset-throws-sab.js (previously Ignored)
test/built-ins/DataView/instance-extensibility-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/instance-extensibility-sab.js (previously Ignored)
test/built-ins/DataView/defined-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/defined-byteoffset-sab.js (previously Ignored)
test/built-ins/DataView/excessive-bytelength-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/excessive-bytelength-throws-sab.js (previously Ignored)
test/built-ins/DataView/negative-bytelength-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/negative-bytelength-throws-sab.js (previously Ignored)
test/built-ins/DataView/return-abrupt-tonumber-byteoffset-symbol-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/return-abrupt-tonumber-byteoffset-symbol-sab.js (previously Ignored)
test/built-ins/DataView/custom-proto-if-not-object-fallbacks-to-default-prototype-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/custom-proto-if-not-object-fallbacks-to-default-prototype-sab.js (previously Ignored)
test/built-ins/DataView/return-abrupt-tonumber-bytelength-symbol-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/return-abrupt-tonumber-bytelength-symbol-sab.js (previously Ignored)
test/built-ins/DataView/newtarget-undefined-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/newtarget-undefined-throws-sab.js (previously Ignored)
test/built-ins/DataView/prototype/byteOffset/return-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/byteOffset/return-byteoffset-sab.js (previously Ignored)
test/built-ins/DataView/prototype/byteOffset/this-has-no-dataview-internal-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/byteOffset/this-has-no-dataview-internal-sab.js (previously Ignored)
test/built-ins/DataView/prototype/byteLength/return-bytelength-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/byteLength/return-bytelength-sab.js (previously Ignored)
test/built-ins/DataView/prototype/byteLength/this-has-no-dataview-internal-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/byteLength/this-has-no-dataview-internal-sab.js (previously Ignored)
test/built-ins/DataView/prototype/buffer/this-has-no-dataview-internal-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/buffer/this-has-no-dataview-internal-sab.js (previously Ignored)
test/built-ins/DataView/prototype/buffer/return-buffer-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/buffer/return-buffer-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-values-custom-offset-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-values-custom-offset-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/toindex-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/toindex-byteoffset-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-abrupt-from-tonumber-byteoffset-symbol-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-abrupt-from-tonumber-byteoffset-symbol-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/negative-byteoffset-throws-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/negative-byteoffset-throws-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/index-is-out-of-range-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/index-is-out-of-range-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/this-has-no-dataview-internal-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/this-has-no-dataview-internal-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-value-clean-arraybuffer-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-value-clean-arraybuffer-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-abrupt-from-tonumber-byteoffset-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-abrupt-from-tonumber-byteoffset-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/to-boolean-littleendian-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/to-boolean-littleendian-sab.js (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-values-sab.js [strict mode] (previously Ignored)
test/built-ins/DataView/prototype/getInt32/return-values-sab.js (previously Ignored)
test/built-ins/Object/seal/seal-sharedarraybuffer.js [strict mode] (previously Ignored)
test/built-ins/Object/seal/seal-sharedarraybuffer.js (previously Ignored)

@codecov
Copy link

codecov bot commented Oct 14, 2023

Codecov Report

Attention: 591 lines in your changes are missing coverage. Please review.

Comparison is base (afb9283) 46.05% compared to head (671d884) 45.72%.
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3384      +/-   ##
==========================================
- Coverage   46.05%   45.72%   -0.34%     
==========================================
  Files         474      482       +8     
  Lines       48742    49171     +429     
==========================================
+ Hits        22450    22485      +35     
- Misses      26292    26686     +394     
Files Coverage Δ
boa_engine/src/builtins/mod.rs 92.73% <100.00%> (+0.03%) ⬆️
boa_engine/src/builtins/temporal/fields.rs 0.00% <ø> (ø)
boa_engine/src/builtins/typed_array/builtin.rs 6.18% <ø> (ø)
boa_engine/src/builtins/typed_array/mod.rs 14.63% <ø> (+6.56%) ⬆️
boa_engine/src/context/hooks.rs 60.60% <100.00%> (+2.54%) ⬆️
boa_engine/src/context/intrinsics.rs 97.56% <100.00%> (+0.01%) ⬆️
boa_engine/src/object/internal_methods/function.rs 76.19% <ø> (ø)
boa_engine/src/string/common.rs 48.48% <ø> (ø)
boa_tester/src/exec/js262.rs 0.00% <0.00%> (ø)
boa_engine/src/object/builtins/jsdataview.rs 0.00% <0.00%> (ø)
... and 14 more

... and 6 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@jedel1043 jedel1043 marked this pull request as ready for review October 14, 2023 05:52
@jedel1043 jedel1043 requested a review from a team October 14, 2023 05:52
Copy link
Member

@raskad raskad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really nice work. I really like the refactor of the typed array kinds!

I still have to go through some of the unsafe call sites to review the invariants.

For others reviewing; it makes sense to compare the old boa_engine/src/builtins/typed_array/mod.rs to the new boa_engine/src/builtins/typed_array/builtin.rs since most of the contents are moved.

boa_engine/src/builtins/array_buffer/utils.rs Outdated Show resolved Hide resolved
boa_engine/src/builtins/array_buffer/utils.rs Outdated Show resolved Hide resolved
boa_engine/src/builtins/array_buffer/utils.rs Outdated Show resolved Hide resolved
@raskad raskad requested a review from a team October 14, 2023 14:01
Copy link
Member

@HalidOdat HalidOdat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really nice work!

just some minor nitpicks that don't block merging :)

boa_engine/src/builtins/array_buffer/shared.rs Outdated Show resolved Hide resolved
boa_engine/src/builtins/array_buffer/shared.rs Outdated Show resolved Hide resolved
@jedel1043 jedel1043 requested a review from raskad October 15, 2023 05:59
@raskad raskad added this pull request to the merge queue Oct 15, 2023
Merged via the queue into main with commit dd05f53 Oct 15, 2023
14 checks passed
@HalidOdat HalidOdat deleted the shared_buffers branch October 15, 2023 13:29
sam-finch-tezos pushed a commit to trilitech/boa that referenced this pull request Nov 29, 2023
* Implement `SharedArrayBuffer`

* Add small documentation

* Fix docs

* Apply review
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
builtins PRs and Issues related to builtins/intrinsics enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants