- 05 Nov, 2014 1 commit
-
-
aandrey@chromium.org authored
This also naturally handles pausing on uncaught exceptions in Object.observe callbacks. R=adamk@chromium.org, yangguo@chromium.org, yurys@chromium.org BUG=chromium:335660 LOG=Y Review URL: https://codereview.chromium.org/692313003 Cr-Commit-Position: refs/heads/master@{#25126} git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@25126 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 29 Oct, 2014 3 commits
-
-
adamk@chromium.org authored
The biggest change is the removal of the map wrapper objects: we now operate directly on the observation weak map, since there are already Get/GetOrCreate/Set functions for each info map. Various other small cleanups as well, including the deletion of unnecessary forwarding functions and making use of standard macros. This is a reland of r24972, retaining GetObservationStateJS() to keep snapshotting working properly. R=rossberg@chromium.org Review URL: https://codereview.chromium.org/663253006 Cr-Commit-Position: refs/heads/master@{#24990} git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24990 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
adamk@chromium.org authored
It broke the context snapshot by trying to get ahold of the per-isolate observation_state object too early. This reverts commit a137cb74. TBR=yangguo@chromium.org Review URL: https://codereview.chromium.org/692473002 Cr-Commit-Position: refs/heads/master@{#24977} git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24977 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
adamk@chromium.org authored
The biggest change is the removal of the map wrapper objects: we now operate directly on the observation weak map, since there are already Get/GetOrCreate/Set functions for each info map. Various other small cleanups as well, including the deletion of unnecessary forwarding functions and making use of standard macros. R=arv@chromium.org, rossberg@chromium.org Review URL: https://codereview.chromium.org/686773002 Cr-Commit-Position: refs/heads/master@{#24972} git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24972 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 15 Oct, 2014 1 commit
-
-
jkummerow@chromium.org authored
Saving a runtime call for many builtin functions. R=ishell@chromium.org Review URL: https://codereview.chromium.org/651223002 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24636 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 14 Jul, 2014 1 commit
-
-
verwaest@chromium.org authored
BUG= R=ishell@chromium.org Review URL: https://codereview.chromium.org/384003003 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@22381 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 03 Jul, 2014 1 commit
-
-
aandrey@chromium.org authored
R=yangguo@chromium.org, adamk@chromium.org, rafaelw@chromium.org, rossberg@chromium.org BUG=chromium:272416 LOG=Y Review URL: https://codereview.chromium.org/362783002 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@22204 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 27 Jun, 2014 1 commit
-
-
verwaest@chromium.org authored
Split SetProperty(...attributes, strictmode) into DefineProperty(...attributes) and SetProperty(...strictmode) BUG= R=rossberg@chromium.org Review URL: https://codereview.chromium.org/351853005 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@22064 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 28 May, 2014 1 commit
-
-
rafaelw@chromium.org authored
The original patch which ensured that Object.observe did allocations in the correct context regressed performance about 12%. This patch gets back most of that (about 11%) by simply returning the correct function which is then directly callable from JS, rather than by making the call from the runtime function. A side-effect is that their implementation is shorter. LOG=Y BUG=NONE R=verwaest@chromium.org Review URL: https://codereview.chromium.org/307543008 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@21575 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 19 May, 2014 1 commit
-
-
adamk@chromium.org authored
This avoids the appearence of a leak due to storing a JSObject as the microtask_state in the strong root list, and allows callers to call Isolate::RunMicrotasks() without having any v8::Context available (as at least Blink has interest in doing). The queue is now a strong root, represented as a FixedArray of JSFunctions (or empty_fixed_array, if it's empty); it doubles in size when it needs to grow. The number of elements in the queue is stored in Isolate::pending_microtask_count(). LOG=Y R=dcarney@chromium.org Review URL: https://codereview.chromium.org/290633010 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@21356 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 14 May, 2014 1 commit
-
-
jkummerow@chromium.org authored
This makes it possible to use %Percent() notation to call any given builtin or runtime function in tests. R=dslomov@chromium.org Review URL: https://codereview.chromium.org/280243002 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@21298 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 09 May, 2014 1 commit
-
-
adamk@chromium.org authored
BUG=v8:3315 LOG=Y R=rossberg@chromium.org Review URL: https://codereview.chromium.org/270763003 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@21244 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 02 May, 2014 4 commits
-
-
adamk@chromium.org authored
Due to overlapping names of natives and runtime functions, the wrong context was used for Notifier.prototype.performChange. The leak test has been augmented to properly cover the leaky case, and the test now passes. Also tightened up type checks in runtime.cc and removed Object.observe functions from knownIssues in fuzz-natives-part2.js. R=jkummerow@chromium.org Review URL: https://codereview.chromium.org/264793015 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@21129 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
rafaelw@chromium.org authored
The Object.observe API may construct internal structures as a result of API calls. These structures can persist as long as an object that was once observed persists. This patch ensures that these structures are created in the correct context so as to avoid leaking contexts R=verwaest@chromium.org, dcarney BUG= Review URL: https://codereview.chromium.org/263833007 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@21126 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
rafaelw@chromium.org authored
This patch reverts r21062 which disabled Object.observe and the relevant tests. It also adds enforcement for the following three invariants: 1) No observer may receive a change record describing changes to an object which is in different security origin (context have differing security tokens) 2) No observer may receive a change record whose context's security token is different from that of the object described by the change. 3) Object.getNotifier will return null if the caller and the provided object are in differing security origins Further, it ensures that the global object can never be observed nor a notifier retrieved for it. Tests are included. R=verwaest@chromium.org, rossberg LOG=Y Review URL: https://codereview.chromium.org/265503002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@21122 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
haraken@chromium.org authored
RunMicrotasks() executes pending tasks and swaps the old array with a new array. However, the new array contains the reference to the current context as its creation context. This prevents the context from gc-ed until RunMicrotasks() is executed in the different context. BUG=crbug.com/367016 LOG=y R=rafaelw@chromium.org, rossberg@chromium.org Review URL: https://codereview.chromium.org/250883002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@21111 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 29 Apr, 2014 2 commits
-
-
danno@chromium.org authored
R=danno@chromium.org, danno BUG= Review URL: https://codereview.chromium.org/252063003 Patch from Rafael Weinstein <rafaelw@chromium.org>. git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@21062 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
bmeurer@chromium.org authored
R=svenpanne@chromium.org Review URL: https://codereview.chromium.org/259183002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@21035 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 14 Apr, 2014 1 commit
-
-
adamk@chromium.org authored
The intent of these calls was to properly key the WeakMap get/set calls on the underlying global object, not the proxy, since that is the object actually being observed. But unwrapping at this layer is unnecessary since GetIdentityHash will already do the unwrapping (via its call to GetHiddenProperty). Also remove the runtime function itself, as these were the only callers, and remove the now-redundant IS_SPEC_OBJECT() checks from object-observe.js's MapWrapper type. R=verwaest@chromium.org Review URL: https://codereview.chromium.org/234143002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@20740 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 13 Mar, 2014 1 commit
-
-
adamk@chromium.org authored
This re-re-re-lands enabling Object.observe. The Chromium tests that failed last time this was rolled into Chromium have been disabled in https://src.chromium.org/viewvc/chrome?view=revision&revision=256706 This patch should be safe to merge once that lands. BUG=v8:2409 LOG=Y TBR=rossberg@chromium.org,dslomov@chromium.org,rafaelw@chromium.org Review URL: https://codereview.chromium.org/198383002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19868 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 11 Mar, 2014 1 commit
-
-
dslomov@chromium.org authored
This reverts commit r19734 for breeaking ChromiumOS browser tests. 'OpenSpecialTypes/FileManagerBrowserTest.Test/3' started to time out, bisecting the roll led to this change. http://build.chromium.org/p/chromium.chromiumos/builders/Linux%20ChromiumOS%20Tests%20%282%29/builds/22224 TBR=rafaelw@chromium.org,rossberg@chromium.org BUG=v8:2409 LOG=Y Review URL: https://codereview.chromium.org/195123005 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19816 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 08 Mar, 2014 3 commits
-
-
rafaelw@chromium.org authored
Original Issue: https://codereview.chromium.org/183683022/ TBR=rossberg BUG=v8:2409 LOG=Y Review URL: https://codereview.chromium.org/189513010 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19736 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
rafaelw@chromium.org authored
TBR=rossberg BUG= Review URL: https://codereview.chromium.org/190853007 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19735 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
rafaelw@chromium.org authored
R=rossberg@chromium.org, rossberg BUG=v8:2409 LOG=Y Review URL: https://codereview.chromium.org/183683022 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19734 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 12 Feb, 2014 1 commit
-
-
rafaelw@chromium.org authored
This patch generalizes Object.observe callbacks and promise resolution into a FIFO queue called a "microtask queue". It also exposes new V8 API which exposes the microtask queue to the embedder. In particular, it allows the embedder to -schedule a microtask (EnqueueExternalMicrotask) -run the microtask queue (RunMicrotasks) -control whether the microtask queue is run automatically within V8 when the last script exits (SetAutorunMicrotasks). R=dcarney@chromium.org, rossberg@chromium.org, dcarney, rossberg, svenpanne BUG= Review URL: https://codereview.chromium.org/154283002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19344 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 07 Feb, 2014 1 commit
-
-
rafaelw@chromium.org authored
TBR=adamk,rossberg BUG= Review URL: https://codereview.chromium.org/150103012 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19176 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 04 Feb, 2014 1 commit
-
-
rafaelw@chromium.org authored
R=rossberg@chromium.org, rossberg BUG= Review URL: https://codereview.chromium.org/131413008 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19084 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 08 Jan, 2014 1 commit
-
-
rafaelw@chromium.org authored
This patch includes the follow two minor optimizations: 1) When Object.unobserve-ing, instead of deleting from changeObservers, set the index position to null, and null-check when iterating elsewhere 2) Isolate creation of null-proto objects inside a utility function These former (deleting) was clearly showing up in d8 --prof traces and the later was preventing optimization of containing functions because of non-standard literal. Combined, on MDV construction/teardown benchmark, saves about 10%. Note that this patch also cleans up retrieving objectInfo inside a utility function. R=rossberg@chromium.org, rossberg BUG= Review URL: https://codereview.chromium.org/123523002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18501 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 27 Nov, 2013 1 commit
-
-
rossberg@chromium.org authored
Based on prototype at https://github.com/rossberg-chromium/js-promise which informed the latest spec draft version at https://github.com/domenic/promises-unwrapping/blob/master/README.md Activated by --harmony-promises. Feature complete with respect to the draft spec, plus the addition of .when and .deferred methods. Final naming and other possible deviations from the current draft will hopefully be resolved soon after the next TC39 meeting. This CL also generalises the Object.observe delivery loop into a simplistic microtask loop. Currently, all observer events are delivered before invoking any promise handler in a single fixpoint iteration. It's not clear yet what the final semantics is supposed to be (should there be a global event ordering?), but it will probably require a more thorough event loop abstraction inside V8 once we get there. R=dslomov@chromium.org, yhirano@chromium.org BUG= Review URL: https://codereview.chromium.org/64223010 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18113 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 06 Nov, 2013 1 commit
-
-
rafaelw@chromium.org authored
Note the spec now reflects the updated naming: http://wiki.ecmascript.org/doku.php?id=harmony:observe_spec_changes R=rossberg@chromium.org, rossberg BUG=v8:2940 Review URL: https://codereview.chromium.org/46043020 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17520 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 05 Nov, 2013 2 commits
-
-
rafaelw@chromium.org authored
Note: spec has been updated here: http://wiki.ecmascript.org/doku.php?id=harmony:observe_spec_changes. R=rossberg@chromium.org, rossberg BUG=v8:2975,v8:2941 Review URL: https://codereview.chromium.org/47703003 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17481 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
rafaelw@chromium.org authored
R=arv@chromium.org, rossberg@chromium.org, rossberg BUG=v8:2942 Review URL: https://codereview.chromium.org/36313002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17476 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 17 Oct, 2013 1 commit
-
-
yangguo@chromium.org authored
Nobody should need to use $NaN, 0/0, 1/0 and void 0. R=mvstanton@chromium.org BUG= Review URL: https://codereview.chromium.org/27491002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17252 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 13 Sep, 2013 1 commit
-
-
rossberg@chromium.org authored
R=rossberg@chromium.org BUG= Review URL: https://codereview.chromium.org/23464058 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16703 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 11 Sep, 2013 2 commits
-
-
adamk@chromium.org authored
This change is mostly straightforward: for 'normal' sorts of change records, simply don't deliver a changeRecord to a given observer callback if an access the callback's Context is not allowed to "GET" or "HAS" changeRecord.name on changeRecord.object, or if ACCESS_KEYS is disallowed. For 'splice' records, the question of whether to hand it to an observer is trickier, since there are multiple properties involved, and multiple types of possible information leakage. Given that access-checked objects are very rare (only two in Blink, Window and Location), and that they are not normally used as Arrays, it seems better to simply not emit any splice records for such objects rather than spending lots of logic to attempt to avoid information leakage for something that may never happen. BUG=v8:2778 R=rossberg@chromium.org Review URL: https://codereview.chromium.org/22962009 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16663 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
rossberg@chromium.org authored
The spec omits the receiver arg with the idea arrow functions with lexical |this| will obviate the need for it. BUG= R=rossberg@chromium.org Review URL: https://codereview.chromium.org/23727006 Patch from Rafael Weinstein <rafaelw@chromium.org>. git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16644 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 10 Sep, 2013 1 commit
-
-
adamk@chromium.org authored
This patch implements optimized objectInfo structure which manages the set of observers associated with an object and the changeRecord types which they accept. Observation in the normal case (Object.observe, default accept types, one observer) now allocates fewer objects and unobservation no longer needs to scan and splice an InternalArray -- making the combined speed of observe/unobserve about 200% faster. This patch implements the following optimizations: -objectInfo is initially created without any connected objects or arrays. The first observer is referenced directly by objectInfo, and when a second observer is added, changeObservers converts to a mapping of callbackPriority->observer, which allows for constant time registration/de-registration. -observer.accept and objectInfo.performing are conceptually the same data-structure. This is now directly represented as an abstract "TypeMap" which can later be optimized to be a smi in common cases, (e.g: https://codereview.chromium.org/19269007/). -objectInfo observers are only represented by an object with an accept typeMap if the set of accept types is non-default R=rossberg@chromium.org Review URL: https://codereview.chromium.org/19541010 Patch from Rafael Weinstein <rafaelw@chromium.org>. git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16629 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 04 Sep, 2013 2 commits
-
-
adamk@chromium.org authored
Revert "This patch implements optimized objectInfo structure which manages the set of observers associated with an object and the changeRecord types which they accept." This reverts r16539 as it triggers crashes on the GC stress bot. git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16540 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
adamk@chromium.org authored
This patch implements optimized objectInfo structure which manages the set of observers associated with an object and the changeRecord types which they accept. Observation in the normal case (Object.observe, default accept types, one observer) now allocates fewer objects and unobservation no longer needs to scan and splice an InternalArray -- making the combined speed of observe/unobserve about 200% faster. This patch implements the following optimizations: -objectInfo is initially created without any connected objects or arrays. The first observer is referenced directly by objectInfo, and when a second observer is added, changeObservers converts to a mapping of callbackPriority->observer, which allows for constant time registration/de-registration. -observer.accept and objectInfo.performing are conceptually the same data-structure. This is now directly represented as an abstract "TypeMap" which can later be optimized to be a smi in common cases, (e.g: https://codereview.chromium.org/19269007/). -objectInfo observers are only represented by an object with an accept typeMap if the set of accept types is non-default R=rossberg@chromium.org Committed: https://code.google.com/p/v8/source/detail?r=16343 Review URL: https://codereview.chromium.org/19541010 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16539 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-
- 26 Aug, 2013 1 commit
-
-
adamk@chromium.org authored
Revert "This patch implements optimized objectInfo structure which manages the set of observers associated with an object and the changeRecord types which they accept." This reverts r16343 due to mjsunit object-observe failures on several bots: - V8 Linux nosse2 - V8 GC stress 2 TBR=rossberg Review URL: https://codereview.chromium.org/23491002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16344 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
-