| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a patch on top of the original patch that adds support for
external resources to v8::Object.
When the provided external resource pointer cannot be encoded in SMI, then we
need to allocate an object on the heap to hold it. That in turn may trigger a
garbage collection, which in turn may end up collecting the object itself.
Similarly to other methods dealing with the allocation of i::Foreign, the
insertion of a HandleScope is required.
Done-with: Lars
Task-Number: QTBUG-29127
Change-Id: I9a99998e2fbfcb8a4c1e31595344680123072c6b
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
|
| |
These methods were used in QtDeclarative but more "V8-friendly"
implementations are used now.
This change should be squashed into the "[V8] Add hashing and comparison
methods to v8::String" commit (566a226893aaba42d7e1f5522b9d80c1cc9dc2a3)
in the next V8 rebase.
Change-Id: I996480619b6622060c725d88015223f28336ae64
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
|
| |
New function v8::Value::IsError was created.
This API is experimental and added only for the purposes of our
research.
Change-Id: Ie9c75681f956a43944c95737b8a2fb57a699df97
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A global custom object comparison callback can be set with:
V8::SetUserObjectComparisonCallbackFunction()
When two JSObjects are compared (== or !=), if either one has
the MarkAsUseUserObjectComparison() bit set, the custom comparison
callback is invoked to do the actual comparison.
This is useful when you have "value" objects that you want to
compare as equal, even though they are actually different JS object
instances.
Change-Id: I5c031b4d90c8a77f4c4ffa38270976397322db76
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
| |
Change-Id: I1fcb08b1d92a3c9ab65fac7a6621588c2bf1c248
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In QML mode, there is a second global object - known as the QML
global object. During property resolution, if a property is not
present on the JS global object, it is resolved on the QML global
object.
This global object behavior is only enabled if a script is being
compiled in QML mode. The object to use as the QML global object
is passed as a parameter to the Script::Run() method. Any function
closures etc. created during the run will retain a reference to this
object, so different objects can be passed in different script
runs.
Change-Id: I75d6f8173260e0d4933fd33ad16a277542048f09
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
V8 was already able to manage and finalize an external string
resource. This change generalizes that mechanism to handle a
single generic external resource - a v8::Object::ExternalResource
derived instance - on normal JSObject's.
This is useful for mapping C++ objects to JS objects where the
C++ object's memory is effectively owned by the JS Object, and
thus needs to destroyed when the JS Object is garbage collected.
The V8 mailing list suggests using a weak persistent handle for
this purpose, but that seems to incur a fairly massive performance
penalty for short lived objects as weak persistent handle callbacks
are not called until the object has been promoted into the old
object space.
Change-Id: Idd4474634d21bf4e021f1ccfb0d6a855ee80bed8
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
By default interceptors are called before the normal property
resolution on objects. When an interceptor is installed as a
"fallback" interceptor, it is only called if the object doesn't
already have the property.
In the case of a global object having an fallback interceptor,
the interceptor is not invoked at all for var or function
declarations.
Change-Id: Iac09d4243b0407a7b3e9ba9149f8d447b7af7766
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
| |
This allows us to more rapidly search for a v8::String inside a hash
of QStrings.
Change-Id: I8f7d7499b02103f346ef02a1e2c70033a0619fbe
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
2215c442af2f0a4fce076e35ea061486d62778a1
Update V8 source to version 3.15.2
* Performance and stability improvements on all platforms.
* Avoid overdeep recursion in regexp where a guarded expression with a
minimum repetition count is inside another quantifier.
* Exposed last seen heap object id via v8 public api.
* Implemented heap profiler memory usage reporting.
* Preserved error message during finally block in try..finally.
* Improved heuristics to keep objects in fast mode with inherited
constructors.
* Fixed lazy sweeping heuristics to prevent old-space expansion.
* Fixed sharing of literal boilerplates for optimized code.
* Expose more detailed memory statistics.
* Cleaned up hardfp ABI detection for ARM (V8 issue 2140).
* Report "hidden properties" in heap profiler for properties case.
* Added optimizing compiler support for JavaScript getters.
* Fixed computation of call targets on prototypes in Crankshaft.
* Fixed ICs for slow objects with native accessor.
* Fixed transcendental cache on ARM in optimized code (issue 2234).
* New heap inspection tools: counters for object sizes and counts,
histograms for external fragmentation.
* Added more support for heap analysis.
* Interpret negative hexadecimal literals as NaN. (issue 2240)
* Improved API calls that return empty handles.
* Added checks for interceptors to negative lookup code in Crankshaft.
* Introduced global contexts to represent lexical global scope(s).
* Allocate block-scoped global bindings to global context.
* Add empty-handle checks to API functions (#ifdef ENABLE_EXTRA_CHECKS)
* Check the return value of API calls on ia32 and x64.
* Activated fixed ES5 readonly semantics by default.
* Added validity checking to API functions and calls.
* Switched on code compaction on incremental GCs.
* ARM: allowed VFP3 instructions when hardfloat is enabled. (Chromium issue 152506)
* Killed off the SCons based build. (relevant for testing)
* Added a faster API for creating v8::Integer objects.
* Speeded up function deoptimization by avoiding quadratic pass over optimized function list. (Chromium issue 155270)
* ES6: Added support for size to Set and Map (issue 2395)
* ES6: Added support for Set and Map clear method (issue 2400)
* Made formatting error message side-effect-free. (issue 2398)
* Fixed V8 issues: 915, 1374, 1465, 1569, 1591, 1609 1645, 1804, 1914, 1981, 1991, 2016, 2017,
2034, 2077, 2087, 2094, 2119, 2120, 2133, 2134, 2139, 2143, 2151, 2156, 2166, 2170, 2172,
2177, 2179, 2185, 2193, 2194, 2201, 2210, 2212, 2219, 2220, 2225, 2239, 2245, 2252, 2260,
2261, 2294, 2297, 2308, 2312, 2313, 2317, 2318, 2322, 2326, 2364, 2372, 2380
Change-Id: Ifa82ec37b6150fdf1c4364c93987a32bbbf6bfd1
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
| |
Ensures that uninitialised symbol_id is not dereferenced if the
string is created on the stack via code generators instead of on
the heap.
Task-number: QTBUG-23126
Change-Id: I083586ad46796e70b0246413742d326c60f379e5
Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu>
|
|
|
|
|
|
|
|
|
|
| |
New function v8::Value::IsError was created.
This API is experimental and added only for the purposes of our
research.
Change-Id: Id2f5a6728d15fc02ae3c03e6b49928afed0f62fa
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A global custom object comparison callback can be set with:
V8::SetUserObjectComparisonCallbackFunction()
When two JSObjects are compared (== or !=), if either one has
the MarkAsUseUserObjectComparison() bit set, the custom comparison
callback is invoked to do the actual comparison.
This is useful when you have "value" objects that you want to
compare as equal, even though they are actually different JS object
instances.
Change-Id: Id1794ffc17131566c7ee30ab5fcf11445dab2ab2
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
| |
Change-Id: I626c8bd090b83af1379fbd85e42b2dae44b5723d
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In QML mode, there is a second global object - known as the QML
global object. During property resolution, if a property is not
present on the JS global object, it is resolved on the QML global
object.
This global object behavior is only enabled if a script is being
compiled in QML mode. The object to use as the QML global object
is passed as a parameter to the Script::Run() method. Any function
closures etc. created during the run will retain a reference to this
object, so different objects can be passed in different script
runs.
Change-Id: I86851683200d02208379744c887dfebc010a7ccc
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
V8 was already able to manage and finalize an external string
resource. This change generalizes that mechanism to handle a
single generic external resource - a v8::Object::ExternalResource
derived instance - on normal JSObject's.
This is useful for mapping C++ objects to JS objects where the
C++ object's memory is effectively owned by the JS Object, and
thus needs to destroyed when the JS Object is garbage collected.
The V8 mailing list suggests using a weak persistent handle for
this purpose, but that seems to incur a fairly massive performance
penalty for short lived objects as weak persistent handle callbacks
are not called until the object has been promoted into the old
object space.
Change-Id: I8f1a1f2a2be052339e8507b98058b289c7f16b0a
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
By default interceptors are called before the normal property
resolution on objects. When an interceptor is installed as a
"fallback" interceptor, it is only called if the object doesn't
already have the property.
In the case of a global object having an fallback interceptor,
the interceptor is not invoked at all for var or function
declarations.
Change-Id: Icf2b84aeca37358df22d6e2229dddd6ff6e1876e
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
| |
This allows us to more rapidly search for a v8::String inside a hash
of QStrings.
Change-Id: I3243d9c97f93bc521cbbdca79cf9b2edac5969b7
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
3e6ec7e018bbf2c63ef04b85ff688198ea204c04
Update V8 source to version 3.11.4
* Performance and stability improvements on all platforms.
* Fixed native ARM build (issues 1744, 539)
* Fixed several bugs in heap profiles (including issue 2078).
* Throw syntax errors on illegal escape sequences.
* Made handling of const more consistent when combined with 'eval' and
'with'.
* Fixed V8 on MinGW-x64 (issue 2026).
* Put new global var semantics behind a flag until WebKit tests are
cleaned up.
* Enabled inlining some V8 API functions.
* Enabled MIPS cross-compilation.
* Implemented clearing of CompareICs (issue 2102).
* Fixed python deprecations. (issue 1391)
* Fixed GCC 4.7 (C++11) compilation. (issue 2136)
Change-Id: I72594bd22356391dd55e315c022d0c9f3fd5b451
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
| |
New function v8::Value::IsError was created.
This API is experimental and added only for the purposes of our
research.
Change-Id: I21c8a3484c2b5a0341b932bd81492b8ebc1f0e05
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A global custom object comparison callback can be set with:
V8::SetUserObjectComparisonCallbackFunction()
When two JSObjects are compared (== or !=), if either one has
the MarkAsUseUserObjectComparison() bit set, the custom comparison
callback is invoked to do the actual comparison.
This is useful when you have "value" objects that you want to
compare as equal, even though they are actually different JS object
instances.
Change-Id: Icd3419349874ee845684fff8455862da73f5ff2d
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
| |
Change-Id: I6efcd64530357a5ca789cd6cccd5426f370b64eb
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In QML mode, there is a second global object - known as the QML
global object. During property resolution, if a property is not
present on the JS global object, it is resolved on the QML global
object.
This global object behavior is only enabled if a script is being
compiled in QML mode. The object to use as the QML global object
is passed as a parameter to the Script::Run() method. Any function
closures etc. created during the run will retain a reference to this
object, so different objects can be passed in different script
runs.
Change-Id: Id3753db6f5723f6d624bd497d6f606244a4ff09a
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
V8 was already able to manage and finalize an external string
resource. This change generalizes that mechanism to handle a
single generic external resource - a v8::Object::ExternalResource
derived instance - on normal JSObject's.
This is useful for mapping C++ objects to JS objects where the
C++ object's memory is effectively owned by the JS Object, and
thus needs to destroyed when the JS Object is garbage collected.
The V8 mailing list suggests using a weak persistent handle for
this purpose, but that seems to incur a fairly massive performance
penalty for short lived objects as weak persistent handle callbacks
are not called until the object has been promoted into the old
object space.
Change-Id: I83677c9d906742a2bf0596961491eecb7ee60003
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
By default interceptors are called before the normal property
resolution on objects. When an interceptor is installed as a
"fallback" interceptor, it is only called if the object doesn't
already have the property.
In the case of a global object having an fallback interceptor,
the interceptor is not invoked at all for var or function
declarations.
Change-Id: Ia8c2b4d37070c97d9ef327da9e62d431427afe89
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
| |
This allows us to more rapidly search for a v8::String inside a hash
of QStrings.
Change-Id: I7d3dc8903bd2c64adc201da924ca2e4954711ec6
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
57f8959fb264354ba1a2e5118db512f588917061
Update V8 source to version 3.10.1.
* Added optimizations and stability improvements on all platforms.
* Various performance improvements.
* Cleanup ScopeInfo and SerializedScopeInfo.
* Introduce extended mode.
* Implemented performance improvements to the incremental garbage
collector.
* Fixed handling of arrays in DefineOwnProperty. (issue 1756)
* Fixed GCC 4.7 warnings.
* Performance improvements for large Smi-only arrays.
* Reduce the space used by the stack for the profiling thread.
* Reduced memory use immediately after starting V8.
* Fixed VFP detection through compiler defines. (issue 1996)
* Remove static initializers in v8. (issue 1859)
* Optimized boot-up memory use.
* Optimized regular expressions.
Change-Id: I2dad3092612de279179950dae4dd43daf0463a9f
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
|
|
|
|
|
|
|
|
|
|
| |
New function v8::Value::IsError was created.
This API is experimental and added only for the purposes of our
research.
Change-Id: I8f20d46bd81b18bcd7a7c2f7cfc25775d82a6834
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A global custom object comparison callback can be set with:
V8::SetUserObjectComparisonCallbackFunction()
When two JSObjects are compared (== or !=), if either one has
the MarkAsUseUserObjectComparison() bit set, the custom comparison
callback is invoked to do the actual comparison.
This is useful when you have "value" objects that you want to
compare as equal, even though they are actually different JS object
instances.
Change-Id: Ifb4074058566062accc2be20d43e3febc1089d13
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
|
|
|
|
|
| |
Change-Id: Ia62421388693604ca5666924337180734be891c0
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In QML mode, there is a second global object - known as the QML
global object. During property resolution, if a property is not
present on the JS global object, it is resolved on the QML global
object.
This global object behavior is only enabled if a script is being
compiled in QML mode. The object to use as the QML global object
is passed as a parameter to the Script::Run() method. Any function
closures etc. created during the run will retain a reference to this
object, so different objects can be passed in different script
runs.
Change-Id: Ib6b4ed363b7e8089d38a9cdcfb0d3b314dc333ca
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
V8 was already able to manage and finalize an external string
resource. This change generalizes that mechanism to handle a
single generic external resource - a v8::Object::ExternalResource
derived instance - on normal JSObject's.
This is useful for mapping C++ objects to JS objects where the
C++ object's memory is effectively owned by the JS Object, and
thus needs to destroyed when the JS Object is garbage collected.
The V8 mailing list suggests using a weak persistent handle for
this purpose, but that seems to incur a fairly massive performance
penalty for short lived objects as weak persistent handle callbacks
are not called until the object has been promoted into the old
object space.
Change-Id: I3d7b5fe4ca6e37d49c92f3314b80d42bd4c84fcd
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
By default interceptors are called before the normal property
resolution on objects. When an interceptor is installed as a
"fallback" interceptor, it is only called if the object doesn't
already have the property.
In the case of a global object having an fallback interceptor,
the interceptor is not invoked at all for var or function
declarations.
Change-Id: Ibbd0a6b3ad4bd68a8d15ce99520e71c46ad14f84
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
|
|
|
|
|
|
|
|
| |
This allows us to more rapidly search for a v8::String inside a hash
of QStrings.
Change-Id: Ied9625aeefba730816d9ed7aa609a36592e5fc33
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
06e55bc22bcb8ddb0a602e54e11971576f2d9d8a
* Implement VirtualMemory on FreeBSD to fix build (issue 1807).
* Fix error handling in Date.prototype.toISOString (issue 1792).
* Crankshaft for MIPS
* Bug fixes (mostly for MIPS)
* Use placement-new for zone-allocation in the Lithium classes.
Change-Id: I70ceacc4f7010cec58f73eb1826cbc06dd31149e
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
|
|
|
|
|
|
|
|
|
| |
New function v8::Value::IsError was created.
This API is experimental and added only for the purposes of our
research.
Change-Id: I16374083eae684d34dd73e46a41e565a4cd236d4
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A global custom object comparison callback can be set with:
V8::SetUserObjectComparisonCallbackFunction()
When two JSObjects are compared (== or !=), if either one has
the MarkAsUseUserObjectComparison() bit set, the custom comparison
callback is invoked to do the actual comparison.
This is useful when you have "value" objects that you want to
compare as equal, even though they are actually different JS object
instances.
Change-Id: Ic7512e8342c071793393e5ad3fcb6fb241f7cc80
|
|
|
|
| |
Change-Id: Iae8b5697d4ad73d7934ee50879859394c66c80da
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In QML mode, there is a second global object - known as the QML
global object. During property resolution, if a property is not
present on the JS global object, it is resolved on the QML global
object.
This global object behavior is only enabled if a script is being
compiled in QML mode. The object to use as the QML global object
is passed as a parameter to the Script::Run() method. Any function
closures etc. created during the run will retain a reference to this
object, so different objects can be passed in different script
runs.
Change-Id: I4950562d455074578c372d8e0e3089887b06e0a1
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
V8 was already able to manage and finalize an external string
resource. This change generalizes that mechanism to handle a
single generic external resource - a v8::Object::ExternalResource
derived instance - on normal JSObject's.
This is useful for mapping C++ objects to JS objects where the
C++ object's memory is effectively owned by the JS Object, and
thus needs to destroyed when the JS Object is garbage collected.
The V8 mailing list suggests using a weak persistent handle for
this purpose, but that seems to incur a fairly massive performance
penalty for short lived objects as weak persistent handle callbacks
are not called until the object has been promoted into the old
object space.
Change-Id: Ia21a181927a2e68d33a623bbe47e0f1a4404ec8e
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
By default interceptors are called before the normal property
resolution on objects. When an interceptor is installed as a
"fallback" interceptor, it is only called if the object doesn't
already have the property.
In the case of a global object having an fallback interceptor,
the interceptor is not invoked at all for var or function
declarations.
Change-Id: I9228c114b2d2f3a9386617b53f7d8ac86371159d
|
|
|
|
|
|
|
| |
This allows us to more rapidly search for a v8::String inside a hash
of QStrings.
Change-Id: I0a8bfb1aa34f00d987862a7bfe94c822a73d8c54
|
|
Change-Id: I152648081e46f599c2bb88eaaf67034fa5daac3a
|