Граф коммитов

66316 Коммитов

Автор SHA1 Сообщение Дата
Cosmin Sabou 1c8ad7b4ba Merge mozilla-inbound to mozilla-central. a=merge 2018-08-15 03:51:45 +03:00
Andreea Pavel 870fc40e66 Merge mozilla-central to autoland. a=merge on a CLOSED TREE 2018-08-14 19:17:13 +03:00
Henri Sivonen 3edc601325 Bug 1402247 - Use encoding_rs for XPCOM string encoding conversions. r=Nika,erahm,froydnj.
Correctness improvements:

 * UTF errors are handled safely per spec instead of dangerously truncating
   strings.

 * There are fewer converter implementations.

Performance improvements:

 * The old code did exact buffer length math, which meant doing UTF math twice
   on each input string (once for length calculation and another time for
   conversion). Exact length math is more complicated when handling errors
   properly, which the old code didn't do. The new code does UTF math on the
   string content only once (when converting) but risks allocating more than
   once. There are heuristics in place to lower the probability of
   reallocation in cases where the double math avoidance isn't enough of a
   saving to absorb an allocation and memcpy.

 * Previously, in UTF-16 <-> UTF-8 conversions, an ASCII prefix was optimized
   but a single non-ASCII code point pessimized the rest of the string. The
   new code tries to get back on the fast ASCII path.

 * UTF-16 to Latin1 conversion guarantees less about handling of out-of-range
   input to eliminate an operation from the inner loop on x86/x86_64.

 * When assigning to a pre-existing string, the new code tries to reuse the
   old buffer instead of first releasing the old buffer and then allocating a
   new one.

 * When reallocating from the new code, the memcpy covers only the data that
   is part of the logical length of the old string instead of memcpying the
   whole capacity. (For old callers old excess memcpy behavior is preserved
   due to bogus callers. See bug 1472113.)

 * UTF-8 strings in XPConnect that are in the Latin1 range are passed to
   SpiderMonkey as Latin1.

New features:

 * Conversion between UTF-8 and Latin1 is added in order to enable faster
   future interop between Rust code (or otherwise UTF-8-using code) and text
   node and SpiderMonkey code that uses Latin1.

MozReview-Commit-ID: JaJuExfILM9
2018-08-14 14:43:42 +03:00
Paul Bone bb08d12025 Bug 1473213 (Part 5) - Only record allocation counts on Nightly builds r=jonco
--HG--
extra : rebase_source : 72a87eec0d4006aa8d6e37a43c0d27d50c7c41b1
extra : source : 29f9f3ab9b416448db79f5ec5beb0c092ba8f6be
2018-07-26 00:35:25 +10:00
Paul Bone 9a888e6cc5 Bug 1473213 (Part 4) - Add cells allocated statistics r=sfink
--HG--
extra : rebase_source : 4a74f930e66b65a3302f15ec28f79179bdabc2e1
extra : source : 129c9ab66f595bf72afebfdeba87a587578173a2
2018-08-08 12:54:50 +10:00
Paul Bone ce08d1bebc Bug 1473213 (Part 3) - Refactor JSContext code for changing zones r=sfink
* Introduce a setZone method that changes the zone and the freelist.
 * leaveAtomsZone() private

--HG--
extra : rebase_source : 7bb624c9091aaa585211577c486288a548926a71
extra : source : 96e57dd562b890bac534d88ff265653d5a00f61c
2018-08-08 12:05:59 +10:00
Paul Bone 271f7a7664 Bug 1473213 (Part 2) - add a comment about an invariant required by the JIT r=sfink
--HG--
extra : rebase_source : b5fc8c7e4099fe57f4d5ed5d21af9d88b8a35316
extra : intermediate-source : e40d822d886b47350c28c1c4cb6c45d335fc5b1b
extra : source : 4e59349dd9776f329c9545aa994c6f490f11d105
2018-07-16 11:36:49 +10:00
Paul Bone 6e12af80d7 Bug 1473213 (Part 1) - Track the number of tenured cells r=jonco
--HG--
extra : rebase_source : 96739a13fe0d44bcb00819cf7422ef97bc97f812
extra : intermediate-source : 8a10fc261acb99c7e8bb4fcb4ee0975c5166990d
extra : source : 445b672aa024fdfca38a2e819f54bcbf28e922dd
2018-07-20 15:09:01 +10:00
André Bargull 4b9f21c0dd Bug 1482846 - Part 4: Remove unused code from BytecodeUtil. r=tcampbell
--HG--
extra : histedit_source : 1b0d6e60f3151801b23cc6f007bd31c554c3bab7
2018-08-13 04:37:21 -07:00
André Bargull 6a9925782f Bug 1482846 - Part 3: Avoid allocating empty arrays and parsing byte code when result is not used. r=tcampbell
--HG--
extra : histedit_source : a81e48ffeeb0aecaa949208d398ceead2c670bfb
2018-08-13 04:38:47 -07:00
André Bargull bad79778b3 Bug 1482846 - Part 2: Parse byte code only once when decompiling an expression. r=tcampbell
--HG--
extra : histedit_source : 3074d73faaa91961fc87d237241e366379fbc005
2018-08-13 04:40:24 -07:00
André Bargull fba1c5de25 Bug 1482846 - Part 1: Mark BytecodeParser methods as const. r=tcampbell
--HG--
extra : histedit_source : 9d1f905b655c02839a29b902f2f500f64c5e3c7a
2018-08-13 04:41:01 -07:00
André Bargull 0250ea3e9f Bug 1482359: Use more JSOP_STRICTEQ optimizations for Object.is(). r=jandem 2018-08-13 08:21:03 -07:00
Mike Hommey f6560362a9 Bug 1480004 - Normalize optimization level passed to the linker when doing LTO with clang. r=froydnj 2018-08-14 07:25:09 +09:00
Jeff Walden 0885260ab1 Bug 1478892 - Instantiate Parser for UTF-8 source text. r=arai
--HG--
extra : rebase_source : a9d318c40f9524583406d21b8b75c19f7848220f
2018-08-09 21:04:22 -07:00
Jeff Walden 74305f6c2c Bug 1478892 - Instantiate GeneralParser for UTF-8 source text. r=arai
--HG--
extra : rebase_source : 467d3e2bf6835586c6eb8a2c6ce8f69bd23827b9
2018-07-30 15:35:35 -07:00
Steve Fink a89504bc45 Bug 1479672 - Force use of gcc for hazard analysis, r=jonco
--HG--
extra : topic : gcstats.thresh
extra : rebase_source : 7b20e570a5b5f040fff7b0a030376525ca5a408d
2018-07-05 12:40:32 -07:00
Steve Fink 37fcd9834c Bug 1479673 - Trivial return value change, r=jonco
JS::ubi::Concrete<T> inherits from JS::ubi::Base but not JS::ubi::Node, so the bare 'Size' in the class declaration refers to Base::Size, not Node::Size. (Note that they're the same underlying type.)

--HG--
extra : topic : gcstats.thresh
extra : rebase_source : 2dd9ccca9e458e4f10bdbb8aff58f08732e712c7
2018-07-11 16:58:23 -07:00
Steve Fink 22ee12770e Bug 1480843 - Avoid hazard by controlling order of operations so that we GC before using any GC heap pointers, r=bz
--HG--
extra : topic : gcstats.thresh
extra : rebase_source : b9e31b5b0da9924bee110b689f16989cf578cb2e
2018-08-03 10:47:21 -07:00
Steve Fink 8aafec573a Bug 1480927 - Whitelist some more nsISupports virtual functions, r=jonco
--HG--
extra : topic : gcstats.thresh
extra : rebase_source : 11542a69c52ae54add2bdd598d702ecdf6856386
2018-08-03 09:22:32 -07:00
Csoregi Natalia fc2133e0bc Backed out 2 changesets (bug 1482153, bug 1469004) for assertion failures at ModuleScript.cpp:59. CLOSED TREE
Backed out changeset 8289b70dc0db (bug 1469004)
Backed out changeset 4129380f8318 (bug 1482153)
2018-08-13 19:37:07 +03:00
André Bargull b8d131ad5c Bug 1480819 - Part 7: Add comments, constants, and better variable names to RegExp stubs. r=mgaudet 2018-08-10 05:43:46 -07:00
André Bargull 2f9a5fff1d Bug 1480819 - Part 6: Add helper methods to MacroAssembler to work with CharEncoding and reduce code duplication. r=mgaudet 2018-08-10 08:50:28 -07:00
André Bargull 10eb8b5dd5 Bug 1480819 - Part 5: Add registers and encoding type as members to CreateDependentString. r=mgaudet 2018-08-03 09:12:53 -07:00
André Bargull 26c3b7560f Bug 1480819 - Part 4: Don't save non-volatile registers. r=mgaudet 2018-08-03 09:12:04 -07:00
André Bargull 5e8e900bbc Bug 1480819 - Part 3: Reorder temporary register names in generateRegExpMatcherStub. r=mgaudet 2018-08-03 09:10:46 -07:00
André Bargull 7a708d17e7 Bug 1480819 - Part 2: Switch the temporary variables used for CopyStringChars in CreateDependentString::generate. r=mgaudet 2018-08-03 09:09:40 -07:00
André Bargull df77deb80c Bug 1480819 - Part 1: Remove dead and unnecessary code to restore registers from generateRegExpMatcherStub. r=mgaudet 2018-08-03 09:08:50 -07:00
Logan F Smyth 4abb1e0558 Bug 1378808 - Use ::Arguments or ::PropertyName location for method call column offsets. r=jorendorff, r=ckerschb
--HG--
extra : rebase_source : 69612b61b1cfbfd26856e285d63600ce56e95ec3
extra : source : 6c6a609463ab5d71e475354cab8c3ff323d0571d
2018-07-12 11:51:17 -07:00
Logan F Smyth 7ca727c2d0 Bug 1378808 - Add a new ParseNodeKind::PropertyName to hold location information about property access name. r=jorendorff
MozReview-Commit-ID: J4vHz4ln5Zt

--HG--
extra : rebase_source : 05ff8c402e682db139b7c87a8ec2f59575eb34d0
extra : intermediate-source : 6dd9c641346afe439fb10c028becf0a7b1f0aedc
extra : source : 3b4f4db5d3d78170faf00bdf9fe2a562ad155fd5
2018-07-12 11:29:05 -07:00
Logan F Smyth ede9c30b6f Bug 1378808 - Add a new ParseNodeKind::Arguments node type for call argument lists. r=jorendorff
MozReview-Commit-ID: 7L4nNHjVoZo

--HG--
extra : rebase_source : 4140fd0df54bece716e4c5e0d68fbb3df16a6268
extra : source : e732697778c260c413047531e372a24286e0b667
2018-07-12 11:24:59 -07:00
Jon Coppeard b094eb1815 Bug 1469004 - Add an API to create a module namespace object r=anba 2018-08-13 16:39:14 +01:00
Jon Coppeard 623032e1f0 Bug 1482153 - Replace ModuleObject's host defined field with one on top-level JSScripts r=jandem r=hsivonen 2018-08-13 16:39:11 +01:00
Matthew Gaudet 1f4ef0d8fa Bug 1481556 - Compute the appropriate stub field index instead of assuming it based on execution order r=jandem
--HG--
extra : rebase_source : e0a82f4c09c0aa66281dc3ceadd0824c9ffa3c75
2018-08-07 13:50:18 -04:00
Matthew Gaudet 180ce7a7f1 Bug 1341261: [Part 9] Rename CacheRegisterAllocator::loadDouble to ensureDoubleRegister r=tcampbell
--HG--
extra : rebase_source : f9779fe958439726341429e09a022c62006716ad
2018-08-10 09:18:42 -04:00
Kris Maglione 3020a8b0a8 Bug 1480244: Part 2 - Replace ExecuteInGlobalAndReturnScope with ExecuteInScopeChainAndReturnNewScope. r=tcampbell
This patch series replaces message manager globals with ordinary JS objects
which live in the shared JSM global. Once that happens,
ExecuteInGlobalAndReturnScope will no longer have useful behavior for them,
since the base global has none of the methods that they rely on, and it
provides no way to insert another plain object into the scope chain.

This patch changes the scope chain for frame scripts to instead look like:

 -+- Shared JSM global
  |
  +- LexicalEnvironment[this=global]
  |
  +- NonSyntacticVariablesObject
  |
  +- WithEnvironmentObject[target=messageManager]
  |
  +- LexicalEnvironment[this=messageManager]

Where lexical assignments end up on the lexical scope, and both qualified and
unqualified assignments wind up on the NSVO.

This has some slight behavioral differences from the previous model, in that
properties defined on the message manager can mask properties on the NSVO. But
those differences are minor, and probably not worth worrying about, since
frame scripts are being deprecated as part of the Fission project.

MozReview-Commit-ID: ACEOY2hExco

--HG--
extra : rebase_source : 384ccd422b4167e9a4fc550dd691fcc027553544
2018-08-10 13:54:23 -07:00
Andreea Pavel aa7818b463 Bug 1483229 - Exit test early if TypedObject is not defined. r=jonco
DONTBUILD

--HG--
extra : source : 8e3582b4162117fb0e721b474133c2f97b7b53da
2018-08-14 16:16:38 +03:00
Ryan VanderMeulen b1b6f583f5 Backed out changeset 8e3582b41621 for landing with the wrong bug number in the commit message. 2018-08-14 12:42:17 -04:00
Andreea Pavel fbf4deefb7 Bug 1481093 - Exit test early if TypedObject is not defined. r=jonco 2018-08-14 16:16:38 +03:00
Thi Huynh d1638fb2b2 Bug 1478910 - Use JSMSG_AWAIT_IN_DEFAULT error for incomplete await expr in async function/generator parameter. r=arai
Differential Revision: https://phabricator.services.mozilla.com/D3207

--HG--
extra : moz-landing-system : lando
2018-08-14 11:06:50 +00:00
Matthew Gaudet 916718b719 Bug 1341261: [Part 8] Dump opcodes for CompareIC to CacheIR logs r=tcampbell
--HG--
extra : rebase_source : f1ebf0d14afe57417492f4d8c3b0aa85fa92e46d
2018-06-15 17:15:24 -07:00
Matthew Gaudet f4f4a7ea1a Bug 1341261: [Part 7] Remove now-unused SharedIC Machinery for CompareICs r=tcampbell
Also, relocate no-longer SharedIC machinery to BaselineIC.cpp

--HG--
extra : rebase_source : 050524cf338aa5335fbf12b918c9990882d7ad3d
2018-06-08 17:28:21 -04:00
Matthew Gaudet 730d598e9e Bug 1341261: [Part 6] Teach the Baseline Inspector about the new CacheIR ops r=tcampbell
--HG--
extra : rebase_source : 87fabc832341afc9e4108223fb3ba1d08537d8b2
2018-06-08 16:46:23 -04:00
Matthew Gaudet 618b094127 Bug 1341261: [Part 5] Number+Null+Undefined Comparisons r=tcampbell
--HG--
extra : rebase_source : 2ce16207c1c2166e45139d2268ded71431346557
2018-08-03 10:31:34 -04:00
Matthew Gaudet f1981b99c3 Bug 1341261: [Part 4] Compare Undefined/Null+Object r=tcampbell
--HG--
extra : rebase_source : a96f7567fee9f43009d13b35c28de2cb04237b73
2018-06-05 13:13:37 -04:00
Matthew Gaudet f0d1895741 Bug 1341261: [Part 3] Support Number/Number Comparisons in CacheIR r=tcampbell
As a bonus, also cleanup a superflous trackAttached

--HG--
extra : rebase_source : c2a78aa40f3f5e704ef5aab158584e10403bf905
2018-05-17 16:29:28 -04:00
Matthew Gaudet b796885ce9 Bug 1341261: [Part 2] Support Int32/Int32 Comparisons in CacheIR r=tcampbell
--HG--
extra : rebase_source : 31c5223109613e9301aea795b9f35144216ffb4b
2018-05-17 12:09:14 -04:00
Matthew Gaudet 56663db2cb Bug 1341261: [Part 1] Enable CacheIR Compare ICs in Ion r=tcampbell
--HG--
extra : rebase_source : 788f7bb1eda50759165850e9f78ba41985563f0c
2018-05-15 16:10:50 -04:00
Matthew Gaudet 080064785c Bug 1341261: [Part 0] Enhance compare test case r=tcampbell
--HG--
extra : rebase_source : 29e7b183e0ea5452aa5af9a700ce5f0fd9a67079
2018-06-15 15:56:39 -07:00
Tooru Fujisawa da07964ec2 Bug 1476203 - Separate IfEmitter and CondEmitter. r=jwalden 2018-08-13 05:19:47 -07:00