aboutsummaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Remove usage of String pointers where not requiredLars Knoll2013-10-113-10/+18
| | | | | Change-Id: Ia533308a1641fab263d8faa8316455e8ade1c859 Reviewed-by: Simon Hausmann <[email protected]>
* Mark strings stored in the lookupsLars Knoll2013-10-111-0/+2
| | | | | Change-Id: I4cb72a3eee9f87305316137b0a1bfd4a003de840 Reviewed-by: Simon Hausmann <[email protected]>
* Remove more direct usages of Managed pointersLars Knoll2013-10-115-40/+44
| | | | | Change-Id: I32f61b7919797eef51a8705695787175b76244c4 Reviewed-by: Simon Hausmann <[email protected]>
* Small optimisation for bit shift operationsLars Knoll2013-10-112-6/+6
| | | | | | | | | We don't need the right side of the shift operation as uint. Converting it to int is cheaper and more then enough, as all but the lowest 5 bits are ignored anyway. Change-Id: I8833e6cc4e565b8bd1e35a22250e03a9b34938df Reviewed-by: Simon Hausmann <[email protected]>
* Fix build on iOSSimon Hausmann2013-10-111-2/+6
| | | | | | | | | | | On 32-bit ARM, iOS uses SJLJ for exceptions, which is probably why _Unwind_Backtrace is not available (it's hard to implement reliably without unwind tables). Don't use it there, we don't need it (because we can't JIT). Task-Number: QTBUG-33979 Change-Id: Ifafbb59a32fd23c9b2e93228779535b2324ac4a3 Reviewed-by: Tor Arne Vestbø <[email protected]>
* Add support for showing disassembled ARM JIT codeSimon Hausmann2013-10-107-4/+2776
| | | | | | | | | | Ported the ARM disassembler from upstream trunk. QtQml needs to be configured with qmake CONFIG+=disassembler and QV4_SHOW_ASM=1 enables the dump at run-time. Change-Id: Ia13a98835829fde0d3c5a795cb8f6ef9de951807 Reviewed-by: Lars Knoll <[email protected]> Reviewed-by: Simon Hausmann <[email protected]>
* qdoc: Added excludedirs to qtquickdialogs.qdocconfMartin Smith2013-10-101-0/+2
| | | | | | | | | Added excludedirs += ../qml to qtquickdialogs.qdocconf. Task-number: QTBUG-33966 Change-Id: I08a74061ed82301712239bc0979ed6fcea0a2448 Reviewed-by: Shawn Rutledge <[email protected]> Reviewed-by: Jerome Pasion <[email protected]>
* V4 runtime: add some more counters.Erik Verbruggen2013-10-102-0/+21
| | | | | Change-Id: I872f259a9fd4580e8faeae664f4d34f59a785c4e Reviewed-by: Lars Knoll <[email protected]>
* V4 JIT: ISel for bitwise or/xor.Erik Verbruggen2013-10-102-9/+63
| | | | | | | Removes another 4mln calls when running v8-bench.js. Change-Id: I7fd777e4e6303f989391c4d1e361277cc24b37e8 Reviewed-by: Lars Knoll <[email protected]>
* V4 JIT: generate some strict (not) equal conditionsErik Verbruggen2013-10-104-33/+194
| | | | | | | | | | | Checks for strict (not) equal to null, undefined, or a boolean value can be generated without reserving extra registers, or doing a call. This reduces the amount of runtime calls from >25mln to ~6500 for v8-bench.js Change-Id: If08d1124b2869227654b1233a89833c5b5e7b40c Reviewed-by: Lars Knoll <[email protected]>
* V4 JIT: do not generate inline fall-back code for strings types.Erik Verbruggen2013-10-101-1/+3
| | | | | Change-Id: I30ac6fcbc7d03f412ff03e87f2ecf61fd2617108 Reviewed-by: Lars Knoll <[email protected]>
* V4: Remove more jumps.Erik Verbruggen2013-10-106-1/+55
| | | | | | | | | | | | | | | | | | | | | Do not generate jump instructions when the target immediately follows the current basic block, even if there are intermediate jumps in between as long as they jump to the same basic block. In the IR snippet below, no jumps will be generated at all. … L8: goto L6; L12: goto L6; L6: goto L4; L11: goto L4; L4: goto L2; L10: goto L2; L2: …. Before this change, the gotos in L8, L6, and L2 were still generated. Change-Id: I718ed0d41c603a6905f2279b782cd9e9cafb7d55 Reviewed-by: Lars Knoll <[email protected]>
* Use common prefix for environment variableKai Koehne2013-10-091-3/+3
| | | | | Change-Id: Idbbdcad42106d30451000fc6593428a0bac4bc04 Reviewed-by: Erik Verbruggen <[email protected]>
* Be explicit about precision specifiers.Gunnar Sletta2013-10-081-1/+1
| | | | | | Task-number: QTBUG-33912 Change-Id: I4b6988e7385bcf9167e5f44d0bde7c80fbc1e117 Reviewed-by: Laszlo Agocs <[email protected]>
* All matrices in a batch need to be 2D safe when merging.Gunnar Sletta2013-10-082-3/+18
| | | | | | | | | | | | If we merge geometry nodes that make actual use of the z-coordinate, this information becomes lost when merging and the result is that we end up with an arbitrary wrongfully applied transformation to the merged element. Task-number: QTBUG-33897 Change-Id: I6129243e9bb890949023c35dc6b7bce30d31709a Reviewed-by: Andrew Knight <[email protected]> Reviewed-by: Eskil Abrahamsen Blomfeldt <[email protected]>
* Several smaller fixes to Animators.Gunnar Sletta2013-10-083-2/+23
| | | | | | | | | | | | | | Backwards animations are not supported for animators as the animation system cannot handle uncontrolled backwards animations. Make sure we write back values only for the animators that have run at all. Clockwise rotation to 0 can easily end up on 360 as a result the _q_interpolateClockwise function not being entirely correct. Change-Id: If69b8555a1361f46600a40e80419b65438c18097 Reviewed-by: Michael Brasser <[email protected]>
* Delay calculation of offline storage path as long as is practically possible.Robin Burchell2013-10-081-6/+10
| | | | | | | | | This avoids calculating it incorrectly in the case that something later clobbers argv, such as a zygote or booster-type mechanism. Change-Id: Ifab16c7c94e9ee3fded0dfda2266a12c910858ee Reviewed-by: Matthew Vogt <[email protected]> Reviewed-by: Martin Jones <[email protected]>
* Fix qquickframebufferobject.h syncqt warningJ-P Nurmi2013-10-071-1/+1
| | | | | | | | QtQuick: WARNING: qquickframebuffe robject.h includes QQuickItem when it should include QtQuick/QQuickItem Change-Id: Ia702bab8881ade601693cbee495b1dc6a5e14abb Reviewed-by: Gunnar Sletta <[email protected]>
* QStringRef has toInt(), so no need to create a new QStringThiago Macieira2013-10-072-10/+6
| | | | | | | | Saves up on memory allocations. Change-Id: I0f7c82521b0b10085861fc62fed9b9d591169b5a Reviewed-by: Simon Hausmann <[email protected]> Reviewed-by: Lars Knoll <[email protected]>
* Reshuffle inlined functions to fix MinGW-warnings.Friedemann Kleint2013-10-052-58/+58
| | | | | | | | | | | | | | | | | | | When compiling QtQuick: qv4value_p.h:80:17: warning: 'QV4::Managed* QV4::Value::asManaged() const' redeclared without dllimport attribute after being referenced with dll linkage ^ qv4value_p.h:180:14: warning: 'static QV4::Value QV4::Value::fromManaged(QV4::Managed*)' redeclared without dllimport attribute after being referenced with dll linkage ^ qv4value_p.h:285:16: warning: 'QV4::String* QV4::Value::asString() const' redeclared without dllimport attribute after being referenced with dll linkage Change-Id: I548a2f8049b8eca06ab1061f56416a332820dc01 Reviewed-by: Erik Verbruggen <[email protected]>
* Fix regression in pressDelay behavior.Michael Brasser2013-10-041-9/+0
| | | | | | | | | | | | | | | Don't deliver a press event when a Flickable is moved before the pressDelay expires. This prevents delegates flickering between pressed and unpressed states when beginning to flick a Flickable. Fixes regression introduced by 429af6244518172e19abf7fecd7112f26bac6b31/ d02131e743597b9bd3070d986c61a1c91ea8317a. Task-number: QTBUG-31168 Change-Id: Id4e853fabe99000837df3681acd8fc4e76d2e9b3 Reviewed-by: Martin Jones <[email protected]>
* Respect DirtyForceUpdate in QSGBatchRenderer.Gunnar Sletta2013-10-041-1/+9
| | | | | | | | | | | | | | There is a way this could have been done slightly more efficitently. If we moved all "combined" logic out of the scene graph and into the Node shadow tree, we could ignore the forceupdate all together. However, this is a quite large change for what is currently a non-common case. It would also increase overall memory consumption a bit as we would have superfluous combined matrix and opacity in the QSGNodes. Task-number: QTBUG-33838 Change-Id: I06c486ace2be15bef1f1dc72a8b41cb649d7c813 Reviewed-by: Eskil Abrahamsen Blomfeldt <[email protected]>
* V4 JIT: enable register allocator for linux/x86.Erik Verbruggen2013-10-041-1/+7
| | | | | Change-Id: I9424838139a419beb2e207f168fc25c0c47c64e3 Reviewed-by: Simon Hausmann <[email protected]>
* V4 JIT: fix visitRet for 32-bit architectures.Erik Verbruggen2013-10-041-10/+43
| | | | | Change-Id: I004fe8d5de0f5a932c23393ed06a04738b8e8bf1 Reviewed-by: Lars Knoll <[email protected]>
* Signal no region descriptors follow the ETH table.Petr Nejedly2013-10-041-1/+2
| | | | | | | | | | | | In our implementation, the 2-word EXIDX is directly followed by a 3-word ETH for personality 2 unwind interpretter. According to ARM EHABI 9.2, "region of interest" descriptors should follow, finished by a single zero word. As the generated functions don't have any such regions, only the closing zero needs to be present. Change-Id: I65fde548371cf12a31aac3e8829275965e034f3a Reviewed-by: Simon Hausmann <[email protected]>
* Make sure to markDirty the node from UniformAnimator.Gunnar Sletta2013-10-031-0/+4
| | | | | | | | Failure to do so will not repaint scene graphs which only has changes from the animator. Change-Id: Id420775d704df17379ca9b0eecd543fd3829fd00 Reviewed-by: Michael Brasser <[email protected]>
* Make sure we apply the last transformation step.Gunnar Sletta2013-10-031-7/+6
| | | | | Change-Id: Ie9b9a04cf41033bb475875f419b16ce91f6a477d Reviewed-by: Michael Brasser <[email protected]>
* Make transform and opacity animators work when layer.enabled: trueGunnar Sletta2013-10-032-0/+15
| | | | | Change-Id: I6d9ece93a75782d524c211fc81a43f4311a38571 Reviewed-by: Michael Brasser <[email protected]>
* Remane private QQuickAction into QQuickStateActionGabriel de Dietrich2013-10-0316-130/+130
| | | | | | | | | | | This avoid symbol conflicts when statically linking with Qt Quick Controls, that has its own QQuickAction class and which may become public some day. (QQuickPropertyAction might be a more apt name, but it's already taken). Change-Id: Ia9514d63d38295603a89d8ec5a88815a651380f7 Reviewed-by: Frederik Gladhorn <[email protected]> Reviewed-by: Jens Bache-Wiig <[email protected]>
* Don't print garbage or crash when using console.logJan Arve Saether2013-10-031-8/+17
| | | | | | | | | | | | | | | | | The problem was that the ctor of QMessageLogger did not make a deep copy of the source or the function. Since the QByteArray returned from toUtf8() was only guaranteed to live within the statement it was used, the pointers that QMessageLogger held would point to released memory as soon as the QByteArray got destructed. This could only be reproduced if the logging framework tried to print the source file or the source function. In my case, I had set this environment variable to provoke this: $env:QT_MESSAGE_PATTERN="%{file}(%{line}):%{message}" Change-Id: I4ea4cf309c6c6420cef5bab0108a6cb2b2f9e841 Reviewed-by: Simon Hausmann <[email protected]>
* A dynamically-created Window can have a parent Item and vice-versaShawn Rutledge2013-10-031-8/+28
| | | | | | | | | | | | There can be a QML-declared Item which uses Component.createObject to instantiate a Window; in that case the Window will be transient for the window containing the Item. There can also be a QML-declared Window which uses Component.createObject to instantiate an Item; in that case the Item's parent will be set to the Window's contentItem. Task-number: QTBUG-33644 Change-Id: I0b1fe2e98c862c100e52bd5952788af3a727d25e Reviewed-by: Alan Alpert (Personal) <[email protected]>
* A dynamically created Window can have a parent WindowShawn Rutledge2013-10-031-9/+17
| | | | | | | | | | | | | So far the parent relationship has existed only for Items. parent is still not exposed as a property of Window, but since it was possible to give a parent parameter to Component.createObject(), it makes sense to try to interpret it as a Window in that case. So now a Window can be created with another Window as its parent just as an Item can be created with a parent Item. Task-number: QTBUG-33644 Change-Id: I796198a38bd47253eef462c80f5098825451c59c Reviewed-by: Alan Alpert (Personal) <[email protected]>
* Invalidate the bounding rects when the roots change.Gunnar Sletta2013-10-031-1/+3
| | | | | | | | | When roots change, matrices are updated in the nodes, so we need to also invalidate the bounding rects for geometry nodes. Change-Id: I61f60ad069c3b1d018ce31c57310a1e5c4807684 Reviewed-by: Eskil Abrahamsen Blomfeldt <[email protected]>
* Animator overview docs and example.Gunnar Sletta2013-10-031-0/+19
| | | | | Change-Id: If0852e48dbbfea4fadca9c897ea0e62393763055 Reviewed-by: Jerome Pasion <[email protected]>
* Separate and fix 8/24-bit text mask materials.Gunnar Sletta2013-10-033-119/+189
| | | | | | | | | | | | | | | | | | The logic was a bit cluttered, trying to handle two rather different pieces of logic in one material shader. The 8-bit shader does not try to be fancy in any way, it just takes the alpha * color which gives similar intensities as the distance fields. The logic for 24-bit contains a tiny fix for opacity. The patch also includes a change from QColor -> QVector4D and QPointF -> QVector2D to simplify the conversion needed and be consistent with what kind of types we use. Task-number: QTBUG-33805 Task-number: QTBUG-33633 Task-number: QTCREATORBUG-10176 Change-Id: Ia8c464f98a1fc2c190a1d323fc21466a4d7b0dfd Reviewed-by: Eskil Abrahamsen Blomfeldt <[email protected]>
* Remove QSGContext's precompilation step.Gunnar Sletta2013-10-032-77/+0
| | | | | | | | | Materials are managed solely inside the renderer now, so these are just wasting time. Task-number: QTBUG-33456 Change-Id: Ie320df20b7971633c257b1bd3a218e7d70e52c3d Reviewed-by: Yoann Lopes <[email protected]>
* Enable profiling of materials and atlas texturesGunnar Sletta2013-10-032-8/+60
| | | | | | | Task-number: QTBUG-33459 Change-Id: Ie9ea176fbb7ee46a128b4bf66a8f4475a5d4c90b Reviewed-by: Aurindam Jana <[email protected]>
* Get lookups working (somehow) on ARMPetr Nejedly2013-10-031-1/+7
| | | | | | | | | | | Edit(Simon): This is a workaround for the register clash on ARM. r0 (ReturnValueRegister) is also used to pass the first argument, therefore we can't use it as "temporary" register for the duration of the parameter setup. Temporarily allocate r8 for now until we have constraints like these properly propagated into the register allocator. Change-Id: Iae266672856dea247b720367b8e8393333622e4e Reviewed-by: Simon Hausmann <[email protected]>
* Temporarily disable libunwind exception throwing on MacSimon Hausmann2013-10-032-3/+3
| | | | | | | | | The run-time appears to have a slightly different behaviour wrt exception ownership. We don't strictly need this code path on Mac, so use regular C++ exceptions until I can figure out what happens there. Change-Id: Idd540c8656d25ffdb4002843f398114881e33214 Reviewed-by: Simon Hausmann <[email protected]>
* Fix backtrace generation on Android/ARM/QNXSimon Hausmann2013-10-031-5/+37
| | | | | | | | | | | | Use a GCC extension to the common C++ ABI's called _Unwind_Backtrace, which generate backtraces if possible. Its direct use will ensure we use the statically linked unwind, which knows about our unwind tables. This also helps for the setup when libc doesn't have the glibc specific backtrace() function we used previously. The unwinder on Mac OS X with clang also implements the same extension. Change-Id: I0b780590c10c16e50ec570f7da1efae2e64c46dd Reviewed-by: Lars Knoll <[email protected]>
* Cleanup exception handlingSimon Hausmann2013-10-0319-234/+97
| | | | | | | | | | The code in the Exception class operates entirely on the engine's data, so move it into ExecutionEngine instead. This eliminates the need for a QV4::Exception class and catches and old code that tries to still do catch (Exception &) instead of catch (...) Change-Id: Ie608bec6af652038aca6c9423c225a4d7eb13b39 Reviewed-by: Lars Knoll <[email protected]>
* Change v4 exceptions to use the common C++ ABIs foreign exceptionsSimon Hausmann2013-10-035-65/+56
| | | | | | | | | | | | | | | | | | | On platforms where we use the common C++ ABI, throw the exception not using a dummy C++ exception structure and the throw keyboard, but instead use the lower-level _Unwind_RaiseException to throw a foreign exception. It is caught with the existing "catch (...)" and re-throw is implemented similarly, by grabbing the current exception from the globals (a standardized data structure) and re-throwing it. On platforms such as ARM that lack hooks for supplying our unwind tables to the system run-time, this patch will make it possible to link the unwinder statically into libQtQml (libgcc or libunwind) and thus force it to use our unwind tables, because throwing or re-throwing will always go through our statically linked code through direct calls to _Unwind_RaiseException (instead of libstdc++). Change-Id: Ic2ac056fc7ed9e93fb51e30ab45f35b260487c5f Reviewed-by: Lars Knoll <[email protected]>
* Forward-declare QV4::String in qqmlmetatype_p.h.Friedemann Kleint2013-10-031-2/+2
| | | | | | | | | Required for follow-up changes reordering inline functions for MinGW as otherwise QV4::Value::isString() is reported as used but not defined. Change-Id: Ib07caa9eee667295ecc88f94ab8960b100cd084b Reviewed-by: Lars Knoll <[email protected]>
* Mark DirtySubtreeBlocked correctly from OpacityNodeGunnar Sletta2013-10-031-2/+2
| | | | | | | | | In the edgecase where the opacity was exactly the OPACITY_THRESHOLD we would fail to mark the tree as dirty. This led to a crash in the renderer. Change-Id: I618910d0c792a215133598b6a87217be1f8729bc Reviewed-by: Eskil Abrahamsen Blomfeldt <[email protected]>
* Respect Qt.vector2d as input to ShaderEffect uniforms.Gunnar Sletta2013-10-031-0/+3
| | | | | Change-Id: I7c24f822424d36cf16648d17df161f15083b0da5 Reviewed-by: Eskil Abrahamsen Blomfeldt <[email protected]>
* Use a QVector instead of a QListLars Knoll2013-10-035-15/+20
| | | | | | | | This makes the code go quite a bit faster (saves ~7-8% of the total amount of instructions executed when running crypto.js Change-Id: I6b3bd08eca98b45593262e2fc6e0ce5056257e76 Reviewed-by: Simon Hausmann <[email protected]>
* V4 JIT: implement convertUInt32ToDouble on ARMv7.Erik Verbruggen2013-10-034-22/+12
| | | | | Change-Id: I11caf07a8776bb2c6527639f22d47103f4ca1cef Reviewed-by: Lars Knoll <[email protected]>
* V4 IR: fix dead-code elimination.Erik Verbruggen2013-10-031-93/+109
| | | | | Change-Id: If00a108fb107d331478dd36ad7feae4c4521c2ae Reviewed-by: Lars Knoll <[email protected]>
* V4: invert conditions when the true block follows the test.Erik Verbruggen2013-10-037-24/+52
| | | | | Change-Id: I5044acd4263b71734e4eb5d7e74b1a4a8414741e Reviewed-by: Lars Knoll <[email protected]>
* Change exception handling APISimon Hausmann2013-10-0238-280/+245
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch changes the exception handling API in the engine slightly, encapsulating any use of direct throw statements and catch blocks with concrete types. In the future we need to be able to change the way these are implemented, in order to ensure that the correct stack unwinding code is triggered for throw and re-throw. This patch separates the C++ exception object thrown from the V4 exception (that includes value, throwing context pointer) and stores the latter inside the engine. In order for that to compile, ExecutionEngine::StackTrace and StackFrame had to move into the QV4 namespace directly. In addition the syntax for catching exceptions changes from try { ... } catch (QV4::Exception &ex) { ex.accept(context); QV4::ScopedValue exceptionValue(scope, ex.value()); } to try { ... } catch (...) { QV4::ScopedValue exception(scope, context->catchException()); } Context::catchException() checks if there's a "current" exception in the engine, and if not assumes that we caught an unrelated exception and consequently re-throws. partiallyUnwind() is also gone and replaced with rethrowException(), in order to encapsulate the re-throw. Lastly, in the future nesting try/catch blocks isn't going to be possible due to limitations in the common C++ ABI with regards to foreign exceptions. Change-Id: Ic81c75b057a2147e3176d8e0b4d326c14278b47d Reviewed-by: Lars Knoll <[email protected]>