[ELF] Remove --fortran-common (#220813)
--fortran-common implements a legacy linker rule that lets a COMMON
symbol extract an archive member providing a STB_GLOBAL definition,
departing from the rule that only an undefined symbol extracts a member.
The option has defaulted to off since LLVM 15, complicates parallel
symbol resolution, and is deemed unneeded.
Close: #205015
Link: https://discourse.llvm.org/t/removal-of-fortran-common-option/91553
[mlir][openacc] Add extra-constructors option to declare ctor conversion (#225194)
Allow acc-declare-ctor-dtor-conversion to declare extra runtime
functions
and call them from a generated constructor. Entries are separated in two
list,
one list where the functions are always added and one where the
functions are
added only if entry-point-name is present in the module.
The extra functions stay external declarations. This is used to generate
sentinel in different compilation mode.
[SPIR-V] Fix wrong element inferred for long vectors when using ByteAdressBuffer (#222220)
fixes #222214
On the offload tests we recently switch the long vector tests from using
StructuredBuffer element loads and stores to ByteAddressBuffer vector
loads and stores With StructuredBuffer you can see we use the right type
for the vector https://hlsl.godbolt.org/z/jYhd57jvn
However with ByteAddressBuffer instead of a float vector we are infering
incorrectly an int vector https://hlsl.godbolt.org/z/KMnxfv8z6
The Fix is to use spv_bitcast instead of an llvm ir bitcast. An ordinary
LLVM bitcast i32 to float becomes a same-size GlobalISel operation. Both
i32 and float use the same low-level type, s32, so
legalization/coalescing can eliminate the bitcast. switching to
spv_bitcast solves this because it forces a `buildAssignType` which will
preserve the type and allows us to distinguish ints from floats.
Remove CDDL and ctfconvert tests when their controlling knobs are disabled
In the event someone specified MK_CDDL == no prior to this change, all
tests under `/usr/tests/cddl` would stick around after the change,
resulting in errors. Similarly, MK_DTRACE == no removed ctfconvert,
which the ctfconvert tests relied on (but remained around after the knob
was disabled).
Remove the tests under the respective blocks now so they don't linger
around on systems where these knobs are disabled, resulting in false
positives when running the complete test suite.
The ctfconvert tests weren't specifically put under
`${MK_DTRACE_TESTS}` == no because ctfconvert was bundled separately
from the upstream provided Dtrace test suite.
MFC after: 2 weeks
MFC with: 30c20ca26 ("Remove Dtrace/ZFS tests if their knobs are disabled")
src.opts.mk: force the Dtrace tests off if ${MK_DTRACE} == no
Prior to this change Dtrace's tests could be enabled even if
`${MK_DTRACE}` == no. Allowing this doesn't make sense so remove the
tests if `${MK_DTRACE}` is also disabled.
MFC after: 2 weeks
[AMDGPU][InstCombine] Fold zero dot operands to accumulator
Fold AMDGPU dot intrinsics when either operand is zero.
`dot(a, 0) = 0` and `dot(0, b) = 0`, so replace the intrinsic with its accumulator.
This avoids unrelated clamp and add/sub reassociation cases.
[AMDGPU][InstCombine] Canonicalize dot constant operands
Move constant dot product source operands to the right hand side
and add tests for signed and unsigned dot intrinsics.
[AMDGPU][InstCombine] Fold constant add/sub into the dot accumulator
`amdgcn.{s,u}dot{2,4,8}(a, b, C) +/- K -> dot(a, b, C +/- K)` when both the
accumulator C and K are constants. The new constant is computed with
wrapping APInt arithmetic to match the non-clamping accumulate.
Only applies when clamp is false (the saturating accumulate does not
reassociate) and the dot has a single use. K - dot is left alone since it
would need the dot product negated.
drm/amd/ras: reset CPER ring on corrupt entry size
From Xiang Liu
a98d0d49757a113ce17960262b9cd4ccc1420108 in linux-6.18.y/6.18.53
4d695e66d7027a0c78302e47ac76293675fbbb4d in mainline linux
drm/amdgpu: use atomic operation to achieve lockless serialization
From Sunil Khatri
08e9e131aa16b123f1f5d94c9775c53468be4447 in linux-6.18.y/6.18.53
4d50a14d346141e03a7c3905e496d91e048bc30c in mainline linux
drm/amdkfd: Check bounds on allocate_doorbell
From David Francis
c2c89118c27cbd3adace62c5df19d15b0e96ade1 in linux-6.18.y/6.18.53
1f087bb8cf9e8797633da35c85435e557ef74d06 in mainline linux
[clang-sycl-linker] Make temp files land relative to cwd with unique names (#224506)
Derive the CodeGen/AOT stem from -o's basename instead of its full
path, so these intermediates land in cwd alongside the .bc temps
instead of splitting -save-temps output across two directories.
Route them through createTempFile instead of building
`<stem>_<index>.ext` directly, so parallel invocations sharing an
output basename don't collide. Its random suffix also makes
`_<index>` redundant, so drop it; `--spirv-dump-device-code` keeps its
index since it has no random suffix and still needs one.
---------
Co-authored-by: Claude Sonnet 5 <noreply at anthropic.com>
drm/amdkfd: Fix OOB memory exposure in get_wave_state()
From Sunday Clement
ec646686613d8ab05b282d1463a7baa49fd6b83b in linux-6.18.y/6.18.53
7ef144458f48d5589e36f1b3d83e83db2e5c5ba5 in mainline linux
Reapply "[CFI] Create an external linkage alias instead of promoting i… (#220339) (#225173)
There were 3 issues with the original commit:
1. handling of `dso_local_equivalent`. This was subsequently addressed in PR #222036 as an independent fix. An earlier version of the fix, 220450, had an extra test, cfi_dso_local_equivalent.ll, which is specific to the interaction between this patch and dso_local_equivalent. That test is re-introduced here.
2. a COFF issue discovered through the original pass, uncovered on Chromium builds, and fixed by @andysjlim in PR #220674. Thank you!
3. an issue we discovered in google downstream, involving coroutines. See the `cfi-import-internal-coroutine.ll`, and the difference between the first version and the second version of this PR (in Graphite) (<- AI was used here)
drm/amdkfd: Check bounds for allocate_sdma_queue restore_sdma_id
From David Francis
dd2870ca036e1d51baa59f942007b36a595b5890 in linux-6.18.y/6.18.53
bfe9a7545b2a7be1c543f1741e16f2d5ec4116ae in mainline linux
dummynet: do not overflow the points[ED_MAX_SAMPLES_NO] array
Otherwise, the following would segfault
dnctl pipe 1 config bw 1Mbit/s profile 1025points.txt
Found with: Claude Code Sonnet 5
MFC after: 2 weeks
drm/amdgpu/userq: pin mqd and fw object bo to avoid eviction
From Sunil Khatri
a16d9986b7b27b08a696524a4dbf03dbf5433a16 in linux-6.18.y/6.18.53
a3bbf32a336939a1d21b9561f8e53333b684b7ef in mainline linux
drm/amd/ras: Fix CPER ring debugfs read overflow
From Xiang Liu
e1023aac607c9f954bd8eb0ea6af08ccb703010e in linux-6.18.y/6.18.53
1e40ef87ffdc291e05ccdade8b9170cc9c1c4249 in mainline linux
Remove Dtrace/ZFS tests if their knobs are disabled
Prior to this change, Dtrace and ZFS tests and their respective
directories would remain installed even if `${MK_DTRACE_TESTS}` == no or
`${MK_ZFS_TESTS}` == no.
This change enhances the logic to remove the tests when the respective
knobs are disabled so the tests will be removed when `make delete-old`
is run.
MFC after: 2 weeks
drm/amd/display: Fix CRC open failure during active rendering
From Tom Chung
fcec938ce172cddca3c5bbc690555942e1430633 in linux-6.18.y/6.18.53
5eb2fdafeb6f4a442643b77a21a4c9e70586a146 in mainline linux
drm/amdgpu: Prefer ROM BAR for default VGA device
From Lijo Lazar
a513f711e08689cd1657c3dc6848dd31f3982c2e in linux-6.18.y/6.18.53
9e32d17592950478baffaecdbda8e2e60935fd3d in mainline linux
[CIR] Widen memory effects for ABI argument memory
A const or pure callee that the ABI gives an sret slot or a byval
pointer writes through that pointer, but CallConvLowering left its
effects claiming memory(none) or memory(read). The sret shape is
invalid IR, so the verifier aborts compilation. The byval shape
verifies, and lets the optimizer drop stores into a slot the callee
reads.
CallConvLowering now widens arg_mem to readwrite on any function the
classifier gives an indirect return or an indirect argument, and on
variadic functions, whose parameters do not cover what an ellipsis can
carry. A call passes a fixed argument list, so it widens only for a
slot it really passes. Classic does the same in ConstructAttributeList.
Assisted-by: Cursor / claude-opus-5
drm/amd/display: Find link encoder for flexible DIG mapping cases
From Ovidiu Bunea
223ceba837ad920fce464c7af8abdbc77901f2b6 in linux-6.18.y/6.18.53
74ef54e656e7006cfc215e960b0cf2720a7a3d48 in mainline linux
drm/amd/pm: Check SMUv13.0.6/12 metrics integrity
From Lijo Lazar
7b6b9fc260b1ae6ad5c5d398381ad176cbb074fa in linux-6.18.y/6.18.53
6fc63d80c01a480e3d2c98620f07d46e5bcfc85a in mainline linux