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

Don't pretend we support SharedArrayBuffer. #26875

Merged
merged 1 commit into from Jun 16, 2020
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

Don't pretend we support SharedArrayBuffer.

  • Loading branch information
jdm committed Jun 16, 2020
commit 83578265b456d53f62e1d71378b6d84fc853ca54
@@ -137,7 +137,7 @@ pub unsafe fn create_global_object(

let mut options = RealmOptions::default();
options.creationOptions_.traceGlobal_ = Some(trace);
options.creationOptions_.sharedMemoryAndAtomics_ = true;
options.creationOptions_.sharedMemoryAndAtomics_ = false;
options.creationOptions_.streams_ = true;

rval.set(JS_NewGlobalObject(
@@ -45,7 +45,6 @@ use js::jsapi::ContextOptionsRef;
use js::jsapi::GetPromiseUserInputEventHandlingState;
use js::jsapi::InitConsumeStreamCallback;
use js::jsapi::InitDispatchToEventLoop;
use js::jsapi::JS_SetFutexCanWait;
use js::jsapi::MimeType;
use js::jsapi::PromiseUserInputEventHandlingState;
use js::jsapi::StreamConsumer as JSStreamConsumer;
@@ -451,14 +450,6 @@ unsafe fn new_rt_and_cx_with_parent(
let (cx, runtime) = if let Some(parent) = parent {
let runtime = RustRuntime::create_with_parent(parent);
let cx = runtime.cx();

// Note: this enables blocking on an Atomics.wait,
// which should only be enabled for an agent whose [[CanBlock]] is true.
// Currently only a dedicated worker agent uses a parent,
// and this agent can block.
// See https://html.spec.whatwg.org/multipage/#integration-with-the-javascript-agent-cluster-formalism
JS_SetFutexCanWait(cx);

(cx, runtime)
} else {
let runtime = RustRuntime::new(JS_ENGINE.lock().unwrap().as_ref().unwrap().clone());
@@ -91,6 +91,12 @@ skip: true
skip: true
[cross-origin-opener-policy]
skip: true
[infrastructure]
skip: false
[safe-passing-of-structured-data]
skip: false
[shared-array-buffers]
skip: true
[semantics]
skip: false
[document-metadata]
@@ -1,4 +1,5 @@
[encodeInto.any.html]
expected: ERROR
[encodeInto() with 𝌆A and destination length 3, offset 4, filler 128]
expected: FAIL

@@ -565,6 +566,7 @@


[encodeInto.any.worker.html]
expected: ERROR
[encodeInto() with 𝌆A and destination length 3, offset 4, filler 128]
expected: FAIL

@@ -11,6 +11,7 @@


[decode-utf8.any.html]
expected: ERROR
[decoding one UTF-8 chunk should give one output string]
expected: FAIL

@@ -55,6 +56,7 @@


[decode-utf8.any.worker.html]
expected: ERROR
[decoding one UTF-8 chunk should give one output string]
expected: FAIL

@@ -1,9 +1,11 @@
[textdecoder-copy.any.html]
expected: ERROR
[Modify buffer after passing it in (SharedArrayBuffer)]
expected: FAIL


[textdecoder-copy.any.worker.html]
expected: ERROR
[Modify buffer after passing it in (SharedArrayBuffer)]
expected: FAIL

@@ -1,8 +1,8 @@
[textdecoder-streaming.any.worker.html]
expected: CRASH
expected: ERROR

[textdecoder-streaming.any.html]
expected: CRASH
expected: ERROR

[textdecoder-streaming.any.sharedworker.html]
expected: ERROR
@@ -1,4 +1,6 @@
[requires-failure.https.any.html]
[[[CanBlock\]\] in a Window]
expected: FAIL

[requires-failure.https.any.serviceworker.html]
expected: ERROR
@@ -1,3 +1,7 @@
[requires-success.any.worker.html]
[[[CanBlock\]\] in a DedicatedWorkerGlobalScope]
expected: FAIL

[requires-success.any.sharedworker.html]
expected: ERROR
[requires-success]
@@ -1,9 +1,12 @@
[constructor-shared.tentative.any.worker.html]
[Shared memory]
expected: FAIL
[Order of evaluation for descriptor (with shared)]
expected: FAIL


[constructor-shared.tentative.any.html]
[Shared memory]
expected: FAIL

[Order of evaluation for descriptor (with shared)]
expected: FAIL
@@ -26,3 +26,8 @@
[X 5: buffer.copyFromChannel(x, 0, -1) incorrectly threw IndexSizeError: "The index is not in the allowed range.".]
expected: FAIL

[Executing "copyFrom-exceptions"]
expected: FAIL

[Executing "copyTo-exceptions"]
expected: FAIL
@@ -1,5 +1,47 @@
[send-data-sharedarraybuffer.any.html]
expected: CRASH
[sending a SharedArrayBuffer]
expected: FAIL
[sending a Int8Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Uint8Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Uint8ClampedArray backed by a SharedArrayBuffer]
expected: FAIL
[sending a Int16Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Uint16Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Int32Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Uint32Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Float32Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Float64Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a DataView backed by a SharedArrayBuffer]
expected: FAIL

[send-data-sharedarraybuffer.any.worker.html]
expected: CRASH
[sending a SharedArrayBuffer]
expected: FAIL
[sending a Int8Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Uint8Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Uint8ClampedArray backed by a SharedArrayBuffer]
expected: FAIL
[sending a Int16Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Uint16Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Int32Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Uint32Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Float32Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a Float64Array backed by a SharedArrayBuffer]
expected: FAIL
[sending a DataView backed by a SharedArrayBuffer]
expected: FAIL

This comment has been minimized.

Copy link
@gterzian

gterzian Jun 16, 2020

Member

nit: do we always want to have a newline at the end of .ini files? If only to not have github show the warning in the diff?

This comment has been minimized.

Copy link
@jdm

jdm Jun 16, 2020

Author Member

I'm not convinced it's a useful thing to care about.

This comment has been minimized.

Copy link
@gterzian
@@ -11005,7 +11005,7 @@
[]
],
"interfaces.js": [
"253dd124cebe9b7d3aa4fc5ff8c9137e7aeb2f66",
"7a105e791dd80bd42d80055a64746bbe5fece41e",
[]
],
"nested_asap_script.js": [
@@ -5,7 +5,6 @@ function test_interfaces(interfaceNamesInGlobalScope) {
var ecmaGlobals = [
"Array",
"ArrayBuffer",
"Atomics",
"BigInt",
"BigInt64Array",
"BigUint64Array",
@@ -43,7 +42,6 @@ function test_interfaces(interfaceNamesInGlobalScope) {
"Reflect",
"RegExp",
"Set",
"SharedArrayBuffer",
"String",
"Symbol",
"SyntaxError",
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.