zfs: fix SIMD defines to match OpenZFS HAVE_SIMD() macro
The OpenZFS merge 80aae8a3f8aa introduced HAVE_SIMD() which checks for
HAVE_TOOLCHAIN_* defines via simd_config.h. The kernel module Makefile
was updated, but kern.pre.mk (static kernel build) and the libzpool/libzfs
Makefiles were missed, still using the old HAVE_SSE2 etc. names. This
caused all vectorized raidz, fletcher, and blake3 implementations to be
compiled out.
[AMDGPU] Fix SIFoldOperands crash on REG_SEQUENCE with physical register (#206976)
The getRegSeqInit function crashes on REG_SEQUENCE instructions with
physical register inputs.
Since both optimizations that use getRegSeqInit do not need to handle
such REG_SEQUENCE instructions, this patch changes the function to
return nullptr which signals that the optimization should not happen.
[Flang][OpenMP] Emit TODO for non-rectangular collapsed loop nests (#205558)
Non-rectangular loop nests (where an inner loop bound depends on an
outer IV) with collapse currently generate incorrect code that segfaults
at runtime, since OpenMPIRBuilder's collapseLoops assumes rectangular
iteration spaces.
Added a check during lowering to detect the non-rectangular case and
emit a clear "not yet implemented" error instead of silently producing
broken code.
minimal reproducer :
```
program repro
implicit none
integer, parameter :: N = 10
integer :: arr(N,N), i, j
arr = 0
[23 lines not shown]
[Clang] Add FileCheck lines to atomic-auto-type codegen test (#206749)
Follow-up to #197874. The codegen test was missing FileCheck lines,
making it a no-op. Add checks that verify both __auto_type _Atomic and
_Atomic __auto_type produce correct allocas and stores.
Follow up to comment from:
https://github.com/llvm/llvm-project/pull/197874#discussion_r3496368126
[Support] Fix VersionTuple DenseMapInfo conformance (#206872)
In C++ standard library (and many other programming languages standard
libraries), if two values are equal, they should return the same hash.
This requirement is pretty common so associative containers can quickly
find values that might be equal by calculating the hash, and if that
requirement is not hold, associative containers might not work as
expected.
The documentation of `DenseMapInfo` does not specify the same
requirement, as far as I can see, but its usage on `DenseMap` relies on
it, or objects that compare equal might end up in different buckets and
will not be correctly found.
`DenseMapInfo<VersionTuple>` implementation of `getHashValue` was
implementing its own logic for hashing, but delegating to `VersionTuple`
for equality. `VersionTuple` equality partially compares its scalar
member variables, skipping some boolean member variables, but the
`getHashValue` implementation was using those boolean member variables
[11 lines not shown]
clang/AMDGPU: Stop passing redundant -target-cpu to cc1
Now that the exact target is encoded in the triple's subarch field,
-target-cpu is redundant. This avoids polluting the resultant IR with
unwanted "target-cpu" attributes. The net result is the desired codegen
when compiling libraries for a major subarch and linking it into a
program compiled for a specific arch. e.g., compiling for "gfx9-generic"
would pollute the IR with "target-cpu"="gfx9-generic", so codegen
would ultimately be performed for the generic target even after
linking into the concrete gfx9 cpu. The specialization will now be
achieved by merging the triples without the linker or optimization
passes needing to fixup function attributes.
clang/AMDGPU: Validate -target-cpu in cc1 is valid for the subarch
Restrict the reported list of valid target-cpus based on the triple's
subarch. This is more consistent with how other targets validate the
target CPU name. Currently we have split handling validating the target
name for the triple in both the driver and here. The driver based diagnostic
seems to be an amdgpu-ism in 2 different places (though there is one arm
validation emitting the same diagnostic). In the future we could probably
drop those.
AMDGPU: Migrate unittests to subarch triples
Replace specifying a processor name with the triple
subarch.
The register-limit helpers in AMDGPUUnitTests.cpp that enumerate every
valid CPU via fillValidArchListAMDGCN still pass the CPU explicitly, as
does the MC Disassembler smoke test (its C disassembler API derives the
subtarget from the CPU, not the triple subarch).
Co-authored-by: Claude (Opus 4.8) <noreply at anthropic.com>
clang: Start using new amdgpu subarch triples
Fixup invocations using --target=amdgcn + -mcpu to introduce
the subarch in the triple.
For offload toolchains, a single toolchain is constructed for the
top level amdgpu architecture, and the effective triple is used for
target specific tool invocations.
The specifics of the resource directory layout are tbd. This does
try to find resources in the subarch named directory. The paths
are searched at toolchain creation time, so that does not work
when there are multiple subarches.
Fixes #154925
AMDGPU: Introduce amdgpu triple arch
Move towards using the triple for representing incompatible
ISA changes. Use the subarch field to represent the various
incompatible cases. Previously we pretended a single triple arch
was universally compatible, and only distinguished by function
level subtargets. Move towards using distinct triples to enable
more sophisticated toolchain handling in the future, like proper
runtime library linking.
Introduce a new subarch per unique ISA, but also introduce
"major subarches" which are compatible by a set of covered
minor ISA versions. These map to the existing generic targets.
There are a few placeholder subarch entries, which currently
have missing backing generic arches for codegen.
This should be the preferred triple arch name going forward,
but is treated as an alias of amdgcn. This does not yet change
clang to emit the new triples.
[2 lines not shown]
[libc++] Add Android assertion handler (#198831)
We're in the process of increasing the use of libc++ hardening in
Android. The handlers we're using deviate from the defaults in two ways:
- All handlers are `nomerge` for better postmortem crash attribution
- `_LIBCPP_VERBOSE_ABORT` is wrapped by a `NOINLINE` function to reduce
binary size overhead slightly (on x86_64, the diff is ~9B per call
to _LIBCPP_VERBOSE_ABORT).
This patch introduces a custom handler for Android with these properties.
[flang] Implement check for statement function dummy argument names (#204417)
Implement F2023 19.4.2 conformance check for statement function dummy
argument names
Fixes: #203820
F2023 19.4.2 permits a statement function dummy argument to share its
name with an **accessible** identifier only when that identifier is a scalar
variable. Flang previously accepted all such clashes silently.
```fortran
subroutine s
real :: arr(10)
real :: ok
f(arr) = arr + 1 ! error: arr is an array
h(ok) = ok + 1 ! ok: scalar variable shadowing is permitted
end subroutine
```
Assisted-by: Claude
[llvm-pdbutil] Include DBI section contribs in YAML (#191624)
The DBI section contribs stream is required for line information in
WinDBG and VS - otherwise, you can't set line breakpoints. With this PR,
we generate and parse it in yaml2pdb/pdb2yaml.
LLVM can't generate the `SectionContrib2` (`SC2`) record, so we don't
support this in yaml2pdb. At least in my small test, MSVC didn't
generate that record either.
NAS-141620 / 25.10.5 / Fix dataset alert quota (by yocalebo) (#19239)
The UX hard-codes the default thresholds for dataset alerts to 80 and 95
and this matched what we did in our quota alert. However, this regressed
in 7f2a017cc59709defd05501740d8dd4525aac839 which coupled the quota
alert with our audit dataset. This reverts those changes and decouples
them so they're handled correctly. Essentially the default values for
the audit dataset do not match any non-audit dataset default values. The
audit alert tests come back clean.
Original PR: https://github.com/truenas/middleware/pull/19238
Co-authored-by: Caleb St. John <30729806+yocalebo at users.noreply.github.com>
filesystems/gvfs: Use fuser(1) in place of lsof(1) by default
- Import patch accepted upstream to allow using fuser(1) to check
for busy mountpoints [1]
- Add option to allow choosing between fuser and lsof (fuser by
default
This removes an hard dependency on lsof for this very commonly used
port.
[1] https://gitlab.gnome.org/GNOME/gvfs/-/merge_requests/321
Reviewed by: gnome (fluffy)
Approved by: gnome (fluffy)
Differential Revision: https://reviews.freebsd.org/D56224
NAS-141620 / 27.0.0-BETA.1 / Fix dataset alert quota (#19238)
The UX hard-codes the default thresholds for dataset alerts to 80 and 95
and this matched what we did in our quota alert. However, this regressed
in 7f2a017cc59709defd05501740d8dd4525aac839 which coupled the quota
alert with our audit dataset. This reverts those changes and decouples
them so they're handled correctly. Essentially the default values for
the audit dataset do not match any non-audit dataset default values. The
audit alert tests come back clean.