Commit Graph

3234 Commits

Author SHA1 Message Date
Sohaib Iftikhar
6157d46259 [MLIR|BUILD]: Fix for 8ceeba838 (#170110) 2025-12-01 12:00:58 +00:00
Aiden Grossman
22257e8d6e [bazel] Port #169873 (#170027)
A new dependency was added.
2025-11-30 00:45:18 -08:00
Sergei Barannikov
f342d793e2 [ARM] Auto-decode pred operands of Thumb instructions (#156540)
Most predicable Thumb instructions do not encode the predicate operand,
but rather take it from an enclosing IT block.
Add `bits<0> p` to the encoding of these instructions to make the
predicate operand decodable by the generated code.

The previous approach was to analyze an instruction after it has been
decoded and add missing predicate operand if necessary. The
post-decoding pass is still required to check predicate applicability
and advance IT block state, but it no longer modifies a decoded
instruction.

Some of the custom decoder methods have become redundant and can be
removed in the future, delegating the decoding task to TableGen-erated
decoder.

Pull Request: https://github.com/llvm/llvm-project/pull/156540
2025-11-28 06:08:38 +00:00
Ingo Müller
48e34d9598 [mlir:bazel] Fix build broken by #169670. (#169804)
This PR adds a dependency to the `BUILD` files overlay silently added by
#169670.

Signed-off-by: Ingo Müller <ingomueller@google.com>
2025-11-27 16:21:49 +01:00
Aiden Grossman
75ca83563d [bazel] Fix build after #169086 (#169725)
Just required wiring up some additional AMDGPU table generated files.
2025-11-26 12:41:37 -08:00
Naveen Seth Hanig
d090311aa7 Reland "[clang] Refactor to remove clangDriver dependency from clangFrontend and flangFrontend" (#169599)
This relands #165277 by reverting #169397.
This also relands the corresponding Bazel port by reverting #169410.

The original revert was due to a report of a broken build, which was
later resolved by fully clearing the build directory.
2025-11-26 13:33:26 +01:00
Keith Smiley
83d9c636b7 [bazel] Add alias for zlib-ng for WORKSPACE compat (#169530)
The consumer of zlib in third-party/BUILD.bazel expects zlib-ng from the
BCR, if you still load this version from your WORKSPACE / MODULE.bazel
you need to use this name instead.
2025-11-25 09:38:01 -08:00
Walter Lee
f0e0a22158 [bazel] Delete redundant visibility (#169493)
default_visibility is already public.
2025-11-25 13:21:56 +00:00
Keith Smiley
9626c90c33 [bazel] Use zlib-ng from the BCR (#169450)
This way if a downstream project also uses this, it is dedup'd
2025-11-24 20:37:05 -08:00
Chandler Carruth
c6f433e880 [bazel][libc] Remove target compatibility restrictions for float128 (#169292)
The restrictions here aren't nearly as much about the OS as the compiler
and architecture, but the Bazel restriction was OS-based. Everything
seems to work well on even Arm64 macOS, and I would expect most BSDs and
other OSes to work well with Clang's support on x86-64.

The source code here already handles detecting when there is compiler
support for the type. And the users of this don't `select` or do
anything else to conditionally include the header, so it seems better to
not restrict access to the header from the build system, and instead
continue making the source code compatible or a no-op on relevant
configurations.
2025-11-24 19:19:26 -08:00
Keith Smiley
ac4cf404d8 [bazel] Use zstd from the BCR (#169146)
This way if the downstream consuming project uses zstd we make sure
they are dedup'd. This uses a new rule to make sure layering_check still
works while allowing us to augment the upstream library rules with LLVM
specific `defines`.
2025-11-24 16:21:28 -08:00
Jordan Rupprecht
adf4c1dbb6 [bazel][clang] Port dea330b38d (#169410) 2025-11-24 16:54:39 -05:00
Ingo Müller
fe9c8e4f10 [mlir:x86vector:transform] Fix bazel build (again) after #168074. (#169316)
This is a second attempt to fix the bazel build (after the first in
#169294, which was accidentally merged before CI passed). In the first
attempt, not all bazel dependencies had been added; this PR should add
them all and make CI pass.

Signed-off-by: Ingo Müller <ingomueller@google.com>
2025-11-24 12:36:05 +01:00
Ingo Müller
c745a512dc [mlir:x86vector:transform] Fix bazel build after #168074. (#169294)
This PR fixes the bazel build that went out of sync with the changes
introduced in #168074.

Signed-off-by: Ingo Müller <ingomueller@google.com>
2025-11-24 09:22:46 +00:00
Aiden Grossman
f7ed15b9e7 [bazel] Fully port 3773bbe9e7 (#169247)
e5edb51207 attempted to port this, but
seemed to miss a couple things that still showed up on CI. This patch
fixes up the missing pieces.
2025-11-23 21:49:10 +00:00
Benjamin Kramer
e5edb51207 [bazel] Port 3773bbe9e7 2025-11-23 19:34:35 +01:00
Keith Smiley
dc3c5a5ffc [bazel] Remove old config option (#169133)
The default of this has been flipped since we're on 8.x
2025-11-21 16:46:12 -08:00
Jordan Rupprecht
01227abf8d [bazel][ORC] Port #168518: orc deps (#169059) 2025-11-21 16:25:50 +00:00
Jordan Rupprecht
3d3307ecd8 [clang][NFC] Inline Frontend/FrontendDiagnostic.h -> Basic/DiagnosticFrontend.h (#162883)
d076608d58 moved some deps around to avoid
cycles and left clang/Frontend/FrontendDiagnostic.h as a shim that
simply includes clang/Basic/DiagnosticFrontend.h. This PR inlines it so
that nothing in tree still includes clang/Frontend/FrontendDiagnostic.h.

Doing this will help prevent future layering issues. See #162865.

Frontend already depends on Basic, so no new deps need to be added
anywhere except for places that do strict dep checking.
2025-11-21 03:39:49 +00:00
Jordan Rupprecht
3723a8b0ac [bazel] Replace --experimental_guard_against_concurrent_changes usage (#168957)
On startup, bazel prints: `WARNING: Option
'experimental_guard_against_concurrent_changes' is deprecated: Use
--guard_against_concurrent_changes instead`
2025-11-20 17:25:07 -06:00
Keith Smiley
1552efe887 [bazel] Bump to 8.4.2 (#168933)
Just staying up to date
2025-11-20 12:27:34 -08:00
Keith Smiley
930066f6e4 [bazel] Add explicit dep on protobuf (#168928)
This is required for correctly loading the protobuf rules. It's
possible we could drop the version here to a lower version, as long as
that version supports the versions of bazel we support. I picked this
because it is the current version being used by bazel 8.0.0 (which is
defined in the .bazelversion). Users can override this in their project
anyways if they need an older one
2025-11-20 11:20:17 -08:00
Keith Smiley
777935c2ed [bazel] Delete WORKSPACE file (#168926)
This has been replaced by the MODULE.bazel file. Users can still use
their own WORKSPACE files, but they didn't inherit this file anyways.
Users should migrate to bzlmod as with bazel 9.x that is required.
2025-11-20 10:51:11 -08:00
Jordan Rupprecht
a07024080a [bazel][LoongArch] Port #168129: tablegen for sdnode (#168907) 2025-11-20 11:29:00 -06:00
Pranav Kant
fda20d99ae [bazel] Fix #165009 (#168804) 2025-11-19 18:17:35 -08:00
Jordan Rupprecht
afcb9537bb [bazel] Fix bzlmod reference to @vulkan_sdk (#168767)
vulkan_sdk_setup is the name of the method that configures it, but the
repo itself has the name vulkan_sdk

This was caught by enabling the bzlmod flag for CI. The GH action runs
`blaze test @llvm-project/...` but the target is tagged manual, so it's
excluded. The buildkite CI runs `bazel query | xargs bazel test` which
will include manual targets.
2025-11-19 13:57:31 -06:00
Jordan Rupprecht
a4456a5ce3 [bazel] Flip --enable_bzlmod to true (#168555)
Switches to the config added in #164891

Fixes #55924
2025-11-19 12:12:41 -06:00
Stefan Gränitz
907e8514b1 [ORC] Remove now unused EPCDebugObjectRegistrar (NFC) (#167868)
EPCDebugObjectRegistrar is unused now that the ELF debugger support plugin uses AllocActions
https://github.com/llvm/llvm-project/pull/167866
2025-11-19 10:39:08 +01:00
Pranav Kant
651785a5ba Fix #168367 (#168635) 2025-11-18 16:21:47 -08:00
Jackson Stogel
db71cc58ec [libc] Implement pkey_alloc/free/get/set/mprotect for x86_64 linux (#162362)
This patch provides definitions for `pkey_*` functions for linux x86_64.

`pkey_alloc`, `pkey_free`, and `pkey_mprotect` are simple syscall
wrappers. `pkey_set` and `pkey_get` modify architecture-specific
registers. The logic for these live in architecture specific
directories:

* `libc/src/sys/mman/linux/x86_64/pkey_common.h` has a real
implementation
* `libc/src/sys/mman/linux/generic/pkey_common.h` contains stubs that
just return `ENOSYS`.
2025-11-18 14:30:15 -08:00
Pranav Kant
e1bb50b284 [bazel] fix #168212 (#168598) 2025-11-18 12:08:03 -08:00
Pranav Kant
b630721d54 [bazel] Fix #164904 (#168593) 2025-11-18 11:20:19 -08:00
Jordan Rupprecht
4d093683ce [bazel] Add MODULE.bazel (#164891)
This is a simple translation of the current WORKSPACE file.

* External repos are replaced with `bazel_dep()`. The versions have been
bumped to newer versions.
* `maybe()` doesn't seem to be a thing, so I just removed that.
* Existing repos where we define our own BUILD file in third_party_build
have *not* been replaced due to compatibility issues. For example,
`nanobind_bazel` could replace the `nanobind` config we have, but
switching to that caused some build errors.
* For these existing repos, they have been specified as module
extensions

This should have no effect since `.bazelrc` defines `common
--enable_bzlmod=false --enable_workspace`

Tested locally: `bazel test --enable_bzlmod --noenable_workspace
--config=generic_clang @llvm-project//... //...`
2025-11-18 09:48:13 -06:00
Alan Li
6fc2bc1ccc [BAZEL] Fix OrcDebugging dep (#168540) 2025-11-18 14:25:30 +00:00
Alan Li
e9f74dff13 [BAZEL] Fix BAZEL build issue (#168539) 2025-11-18 14:12:08 +00:00
Pranav Kant
1bf902ec59 [bazel] Fix #168108 (#168461) 2025-11-18 00:10:58 +00:00
Pranav Kant
ed617bd780 [bazel][buildifier] reformat changes in #168434 (#168443) 2025-11-17 13:21:59 -08:00
Pranav Kant
7693f124ff [mlir][bazel] Fix #167957 (#168441) 2025-11-17 13:08:06 -08:00
Pranav Kant
4bec74a9fb [mlir][bazel] Fix #168066 (#168435) 2025-11-17 12:42:46 -08:00
Pranav Kant
3fb374256b [bazel] Fix #168113 (#168434) 2025-11-17 12:38:57 -08:00
Pranav Kant
bac8d01a4d [bazel][libc] Fixes #165219 (#168429) 2025-11-17 20:18:01 +00:00
Keith Smiley
af6af8e4eb [bazel] Port 0a58e49c44 (#168424) 2025-11-17 11:08:22 -08:00
Keith Smiley
adeedad449 [bazel] Port 900c517919 (#168423) 2025-11-17 18:56:00 +00:00
Keith Smiley
aa4de7b4ef [bazel] Add support for multiple tblgen outputs (#168158)
Required after https://github.com/llvm/llvm-project/pull/167700

This adds yet another format for `tbl_outs` where you pass the list of
opts, and a list of outputs (where previously you could only have 1
output). In that case all outputs must be produced, but the first is
used for the `-o` arg since tblgen is generating the other names based
on that single argument.
2025-11-17 10:41:05 -08:00
Benjamin Chetioui
ae2fec04cc [mlir][bazel] Fix build after #167848. (#168366) 2025-11-17 13:30:40 +00:00
Michael Jones
274354348e [mlir][bazel] Add apfloat test library (#168115)
The apfloat code was added in #167848, and some bazel was added
in #167916 but the runtime library for test-apfloat-emulation.mlir was
missed. This patch adds the appropriate target.
2025-11-14 14:17:37 -08:00
Alexey Samsonov
e797ec6476 [libc] Templatize strtofloatingpoint and implement wcstof. (#167755)
This change follows the pattern of
315dfe5865 by making strtofloat also
accept wchar_t* strings
(in addition to regular char*). It uses overloads from wctype_utils or
specialized functions to ensure comparison with literal characters (or
literal strings) pick char or wchar_t variants based on the argument
type.

The wcstof implementation is added, with unit test cases copied from
strtof test suite.
2025-11-13 11:38:33 -08:00
Nikolay Panchenko
b49a847173 [bazel] Added ArithToAPFloat library to bazel (#167916) 2025-11-13 12:40:00 -05:00
Aiden Grossman
28dbbba6c3 [bazel] Fix LLDB :Host Build (#167711)
On some systems (probably those with a more recent clang), building
:Host errors out with a layering check violation due to the histedit.h
system include. Opt it out of layering checks for now, similar to other
targets that depend on non standard library system includes.
2025-11-12 19:30:13 +00:00
Will Froom
57b2341b84 [BLAZE] Add missing SCFUtil dep after #167356 (#167671) 2025-11-12 11:05:23 +00:00