aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Simplify function prologue code in the JITSimon Hausmann2017-03-291-3/+1
| | | | | | | | | We don't have to do a engine->current->engine dance to get hold of the engine pointer, in order to update jsStackTop. We have a dedicated engine register :) Change-Id: I187ea67bf9f3e43b0048dca3cd6ee35f70d8737c Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Minor cleanup: Remove unused functionSimon Hausmann2017-03-291-7/+0
| | | | | Change-Id: Ie8d0c7b360ff120f381e33439037cf7b01257456 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Fix manual register allocation when cross-compiling for ARMv7Simon Hausmann2017-03-291-3/+3
| | | | | | | | Let's assume that we always generate thumb2 code. I'm not even sure that we still support plain ARM anyway. Change-Id: Ie7ec4d1de8f9f6cb86d80193990e492782ff2cf2 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Add support for showing disassembly for cache mapped codeSimon Hausmann2017-03-291-0/+6
| | | | | Change-Id: I6199d624a23e2e1b67bcbb841f0bc999880a3993 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Add missing header inclusionKimmo Ollila2017-03-281-0/+1
| | | | | Change-Id: I7c215db87552c63291e6c82d7b962ee17ec2f610 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Add tst_qquickflickable::nestedSliderUsingTouchShawn Rutledge2017-03-272-0/+197
| | | | | | | | | | | to verify that when a touch-handling component is inside the Flickable, it can control whether the flickable can steal the grab by means of setKeepTouchGrab. Task-number: QTBUG-59416 Task-number: QTBUG-59707 Change-Id: I93cf3abb07a96a69290c3b5b055b688a62fe8fff Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Flickable: don't steal grab from item with keepTouchGrab setShawn Rutledge2017-03-271-3/+4
| | | | | | | | | | | | Sometimes filterMouseEvent can be given a mouse event which was synthesized from a touch point which was already grabbed. In such cases, if the grabber has keepTouchGrab set, respect it. This makes it possible again for a QQControls 2 slider to be draggable inside a Flickable which is also draggable in the same direction. Task-number: QTBUG-59416 Change-Id: I93b7fd9cb846b1e574615154f9a54316b60c0477 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* tst_qquickflickable: clean up touch event handlingShawn Rutledge2017-03-271-17/+9
| | | | | | | | Use QTest::createTouchDevice now that it exists. No need for each test to create a device and pass it in to flickWithTouch Change-Id: I81131a13aaba01cfa0f04b25f334c80263625d12 Reviewed-by: Robin Burchell <robin.burchell@crimson.no>
* in childMouseEventFilter, touchpoint grabber is also the mouse grabberShawn Rutledge2017-03-271-5/+21
| | | | | | | | | | | | | | | | | | | | | | When an item (such as Flickable) filters its children's mouse events, sometimes the mouse event may be one that is synthesized from a touch point. If that touch point is already grabbed, then in the context of childMouseEventFilter QQuickWindow::mouseGrabberItem() should return the item which has grabbed the touchpoint from which the mouse event was synthesized. Otherwise, there was a regression in which an item which can be dragged via touch (such as Slider in QQ Controls 2) could have its grab stolen by a filtering parent, such as Flickable, or the gesture recognizer in QtLocation. mouseGrabberItem() was returning null because touchMouseId and touchMouseDevice were not set, and the actual mouse was not grabbed. If a touch event is used to synthesize a mouse event, and during delivery an Item steals the grab of the synthetic mouse event, the original grabber needs to be notified that it has lost the grab. Task-number: QTBUG-59416 Change-Id: Ib121b06121df7593c0d549a6df42397b8ead1c45 Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* Merge "Merge remote-tracking branch 'origin/5.8' into 5.9" into refs/staging/5.9Simon Hausmann2017-03-2515-48/+137
|\
| * Merge remote-tracking branch 'origin/5.8' into 5.9Simon Hausmann2017-03-1515-48/+137
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/compiler/qqmltypecompiler.cpp src/qml/compiler/qqmltypecompiler_p.h src/qml/qml/qqmltypeloader.cpp src/qml/qml/qqmltypeloader_p.h Change-Id: I4894555ab7a0879b56bbda7a46d16d1c40c19e7c
| | * Doc: Removed non-working reimplementation suggestionsChristoph Sterz2017-03-152-8/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QSGSimpleMaterialShader::uniformMatrixName() and QSGSimpleMaterialShader::uniformOpacityName() cannot be reimplemented since they are non-virtual. Removed the suggestion, so nobody is tempted to do so. Added a Remark in the header to fix towards intended behavior in Qt6. Change-Id: Id23c8d54728095f143f1d0e0520590303cff91a0 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Jan Arne Petersen <jan.petersen@kdab.com> Reviewed-by: Gunnar Sletta <gunnar@crimson.no>
| | * Fix QQmlTypeLoader::Blob::qmldirDataAvailable memory overwriteJosh Faust2017-03-141-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | An invalid iterator was being dereferenced. Task-number: QTBUG-59268 Change-Id: I58635667ab4591c06f1d7644243b83fd0172e74f Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Doc: added snippets to Extension Objects ExampleNico Vertriest2017-03-131-9/+9
| | | | | | | | | | | | | | | Change-Id: Icbd2393d4b8523e24328f765e76869c86afb3e72 Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
| | * Fix caching of QML singleton typesSimon Hausmann2017-03-133-2/+89
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a QML file depends on a QML singleton, we failed to include it in the dependency hash. Thus changes to the QML singleton did not result in a re-creation of the caches of files that use it. The list of singletons comes from random-ordered hashes in the qml import handling. We provide an order to the direct dependencies by sorting by the singleton type names. Task-number: QTBUG-58486 Change-Id: Ie7e9d006f9bf3a60af1f819ee439c29bc234bd8a Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| | * Clean up type dependency hashing for QML cachingSimon Hausmann2017-03-138-23/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of passing the engine parameter all the way through the data structure generator, along with the dependent type data structure that is unused otherwise, let's simply provide a function object for the dependency hashing. This is also in preparation for adding singleton types to the dependency hash. Task-number: QTBUG-58486 Change-Id: I5bb5e5c06b7b5c77195cec3da13141333cfea7a8 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| | * Fix accidental assignment in assertionSimon Hausmann2017-03-131-1/+1
| | | | | | | | | | | | | | | | | | Change-Id: I5b63697c0607f4300b7f203eeac74914f3fb43af Reviewed-by: Holger Freyther <holger+qt@freyther.de> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| | * JS: Fix 0 == -0Erik Verbruggen2017-03-081-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The double representation of 0 and -0 are different in the sign bit, so the raw values are not the same. However, neither is managed, so non-strict equality comparison erroneously returned false. Task-number: QTBUG-56808 Change-Id: If966ddbc9f1a1c006dc5901aecafca063f71e404 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Run ES5 tests on Linux/x86-64Simon Hausmann2017-03-2410-26/+114
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This requires including the test suite as a submodule by default and bumping the module to a new sha1 that removes some particularly long paths. Also force the test suite to run under a US locale, as tests like ch15/15.5/15.5.4/15.5.4.7/S15.5.4.7_A1_T11 cannot deal with locale dependent output for date formatting. The test harness now returns a non-zero exit code when a test fails. This is used by the QTestLib wrapper to determine success or failure. The tests with JIT are run, but the tests with the interpreter are omitted at the moment until the last failure is fixed. The tests add about 10-15 minutes extra time to the total time it takes to run tests on Linux in the CI. Change-Id: Id01fd3b41350f9c9a6ce9e43236f51f7f0fb71c8 Reviewed-by: Robin Burchell <robin.burchell@crimson.no>
* | | Fix prototype property when set to non-objectsSimon Hausmann2017-03-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 180decaf11ea6fb1147825a78a95c455400f7c7e regressed ch15/15.3/15.3.5/S15.3.5.3_A2_T6 in the sense that when a non-object was set for the prototype property, the protoProperty() helper function would perform an unsafe cast to Object * and return a non-null pointer, which however instanceof() does not expect. Change-Id: I134fd41f6b2d3349ebe7d9e91c6b6e5788f599b6 Reviewed-by: Robin Burchell <robin.burchell@crimson.no>
* | | Blacklist a qmltest::ListView test in macOS 10.12Tony Sarajärvi2017-03-231-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Precise name of blacklisted test: qmltest::ListView::test_listInteractiveCurrentIndexEnforce() Task-number: QTBUG-58971 Change-Id: Iac01f0a5c31c91b08438fd6d7601bdb2ced41ac6 Reviewed-by: Liang Qi <liang.qi@qt.io>
* | | Build for for -no-feature-quick-spritePaul Olav Tvete2017-03-226-3/+19
| | | | | | | | | | | | | | | Change-Id: Iaf26d9cec7f9fa7a5d6d24c729b2dc92737cca1f Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* | | Build fix for configure -no-openglPaul Olav Tvete2017-03-222-0/+4
| | | | | | | | | | | | | | | | | | | | | Change-Id: I21f111a04d9e2ce367d7677dbb48abbd591a4e71 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Joni Poikelin <joni.poikelin@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Codegen: do not assume QStringRef(const QString *) is implicitMarc Mutz2017-03-221-2/+2
| | | | | | | | | | | | | | | | | | | | | It won't be for very much longer. Change-Id: I90fae21b621f104053b776296fc9f6525e8baf52 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Speed up source code readingSimon Hausmann2017-03-221-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since we always convert the source code of .qml/.js/qmldir files from utf-8 to utf-16, we always end up copying bytes around. That means instead of allocating memory on the C++ heap and copying bytes from kernel space to user space and then a few times through QIODevice buffers until we reach QString::fromUtf8, we might as well mmap() the file directly - if possible. Change-Id: I54c88d4d9f03f9967130d65a7b53cfec93734018 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Avoid an extra stat() on the source .qml file when loading cacheSimon Hausmann2017-03-2212-30/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | For timestamp comparison it is not necessary to create another QFileInfo() object and call exists() and lastModified(), when we can pass that information through from the type loader. Change-Id: I225cd36e672f1f390bddb4e6ebfafa3fc1269795 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Fix handling of huge memory segmentsLars Knoll2017-03-221-3/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allocating a MemorySegment larger than 4M was not working correctly. We would in this case reserve the right amount of memory, but where not able to use it, leading to an assertion in the HugeItemAllocator. Fix this by ensuring we can properly allocate the memory that was reserved in the Segment. Change-Id: I1e3d2b3beebdde0a509fd123ad2aa8b1bc35a26b Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Allow info messages in debug message serviceUlf Hermann2017-03-221-1/+1
| | | | | | | | | | | | | | | | | | | | | QtInfoMsg > QtFatalMsg, and it was added later. Change-Id: If565ebd491aba57b162c7f8ddb5534e416f7ab44 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Avoid reading (not parsing) .qml files when using the cacheSimon Hausmann2017-03-212-36/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By making SourceCodeData copyable we can delay the reading of the source file until we really need to. This also allows persisting the QFileInfo object and therefore having only one stat() call to check if the file exists, what its size is and what the last modification time is. Change-Id: Ic7e4d5f566d870f3b1fa8302227417fa813cb139 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Simplify internal source access APISimon Hausmann2017-03-212-37/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All call sites of QQmlDataBlob::Data immediately convert the data to UTf-8 - for .qml, .js and qmldir files. We can simplify the code by reflecting that in the API and that also opens up the possibility for future optimizations. This means that the bi-pointer has to go, but at the moment the Data object is stack-allocated anyway. Since the "Data" class always represents source code, it is now called SourceCodeData. Change-Id: Icd262ed1e35f9edd64945ba6c16d80f9917eae72 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | V4 Debugger: Encode NaN and +/-Infinity as stringsUlf Hermann2017-03-211-2/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | JSON doesn't have numerical values for those. However, as we give the type of each item in a separate field, we can just use strings here and the result will still not clash with actual strings. Task-number: QTBUG-47880 Change-Id: I85ffa008890a8a9e6894dd3151f7dc6b527ed5e1 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Complete transition to standard layout classes for JIT accessSimon Hausmann2017-03-218-20/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the Runtime function pointer array into EngineBase so that we can eliminate the last use of qOffsetOf. For improved cache locality the memory manager point is now also located in the EngineBase. Change-Id: I0b3cf44c726aa4fb8db1206cc414a56c2f522a84 Task-number: QTBUG-58666 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | QQuickEvents: Fix documentation of types for MouseEvent and WheelEvent x/yRobin Burchell2017-03-201-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | These types are qreal, not int. Change-Id: I26569c40825ce098ea095b3d9dc9b84eb3870c02 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | stocqt Demo: Add error checksFriedemann Kleint2017-03-201-17/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check for corrupted records, fixing warnings: qrc:///demos/stocqt/content/StockListModel.qml:90: TypeError: Cannot call method 'split' of undefined Also check the value and prevent NaN from appearing. Change-Id: I3a9d010c61fb0f017aef37df7f54a7ad4d7d7d53 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* | | Protect CallContext member usage against word size differencesSimon Hausmann2017-03-173-5/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ensure the offsets we're taking from ExecutionContext members in the JIT code generator can be translated from host architecture sizes to target architecture, using assertions and a memory layout that we already have in the dev branch with commit 4de7e48ab160dacc7a09360e80264eac4945a8f4. Change-Id: I1b26ef265234b05a6e5c8688a8aad2f33cd28783 Task-number: QTBUG-58666 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Remove unused macroSimon Hausmann2017-03-171-4/+0
| | | | | | | | | | | | | | | | | | | | | This duplicate of qOffsetOf is not used in this file. Change-Id: I8a5ddfe18202501605a06f65c952b58e557dbfac Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Protect ExecutionContext member usage against word size differencesSimon Hausmann2017-03-175-19/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ensure the offsets we're taking from ExecutionContext members in the JIT code generator can be translated from host architecture sizes to target architecture, using assertions and a memory layout that we already have in the dev branch with commit 4de7e48ab160dacc7a09360e80264eac4945a8f4. Task-number: QTBUG-58666 Change-Id: I26cdbd1ddb995b116624fab16f7caba5d21c13b5 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Clean up qOffsetOf usageSimon Hausmann2017-03-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | For offsets from CompiledData::Unit we can use C++11's offsetof macro as the class has standard layout. Change-Id: I7377294679a9cd79c35486fa34355933271f9251 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Protect CompilationUnit member usage against word size differencesSimon Hausmann2017-03-1710-22/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | Currently we only use the runtimeStrings offset in JIT generated code, so move that into a standard layout base class and use that instead. Task-number: QTBUG-58666 Change-Id: Id933ba5df3a6990e89886c2b328e9e814ec5e413 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Protect Lookup usage against cross-compilation word size differencesSimon Hausmann2017-03-172-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | The offsets we're taking from Lookup in the code generator are always zero, but with static assertions we can ensure that they stay that way. Task-number: QTBUG-58666 Change-Id: I91e047d2101ba33e36aaada4a5adc75e20fea7d8 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Protect CallData usage against cross-compilation word size differencesSimon Hausmann2017-03-175-19/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ensure via static asserts that the members always have the same offsets. Since the class has standard layout, we can also use the C++11 offsetof macro instead of qOffsetOf. Task-number: QTBUG-58666 Change-Id: I7dcecf517c771c7081334cd9d0b7ae133b23b23a Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Prepare run-time method calling mechanism for cross-compilationSimon Hausmann2017-03-1712-358/+282
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current way of encoding the offsetof() of the method_ members in QV4::Runtime is not portable when cross-compiling from a 64-bit host (where the offsetof would be calculated on) to a 32-bit target (where the offset would be different), or vice versa. In preparation for making this work, this patch first replaces the direct use of the run-time members with use through a void * and an enum for indexing. This gives us some type-safety in some places and will also allow for a translation of the pointer offset from host pointer indexing to target pointer indexes. As a bonus we can avoid going through the engine->runtime indirection in the interpreter altogether and call the static methods right away. Task-number: QTBUG-58666 Change-Id: I3cd6459523923a9719408317fa729bca19c2bf3c Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Fix running of 32-bit JIT code generated on 64-bit hostsSimon Hausmann2017-03-176-19/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The offsets of members encoded in JIT generated code differ between 32-bit and 64-bit architectures. This patch moves some of the ExecutionEngine members into a separate standard-layout EngineBase class (in line with the same class in commit 2a554434a571dcefd26cf10ef8c5ae8b3b7d66db and subject to merging). By ensuring that the members are stored at pointer intervals, we can translate from host pointer size to target when generating the code. Task-number: QTBUG-58666 Change-Id: I1c38a7da059826848b80fd9972ed073214501386 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | QRegExp include cleanupSamuel Gaist2017-03-173-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | This patch adds missing include statement where the QRegExp class is used. Change-Id: I02d2995dd380f1e4db3777ae9759098c0e7757bd Reviewed-by: Robin Burchell <robin.burchell@crimson.no>
* | | Flickable: fix doc statement about content anchoringNikita Krupenko2017-03-161-2/+4
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-54101 Change-Id: I3b0a0225efb77003c1c80c1d5b94ab572f3cc785 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | | QHash: use the public functions to set the global hash seedThiago Macieira2017-03-163-12/+7
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-47566 Change-Id: I4a7dc1fe14154695b968fffd14abd2e3189c6ad2 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Fix QQmlMetaType::prettyTypeName to deal with malformed type namesUlf Hermann2017-03-152-5/+35
| | | | | | | | | | | | | | | | | | | | | | | | We can have QML type names that are empty or end in '/'. In those cases use the QMetaObject to retrieve a more meaningful type name. Change-Id: I4dd0841de13d4e7524a104f0bbc08cb854484cfe Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | qml runtime: don't assume http by defaultShawn Rutledge2017-03-151-1/+1
|/ / | | | | | | | | | | | | | | Avoid doing network operations unless a network-specific scheme is given. Task-number: QTBUG-57870 Change-Id: I1387603da5b8325232bef27b0ed45483a0ae30a4 Reviewed-by: David Faure <david.faure@kdab.com>
* | V4 Debugger: Fix typoUlf Hermann2017-03-141-1/+1
| | | | | | | | | | | | | | We want to set redundantRefs if the client states "redundantRefs". Change-Id: I277120e3feedec14492679ad827845732dc36495 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Merge "Merge remote-tracking branch 'origin/5.8' into 5.9" into refs/staging/5.9Liang Qi2017-03-1413-13/+47
|\ \