2384 Commits

Author SHA1 Message Date
Pranav Kant
8dd9f206b5
[bazel] Fix mlir:VectorToSPIRV (#115188) 2024-11-06 09:56:50 -08:00
Alexey Samsonov
2f48765b45
[libc][bazel] Remove -mllvm --tail-merge-threshold=0 from Bazel. (#115061)
Follow-up on the `-mllvm --tail-merge-threshold=0` removal promised in
aeccc16497a84d61200f7ccfa3864096349260d3 (see
b2a9ea4420127d10b18ae648b16757665f8bbd7c commit message on why we don't
need this in Bazel, and will only keep in AArch64-specific compile flags
in CMake build).
2024-11-06 10:51:08 +01:00
Pranav Kant
c8221359f0
[bazel] Add dep on Analysis to fix build break (#115033) 2024-11-05 09:44:29 -08:00
Pranav Kant
8dfd9ff4b5
[bazel] Unbreak bazel bot (#115016)
Broken first by #114620
2024-11-05 08:23:46 -08:00
Pranav Kant
41312b011a
[bazel] Add :support to ast target (#115014) 2024-11-05 08:20:18 -08:00
Dmitri Gribenko
21f8e8c918 [bazel][libc] Port 9cfe3028ca7977fb582fa3b15b875e8772fc8fc0 (part 2) 2024-11-05 12:35:02 +01:00
Pranav Kant
2d2371df0f
[bazel][libc] Fix bazel build (#114917) 2024-11-04 19:10:57 -08:00
Vincent Lee
bb9ff32867
[bazel] Clean up unused exported files (#114620)
Some minor cleanup to the bazel files. These exported files are not
being referenced anymore in the tree, afaict, so let's clean them up.
Additionally, moved one of the filegroup targets higher to be consistent
with other filegroup usages where it's defined before first usage.
2024-11-04 15:22:38 -08:00
Benjamin Kramer
8528130a0c [bazel] Add missing dependency for 704808c275fa63d618c8d786313b3da815d4a75b 2024-11-04 22:42:32 +01:00
Benjamin Kramer
89b948d0ab [bazel][lld] Port 9a450a0096befc91bc947db6410d4c640c3d97cd 2024-11-03 18:27:59 +01:00
Benjamin Kramer
53ce5daf2c [bazel][mlir] Port a6e72f93923378bffe13367f6dedd526ad39b184 2024-11-03 18:23:49 +01:00
Benjamin Kramer
1b1e325583 [bazel][libc] Port 33bdb53d864e3e244d8fd5649062f17b7d4c958d 2024-11-03 18:11:55 +01:00
Alexey Samsonov
33d636f0f6
[libc][bazel] Fix linter warning - remove unused load. (#114493)
This load is no longer necessary since PLATFORM_CPU_ARM64 was removed in
fa17977c315062646d4d1e01262d68dd69313e61
2024-10-31 17:34:39 -07:00
Jorge Gorbe Moya
93d12d4881
Revert "[Bazel] Fix for 1bc58a258e2edb6221009a26d0f0037eda6c7c47" (#114444)
This reverts commit 5ce8a93ebb7688c66bd08fa27d2e04bca33b6763.

Commit 1bc58a258e2edb6221009a26d0f0037eda6c7c47 was reverted in
a9a8351ef181610559687679a40efe24649f9600, so the bazel fix is no longer
needed.
2024-10-31 11:21:04 -07:00
Dmitry Chernenkov
ca9f5b6c3e [Bazel] Fix for 0f8a6b7d03550cb58cf49535af2de2230abfe997 2024-10-31 17:13:23 +00:00
Dmitry Chernenkov
5ce8a93ebb [Bazel] Fix for 1bc58a258e2edb6221009a26d0f0037eda6c7c47 2024-10-31 17:13:23 +00:00
Alexey Samsonov
14f3cdc8e2
[libc][bazel] Add BUILD rules for float16 math functions. (#114187)
Adds libc_math_function rules for various f16* and *f16 functions.
Closes #114140
2024-10-30 19:05:24 -07:00
Dmitry Chernenkov
d693e7c7f7 [Bazel] fix clang for 508263824f4ef0c70f37523810e5f7d56bcfa653 2024-10-30 14:11:22 +00:00
Dmitry Chernenkov
872981bd23 [Bazel] Fix layering for libc 2024-10-29 14:34:51 +00:00
Dmitry Chernenkov
340cd4e631 [Bazel] fix for abc49cc19463970d5523d7d3332e4c1f83bc2ef7 2024-10-29 14:13:20 +00:00
Guillaume Chatelet
b1ede8fcb4
[reland][libc][bazel] Enable software prefetching for memcpy (#113886)
This will affect only Bazel configuration for now.
This is a reland of #108939 which has been reverted because of codegen
issues fixed by https://github.com/llvm/llvm-project/pull/113161.
2024-10-28 14:43:10 +01:00
Yijia Gu
d3c29e8d2f [mlir][test][bazel] add missing deps for TestPass 2024-10-25 10:24:31 -07:00
Benjamin Kramer
6854ad90e3 [bazel][lldb] "Fix" the build after b852fb1ec5fa15f0b913cc4988cbd09239b19904
b852fb1ec5fa15f0b913cc4988cbd09239b19904 split out ValueObject, but it's
still all a big pile of dependency spaghetti so just build it with Core.
2024-10-25 14:23:56 +02:00
NAKAMURA Takumi
20c59838d0 [Bazel][SystemZ] Update for #112975 2024-10-23 03:38:31 +00:00
Krasimir Georgiev
deecfa90c6
bazelbuild: adapt for commit b735c66da9 (#113302) 2024-10-22 13:59:59 +02:00
Michael Jones
6c4267fb17
[libcxx][libc] Hand in Hand PoC with from_chars (#91651)
Implements std::from_chars for float and double.

The implementation uses LLVM-libc to do the real parsing. Since this is
the first time libc++
uses LLVM-libc there is a bit of additional infrastructure code. The
patch is based on the
[RFC] Project Hand In Hand (LLVM-libc/libc++ code sharing)

https://discourse.llvm.org/t/rfc-project-hand-in-hand-llvm-libc-libc-code-sharing/77701
2024-10-21 15:04:06 -07:00
Keith Smiley
28a2f57c98
[bazel] Pass --build_runfile_links=false (#113221)
This improves performance of doing a `bazel test @llvm-project//...` a
lot because previously every lit test would have some symlink tree
configured for it.
2024-10-21 14:01:29 -07:00
Keith Smiley
3903cb4695
[bazel] Use rules_python load statements (#113213)
With bazel 8.x these are strongly encouraged, and this disambiguates
which version of these rules we get for older versions. Specifically the
native.py_test was using the wrong version of py_test.
2024-10-21 13:19:21 -07:00
Yijia Gu
2c331b3571 [mlir][bazel] remove tab blank in OpenAccTransforms 2024-10-21 10:43:55 -07:00
Yijia Gu
ab07fc8320 [mlir][bazel] add missing dep in OpenAccTransforms 2024-10-21 10:41:12 -07:00
Krasimir Georgiev
df02bcc81d
bazelbuild: fix for commit d80b9cf713fd (#113153)
Fix for
d80b9cf713.

No functional changes intended.
2024-10-21 13:39:25 +02:00
Krasimir Georgiev
25b58c877c
bazelbuild: fix for commit 2ce10 (#113142)
bazelbuild: fix for
2ce10f0491.

No functional changes intended.
2024-10-21 13:08:49 +02:00
Benjamin Kramer
c7d1163554 [bazel] Port 7be4ab0a86f9a52f1b49dad5665617441ec24a2e 2024-10-18 12:28:15 +02:00
Benjamin Kramer
9ad4f05ef7 [bazel][lldb] Port 5f2cf99e146ce99d4e148038d9bdd012331b4821 2024-10-16 14:41:20 +02:00
Benjamin Kramer
8bb100b940 [bazel] Add missing dependencies for d4efc3e097f40afbe8ae275150f49bb08fc04572 2024-10-14 20:54:31 +02:00
Benjamin Kramer
b2cac3babd [bazel] Add missing dependency for 58d97034c9c149d175c66440d31f46e9dfd4b760 2024-10-13 12:58:36 +02:00
Jacques Pienaar
4c25a538d3
[mlir] Start rewrite tool (#77668)
Initial commit of a tool to help in textual rewrites of .mlir files.
This tool builds of of AsmParserState and is rather simple. Took some
inspiration from when I used clang's AST rewrites where I'd often treat
it as a "localizing" regex applicator in fallback cases, and started
with that as functionality. There though, one does have access to the
lower level info than here, but still a step up over sed over entire
file.

This aims to be helpful (e.g., rewrite syntax including best effort
inside comments) rather than bulletproof tool. It may even be better
suited under utils than tools. And most of the rewrites would be rather
short lived and might never make it upstream (while the helpers of those
rewrites may for future rewrites).

The layering at the moment is not ideal as it is reusing the
RewriteBuffer class from clang's rewrite engine. So only optionally
enabling where clang is also enable. There doesn't seem to be anything
clang specific there (the dep does pull in more dependencies than ideal,
but leaving both refactorings).

Additionally started it as a single file to prototype more easily,
planning to refactor later to include and libs for out of file usage.
2024-10-12 15:10:34 -07:00
Keith Smiley
24ac6cf4f7
[bazel] Port 58d97034c9c149d175c66440d31f46e9dfd4b760 (#112064) 2024-10-11 18:10:38 -07:00
Keith Smiley
0add1741d5
[bazel] Port e9c8f75d45ababe7f805078bbf7bda2e7425f1b7 (#111928) 2024-10-10 16:55:41 -07:00
Keith Smiley
6640dac22b
[bazel] Add include-cleaner tests (#111924) 2024-10-10 16:43:29 -07:00
Keith Smiley
ba530e6b64
[bazel] Add initial clang-doc config (#111779) 2024-10-10 11:42:23 -07:00
Mikhail Goncharov
c15611a697 [bazel] port dc85d5263ed5e416cb4ddf405611472f4ef12fd3 2024-10-10 08:32:15 +02:00
Jorge Gorbe Moya
756ec99c36
[SandboxVec] Re-land "Use sbvec-passes flag to create a pipeline of Region passes after BottomUpVec. (#111223)" (#111772)
https://github.com/llvm/llvm-project/pull/111223 was reverted because of
a build failure with `-DBUILD_SHARED_LIBS=on`.

The Passes component depends on Vectorizer (because PassBuilder needs to
be able to instantiate SandboxVectorizerPass). This resulted in CMake
doing this

1. when it builds lib/libLLVMVectorize.so.20.0git it adds
lib/libLLVMSandboxIR.so.20.0git to the command line, because it's listed
as a dependency (as expected)
2. when it's trying to build lib/libLLVMPasses.so.20.0git it adds
lib/libLLVMVectorize.so.20.0git to the command line, because it's listed
as a dependency (also as expected). But not libLLVMSandboxIR.so.

When SandboxVectorizerPass has its ctors/dtors defined inline, this
caused "undefined reference to vtable" linker errors. This change works
around that by moving ctors/dtors out of line.

Also fix a bazel build problem by adding the new
`llvm/lib/Transforms/Vectorize/SandboxVectorizer/Passes/PassRegistry.def`
as a textual header in the Vectorizer target.
2024-10-09 18:00:17 -07:00
Mikhail Goncharov
f59b151f09 [bazel] port 8e2ccdc4deedd463a20237b4d842b4c51f9fe603 2024-10-09 15:51:52 +02:00
Mikhail Goncharov
1a1de2465d [bazel] update abi-breaking.h.cmake for 3be691651a2143f23bcf8f2704e55b01bbaa2550 2024-10-09 11:09:13 +02:00
Mikhail Goncharov
f016e105b3 [bazel] update config.h.cmake
for 84088d3a28fdc2d6314c59bfa11026a72b9b0bff
2024-10-09 11:02:30 +02:00
Guillaume Chatelet
dda107b8cb
Revert "[libc][bazel] Enable software prefetching for memcpy" (#111370)
Reverts llvm/llvm-project#108939

When `AVX` is available but `-mprefer-vector-width=128` some of the
`mov` instructions turn into the x86 `rep;movsb` instruction leading to
poor performance on "old" architectures (sandybridge, haswell). The
possible solutions are : get rid of the `-mprefer-vector-width` option
or use smaller static copy sizes in
`inline_memcpy_x86_sse2_ge64_sw_prefetching`. Right now a copy size of 3
cache lines (192B) relying exclusively on xmm registers gets turned into
`rep;movsb`.
2024-10-07 15:00:31 +02:00
Mikhail Goncharov
d926e340b7 [bazel] port 9144fed31b59089f4e3e5fedf7eb87d2695ef843 2024-10-07 11:02:47 +02:00
Benoit Jacob
dd04cf0c9d
MLIR BUILD.bazel: fold BasicPtxBuilderInterface into NVVMDialect (#111172)
While doing an integrate into downstream
https://github.com/iree-org/iree, I ran into a typical Bazel error with
`BasicPtxBuilderInterface.cpp` including `NVVMDialect.h` which was not
exposed as a header by a declared dependency. I tried fixing this the
straightforward way, by letting `:BasicPtxBuilderInterface` depend on
`:NVVMDialect` , but that caused another Bazel error: circular
dependency between these two targets, as `:NVVMDialect` was already
depending on `:BasicPtxBuilderInterface`. I tried breaking that circle
by dropping the latter dependency, but it was a real dependency in the
code, specifically in the TableGen-generated code. So in the end it
seems that these two targets just need to be fused, which this PR does.

Signed-off-by: Benoit Jacob <jacob.benoit.1@gmail.com>
2024-10-04 12:13:06 -04:00
Danial Klimkin
53b3c9e408
[bazel] Fix libc/hdr past c63112a9118277a20ae440f3f69189c0937e8f4d (#111135) 2024-10-04 13:21:25 +02:00