Commit graph

40 commits

Author SHA1 Message Date
Martok
85af7f6e80 Issue #1952 - m-c 1383775: Clean up function toString/toSource code, remove remnants of source decompiler 2022-07-03 06:55:19 +08:00
Moonchild
574b295d15 Issue #1742 - Part 3: use JS::PropertyResult instead of Shape*
This is the meat of the issue and switches using raw shape pointers out for
PropertyResult objects where feasible.
2022-05-31 09:12:29 +08:00
Moonchild
5d2fea0dac [js] Add AutoEnterOOMUnsafeRegion to JS_TransplantObject.
Transplanting objects is inherently oom-unsafe, so add
`AutoEnterOOMUnsafeRegion` to `JS_TransplantObject()` and annotate crashes
accordingly if they do happen.
2021-01-27 21:02:55 +08:00
Moonchild
ec0865128b Issue #1624 - Make ion inlining optimizations a pref.
This also adds it to JS_SetGlobalJitCompilerOption()
2020-12-04 08:52:49 +08:00
Moonchild
3e118e4948 [devtools] More gracefully (than a crash) handle stack capture failures. 2020-11-06 09:42:40 +08:00
Moonchild
dabd32f955 Issue #1656 - Part 7: Nuke vim config lines in JS 2020-09-25 22:04:24 +08:00
Moonchild
ef11a4d7e8 Issue #618 - Clear the module map when changing a Document's global and add
release build assertions for mismatching compartments.
2020-09-10 21:07:51 +08:00
Moonchild
34db761758 Issue #618 - Simplify module resolve hook to be a function pointer
This is an ahead-of time port to try and address #1624.
This is based on BZ 1461751 and Jon Coppeard's work in it.
2020-08-29 08:08:41 +08:00
Moonchild
976239c8d0 [js] Add some utility functions to get the current JS runtime. 2020-08-29 08:08:38 +08:00
Moonchild
0d874713ef Issue #618 - Align error handling for module scripts with the spec (again)
This updates module implementation to match spec regarding handling of
instantiation errors, after it was changed yet again, this time to not remember
instantiation errors, but instead immediately rethrow applicable ones.

Ref: BZ 1420420
2020-08-29 08:07:00 +08:00
Moonchild
c65ca2ca58 Issue #618 - Remove context and heap-idle check
For checking if a module is in an error state and what the error is, it
shouldn't matter if we are currently GC-ing or not. So we don't need to check
for it, which removes the requirement to pass in the JS context (needed for
AssertHeapIsIdle's runtime check); this unblocks progress where otherwise we'd
have to figure out what the context is at the module level just to satisfy this
check.
2020-07-10 22:18:01 +08:00
Moonchild
b590ecea12 Issue #618 - Fix JSAPI additions to pass the JS context. 2020-07-10 22:17:55 +08:00
Moonchild
91a79c0ddc Issue #618 - Match JSAPI names with the changes in 9ca74147225eed305e28c7887f9b2251aeeb0f36
Ref: BZ 1388728
2020-07-10 22:17:52 +08:00
Moonchild
5838eded5f Issue #618 - Add APIs to query module record errors
Ref: BZ 1388728
2020-07-10 22:17:48 +08:00
Moonchild
c7d195e633 Issue #618 - Align module instantiation/errors with the updated spec.
Store and re-throw module instantiation and evaluation errors.
Ref: BZ 1374239, 1394492
2020-07-10 22:17:41 +08:00
wolfbeast
5386cd812b Issue #1570 - Implement globalThis
This resolves #1570
2020-06-06 07:19:04 +08:00
wolfbeast
2996c783d8 Revert #1091 Remove unboxed object code phase 1 + extras.
This should be the last code backout for this. merging this branch
should get us back to the way we were (+ additional code changes for
later changes) as fasr as the unused unboxed code is concerned.
2020-02-27 07:34:57 +08:00
Gaming4JC
10b93afff4 Bug 1331092 - Part 2: Implement Async Generator except yield*.
Tag #1287
2019-12-18 09:16:52 +08:00
wolfbeast
ca9e376e55 Issue #1257 - Part 2: Remove watch/unwatch and JS watchpoint class. 2019-11-01 10:24:09 +08:00
wolfbeast
cfc50f18c4 Fix a crash in IndexedDB. 2019-09-06 23:49:51 +08:00
Gaming4JC
367fc9432e Issue #1195 - Fix errant use of JSContext in ErrorNotes
We want to ensure that ErrorNotes stays on the main thread to prevent a race condition that was introduced in 1283712 - Part 1. This fixes #1195.
2019-07-22 19:56:06 +08:00
Gaming4JC
6072c7290b Make JSErrorNotes Single Threaded 2019-07-22 19:49:35 +08:00
Gaming4JC
c2bd1ca0bc 1283712 - Part 1: Add JSErrorBase, JSErrorNotes, JSErrorNotes::Note, and JSErrorReport.{notes,freeNotes}. 2019-07-22 19:49:32 +08:00
Gaming4JC
8a42a64748 1320408 - Part 23: Change RegExpObject::{getShared,createShared,dumpBytecode} to static method. 2019-07-22 19:48:59 +08:00
Gaming4JC
e5b36e01b9 1320408 - Part 20: Change PromiseObject::resolve and PromiseObject::reject to static method. 2019-07-22 19:48:40 +08:00
Gaming4JC
cc8cb910dd 1320408 - Part 14: Change some GlobalObject methods to static method. 2019-07-22 19:48:14 +08:00
Gaming4JC
d208cccd10 1320408 - Part 12: Change JSScript::sourceData to static method. 2019-07-22 19:48:01 +08:00
Gaming4JC
7f856ff769 1320408 - Part 9: Change JSObject::setFlags and depending methods to static method. 2019-07-22 19:47:51 +08:00
Gaming4JC
07cd213071 1320408 - Part 2: Change JSFunction::getOrCreateScript to static method. 2019-07-22 19:47:27 +08:00
Gaming4JC
146dbe7bee 1323324 - Part 1: Make Promise::unforgeable{Resolve,Reject} spec-compliant. 2019-07-22 19:46:50 +08:00
wolfbeast
3c6346afa9 Unhook Unboxed Objects option 2019-05-24 21:55:41 +08:00
wolfbeast
b68de773fd Stage 1-1: Implement Function.prototype.toString revision proposal.
Tag #960
2019-04-13 07:00:18 +08:00
wolfbeast
eb32b5d7e4 Pref the use of unboxed plain objects in JS and disable by default.
This should be all that's needed for #1017, but verification of
impact is definitely desired.
2019-03-23 06:44:08 +08:00
wolfbeast
930cc1db3b Fix a longstanding IndexedDB correctness issue.
Standards Compliance fix, port of Bug 1492737
2019-02-16 00:18:35 +08:00
janekptacijarabaci
748c69d7fd Part 1: Implement ES6 function name property semantics
Issue #78
2019-02-15 23:38:44 +08:00
janekptacijarabaci
e7ee7caf1e Bug 1320388: Move JSFunction::HAS_REST to JSScript and LazyScript
Issue #78
[Depends on] Bug 883377: Implement ES6 function "name" property
semantics
2019-02-15 23:38:38 +08:00
janekptacijarabaci
0e7a16c088 Bug 755821: Function() should use the parser's argument parsing code 2019-02-15 23:38:10 +08:00
wolfbeast
b5de790f2a Remove remaining conditional GCZeal code.
Creates stubs:
jsgc.h/cpp
VerifyBarriers() stub
MaybeVerifyBarriers() stub
GCRuntime::computeNonIncrementalMarkingForValidation() stub
GCRuntime::validateIncrementalMarking() stub
GCRuntime::finishMarkingValidation() stub
GCRuntime::pushZealSelectedObjects() stub
bool useZeal?
GCRuntime::runDebugGC() stub
XPConnect:
nsXPCComponents_Utils::SetGCZeal() stub (always NS_OK)
2019-02-14 14:37:52 +08:00
wolfbeast
935b074787 Implement configuration pref for Generational Garbage Collection.
Pref: javascript.options.mem.gc_generational
This resolves #20
2019-02-14 14:28:26 +08:00
Roy Tam
dcd9973243 import FIREFOX_52_6_0esr_RELEASE from mozilla-esr52 hg repo 2018-01-19 03:59:58 +08:00