Commit Graph

68490 Commits

Author SHA1 Message Date
Jan de Mooij
cdbd8647b5 Bug 1516237 - Fix FixWaiverAfterTransplant to nuke CCWs for oldWaiver in the new compartment. r=bholley
This case can come up with same-compartment realms. Keeping these CCWs
would confuse RemapWrapper because it'd be called with the CCW and target
in the same compartment.

Differential Revision: https://phabricator.services.mozilla.com/D15491

--HG--
extra : moz-landing-system : lando
2019-01-03 09:04:02 +00:00
Jan de Mooij
c310b8a7a7 Bug 1467124 - Fix WindowProxy optimizations in the JIT for same-compartment realms. r=bzbarsky
Makes the following changes:

* The WindowProxy optimizations in the ICs and Ion now guard the WindowProxy's
  global is the script's global. Other WindowProxies are harder to optimize
  because of potential security checks based on document.domain.

* IsWindowProxyForScriptGlobal was added as helper function to consolidate the
  logic for this.

* Removes the WindowProxy optimization for CCWs. This becomes more complicated
  in the new world for various reasons and it seems better to focus on
  getting same-compartment realms working to address that use case.

Differential Revision: https://phabricator.services.mozilla.com/D15492

--HG--
extra : moz-landing-system : lando
2019-01-03 08:52:43 +00:00
Jan de Mooij
f9e1248a94 Bug 1516967 - Call the large allocation callback before reporting OOM in JSRuntime::createJitRuntime. r=lhansen
Differential Revision: https://phabricator.services.mozilla.com/D15560

--HG--
extra : moz-landing-system : lando
2019-01-03 08:48:33 +00:00
Bogdan Tara
954395da08 Merge mozilla-central to mozilla-inbound. a=merge CLOSED TREE 2019-01-02 23:41:59 +02:00
Bogdan Tara
6582cc9a1d Merge inbound to mozilla-central. a=merge 2019-01-02 23:36:12 +02:00
Sean Stangl
159e4bb574 Bug 1516701 - Implement MacroAssembler::storeRegsInMask(). r=nbp
Makes progress in basic/array-copyWithin.js.

Fixup for storeRegsInMask.
2018-12-28 14:26:00 +02:00
Sean Stangl
4e37f82d83 Bug 1516700 - ARM64: Use SwitchTableType::OutOfLine. r=nbp 2018-12-28 14:23:00 +02:00
Sean Stangl
18984545af Bug 1516693 - ARM64: Correctly update framePushed_ in buildOOLFakeExitFrame(). r=nbp 2018-12-28 13:07:00 +02:00
Jon Coppeard
9f444751c3 Bug 1514850 - Don't delay checking of cells that are already marked black r=sfink 2019-01-02 18:19:01 +00:00
Jon Coppeard
bc5158e75b Bug 1516138 - Check GC zeal mode is in range r=allstars.chh 2019-01-02 18:19:01 +00:00
Jon Coppeard
26e28a8c42 Bug 1516409 - Separate out flags for gray and black delayed marking r=sfink 2019-01-02 18:19:01 +00:00
Peter Van der Beken
066d891adb Bug 1353867 - Add cross-process proxies for WindowProxy. r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D12656

--HG--
extra : moz-landing-system : lando
2019-01-02 13:29:18 +00:00
Peter Van der Beken
43adb531b7 Bug 1353867 - Expose IsCrossOriginWhitelistedProp/AppendCrossOriginWhitelistedPropNames to DOM code. r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D12655

--HG--
extra : moz-landing-system : lando
2019-01-02 13:28:40 +00:00
Peter Van der Beken
58c7fc4d20 Bug 1353867 - Change WindowProxyHolder's native type to BrowsingContext. r=bzbarsky
Make the WindowProxyHolder hold a strong reference to a BrowsingContext, as in the future
we might not have a nsPIDOMWindowOuter (if the document is loaded in a different process).

Differential Revision: https://phabricator.services.mozilla.com/D12651

--HG--
extra : moz-landing-system : lando
2019-01-02 13:27:05 +00:00
Ms2ger
3bb5e1c023 Bug 1515010 - Update core wasm tests; r=luke 2019-01-02 12:19:13 +01:00
Brindusan Cristian
2c544a2ad5 Backed out 1 changesets (bug 1515010) for wpt failures on align.wast.js.html and sm build bustage.
Backed out changeset a3025b3c5c6a (bug 1515010)
2019-01-02 14:52:11 +02:00
Ms2ger
ec75f6d41d Bug 1515010 - Update core wasm tests; r=luke 2019-01-02 12:19:13 +01:00
Boris Zbarsky
b7c8308871 Bug 1516560. Stop trying to do DOM proxy caching for DOM proxies with dynamic prototypes. r=jandem
This only affects Location.

Differential Revision: https://phabricator.services.mozilla.com/D15422

--HG--
extra : moz-landing-system : lando
2018-12-31 16:16:00 +00:00
Bob Clary
664095fb28 Bug 1475648 - disable jittests on android-hw-p2, r=jmaher.
This patch disables the following tests for the specified arm platform:

jit-test/tests/wasm/atomic.js arm64
jit-test/tests/wasm/baseline-abs-addr-opt.js arm64
jit-test/tests/wasm/bce.js arm64
jit-test/tests/wasm/memory.js arm64
jit-test/tests/wasm/spec/float_memory.wast.js arm7
jit-test/tests/wasm/spec/memory_redundancy.wast.js arm7

This uses the following rules to determine when to skip the
test:

skip arm7       // |jit-test| skip-if: !getBuildConfiguration()['x86'] && !getBuildConfiguration()['x64'] && !getBuildConfiguration()['arm64']
skip arm64      // |jit-test| skip-if: getBuildConfiguration()['arm64']
skip arm7+arm64 // |jit-test| skip-if: !getBuildConfiguration()['x86'] && !getBuildConfiguration()['x64']

Bug 1516915 has been filed to add an arm7 property to getBuildConfiguration.
2018-12-31 10:14:26 -08:00
Bob Clary
a6b6fd36a7 Bug 1511615 - disable js/src/jit-test/tests/ctypes/conversion-finalizer.js for android-hw-p2, r=jmaher. 2018-12-31 10:14:25 -08:00
Bob Clary
8d9db10b16 Bug 1511618 - js/src/tests/lib/jittests.py check_output should detect rc 139 as a crash, r=jmaher. 2018-12-31 10:14:25 -08:00
Yoshi Cheng-Hao Huang
f0323a414d Bug 1515648 - Part 5: fix in EnvironmentObject.cpp. r=jonco 2018-12-31 11:01:21 +01:00
Yoshi Cheng-Hao Huang
ca060916c7 Bug 1515648 - Part 4: fix in SavedStacks.cpp. r=jonco 2018-12-31 11:01:16 +01:00
Yoshi Cheng-Hao Huang
28981210df Bug 1515648 - Part 3: use unbarrieredGet() for Debugger. r=jonco 2018-12-31 11:01:11 +01:00
Yoshi Cheng-Hao Huang
f84b90a81c Bug 1515648 - Part 2: fix in Shape.cpp. r=jonco 2018-12-31 11:01:06 +01:00
Yoshi Cheng-Hao Huang
947a7a8bef Bug 1515648 - Part 1: Assert read barriers won't fire during collection. r=jonco 2018-12-31 11:01:00 +01:00
Daniel Varga
480ddc48ba Merge mozilla-central to autoland. a=merge
--HG--
extra : rebase_source : 8f0c469789f229e6bda880e040ef14179e70f9cf
2018-12-29 11:38:36 +02:00
Daniel Varga
732a632f8d Merge mozilla-inbound to mozilla-central. a=merge 2018-12-29 11:35:40 +02:00
Jan de Mooij
35eadca8e9 Bug 1515590 part 6 - Fix AddSizeOfTab to reserve number-of-realms instead of number-of-compartments in the realms Vector. r=bzbarsky
ASan builds caught this.

Differential Revision: https://phabricator.services.mozilla.com/D15308

--HG--
extra : moz-landing-system : lando
2018-12-29 09:27:16 +00:00
Jan de Mooij
2aa7efc012 Bug 1515590 part 5 - Fix test_bug771429.xul to work with same-compartment realms. r=bzbarsky
Changes the test to test both freshCompartment: true and freshCompartment: false
sandbox options.

There's one sub test that fails with same-copartment realms, I commented that
and added a weaker test for the same-compartment case.

Differential Revision: https://phabricator.services.mozilla.com/D15289

--HG--
extra : moz-landing-system : lando
2018-12-29 09:27:14 +00:00
Oriol Brufau
b8f683c47e Bug 1515447 - Add receiver parameter to Debugger.Object's getProperty and setProperty. r=jimb
Differential Revision: https://phabricator.services.mozilla.com/D15018

--HG--
extra : moz-landing-system : lando
2018-12-28 19:07:15 +00:00
Sylvestre Ledru
cccdda3c2a Bug 1516555 - Reformat everything to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D15426

--HG--
extra : moz-landing-system : lando
2018-12-28 15:48:06 +00:00
Boris Zbarsky
edab779db9 Bug 1516473. Remove the compartment assert from GetObjectClassName. r=jandem
This is the one thing preventing use of a js::Wrapper for a proxy handler that
forwards all ops to a wrapped proxy without entering its compartment.  None of
the other ops at this level do compartment asserts.

Callers of this function other than ForwardingProxyHandler do their own asserts
already.
2018-12-27 11:58:01 -08:00
Nicolas B. Pierron
99fca236e3 Bug 1515963 - Add vixl::GdbDisassembleInstruction. r=sstangl
This add a simple function made to be called from gdb, which uses the vixl
decoder to output in a static buffer the string corresponding to a single
instruction.

This is useful when breaking at vixl::Simulator::ExecuteInstruction function, as follow:

(gdb) b vixl::Simulator::ExecuteInstruction
Breakpoint 1 at 0x...: file ../jit/arm64/vixl/MozSimulator-vixl.cpp.
(gdb) command 1
> call vixl::GdbDisassembleInstruction(this->pc_)
> end
2018-12-27 18:52:32 +01:00
Nicolas B. Pierron
6b584f7dd8 Bug 1515704 - ARM64: Generate code for LPowHalfD. r=sstangl 2018-12-27 18:52:30 +01:00
Jeff Walden
8a135a9c5a Bug 1515801 - Make subscripts have lazy source, and change the source-hook to hint UTF-8 rather than offer no charset hint so that lazy-source for them will work correctly. r=kmag 2018-12-26 14:37:42 -06:00
Jeff Walden
4f1eec4171 Bug 1515801 - Remove JS::CompileLatin1{ForNonSyntacticScope} now that both are unused. r=jandem
--HG--
extra : rebase_source : d092af0c2f7337fae899e1bc55e6551ff44830cb
2018-12-14 14:34:16 -08:00
Jeff Walden
605ce5d8cc Bug 1515801 - Rip out vestigial handling of non-UTF-8 character sets from the subscript loader. r=kmag
--HG--
extra : rebase_source : 97a7604c6649d73d6b7a1f8d608cfdfe7c13a6aa
2018-12-14 14:25:56 -08:00
Boris Zbarsky
d6876ebbfa Bug 1515999. Remove the unused JSContext argument from GetArrayIndexFromId. r=peterv 2018-12-26 13:45:15 -08:00
Bogdan Tara
601b0d2329 Merge mozilla-central to mozilla-inbound. a=merge CLOSED TREE 2018-12-24 00:10:07 +02:00
arthur.iakab
41c674d64c Merge mozilla-central to autoland 2018-12-22 23:56:12 +02:00
arthur.iakab
49e5be726a Merge inbound to mozilla-central a=merge 2018-12-22 23:54:25 +02:00
Jan de Mooij
a62ba0ea68 Bug 1515754 - Change Debugger::onPromiseSettled to check promise->realm()->isDebuggee() instead of cx->realm()->isDebuggee(). r=arai
As discussed on IRC this is hard to trigger, but this is more consistent with
the cross-compartment code.

Differential Revision: https://phabricator.services.mozilla.com/D15214

--HG--
extra : moz-landing-system : lando
2018-12-22 21:42:23 +00:00
Jan de Mooij
1d8954ace9 Bug 1515754 - Enter the reaction's realm in EnqueuePromiseReactionJob before creating the job. r=arai
This is consistent with what we do for cross-compartment wrappers and avoids
problems with running jobs against a dying global (Gecko drops such jobs).

I added a globalOfFirstJobInQueue() shell function so I could write a test that
checks both the compartment-per-global and single-compartment cases.

Differential Revision: https://phabricator.services.mozilla.com/D15176

--HG--
extra : moz-landing-system : lando
2018-12-22 21:42:21 +00:00
inspiro
b8d53fc5d2 Bug 1320105 : Convert JSID_IS_INT to PropertyKey::isInt() r=jandem
Convert JSID_IS_INT to PropertyKey::isInt()

Differential Revision: https://phabricator.services.mozilla.com/D14011

--HG--
extra : moz-landing-system : lando
2018-12-22 14:17:44 +00:00
Kris Maglione
39ae97e234 Bug 1515884: Remove unused XPCWrappedJS nsIPropertyBag implementation. r=bholley
This helper code is currently unused, and presents a pretty significant
footgun for any JS object which implements nsIPropertyBag itself.

When those objects are first queried to nsIWritablePropertyBag, they behave as
expected, returning the JS-implemented nsIPropertyBag methods. But when
they're first queried to nsIPropertyBag, they use the XPCWrappedNative stubs,
which don't behave as expected.

Differential Revision: https://phabricator.services.mozilla.com/D15235

--HG--
extra : rebase_source : 02942592dc8c4efcc1190610448a46593faa5703
2018-12-21 15:03:13 -08:00
Jan de Mooij
ecaf5bdea0 Bug 1515590 part 4 - Don't call FixWaiverAfterTransplant if JS_TransplantObject didn't change object identity. r=bholley
Depends on D15093

Differential Revision: https://phabricator.services.mozilla.com/D15094

--HG--
extra : moz-landing-system : lando
2018-12-21 18:33:08 +00:00
Jan de Mooij
9190590e09 Bug 1515590 part 3 - Fix some debugger tests by forcing separate compartments for the debugger and debuggee. r=ochameau
With same-compartment chrome globals these would end up in the same compartment.
We need to prevent that because the debugger doesn't support it.

Differential Revision: https://phabricator.services.mozilla.com/D15093

--HG--
extra : moz-landing-system : lando
2018-12-22 21:39:56 +00:00
Jan de Mooij
929107cd39 Bug 1515590 part 2 - Fix test_bug1042436.xul to create the sandbox in a new compartment because Xray warning state is stored per compartment. r=bholley
Differential Revision: https://phabricator.services.mozilla.com/D15092

--HG--
extra : moz-landing-system : lando
2018-12-21 18:34:12 +00:00
Sean Stangl
94bebab09d Bug 1514404 - ARM64 handling for MTableSwitch. r=nbp 2018-12-21 14:51:00 +02:00