Commit Graph

3191 Commits

Author SHA1 Message Date
Aries 521e83631d Roughly cleaned RVV instruction selection. 2022-12-19 09:40:05 +08:00
LLVM GN Syncbot 5fa43db46e [gn build] Port 122efef8ee 2022-12-05 00:11:52 +00:00
LLVM GN Syncbot 7724ac6163 [gn build] Port 17db0de330 2022-12-03 20:23:49 +00:00
LLVM GN Syncbot e1da0e9ce0 [gn build] Port 89f36dd8f3 2022-12-01 11:19:48 +00:00
LLVM GN Syncbot 9b8eb0cf05 [gn build] Port 65d6d67fc9 2022-12-01 11:19:48 +00:00
LLVM GN Syncbot 0926035ed5 [gn build] Port b95646fe70 2022-11-30 22:46:01 +00:00
LLVM GN Syncbot b802b537f8 [gn build] Port 77b2205245 2022-11-30 14:41:02 +00:00
LLVM GN Syncbot 9fa65ba155 [gn build] Port d3c851d3fc 2022-11-30 13:51:23 +00:00
LLVM GN Syncbot 1114d1a976 [gn build] Port 185d4964a1 2022-11-29 20:47:01 +00:00
Arthur Eubanks 16312c5d7a [MCJIT][test] Use new pass manager API 2022-11-28 12:23:42 -08:00
LLVM GN Syncbot eddcc01f35 [gn build] Port ed34590c1a 2022-11-25 13:20:54 +00:00
Nico Weber 4ffc6f3b83 [bolt] Stop setting config.llvm_plugin_ext in lit.site.cfg.py.in
config.llvm_plugin_ext is used by lit to set the %pluginext
substitution. bolt's tests don't use %pluginext, so they don't
need to set config.llvm_plugin_ext.

Differential Revision: https://reviews.llvm.org/D138325
2022-11-22 20:29:14 -05:00
Sami Tolvanen cacd3e73d7 Add generic KCFI operand bundle lowering
The KCFI sanitizer emits "kcfi" operand bundles to indirect
call instructions, which the LLVM back-end lowers into an
architecture-specific type check with a known machine instruction
sequence. Currently, KCFI operand bundle lowering is supported only
on 64-bit X86 and AArch64 architectures.

As a lightweight forward-edge CFI implementation that doesn't
require LTO is also useful for non-Linux low-level targets on
other machine architectures, add a generic KCFI operand bundle
lowering pass that's only used when back-end lowering support is not
available and allows -fsanitize=kcfi to be enabled in Clang on all
architectures.

This relands commit eb2a57ebc7 with
fixes.

Reviewed By: nickdesaulniers, MaskRay

Differential Revision: https://reviews.llvm.org/D135411
2022-11-22 23:01:18 +00:00
Nico Weber edbfb829ba [gn build] Add missing dep from check-bolt on llvm-bat-dump 2022-11-21 20:48:46 -05:00
Nico Weber 6bb781fa9a [gn build] Add build files for //bolt
Adds build files for libraries, tools, and tests -- everything except
the runtime.

Doesn't hook up bolt in the main BUILD.gn file yet -- I want to verify
that it builds on Linux, macOS, Windows before doing that. (I've only
checked on macOS so far.)

`ninja check-bolt` passes on macOS with this.
(I locally bumped the deployment target to macOS 10.12 for that. bolt/ uses
std::mutex quite a bit, which requires 10.12.)

Differential Revision: https://reviews.llvm.org/D138355
2022-11-21 19:45:54 -05:00
Nico Weber 281a5c7ef1 [llvm,polly,clang] Stop setting config.enable_shared in most places
Clang's lit.cfg.py reads this to add an "enable-shared" feature that
three of clang's lit tests use. Nothing else reads enable_shared, so
remove it from most lit.site.cfg.py.in files.

Differential Revision: https://reviews.llvm.org/D138301
2022-11-21 08:54:14 -05:00
Nico Weber 3b48a97b19 [gn build] port af8c49dc1e 2022-11-20 12:02:33 -05:00
Nico Weber 7c188afde1 [gn build] Reformat all build files
Ran:

    git ls-files '*.gn' '*.gni' | xargs llvm/utils/gn/gn.py format
2022-11-19 11:54:55 -05:00
Nico Weber 63f79fe2eb [gn build] port 7059a6c32c 2022-11-18 06:48:51 -05:00
Fangrui Song fc91c70593 Revert D135411 "Add generic KCFI operand bundle lowering"
This reverts commit eb2a57ebc7.

llvm/include/llvm/Transforms/Instrumentation/KCFI.h including
llvm/CodeGen is a layering violation. We should use an approach where
Instrumementation/ doesn't need to include CodeGen/.
Sorry for not spotting this in the review.
2022-11-17 22:45:30 +00:00
Sami Tolvanen eb2a57ebc7 Add generic KCFI operand bundle lowering
The KCFI sanitizer emits "kcfi" operand bundles to indirect
call instructions, which the LLVM back-end lowers into an
architecture-specific type check with a known machine instruction
sequence. Currently, KCFI operand bundle lowering is supported only
on 64-bit X86 and AArch64 architectures.

As a lightweight forward-edge CFI implementation that doesn't
require LTO is also useful for non-Linux low-level targets on
other machine architectures, add a generic KCFI operand bundle
lowering pass that's only used when back-end lowering support is not
available and allows -fsanitize=kcfi to be enabled in Clang on all
architectures.

Reviewed By: nickdesaulniers, MaskRay

Differential Revision: https://reviews.llvm.org/D135411
2022-11-17 21:55:00 +00:00
LLVM GN Syncbot ed4943d560 [gn build] Port 332c4af35d 2022-11-16 15:19:13 +00:00
LLVM GN Syncbot e611d41143 [gn build] Port 617277e7cb 2022-11-16 06:08:50 +00:00
Woody Lin 409eaff5dd [AArch64InstPrinter] Print TargetAddress as an uint64_t
Outputs readable addresses by printed 'TargetAddress' as an uint64_t
value.

`bl     -0x37efd56628` => `bl     0xffffffc8102a99d8`

Reviewed By: dmgreen

Differential Revision: https://reviews.llvm.org/D137260
2022-11-16 13:34:22 +08:00
LLVM GN Syncbot 8d0b2f09a2 [gn build] Port a16bd4f9f2 2022-11-15 22:46:53 +00:00
LLVM GN Syncbot b7d9310128 [gn build] Port 4be39288f5 2022-11-15 22:46:52 +00:00
Nico Weber 20b0e0a71a [gn build] Stop defining GTEST_LANG_CXX11, pass /Zc:__cplusplus with msvc
Ports:
* https://reviews.llvm.org/D84023
* https://reviews.llvm.org/rG4f5ccc72f6a6e
  (but see https://reviews.llvm.org/rG4901199f5b84b223)

No intended behavior change.
2022-11-15 10:56:53 -05:00
Nico Weber 1b829c3d3a [gn build] Make libcxx_enable_debug_mode work better, maybe
Refer to _LIBCPP_ENABLE_DEBUG_MODE instead of the old _LIBCPP_DEBUG
in a comment, and write that to __config_site correctly too.

See 13ea134323 and the comments in https://crbug.com/1358646.

Also change the default of libcxx_enable_debug_mode to false for now.
Since we used to not write _LIBCPP_ENABLE_DEBUG_MODE, the previous
default of true had no effect (except for compiling debug.cpp and
legacy_debug_handler.cpp, which we now no longer build by default).
So this (mostly) preserves previous behavior.
2022-11-15 10:45:41 -05:00
LLVM GN Syncbot a4ae029b08 [gn build] Port 1ebfe9b264 2022-11-15 09:07:55 +00:00
LLVM GN Syncbot c83c69dd0d [gn build] Port d52e2839f3 2022-11-14 14:05:19 +00:00
LLVM GN Syncbot 7e4cfcdb6f [gn build] Port dd46a08008 2022-11-14 10:12:18 +00:00
Nico Weber 6e8f8b1964 [gn build] Extract gen_arch_intrinsics() template to remove some duplication
No behavior change.

Differential Revision: https://reviews.llvm.org/D137784
2022-11-13 09:38:53 -05:00
Nico Weber 369237abc4 [gn build] port e1b88c8a09 (clang resource dir uses only major version) 2022-11-10 10:13:59 -05:00
LLVM GN Syncbot baf4930fb0 [gn build] Port 85f08c4197 2022-11-10 13:53:38 +00:00
LLVM GN Syncbot f9256fca66 [gn build] Port 135a9272a4 2022-11-10 13:53:37 +00:00
Nico Weber c3c94a885c [gn build] port b60f801607 2022-11-10 08:53:12 -05:00
Nico Weber ce2474ff60 [gn build] port a11cd0d94e (gtest llvm/utils/unittest -> third-party/unittest) 2022-11-09 19:58:28 -05:00
LLVM GN Syncbot ec9aae9784 [gn build] Port 428ac8f3a0 2022-11-07 23:22:09 +00:00
LLVM GN Syncbot 23831f0efe [gn build] Port 59ef4b3686 2022-11-05 20:26:22 +00:00
LLVM GN Syncbot f6a6f35d1b [gn build] Port cf239c2f17 2022-11-02 21:01:56 +00:00
Nico Weber c68c19fb87 [gn build] port 6e6704b0dc 2022-11-01 10:07:13 -04:00
LLVM GN Syncbot f4ac737218 [gn build] Port 627465cf9f 2022-10-31 23:37:46 +00:00
LLVM GN Syncbot 70fdabff41 [gn build] Port 84ea6b6f78 2022-10-31 21:45:27 +00:00
LLVM GN Syncbot a2752e3d85 [gn build] Port 0d01300aac 2022-10-31 21:45:26 +00:00
LLVM GN Syncbot cf4d409635 [gn build] Port aee2a35ac4 2022-10-31 15:53:48 +00:00
LLVM GN Syncbot d437f59f21 [gn build] Port 30ea3fcc4c 2022-10-29 06:45:02 +00:00
LLVM GN Syncbot cf953e34d0 [gn build] Port 23f02693ec 2022-10-28 02:40:48 +00:00
LLVM GN Syncbot e6c23f4724 [gn build] Port 0e720e6ada 2022-10-28 01:53:34 +00:00
LLVM GN Syncbot 5ed5b2a28c [gn build] Port b51b90d6e2 2022-10-27 12:53:31 +00:00
LLVM GN Syncbot 93736d416a [gn build] Port 17059753f1 2022-10-27 12:53:30 +00:00