[SPIR-V] Convert integer vector to bool vector for OpAny/OpAll (#191804)
OpenCL any()/all() builtins receive integer vectors, but OpAny/OpAll
require boolean vector inputs per the SPIR-V spec
related to https://github.com/llvm/llvm-project/issues/190736
[LV][NFC] Remove "REQUIRES: asserts" line from some tests (#191795)
Several tests seemed to require asserts despite not testing any debug
output so I have removed the line.
[AMDGPU]Refactor `lowerWaveReduce` for maintainability (#189223)
The function to lower wave reduce pseudos is already quite
large ,and there are yet a few more operations to support.
Refactoring some of the code to make it more manageable.
Summary of changes:
1. Moved the expansion for `V_CNDMASK_B64_PSEUDO` to a
separate function. It's needed for 64 bit dpp operations.
2. Collapsed `getIdentityValueFor32BitWaveReduction` and
`getIdentityValueFor64BitWaveReduction` into a single
function which returns a 64 bit unsigned value.
3. Modified `getDPPOpcForWaveReduction` to also return
the `Clamp` opcode.
4. Added a lambda: `BuildRegSequence` and a static function
`ExtractSubRegs` as those code blocks are repeated with
little variation.
[2 lines not shown]
[LoongArch] Select `V{AND,OR,XOR,NOR}I.B` for bitwise with byte splat immediates
The `V{AND,OR,XOR,NOR}I.B` instructions operate on byte elements and accept
an 8-bit immediate. However, when the same byte splat constant is used with
wider vector element types (e.g. v8i16, v4i32, v2i64), instruction selection
currently falls back to materializing the constant in a temporary register.
```
vrepli.b -1
vxor.v
```
even though the immediate form is available:
```
vxori.b 255
```
This happens because selectVSplatImm requires the splat bit width to match
[11 lines not shown]
[lldb][FreeBSDKernel] Supply values for CS/SS registers (#192207)
These two values ensure that CPU was in kernel privilege at the time of
crash. This change is from KGDB's `amd64fbsd-kern.c`.
Signed-off-by: Minsoo Choo <minsoochoo0122 at proton.me>
[llvm] Move libSupportHTTP to top-level libHTTP (NFC) (#191202)
The HTTP implementation depends on CURL and would preferably not be part
of the LLVM dylib. This was not possible as a nested library under
libSupport, because libSupport itself is part of the LLVM dylib. This
patch moves the HTTP code into a separate top-level library that is
independent from libSupport and excluded from the LLVM dylib.
[lldb] Fix FreeBSD/NetBSD plugin build after AsCString API change (#192110)
The argument to `AsCString` was made explicit in
116b045b1e2bff462afff0dc0b06218e6074f427.
```
/home/ewilde/llvm-project/freebsd-lldb-build/lldb/source/Plugins/Process/FreeBSD/NativeProcessFreeBSD.cpp:754:48: error: too few arguments to function call, single argument 'value_if_empty' was not specified
754 | module_file_spec.GetFilename().AsCString());
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/home/ewilde/llvm-project/freebsd-lldb-build/lldb/include/lldb/Utility/ConstString.h:183:15: note: 'AsCString' declared here
183 | const char *AsCString(const char *value_if_empty) const {
| ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
```
Not all use-sites were updated to pass an argument resulting in build
failures. I'm updating the errors in the FreeBSD and NetBSD plugins to
use formatv instead of expanding the C String, like what is done on
Linux, avoiding the issue entirely.
rdar://174675042
[sanitizer] Use close_range on Linux to close FDs in StartSubprocess (#191450)
Enable the close_range syscall on Linux when __NR_close_range is
available in kernel headers (Linux 5.9+). On older kernels, the
syscall returns ENOSYS and callers fall back gracefully.
This fixes the slow FD closing loop in StartSubprocess when
RLIMIT_NOFILE is high (e.g. 1B in Docker environments).
Fixes https://github.com/llvm/llvm-project/issues/63297.
Fixes https://github.com/llvm/llvm-project/issues/152459.
Fix registered matcher for bugprone-unchecked-optional-access (recent changes to libcxx) (#191681)
Further fix for #187788. Previous attempt in PR #188044 only updated the
model and model tests, but forgot to update the registered matcher.
[Hexagon] Add LTO options to Hexagon driver link args (#191336)
The Hexagon driver's constructHexagonLinkArgs() was not calling
addLTOOptions(). This meant that LTO plugin options weren't forwarded to
the linker.
This caused a crash when using ThinLTO with -fenable-matrix on
llvm-test-suite/SingleSource/UnitTests/matrix-types-spec.cpp:
LowerMatrixIntrinsicsPass did not run in the LTO backend because
-enable-matrix was not forwarded via -plugin-opt.
Add the addLTOOptions() call to both the musl and bare-metal code paths
in constructHexagonLinkArgs().