1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 12:12:47 +01:00
Commit Graph

9938 Commits

Author SHA1 Message Date
LLVM GN Syncbot
6139db4174 [gn build] Port 3bc88eb3924f 2021-04-16 01:16:51 +00:00
Craig Topper
6b675e5ab5 [TableGen] Reduce the number of map lookups in TypeSetByHwMode::getOrCreate. NFCI
hasMode was looking up the map once. Then we'd either call get which
would look up again, or we'd insert into the map which requires
walking the map to find the insertion point.

I believe the hasMode was needed because get has a special case
to look for DefaultMode if the mode being asked for doesn't exist.
We don't want that here so we were using hasMode to make sure we
wouldn't hit that case.

Simplify to a regular operator[] access which will default
construct a SetType if the lookup fails.
2021-04-15 12:32:21 -07:00
LLVM GN Syncbot
3e03953b19 [gn build] Port 82787eb2285d 2021-04-15 18:54:08 +00:00
Martin Storsjö
a74fefb10d Reland "[lit] Handle plain negations directly in the internal shell"
Keep running "not --crash" via the external "not" executable, but
for plain negations, and for cases that use the shell "!" operator,
just skip that argument and invert the return code.

The libcxx tests only use the shell operator "!" for negations,
never the "not" executable, because libcxx tests can be run without
having a fully built llvm tree available providing the "not"
executable.

This allows using the internal shell for libcxx tests.

It should be possible to reland this now that D99938 fixed the
one test failure in clang-tidy that broke when "not" was handled
internally, letting lit/python execute grep.exe directly instead
of via not.exe. (See D99330 and D99406 for more commentery on the
exact issue that broke and other potential ways of fixing it.)

Differential Revision: https://reviews.llvm.org/D98859
2021-04-15 11:02:14 +03:00
LLVM GN Syncbot
275a701620 [gn build] Port b7459a10dad1 2021-04-15 01:52:03 +00:00
Nico Weber
691c156cc8 [llvm-objdump] Switch command-line parsing from llvm::cl to OptTable
This is similar to D83530, but for llvm-objdump.

The motivation is the desire to add an `llvm-otool` symlink to
llvm-objdump that behaves like macOS's `otool`, using the same
technique the at llvm-objcopy uses to behave like `strip` (etc).

This change for the most part preserves behavior. In some cases,
it increases compatibility with GNU objdump a bit. For example,
the long options now require two dashes, and the long options
taking arguments for the most part now require a `=` in front
of the value. Exceptions are flags where tests passed the
value separately, for these the separate form is kept as
an alias to the = form.

The one-letter short form args are now joined or separate
and long longer accept a =, which also matches GNU objdump.

cl::opt<>s in libraries now have to be explicitly plumbed
through. This patch does that for --x86-asm-syntax=, but
there's hope that we can remove that again.

Differential Revision: https://reviews.llvm.org/D100433
2021-04-14 20:12:24 -04:00
LLVM GN Syncbot
c9f9984c19 [gn build] Port f992cfba7173 2021-04-14 18:37:22 +00:00
LLVM GN Syncbot
8065b78450 [gn build] Port e98060fa72cc 2021-04-14 18:37:21 +00:00
Nico Weber
a59d6ed74c [gn build] try to make sync_source_lists_from_cmake.py py3-compatible 2021-04-14 14:36:29 -04:00
LLVM GN Syncbot
7c925af450 [gn build] Port bbab9f986c6d 2021-04-14 13:59:02 +00:00
Martin Storsjö
1e4209ecab [lit] Always quote arguments containing '[' on windows
This avoids breaking clang-tidy/infrastructure/validate-check-names.cpp
if 'not' is evaluated as a lit internal tool (making TestRunner
invoke 'grep' directly in that test, instead of invoking 'not', which
then invokes 'grep').

The quoting of arguments is still brittle if the executable is an
MSYS based tool though, as MSYS based tools incorrectly unescape
backslashes in quoted arguments (contrary to regular win32 argument
parsing rules), see D99406 and
https://github.com/msys2/msys2-runtime/issues/36 for more examples
of the issues.

Differential Revision: https://reviews.llvm.org/D99938
2021-04-14 12:32:48 +03:00
LLVM GN Syncbot
516ac4b887 [gn build] Port 530456caf908 2021-04-14 07:28:18 +00:00
LLVM GN Syncbot
17e8adc605 [gn build] Port cbc9c4ea90e1 2021-04-14 06:32:13 +00:00
LLVM GN Syncbot
222a60a438 [gn build] Port 8ca366935b05 2021-04-13 18:49:06 +00:00
LLVM GN Syncbot
f9f3d0dc0e [gn build] Port 46b8ea2fff90 2021-04-13 18:49:05 +00:00
LLVM GN Syncbot
5869cb34cc [gn build] Port bb6d96ced80f 2021-04-13 16:05:40 +00:00
LLVM GN Syncbot
1d77addbf5 [gn build] Port 8914902b01a3 2021-04-13 16:05:39 +00:00
LLVM GN Syncbot
c4d0a1f07c [gn build] Port be54341cd2ff 2021-04-13 13:07:25 +00:00
LLVM GN Syncbot
658e3794a9 [gn build] Port 9b0a3388eb36 2021-04-13 13:07:25 +00:00
LLVM GN Syncbot
9521c0c689 [gn build] Port 916fecb499c5 2021-04-13 13:07:24 +00:00
LLVM GN Syncbot
3d6e4d2ad8 [gn build] Port 7f1963dc8e23 2021-04-13 13:07:23 +00:00
LLVM GN Syncbot
aff7a3e7fe [gn build] Port 4f9b2469f33f 2021-04-13 13:07:23 +00:00
LLVM GN Syncbot
99244a139d [gn build] Port 21d6636d83b3 2021-04-13 13:07:22 +00:00
Nico Weber
50f9ad1921 [gn build] fix bug in fb0b19c3de3b
Since __config is no longer in the concatenated generated __config_site,
it now needs to be copied.

(Also fix a comment typo while here.)
2021-04-13 09:06:29 -04:00
LLVM GN Syncbot
3b34c914bc [gn build] Port e96df3e531f5 2021-04-13 01:35:58 +00:00
LLVM GN Syncbot
f7c08f057f [gn build] Port 6a1ac88fc19a 2021-04-12 15:51:13 +00:00
LLVM GN Syncbot
0357a99e88 [gn build] Port 26beecfe470b 2021-04-12 15:51:12 +00:00
LLVM GN Syncbot
4bd3808535 [gn build] Port 0b439e4cc9db 2021-04-12 15:51:11 +00:00
Yuanfang Chen
2ff261f721 abtest.py: support bisection based on a response file
Also makes LINK_TEST customizable from commandline with `--test` option.
2021-04-08 09:46:01 -07:00
Luís Marques
c7d86ed0c7 [lit testing] Fix xfail-cl.py test worker count
This would fail in test environments with < 3 hardware threads.

Differential Revision: https://reviews.llvm.org/D99858
2021-04-06 20:48:18 +01:00
Arthur Eubanks
a5a1ba95e0 [llvm-reduce] Remove unwanted module inline asm
We can clear line by line, but that's likely not very important.

Reviewed By: hans

Differential Revision: https://reviews.llvm.org/D99921
2021-04-06 09:35:37 -07:00
Nico Weber
03c7f6ee36 [gn build] (manually) port 0116d04d04f2 2021-04-05 14:12:58 -04:00
LLVM GN Syncbot
05484c625c [gn build] Port 9b3df78b4c2a 2021-04-05 17:21:14 +00:00
Craig Topper
100a1c9836 [TableGen] Use StringRef instead of std::string to split up a string that's being parsed. NFCI 2021-04-03 11:48:13 -07:00
Nikita Popov
5794a3620e [FastISel] Remove kill tracking
This is a followup to D98145: As far as I know, tracking of kill
flags in FastISel is just a compile-time optimization. However,
I'm not actually seeing any compile-time regression when removing
the tracking. This probably used to be more important in the past,
before FastRA was switched to allocate instructions in reverse
order, which means that it discovers kills as a matter of course.

As such, the kill tracking doesn't really seem to serve a purpose
anymore, and just adds additional complexity and potential for
errors. This patch removes it entirely. The primary changes are
dropping the hasTrivialKill() method and removing the kill
arguments from the emitFast methods. The rest is mechanical fixup.

Differential Revision: https://reviews.llvm.org/D98294
2021-04-03 15:50:13 +02:00
Nico Weber
81b1b4c379 [gn build] hook up tsan on macOS too
Mostly just works already.
2021-04-02 19:21:38 -04:00
Nico Weber
3b240e5b42 [gn build] (manually) port 4c58f333f141 2021-04-02 18:21:37 -04:00
Nico Weber
6c0a714ca5 [gn build] add build file for tsan runtime
Linux-only for now. Some mac bits stubbed out, but not tested.

Good enough for the tiny_race.c example at
https://clang.llvm.org/docs/ThreadSanitizer.html :

   $ out/gn/bin/clang -fsanitize=address -g -O1 tiny_race.c
   $ while true; do ./a.out || echo $? ; done

While here, also make `-fsanitize=address` work for .c files.

Differential Revision: https://reviews.llvm.org/D99795
2021-04-02 12:59:14 -04:00
LLVM GN Syncbot
c1f569fa7a [gn build] Port 0f7bbbc481e2 2021-04-02 10:22:54 +00:00
Samuel
caa230762f [llvm-reduce] Add header guards and fix clang-tidy warnings
Add header guards and fix other clang-tidy warnings in .h files.
Also align misaligned header docs

Reviewed By: aeubanks

Differential Revision: https://reviews.llvm.org/D99634
2021-04-01 20:38:49 -07:00
LLVM GN Syncbot
7469d16788 [gn build] Port fdc4f19e2f80 2021-04-01 17:18:32 +00:00
Philip Reames
4739f740ea Revert "Make TableGenGlobalISel an object library"
This reverts commit 2c3cf62d4a26de85aab180bb43a579c913b17f3e.

Causes build failures on x86_64, will respond to commit thread with link errors.
2021-03-31 13:27:00 -07:00
Aaron Puchert
936867007c Make TableGenGlobalISel an object library
That's how it was originally intended but that wasn't possible because
we still needed to support older CMake versions.

The problem here is that the sources in TableGenGlobalISel are meant to
be linked into both llvm-tblgen and TableGenTests (a unit test), but not
be part of LLVM proper. So they shouldn't be an ordinary LLVM component.
Because they are used in llvm-tblgen, they can't draw in the LLVM dylib
dependency, but then we'd have to do the same thing in TableGenTests to
make sure we don't link both a static Support library and another copy
through the LLVM dylib.

With an object library we're just reusing the object files and don't
have to care about dependencies at all.

Reviewed By: beanz

Differential Revision: https://reviews.llvm.org/D74588
2021-03-31 22:20:56 +02:00
Alex Richardson
99e7c8e198 [TableGen] Emit more helpful error messages on empty type set
I have seen this error quite frequently in our out-of-tree CHERI backends
and the lack of location information sometimes makes it quite difficult
to track down the actual source of the error.
This patch changes the llvm_unreachable() to a PrintFatalError() so that
tablegen prints a stack of source locations.

Reviewed By: craig.topper

Differential Revision: https://reviews.llvm.org/D99468
2021-03-31 09:24:03 +01:00
Zhiwei Chen
3b962fb76d [Utils][Emacs] Improve syntax highlight
Reviewed By: MaskRay

Differential Revision: https://reviews.llvm.org/D99404
2021-03-30 19:32:30 -07:00
Nico Weber
950096655f Reland "[gn build] port 48e4b0f (__config_site)"
This reverts commit 13aff21f0da7007c42d407b4ec5c1f6b24cb6831,
since the CMake part relanded in c06a8f9caa51c7ea7.

The GN part is a bit simpler than last time due to the
prior simplifications in acea470c167fc40.
2021-03-30 20:32:36 -04:00
LLVM GN Syncbot
61b6f61fa0 [gn build] Port c51e91e04681 2021-03-30 12:15:19 +00:00
Nico Weber
9d6f4d8829 [gn build] (semi-manually) port 51fa9e0fd984 2021-03-30 06:59:37 -04:00
Dave Lee
ff0a7ebbd3 [llvm][utils] Fix handling of llvm::None 2021-03-29 17:43:53 -07:00
LLVM GN Syncbot
905dd0e95b [gn build] Port 5178ffc7cf92 2021-03-29 22:12:00 +00:00