Commit Graph

26 Commits

Author SHA1 Message Date
Ivan Donchevskii
6cf1465ff8 Clang: Fix paths and updated diff for latest clang patches
I forgot that they must be relative to LLVM folder.
Also one patch had a typo and therefore is updated here.

Change-Id: I35241db84c0aa394211dfc7b4d779f8dfac5326a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-03-09 09:33:23 +00:00
Ivan Donchevskii
1a47df0a93 Clang: Fix code completion for connect()
Clang built with this patch properly handles
not only normal methods but also templated ones
which fixes code completion for QObject::connect.

Change-Id: If1c4c0f5fda29c1aff106d8ed7065ff502a26328
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2018-02-23 08:41:29 +00:00
Ivan Donchevskii
b90f2fb251 Clang: Fix crash in connect() statement
With this patch ClangCodeModel can properly
handle static overloads together with non-static ones.

Code completion still might crash - requires another patch.

Task-number: QTCREATORBUG-19184
Change-Id: I12f0e8cb56b3bed3f5ca1f7a9fe4ca3932b78125
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2018-02-19 10:12:56 +00:00
Nikolai Kosjar
38807f3ded Clang: Fix clang test LibclangPrintingPolicyTest.SetAndGetProperties
Change-Id: I2b20cff1d5f0341eea0d1d994554fe2c8df9e837
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-02-02 11:08:53 +00:00
Nikolai Kosjar
40383715f7 Clang: Fix linkage in clang patch
Change-Id: I89759ff1b5d7cc9f17c74e34dc21479e91ee93a8
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-01-16 12:23:37 +00:00
Nikolai Kosjar
1a706b410c Clang: Add patches improving pretty printing declarations
Change-Id: I36b57c12998b959a3c7c350628c29beab46457b5
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-01-16 10:10:20 +00:00
Nikolai Kosjar
3c745a9eaa Clang: Enumerate clang patches
...to provide some more natural way of appending/inserting new ones at a
specific position. The enumeration also helps to communicate about the
patches.

Change-Id: I8ac911269a11d24a46920c81cd3231c06b94b828
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-01-16 10:10:07 +00:00
Nikolai Kosjar
c205b43af1 Clang: Clean up clang patches with regard to CINDEX_VERSION_MINOR
Ensure that CINDEX_VERSION_MINOR is never increased and that instead
specific macros indicate backported functionality. This minimizes
potential build problems with other API functions that might have been
backported or not in the meanwhile.

Change-Id: I44d868e82dd6a3ea5aa3e8b22e18bba5c4bf8d16
Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
2018-01-16 10:09:57 +00:00
Ivan Donchevskii
7a2e1e29cb Clang: update clang patches
These patches should be applied on top of llvm/clang 5.0
List is taken from https://wiki.qt.io/Qt_Creator_Clang_Code_Model

Change-Id: Icd927ae12fc1ef8181a45e2d800efe3007c616ae
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-01-12 09:27:43 +00:00
Ivan Donchevskii
4f9b664d13 Clang: update patches for build with clazy
Clazy will now be a part of clang-tools-extra during
the build process which will allow to build clang one time.

Change-Id: Id506db267f4a1f0f0e8351ba21f1bc70a4555556
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2018-01-04 11:30:26 +00:00
Nikolai Kosjar
b2a3884cf3 Clang: Use markdown for documentation of extra patches
Makes the links clickable.

Change-Id: I2f0f7826e295bdb3ce6fc7aeaf478ee040e54141
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-12-12 14:14:25 +00:00
Ivan Donchevskii
b6ba40df00 Clang: fix libclang link directory for 64bit linux
When Clazy is installed in lib64 folder instead of lib.

Change-Id: Ifb24e09c307dab2dd2f5121bf44a17a357c1a212
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-11-03 08:01:48 +00:00
Ivan Donchevskii
58e8904856 Clang: enable clang tidy and clazy in code model
Set QTC_CLANG_PLUGINS_LOAD env variable to get diagnostics
that come from libclang plugins.
This functionality works after the patch is applied to
clang repository and clang is properly built with it.

Task-number: QTCREATORBUG-15157
Change-Id: Iefeee4dd115f3f43ddc6ed79452a1135e653def6
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2017-11-02 10:25:28 +00:00
Nikolai Kosjar
6de3eb7a1a Clang: Update patches for clang 5.0
Remove a bunch of on-top patches that are already part of llvm/clang 5.
Rebase the remaining ones and add backported ones.

Add also a README providing more information about the patches.

Task-number: QTCREATORBUG-18824
Task-number: QTCREATORBUG-17769
Change-Id: I9f6904b2e6d7c83de175e7b8c194e1a494cd2571
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2017-10-27 14:21:13 +00:00
Nikolai Kosjar
9ddbae8987 Clang: Add patch allowing to suspend a translation unit
This will allow us to free memory.

Change-Id: I25c5c3c4473e58798ec58ffdf18ed3103dd6453c
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:24:24 +00:00
Nikolai Kosjar
dd73160424 Clang: Add patches fixing preamble generation for ifdef-guarded headers
This improves reparses for big header files significantly. The second
patch fixes invalid diagnostics associated with the new behavior.

Change-Id: I1606cff0164c69994e82c02766f955196d43953a
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:24:02 +00:00
Ivan Donchevskii
42ceae5e47 Clang: Add patch improving reparse performance on windows
Patch provides faster preamble loading by improving the handling of
diagnostics.

Change-Id: I61a79160e0272335d6d4e76478a7a35760cdf9ef
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:23:46 +00:00
Ivan Donchevskii
7acbef5a90 Clang: Add patch fixing locked files for windows
This clang patch makes llvm avoid using memory map
which makes llvm work without locking files.
Without that patch the user is sometimes unable to
save files in qt creator.

Task-number: QTCREATORBUG-15449
Change-Id: Iab77a758174d153f860edb2f419b6ab767571964
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:23:41 +00:00
Nikolai Kosjar
f2041c7881 Clang: Add patch fixing crash in completion
...with overloads.

https://bugs.llvm.org/show_bug.cgi?id=31093

Change-Id: I2f177794d8d84c91b5bc47da38a3a6c90f8d8d55
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:23:35 +00:00
Nikolai Kosjar
e88fcdbdb6 Clang: Add patch fixing crash on reparse
...in preamble serialization.

https://bugs.llvm.org/show_bug.cgi?id=20320

Change-Id: I241a04ffae7ebb1dc241bed81f2036178a86afb9
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:23:30 +00:00
Nikolai Kosjar
7865bb67d4 Clang: Update patch for leaking file descriptors
...to make it apply cleanly.

Change-Id: I512a48ecd7ce742885520a01bc6b774e244b1545
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:23:25 +00:00
Nikolai Kosjar
249b392947 Clang: Remove patch fixing mingw build
It was for llvm/clang >= 4.0, but we are still on 3.9 for now.

Change-Id: I29338b6ed90b3ac4f32021085139e6917fd5ac9e
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2017-07-13 13:23:19 +00:00
Nikolai Kosjar
bd0d8f532c Clang: Limit mingw workaround to mingw
MSVC seems to have problems linking llvm-tblgen.exe with debug and release
libraries.

Change-Id: Ic7cd120f2bb19f762e656de565ebc3c98bbd750c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-03-08 11:07:14 +00:00
Eike Ziller
6508956d15 Clang: Add patch against very slow reparsing of large files
Task-number: QTCREATORBUG-17397
Change-Id: I3734b77341ca2c7fd87b0f8e5d1502b859de7692
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-03-08 10:38:39 +00:00
Nikolai Kosjar
83f1b19a3f Clang: Add patch for workaround of llvm-tblgen crash during mingw build
https://bugs.llvm.org/show_bug.cgi?id=32018
Bug 32018 - llvm-tblgen.exe crashes while compiling LLVM/Clang current
release_40 with MinGW 4.9.2

Change-Id: Ie5ac7c5d0ef040b5767162e19532a8a255633322
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-03-08 08:31:28 +00:00
Nikolai Kosjar
da4e42ec25 Clang: Add patch against leaking file descriptors on windows
FileManager: mark virtual file entries as valid entries
https://reviews.llvm.org/D27810

Task-number: QTCREATORBUG-15449
Change-Id: I8db251a6556f0eb6f3057df751d69dfd09771631
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-03-08 08:31:17 +00:00