summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fix loading of this value on 32-bitHEADmasterSimon Hausmann2013-04-151-0/+4
| | | | | | | Make sure to copy all 64-bits out of ctx->thisObject Change-Id: I9984f83f5f238177e75e469c574ef49ee5bb0665 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Tiny optimisationLars Knoll2013-04-151-2/+2
| | | | | Change-Id: Iba4355e547c6f0d18bb31a977448bf433021c9f9 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Add some inline property data to ObjectLars Knoll2013-04-152-4/+11
| | | | | | | | This avoids malloc'ing the memberData array in most cases, and speed up the V8 benchmark by another 10% Change-Id: Id5976a9f9b389ee2d1568211b486c2896d818dd3 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Smaller cleanupsLars Knoll2013-04-153-21/+12
| | | | | Change-Id: I47e0211536ca7bae2f38aca04cb5e338759caa68 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove context argument for increment/decrement valueLars Knoll2013-04-154-8/+8
| | | | | Change-Id: I35c87190527a9eebd596aba8c4b100be77f552cd Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Fix compilation in release modeLars Knoll2013-04-151-1/+1
| | | | | Change-Id: I02a41aa5336c8aaad8584c1b8a857ee6cecc2370 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Specialized lookups for accessor propertiesLars Knoll2013-04-152-2/+140
| | | | | Change-Id: Ic4afb5b2b73b3311077d3d64ddc03fa6da842e82 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Implement fast lookup for constructor calls to the global objectLars Knoll2013-04-153-0/+32
| | | | | Change-Id: I8a03089032aabdd7cf07c3dd197f6f47dabd66ab Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove unused methodLars Knoll2013-04-151-5/+0
| | | | | Change-Id: I6961116e0b973d46e497d96d97203cb6046a06bb Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Small fix for qmljs_delete_subscriptLars Knoll2013-04-151-5/+1
| | | | | Change-Id: I19f5ae0bb0a138756bb3396ebda6300eb8958b16 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove the context pointer from unary operationsLars Knoll2013-04-155-24/+19
| | | | | Change-Id: Idaf67f719402666e11676983d6bc99952f48a72d Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Get rid of qmljs_get_this_objectLars Knoll2013-04-154-6/+4
| | | | | | | This is trivial to inline. Change-Id: Idccfc3c39d19e85768ec1be4b3b62b67abf00325 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove the ExecutionContext parameter from some methodsLars Knoll2013-04-1516-306/+300
| | | | | | | We can avoid passing the context into many methods now. Change-Id: I3cfedd679441117c5ea3aa735d5342788d7dfac5 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* use lookups for the global scopeLars Knoll2013-04-1513-12/+180
| | | | | | | | Gives about 12% speed improvement for the V8 benchmark. fact.2.js is almost twice as fast. Change-Id: Icfa1a780b30e131b9531e12f4bd569516c404e86 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Introduce specialized lookup methodsLars Knoll2013-04-144-10/+77
| | | | | | | | Add specialized lookup methods for data properties. Speeds up the v8 benchmark by ~10% Change-Id: Ib61a59529b6eaba1ac5ad3020fd1ff52594b7ddf Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Move the lookup class into it's own fileLars Knoll2013-04-146-80/+205
| | | | | Change-Id: Id57b23ebd6de4579f8e425bd2964b1249fb327c1 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Fix build of the rest of v4vm against WTF/JSC updateSimon Hausmann2013-04-126-12/+25
| | | | | | | | | * Add missing functions to our WTF stubs * Some of the math functions wrapped with MathExtras.h are back in the std:: namespace they belong to Change-Id: I9da43e8344ab8c95edc8db19f44ccdbd91b4ac70 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Apply modifications on top of WTF/JSCSimon Hausmann2013-04-124-16/+9
| | | | | | | | | * Extend FunctionPtr by another overloaded constructor that allows passing 6 arguments * Work around STL <> WTF incompatibilities with iterators * Remove unused printInternal functions that rely on CString/WTFString Change-Id: Ie0cc503288871cb594716e47e03dd509b1b5ac85 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* WTF/JSC update to r148273Simon Hausmann2013-04-1245-711/+2304
| | | | | | | | | | | | | This brings in various bug fixes in the ARM and MIPS assemblers as well as a Yarr crash fix and performance fix. This change doesn't compile as-is, but the next change will apply the modifications necessary to compile. That'll make future updates easier as it allows for cherry-picking because the modifications are usually always the same. Change-Id: Iac32f62c71e8ff908deb41f28f12fbc98c0823e1 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Smaller cleanup in the lookup codeLars Knoll2013-04-122-6/+6
| | | | | Change-Id: I74835d7c088b803205aa417ec2b7a2808f66f6ca Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Rename file to reflect class name changeLars Knoll2013-04-128-7/+7
| | | | | Change-Id: Ib6d32ac61f54f2fb4325f67c54aeb01b99624ab9 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove getValueChecked()Lars Knoll2013-04-123-19/+8
| | | | | | | | In the two places where we need to check, we can do it more easily on the calling side. Change-Id: I259d3cc798660121bba13208ef46e371e3173053 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove context arguments where they aren't requiredLars Knoll2013-04-1211-49/+49
| | | | | | | | A bunch of methods took pointers to the current execution context even though they don't require it. Change-Id: I2a504a72069af16bb8bdbb62be438ee1cab723b0 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Simplify logic for put and putIndexedLars Knoll2013-04-121-33/+14
| | | | | Change-Id: Ia67dc06f505fdb064a22920a9786708aa6d83e6e Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Move property attributes out of the property arraysLars Knoll2013-04-1234-643/+908
| | | | | | | | | | | Rather large change that fully separates the property attributes from the property data. This saves quite some memory. Since the property data for members is saves in the class structure it'll also allow optimizations to the lookup code. Change-Id: I9ba1d372bb756695bef8188d1b86275562a1b219 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Small fix to PropertyAttributesLars Knoll2013-04-122-5/+7
| | | | | Change-Id: I9fc8b291c434dc6552eba2a39623a4fe75291e0f Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Move functionality from PropertyDescriptor to PropertyLars Knoll2013-04-127-135/+128
| | | | | Change-Id: I37177b5287ec323f54826cce1cb307ee7f678930 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Use PropertyAttributes in PropertyDescriptorLars Knoll2013-04-1219-239/+168
| | | | | | | | | This further encapsulates the property attribute handling, and will allow to separate the attributes from the proprety data. Change-Id: I140a6c9349cd1e871cd9fdcef51abac7ae78e517 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Make the PropertyAttributes a proper classLars Knoll2013-04-124-34/+76
| | | | | Change-Id: Ia81236136aedcddaad303187b353cfcf03d792c6 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Change internal class when attributes of properties changeLars Knoll2013-04-1217-80/+117
| | | | | | | | | | This should allow us to share property attributes for different class instances saving quite some memory. In addition, it can be used to speed up property access (as we then know in the lookup whether it's a data or accessor property). Change-Id: Ide9c6168a07b5c83a1e73d075d8fc4f6594e08fd Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Simplify internal class logicLars Knoll2013-04-083-26/+10
| | | | | | | | getOrAddMember was always used for adding. Make that explicit. Change-Id: Iff202a83e857aefd231eadf59f310619c4338b52 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Avoid defining name twice in some error objectsLars Knoll2013-04-083-44/+18
| | | | | Change-Id: I2e96718556ef5a4262816233351b71dd6a80cb9d Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Store the global object as an Object pointer in the engineLars Knoll2013-04-086-47/+45
| | | | | Change-Id: Ia8b010a9d9c9dd3aacb1b08ce34a42236fa73195 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Change the Context stack back to a singly linked listLars Knoll2013-04-077-85/+33
| | | | | | | | | | | | | | The other implementation was too complicated, and only solved one special case (indirect eval calls), but that one can be solved by simply creating a GlobalContext when needed. In addition it'll make it simpler to implement context optimisations for simple methods in the future. Speeds up the V8 benchmark by 3% Change-Id: I61ac7753821e0174476094f51a9a4e934563f8e0 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Convert the remaining builtin methods to use the SimpleCallContextLars Knoll2013-04-0614-225/+173
| | | | | Change-Id: Ib01bd0c15578b93829abd6fcf8df22cac12daf14 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Introduce a SimpleCallContext for simple functionsLars Knoll2013-04-0629-291/+315
| | | | | | | | Use it for most builtin methods. Gives ~10% speed improvement on the V8 benchmark. Change-Id: I0039f102e561c0adbe1a9b070150ad32142a33e8 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Fix scope for functions created through bind()Lars Knoll2013-04-061-1/+1
| | | | | Change-Id: I69718b2943259dc0f6d6bf2856e651bfb4fbe3a5 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Move arguments out of ExecutionContext and into CallContextLars Knoll2013-04-0533-286/+274
| | | | | Change-Id: Ic826e3e71eac9171fa113dec79db7c69982f2386 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Move activation out of ExecutionContextLars Knoll2013-04-054-86/+113
| | | | | | | | Have an activation object (for now) in CallContext, and a global object in the GlobalContext. Change-Id: I02b1e6a2e976d914acfcc3d35cd8abda08dfd298 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Don't create new Objects in the current scopeLars Knoll2013-04-051-1/+1
| | | | | | | | | | | When creating new objects through the V8 API, use the root context, not the current context. Fixes some crashes in QML, after creating contexts on the stack again. Change-Id: I9e49fa39f6222dcfa747b7466f1555572dc24f94 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Move function pointer from ExecutionContext to CallContextLars Knoll2013-04-056-40/+29
| | | | | Change-Id: Id992154d38e26ee95ccf6f175eeab360c63c0b04 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove unused methodsLars Knoll2013-04-052-38/+0
| | | | | Change-Id: I928b9c4816b421e3d79bd038c37e24d09129899d Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Move locals from ExecutionContext to CallContextLars Knoll2013-04-055-34/+54
| | | | | Change-Id: I3f6751fc7e0450a74339f1131b10b56a2ebe6a50 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Split out the Context for With/Catch into their own classesLars Knoll2013-04-056-197/+225
| | | | | Change-Id: I8e7d2fe649eb2c8119f9a787d54b8e92c0e9684f Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Introduce different context typesLars Knoll2013-04-053-38/+56
| | | | | | | | These will be used to split up the context into more specialized subclasses. Change-Id: Ic346c1738ad6e9c4d78e2e6f51133c8ea781f59b Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Clean up the property lookup codeLars Knoll2013-04-053-87/+69
| | | | | | | | Also look a bit deeper into the proto chain. This speeds up the deltablue benchmark by 10% Change-Id: Id3f5de58f336d7ca74c7c32e6c30564410baf1e4 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Create some execution contexts on the stack againLars Knoll2013-04-045-2/+39
| | | | | | | | This seems to be working now, and speeds up our benchmarks with another 20%. Change-Id: Ib01bf8f66db91b0e06090eff705db79b0caf66ee Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Remove stray backslashSimon Hausmann2013-04-041-1/+1
| | | | | | | Not needed :) Change-Id: If22d077a05ffa21f393569f93fcb9f599008af82 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Don't include internal headers in qv4v8.hLars Knoll2013-04-031-2/+0
| | | | | Change-Id: I2b43d8c356a8b433836c1e3f6a99675e69b670fa Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Speed up Context creation and handlingLars Knoll2013-04-037-132/+101
| | | | | | | | | | | Creating context and locals in two mallocs wasn't very good for performance. This allocates them in one go again, while still managing them through the garbage collector. This brings performance up by around 20%. Change-Id: I9b31d669e1a502c90a117bacf5fee5d23e9821b4 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>