#
38818b60 |
| 04-Jan-2023 |
serge-sans-paille <sguelton@mozilla.com> |
Move from llvm::makeArrayRef to ArrayRef deduction guides - llvm/ part
Use deduction guides instead of helper functions.
The only non-automatic changes have been:
1. ArrayRef(some_uint8_pointer, 0
Move from llvm::makeArrayRef to ArrayRef deduction guides - llvm/ part
Use deduction guides instead of helper functions.
The only non-automatic changes have been:
1. ArrayRef(some_uint8_pointer, 0) needs to be changed into ArrayRef(some_uint8_pointer, (size_t)0) to avoid an ambiguous call with ArrayRef((uint8_t*), (uint8_t*)) 2. CVSymbol sym(makeArrayRef(symStorage)); needed to be rewritten as CVSymbol sym{ArrayRef(symStorage)}; otherwise the compiler is confused and thinks we have a (bad) function prototype. There was a few similar situation across the codebase. 3. ADL doesn't seem to work the same for deduction-guides and functions, so at some point the llvm namespace must be explicitly stated. 4. The "reference mode" of makeArrayRef(ArrayRef<T> &) that acts as no-op is not supported (a constructor cannot achieve that).
Per reviewers' comment, some useless makeArrayRef have been removed in the process.
This is a follow-up to https://reviews.llvm.org/D140896 that introduced the deduction guides.
Differential Revision: https://reviews.llvm.org/D140955
show more ...
|
#
d9ab3e82 |
| 26-Dec-2022 |
serge-sans-paille <sguelton@mozilla.com> |
[clang] Use a StringRef instead of a raw char pointer to store builtin and call information
This avoids recomputing string length that is already known at compile time.
It has a slight impact on pr
[clang] Use a StringRef instead of a raw char pointer to store builtin and call information
This avoids recomputing string length that is already known at compile time.
It has a slight impact on preprocessing / compile time, see
https://llvm-compile-time-tracker.com/compare.php?from=3f36d2d579d8b0e8824d9dd99bfa79f456858f88&to=e49640c507ddc6615b5e503144301c8e41f8f434&stat=instructions:u
This a recommit of e953ae5bbc313fd0cc980ce021d487e5b5199ea4 and the subsequent fixes caa713559bd38f337d7d35de35686775e8fb5175 and 06b90e2e9c991e211fecc97948e533320a825470.
The above patchset caused some version of GCC to take eons to compile clang/lib/Basic/Targets/AArch64.cpp, as spotted in aa171833ab0017d9732e82b8682c9848ab25ff9e. The fix is to make BuiltinInfo tables a compilation unit static variable, instead of a private static variable.
Differential Revision: https://reviews.llvm.org/D139881
show more ...
|
#
aa171833 |
| 26-Dec-2022 |
Vitaly Buka <vitalybuka@google.com> |
Revert "[clang] Use a StringRef instead of a raw char pointer to store builtin and call information" Revert "Fix lldb option handling since e953ae5bbc313fd0cc980ce021d487e5b5199ea4 (part 2)" Revert "
Revert "[clang] Use a StringRef instead of a raw char pointer to store builtin and call information" Revert "Fix lldb option handling since e953ae5bbc313fd0cc980ce021d487e5b5199ea4 (part 2)" Revert "Fix lldb option handling since e953ae5bbc313fd0cc980ce021d487e5b5199ea4"
GCC build hangs on this bot https://lab.llvm.org/buildbot/#/builders/37/builds/19104 compiling CMakeFiles/obj.clangBasic.dir/Targets/AArch64.cpp.d
The bot uses GNU 11.3.0, but I can reproduce locally with gcc (Debian 12.2.0-3) 12.2.0.
This reverts commit caa713559bd38f337d7d35de35686775e8fb5175. This reverts commit 06b90e2e9c991e211fecc97948e533320a825470. This reverts commit e953ae5bbc313fd0cc980ce021d487e5b5199ea4.
show more ...
|
#
e953ae5b |
| 12-Dec-2022 |
serge-sans-paille <sguelton@mozilla.com> |
[clang] Use a StringRef instead of a raw char pointer to store builtin and call information
This avoids recomputing string length that is already known at compile time.
It has a slight impact on pr
[clang] Use a StringRef instead of a raw char pointer to store builtin and call information
This avoids recomputing string length that is already known at compile time.
It has a slight impact on preprocessing / compile time, see
https://llvm-compile-time-tracker.com/compare.php?from=3f36d2d579d8b0e8824d9dd99bfa79f456858f88&to=e49640c507ddc6615b5e503144301c8e41f8f434&stat=instructions:u
This is a recommit of 719d98dfa841c522d8d452f0685e503538415a53 that into account a GGC issue (probably https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92181) when dealing with intiailizer_list and constant expressions.
Workaround this by avoiding initializer list, at the expense of a temporary plain old array.
Differential Revision: https://reviews.llvm.org/D139881
show more ...
|
#
07d9ab9a |
| 23-Dec-2022 |
serge-sans-paille <sguelton@mozilla.com> |
Revert "[clang] Use a StringRef instead of a raw char pointer to store builtin and call information"
There are still remaining issues with GCC 12, see for instance
https://lab.llvm.org/buildbot/#/b
Revert "[clang] Use a StringRef instead of a raw char pointer to store builtin and call information"
There are still remaining issues with GCC 12, see for instance
https://lab.llvm.org/buildbot/#/builders/93/builds/12669
This reverts commit 5ce4e92264102de21760c94db9166afe8f71fcf6.
show more ...
|
#
5ce4e922 |
| 12-Dec-2022 |
serge-sans-paille <sguelton@mozilla.com> |
[clang] Use a StringRef instead of a raw char pointer to store builtin and call information
This avoids recomputing string length that is already known at compile time.
It has a slight impact on pr
[clang] Use a StringRef instead of a raw char pointer to store builtin and call information
This avoids recomputing string length that is already known at compile time.
It has a slight impact on preprocessing / compile time, see
https://llvm-compile-time-tracker.com/compare.php?from=3f36d2d579d8b0e8824d9dd99bfa79f456858f88&to=e49640c507ddc6615b5e503144301c8e41f8f434&stat=instructions:u
This is a recommit of 719d98dfa841c522d8d452f0685e503538415a53 with a change to llvm/utils/TableGen/OptParserEmitter.cpp to cope with GCC bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108158
Differential Revision: https://reviews.llvm.org/D139881
show more ...
|
#
b7065a31 |
| 23-Dec-2022 |
serge-sans-paille <sguelton@mozilla.com> |
Revert "[clang] Use a StringRef instead of a raw char pointer to store builtin and call information"
Failing builds: https://lab.llvm.org/buildbot#builders/9/builds/19030 This is GCC specific and ha
Revert "[clang] Use a StringRef instead of a raw char pointer to store builtin and call information"
Failing builds: https://lab.llvm.org/buildbot#builders/9/builds/19030 This is GCC specific and has been reported upstream: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108158
This reverts commit 719d98dfa841c522d8d452f0685e503538415a53.
show more ...
|
#
719d98df |
| 12-Dec-2022 |
serge-sans-paille <sguelton@mozilla.com> |
[clang] Use a StringRef instead of a raw char pointer to store builtin and call information
This avoids recomputing string length that is already known at compile time.
It has a slight impact on pr
[clang] Use a StringRef instead of a raw char pointer to store builtin and call information
This avoids recomputing string length that is already known at compile time.
It has a slight impact on preprocessing / compile time, see
https://llvm-compile-time-tracker.com/compare.php?from=3f36d2d579d8b0e8824d9dd99bfa79f456858f88&to=e49640c507ddc6615b5e503144301c8e41f8f434&stat=instructions:u
Differential Revision: https://reviews.llvm.org/D139881
show more ...
|
#
6a35815c |
| 04-Dec-2022 |
serge-sans-paille <sguelton@mozilla.com> |
Store OptTable::Info::Name as a StringRef
This is a recommit of 8ae18303f97d5dcfaecc90b4d87effb2011ed82e, with a few cleanups.
This avoids implicit conversion to StringRef at several points, which
Store OptTable::Info::Name as a StringRef
This is a recommit of 8ae18303f97d5dcfaecc90b4d87effb2011ed82e, with a few cleanups.
This avoids implicit conversion to StringRef at several points, which in turns avoid redundant calls to strlen.
As a side effect, this greatly simplifies the implementation of StrCmpOptionNameIgnoreCase.
It also eventually gives a consistent, humble speedup in compilation time (timing updated since original commit).
https://llvm-compile-time-tracker.com/compare.php?from=de4b6a1bc64db33643f001ad45fae7b92b4a4688&to=c23a93d1292052b4be2fbe8c586fa31143d0c7ed&stat=instructions:u
Differential Revision: https://reviews.llvm.org/D139274
show more ...
|
#
d5090cd9 |
| 06-Oct-2022 |
Alex Brachet <abrachet@google.com> |
[llvm-driver] Add various tools to the llvm-driver
The llvm-driver, enabled with LLVM_TOOL_LLVM_DRIVER_BUILD combines many llvm executables into one to save overall toolchain size. This patch adds a
[llvm-driver] Add various tools to the llvm-driver
The llvm-driver, enabled with LLVM_TOOL_LLVM_DRIVER_BUILD combines many llvm executables into one to save overall toolchain size. This patch adds a few more llvm tools to the llvm-driver.
Differential Revision: https://reviews.llvm.org/D135281
show more ...
|
Revision tags: llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1, llvmorg-16-init |
|
#
64a78c85 |
| 05-Jul-2022 |
Nicolai Hähnle <nicolai.haehnle@amd.com> |
Remove unnecessary includes of ManagedStatic.h
Differential Revision: https://reviews.llvm.org/D129115
|
Revision tags: llvmorg-14.0.6, llvmorg-14.0.5, llvmorg-14.0.4, llvmorg-14.0.3, llvmorg-14.0.2, llvmorg-14.0.1, llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3, llvmorg-14.0.0-rc2, llvmorg-14.0.0-rc1 |
|
#
7cca34ac |
| 08-Feb-2022 |
Tobias Hieta <tobias@hieta.se> |
[llvm-rc]: Find <target>-clang over just clang
This patch makes llvm-rc/windres prefer <target>-clang over clang when doing it's preprocessing. This is so that we can have a .cfg file for <target> a
[llvm-rc]: Find <target>-clang over just clang
This patch makes llvm-rc/windres prefer <target>-clang over clang when doing it's preprocessing. This is so that we can have a .cfg file for <target> and configure sysroot and other important flags.
Config files not picked up with clang --target=<target> automatically.
We only look for <target>-clang in the same dir as llvm-windres and not for all PATHs to minimize the change.
Reviewed By: mstorsjo
Differential Revision: https://reviews.llvm.org/D119219
show more ...
|
Revision tags: llvmorg-15-init, llvmorg-13.0.1, llvmorg-13.0.1-rc3, llvmorg-13.0.1-rc2, llvmorg-13.0.1-rc1 |
|
#
8189c4ee |
| 19-Oct-2021 |
Fangrui Song <i@maskray.me> |
[tools] Delete redundant 'static' from namespace scope 'static const'. NFC
|
Revision tags: llvmorg-13.0.0, llvmorg-13.0.0-rc4, llvmorg-13.0.0-rc3, llvmorg-13.0.0-rc2, llvmorg-13.0.0-rc1 |
|
#
46020f6f |
| 02-Aug-2021 |
Martin Storsjö <martin@martin.st> |
[llvm-rc] Allow specifying language with a leading 0x prefix
This option is always interpreted strictly as a hexadecimal string, even if it has no prefix that indicates the number format, hence the
[llvm-rc] Allow specifying language with a leading 0x prefix
This option is always interpreted strictly as a hexadecimal string, even if it has no prefix that indicates the number format, hence the existing call to StringRef::getAsInteger(16, ...).
StringRef::getAsInteger(0, ...) consumes a leading "0x" prefix is present, but when the radix is specified, the radix shouldn't be included.
Both MS rc.exe and GNU windres accept the language with that prefix.
Also allow specifying the codepage to llvm-windres with a different radix, as GNU windres allows that (but MS rc.exe doesn't).
This fixes https://llvm.org/PR51295.
Differential Revision: https://reviews.llvm.org/D107263
show more ...
|
#
6da3d8b1 |
| 28-Jul-2021 |
Fangrui Song <i@maskray.me> |
[llvm] Replace LLVM_ATTRIBUTE_NORETURN with C++11 [[noreturn]]
[[noreturn]] can be used since Oct 2016 when the minimum compiler requirement was bumped to GCC 4.8/MSVC 2015.
Note: the definition of
[llvm] Replace LLVM_ATTRIBUTE_NORETURN with C++11 [[noreturn]]
[[noreturn]] can be used since Oct 2016 when the minimum compiler requirement was bumped to GCC 4.8/MSVC 2015.
Note: the definition of LLVM_ATTRIBUTE_NORETURN is kept for now.
show more ...
|
Revision tags: llvmorg-14-init, llvmorg-12.0.1, llvmorg-12.0.1-rc4, llvmorg-12.0.1-rc3 |
|
#
bdb03557 |
| 18-Jun-2021 |
Martin Storsjö <martin@martin.st> |
[llvm-rc] Don't rewrite the arch in the default triple unless necessary
When the default target arch isn't one that is supported as a windows target, we want to set a suitable architecture (so that
[llvm-rc] Don't rewrite the arch in the default triple unless necessary
When the default target arch isn't one that is supported as a windows target, we want to set a suitable architecture (so that Clang tests that run plain 'llvm-rc' succeed checks for e.g. "#ifdef _WIN32" even for llvm builds that default to e.g. ppc64).
But if the default target architecture is usable, don't rewrite it. (Rewriting it, by e.g. "T.setArch(T.getArch())", normalizes the spelling of the architecture, e.g. changing i686 to i386. Such a change can make clang unable to find the right sysroot.)
This can't, unfortunately, practically be tested very well because it is entirely dependent on the default triple of the llvm build.
Differential Revision: https://reviews.llvm.org/D104589
show more ...
|
#
f1e2d585 |
| 24-Jun-2021 |
Fangrui Song <i@maskray.me> |
[OptTable] Rename PrintHelp to printHelp
To be consistent with other member functions and match the coding standard.
|
#
42f74e82 |
| 23-Jun-2021 |
Martin Storsjö <martin@martin.st> |
[llvm] Rename StringRef _lower() method calls to _insensitive()
This is a mechanical change. This actually also renames the similarly named methods in the SmallString class, however these methods do
[llvm] Rename StringRef _lower() method calls to _insensitive()
This is a mechanical change. This actually also renames the similarly named methods in the SmallString class, however these methods don't seem to be used outside of the llvm subproject, so this doesn't break building of the rest of the monorepo.
show more ...
|
Revision tags: llvmorg-12.0.1-rc2 |
|
#
703b0ed8 |
| 14-Jun-2021 |
Martin Storsjö <martin@martin.st> |
[ADT] Add StringRef consume_front_lower and consume_back_lower
These serve as a convenient combination of consume_front/back and startswith_lower/endswith_lower, consistent with other existing case
[ADT] Add StringRef consume_front_lower and consume_back_lower
These serve as a convenient combination of consume_front/back and startswith_lower/endswith_lower, consistent with other existing case insensitive methods named <operation>_lower.
Differential Revision: https://reviews.llvm.org/D104218
show more ...
|
Revision tags: llvmorg-12.0.1-rc1 |
|
#
f8de9aae |
| 15-Apr-2021 |
Martin Storsjö <martin@martin.st> |
[llvm-rc] Add a GNU windres-like frontend to llvm-rc
This primarily parses a different set of options and invokes the same resource compiler as llvm-rc normally. Additionally, it can convert directl
[llvm-rc] Add a GNU windres-like frontend to llvm-rc
This primarily parses a different set of options and invokes the same resource compiler as llvm-rc normally. Additionally, it can convert directly to an object file (which in MSVC style setups is done with the separate cvtres tool, or by the linker).
(GNU windres also supports other conversions; from coff object file back to .res, and from .res or object file back to .rc form; that's not yet implemented.)
The other bigger complication lies in being able to imply or pass the intended target triple, to let clang find the corresponding mingw sysroot for finding include files, and for specifying the default output object machine format.
It can be implied from the tool triple prefix, like `<triple>-[llvm-]windres` or picked up from the windres option e.g. `-F pe-x86-64`. In GNU windres, that option takes BFD style format names such as pe-i386 or pe-x86-64. As libbfd in binutils doesn't support Windows on ARM, there's no such canonical name for the ARM targets. Therefore, as an LLVM specific extension, this option is extended to allow passing full triples, too.
Differential Revision: https://reviews.llvm.org/D100756
show more ...
|
#
066b8f2f |
| 21-Apr-2021 |
Martin Storsjö <martin@martin.st> |
[llvm-rc] Try to fix the Preprocessor/llvm-rc.rc test on non arm/x86 architectures
When llvm-rc invokes clang for preprocessing, it uses a target triple derived from the default target. The test ver
[llvm-rc] Try to fix the Preprocessor/llvm-rc.rc test on non arm/x86 architectures
When llvm-rc invokes clang for preprocessing, it uses a target triple derived from the default target. The test verifies that e.g. _WIN32 is defined when preprocessing.
If running clang with e.g. -target ppc64le-windows-msvc, that particular arch/OS combination isn't hooked up, so _WIN32 doesn't get defined in that configuration. Therefore, the preprocessing test fails.
Instead make llvm-rc inspect the architecture of the default target. If it's one of the known supported architectures, use it as such, otherwise set a default one (x86_64). (Clang can run preprocessing with an x86_64 target triple, even if the x86 backend isn't enabled.)
Also remove superfluous llvm:: specifications on enums in llvm-rc.cpp.
show more ...
|
#
64bc44f5 |
| 14-Apr-2021 |
Martin Storsjö <martin@martin.st> |
[llvm-rc] Run clang to preprocess input files
Allow opting out from preprocessing with a command line argument.
Update tests to pass -no-preprocess to make it not try to use clang (which isn't a bu
[llvm-rc] Run clang to preprocess input files
Allow opting out from preprocessing with a command line argument.
Update tests to pass -no-preprocess to make it not try to use clang (which isn't a build level dependency of llvm-rc), but add a test that does preprocessing under clang/test/Preprocessor.
Update a few options to allow them both joined (as -DFOO) and separate (-D BR), as rc.exe allows both forms of them.
With the verbose flag set, this prints the preprocessing command used (which differs from what rc.exe does).
Tests under llvm/test/tools/llvm-rc only test constructing the preprocessor commands, while tests under clang/test/Preprocessor test actually running the preprocessor.
Differential Revision: https://reviews.llvm.org/D100755
show more ...
|
#
73cda4d1 |
| 16-Apr-2021 |
Martin Storsjö <martin@martin.st> |
[llvm-rc] Fix handling of the /X option to match its documentation and rc.exe
This matches how it's documented in the option listing.
Differential Revision: https://reviews.llvm.org/D100754
|
Revision tags: llvmorg-12.0.0, llvmorg-12.0.0-rc5, llvmorg-12.0.0-rc4, llvmorg-12.0.0-rc3, llvmorg-12.0.0-rc2, llvmorg-11.1.0, llvmorg-11.1.0-rc3, llvmorg-12.0.0-rc1, llvmorg-13-init, llvmorg-11.1.0-rc2, llvmorg-11.1.0-rc1, llvmorg-11.0.1, llvmorg-11.0.1-rc2, llvmorg-11.0.1-rc1, llvmorg-11.0.0, llvmorg-11.0.0-rc6, llvmorg-11.0.0-rc5, llvmorg-11.0.0-rc4, llvmorg-11.0.0-rc3, llvmorg-11.0.0-rc2 |
|
#
c913f6dc |
| 05-Aug-2020 |
Martin Storsjö <martin@martin.st> |
[llvm-rc] Lowercase the option definitions. NFC.
This matches how such options are most commonly defined in other tools.
This was pointed out in an earlier review a few months ago, that the llvm-rc
[llvm-rc] Lowercase the option definitions. NFC.
This matches how such options are most commonly defined in other tools.
This was pointed out in an earlier review a few months ago, that the llvm-rc td entries felt shouty.
The INCLUDE option is renamed to includepath, to avoid clashing with the tablegen include directive.
show more ...
|
Revision tags: llvmorg-11.0.0-rc1, llvmorg-12-init, llvmorg-10.0.1, llvmorg-10.0.1-rc4, llvmorg-10.0.1-rc3, llvmorg-10.0.1-rc2 |
|
#
f36f8b41 |
| 20-Jun-2020 |
Martin Storsjö <martin@martin.st> |
[llvm-rc] Implement the language id option
Differential Revision: https://reviews.llvm.org/D82265
|