emulators/flycast: Update to 2.7 and unbreak
Port changes:
- Switch to net/asio130 to unbreak the build. This also guarantees a
more stable update path for the flycast port, because newer versions
of net/asio are constantly deprecating and removing APIs.
- Unbreak on FreeBSD < 15 for newer DreamPicoPort submodule.
- Unbundle several dependencies. This is accompanied with an
EXTRACT_AFTER_ARGS block to exclude unbundled and unused deps, which
ensures that these aren't accidently referenced by the build process.
- Add LIBCDIO option, enabled by default. This enables CDROM support via
libcdio. It was already available in previous flycast versions but was
forgotten in the port.
- Prevent searching for git via CMAKE_DISABLE_FIND_PACKAGE_Git.
- Separate several blocks with newlines to improve readability.
- Remove obsolete patches.
Changelog:
https://github.com/flyinghead/flycast/releases/tag/v2.7
[3 lines not shown]
[NFC][DirectX] Fix memory leaks exposed by ASAN (#220152)
This PR should fix ASAN errors from
https://lab.llvm.org/buildbot/#/builders/52/builds/19811
There are three sources of leaks:
1. TargetPassConfig not being `PM.add()`ed
```
Direct leak of 136 byte(s) in 1 object(s) allocated from:
#1 ...createPassConfig(...) DirectXTargetMachine.cpp:216:10 <- return new DirectXPassConfig(*this, PM);
#2 ...addPassesToEmitFile(...) DirectXTargetMachine.cpp:177:34 <- TargetPassConfig *PassConfig = createPassConfig(PM);
Indirect leak of 144 byte(s) in 1 object(s) allocated from:
#1 llvm::TargetPassConfig::TargetPassConfig(...) TargetPassConfig.cpp:604:10 <- Impl = new PassConfigImpl();
#2 DirectXPassConfig DirectXTargetMachine.cpp:112:9
```
2. MachineModuleInfoWrapperPass not being `PM.add()`ed
```
[18 lines not shown]
[OpenMP][libomp] Fix dist barrier arrival synchronization (#213845)
Make distributedBarrier::stillNeed atomic and use release/acquire
ordering for distributed barrier gather arrival flags.
The old volatile stillNeed flag did not synchronize an arriving thread's
pre-barrier writes with the thread that observed its arrival. On weakly
ordered architectures, a group leader could observe stillNeed == 0
before the arriving thread's pre-barrier writes were visible. This
allowed another thread to pass the barrier and read stale data written
before the barrier.
Use release stores when publishing stillNeed == 0. Keep the spin loops
on relaxed loads, then perform one acquire fence after all expected zero
values have been observed. This connects the arriving threads'
pre-barrier writes to the observer through the standard release/acquire
happens-before chain, without using acquire loads on every poll.
The same pattern is used when a group leader publishes its own stillNeed
[106 lines not shown]
Fix layering violation from #220073 (#220150)
That PR introduced circular dependencies LLVMTransformUtils <->
LLVMPasses. Move Trigger*CrashPasses into LLVMPasses.
Move TriggerCrashFunctionLegacyPass alongside the one usage
`-codegen-pipeline-trigger-crash` just to prevent a tiny .cpp file.
kernel - Expand cpu_topology_nodes[] array
* Double the size of the array, which stores nodes as well as leafs
in the cpu topology tree. The array was being blown out in early
boot before if there were more than 128 CPUs.
* Add a KKASSERT() to catch any remaining issue, in case the tree
winds up being more complex and requires more nodes.
Reported-by: ivadasz
kernel - Move primary lockf management into struct vnode
* Move lockf management out of per-filesystem in-memory inodes and
into the general vnode structure. This will make follow-on work
easier and removes unnecessary code from various filesystem
implementations.
* Remove related implementations from fs code except for smbfs.
* Add optimization to avoid allocating struct lockf for LK_GETLK.
Allows filesystem lock scans to avoid allocating struct lockf
unnecessarily. Suggested by ryao.
* Just enable for existing filesystems that previously implemented it
in this commit. There may be a follow-up to enable it in the
default VOPS for all vnodes.
[SPIR-V] Always reject OpTypeVector with a non-standard width (#212685)
SPV_EXT_long_vector does not widen OpTypeVector past 4 components. Those
widths need OpTypeVectorIdEXT, so requesting the extension here was
wrong
[ADT][TableGen] Add UniquingSet, a FoldingSet with typed keys (#219630)
FoldingSet serializes a key into a FoldingSetNodeID to look a node up
and rebuilds the stored node's profile to compare against it. Where a
key can be read out of a node, neither is necessary.
UniquingSet reuses FoldingSetBase's storage, growth, removal and insert
token and replaces only the key: the node's `getKey()` supplies it, the
key type's `operator==` compares it, and DenseMapInfo hashes it inline.
An Info parameter overrides the key type or its hash. The hash cached on
each node keeps growth and erasure from calling `getKey()`, which a
DenseSet cannot avoid.
Prefer `UniquingSet` where a key can be read out of a node in O(1) and
the lookup key is built beside `getKey()`; keep FoldingSet for keys that
are wide, polymorphic or assembled at many call sites, where one Profile
helper keeps both sides consistent. insert asserts that a node hashes as
its lookup did.
[18 lines not shown]
[docs] [C++20] [Modules] Mentioning tricks to use std module without touching the code (#220147)
This commit introduces two tricks to use std module without changing
user's code.
Revert "[CSSPGO] Don't let pseudo probes block early-exit vectorization" (#220146)
Reverts llvm/llvm-project#219872
This was accidentally merged without approval
[clang][docs] Suppress Sphinx highlighting failure warnings in conf.py (#220118)
Following the upgrade to Sphinx 8.2 (#219299), Pygments syntax
highlighting fallbacks (e.g. on custom C++ attribute syntaxes like
`[[clang::...]]`) emit `[misc.highlighting_failure]` warnings when
retrying in relaxed mode. Because sphinx-build runs with `-W`, these
warnings abort the documentation build.
Mirror the configuration in `llvm/docs/conf.py` by setting
`suppress_warnings = ["misc.highlighting_failure"]`.
AI tool usage: An AI assistant was used to help research and draft the
documentation updates.
[mlir][arith] Expand ops for F8E4M3FN and F8E5M2 type. (#216653)
Patch to add support for arith op (`arith.truncf`) to truncate `f32/f16`
type to `f8E4M3FN/f8E5M2`.
[lld][MachO] Compare referent offsets in ICF (#219960)
ICF::equalsConstant() compared only the addends of relocations that
reference symbols in ConcatInputSections, not the symbols' offsets
within their sections. The ICF hash merely sums the referent symbols'
offsets, so two code sections whose relocations reference the same input
section at swapped offsets have equal hashes, pass both the constant and
the variable comparison, and are folded together even though they
reference different data.
Compare the symbol value plus the addend instead, as the ELF backend
does.
This issue was found by LLM while investigating why identical LSDAs were
not being folded. It has not been observed in a real-world link, and the
regression test is synthetic.
Merge tag 'edac_updates_for_v7.3_rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/ras/ras
Pull forgotten EDAC updates from Borislav Petkov:
"Somewhat belated (and forgotten :-\) EDAC updates lineup for v7.3:
- Mark the mpc85xx and ThunderX EDAC drivers as orphaned due to lack
of access to hardware
- Remove the unused fake error injection interface from the EDAC
debugfs code due to potential races between logging a fake and a
real hw error
- edac_mc_sysfs: Use sysfs_emit_at() for proper bounds checking
- Remove Mark Gross from maintainer entries and move him to CREDITS
- Load the AMD address translation library only on systems which can
actually make use of it (have ECC memory) instead of on every AMD
Zen system out there
[40 lines not shown]
only allow an NFS server to set file type on a new vnode
Otherwise, a malicous server could aid a local user in avoiding access
controls.
This reverts nfs_subs.c rev 1.3. Which was part of a commit to fix the
use of automount with direct maps.
reported by Andrew Griffiths
Merge remote-tracking branches 'ras/edac-misc', 'ras/edac-drivers' and 'ras/edac-amd-atl' into edac-updates
* ras/edac-misc:
EDAC/thunderx: Orphan it
EDAC/device_sysfs: Cleanup around edac_device_ctl_poll_msec_store()
EDAC/device_sysfs: Use kstrtouint() for poll_msec to prevent truncation
MAINTAINERS: Add Radhey Shyam Pandey as Xilinx EDAC reviewer
MAINTAINERS: Remove Mark Gross from relevant entries
EDAC/sysfs: Use sysfs_emit_at() in dimmdev_location_show()
EDAC/mpc85xx: Orphan it
* ras/edac-drivers:
EDAC/igen6: Add Intel Starfire SoCs support
EDAC/igen6: Refactor address translation logic
EDAC/igen6: Remove redundant resource configuration tables
EDAC/igen6: Detect present memory controllers at runtime
EDAC/igen6: Simplify compute die ID comments
EDAC/igen6: Remove unnecessary XOR on the zero-valued interleave bit
EDAC/igen6: Fix Raptor Lake-P logged error address
[14 lines not shown]
[flang][cuda] Propagate CUDA attrs from parent variable to component deallocs (#220059)
This is a follow up to
[#206614](https://github.com/llvm/llvm-project/pull/206614), which made
`allocate(foo(i)%arr(...))` inherit `foo`'s CUDA memory attribute, but
did not add the equivalent inheritance for `deallocate(foo(i)%arr)`. The
deallocation still lowered to an inlined `fir.freemem`, so memory
obtained from a CUDA allocator was released with libc `free()`.
The allocate side already walked the `DataRef` chain for a
CUDA-attributed parent, but the helpers were private to
`AllocateStmtHelper` and unreachable from the deallocate path. This
patch hoists `findCUDAAttrInDataRef` to file scope, adds
`getCUDAAttrParentSymbol(AllocateObject)` beside it, and reduces the
existing member to a thin wrapper. The allocate behavior is unchanged.
`genDeallocate` gains an optional `cudaSymbol` used only for the CUDA
decisions (`isCudaSymbol` and the `genCudaDeallocate` call).
`genDeallocateStmt` supplies the parent symbol, which is non-null only
[9 lines not shown]
[WebAssembly] Mark SIMD min and max as commutable (#219812)
Vector add/mul and scalar floating-point min/max are already marked as
commutable. This extends the same property to floating-point vector
min/max, allowing better WebAssembly register stackification.
Should avoid any locals as per what's happening now
```
.local v128
call red
local.set 0
call green
local.get 0
f32x4.min
```
dd(1): Sync with FreeBSD
New features:
- Added conv=fsync flag
- Added conv=fdatasync flag
- Added oflag=fsync and oflag=sync flags
- Added iflag=fullblock flag
- Added iflag=direct and oflag=direct flags that set O_DIRECT
Fixes:
- Fixed SIGINT handling.
[SelectionDAG] Fix CSE keys that disagree with SDNode::Profile (#219911)
A getNode helper builds its lookup ID by hand; matching it later
rebuilds one from the node with AddNodeIDCustom. Where the two disagree
the compare always fails and the node never CSEs. Fix whichever side is
wrong: the labels, DEACTIVATION_SYMBOL, GET/SET_FPENV_MEM and
EXPERIMENTAL_VECTOR_HISTOGRAM have no case; getLifetimeNode keys on a
frame index operand 1 already carries, getStridedLoadVP on the result
type instead of the memory type, and getPseudoProbeNode drops the
attributes its case profiles.
Ask AtomicSDNode instead of an opcode list stale since ATOMIC_LOAD_FADD,
and add the two opcodes its own classof was missing.
AddNodeIDCustom now takes the opcode to profile under, so MorphNodeTo's
pre-morph lookup keys on what the morph produces. Machine opcodes
profile nothing: the morph overlays MachineSDNode's memory references on
the fields the MemSDNode checks read.
[2 lines not shown]
[NFC][HLSL] Refactor texture type declaration (#219561)
Fixes https://github.com/llvm/llvm-project/issues/219542
Refactors texture type declaration in `HLSLExternalSemaSource.cpp` so
that new
texture types can more easily be added without adding a bunch of new
helper
functions.
This is accomplished with the introduction of a new `TextureTypeInfo`
struct
to record the properties of each texture type, as well as its
capabilities
indicated by the `TexCap` bitmask enum.
Adding a new texture type to be declared should, in most cases, only
require
appending a new entry to the static `TextureTypes` array of
[12 lines not shown]