dmu: remove dmu_prealloc()
ztest is the only caller, and its ZTI_INIT entry has sat behind #if 0
since the 2010 import from OpenSolaris build 141, so nothing exercises
it. No kernel or libzpool code calls it either.
Remove the function and its export, plus the ztest code that existed
only for it: ztest_dmu_prealloc(), the ztest_prealloc() helper it
called, and the disabled ZTI_INIT entry.
Reviewed-by: Brian Behlendorf <behlendorf1 at llnl.gov>
Signed-off-by: Patrick Domack <patrickdk at patrickdk.com>
Closes #19090
dbuf: account dirty data for embedded writes
dmu_buf_will_not_fill() leaves the dbuf DB_NOFILL and dbuf_dirty()
skips the dirty accounting for those, so the dirty record from an
embedded write never raises dp_dirty_total. A receive of a stream
of embedded records runs unthrottled ahead of the syncing TXG,
pinning dbufs the ARC cannot evict. Same gap as dmu_brt_clone().
An embedded write fills a whole block, so charge one.
No reproducer yet. A receive of 300,002 embedded records against
a 64 MiB ARC peaks at 116%, and the same receive carrying 2
embedded records peaks at 118%, so that overshoot is dnode and
bonus buffers from creating 300,000 files rather than the embedded
writes. The accounting gap is real either way.
Reviewed-by: Brian Behlendorf <behlendorf1 at llnl.gov>
Signed-off-by: Patrick Domack <patrickdk at patrickdk.com>
Closes #19071
zdb.8: document the -Z flag
Add Z to the SYNOPSIS and an entry for -Z, --zstd-headers to
the option list.
Reviewed-by: Brian Behlendorf <behlendorf1 at llnl.gov>
Signed-off-by: Christos Longros <chris.longros at gmail.com>
Closes #19094
ftp/py-ftpretty: Wrapper for FTP operations
The goal of this library is to provide a frictionless experience to
FTPing files in way similar to Amazons3cmd command line tool. The
API should be intuitive with the order of arguments reflecting the
transfer direction of bytes.
[CMake] Don't reference unexported targets from dependency-only configs (#222630)
#221724 stopped exporting a project's targets file when that project is
enabled only as another project's dependency, but the build-tree
`ClangConfig.cmake` and `MLIRConfig.cmake` still include it
unconditionally. `find_package()` therefore finds the config and fails
inside it:
```
CMake Error at build/lib/cmake/clang/ClangConfig.cmake:19 (include):
include could not find requested file:
build/lib/cmake/clang/ClangTargets.cmake
Call Stack (most recent call first):
CMakeLists.txt:90 (find_package)
```
This breaks any configuration that enables Flang without also enabling
Clang or MLIR explicitly: `runtimes/CMakeLists.txt` calls
`find_package(Clang ...)`, which is deliberately not `REQUIRED` and is
[16 lines not shown]
[compiler-rt] Support GNU section attributes on Windows (#222707)
MSVC and Clang place sanitizer sentinels and CRT callbacks with
__declspec(allocate) after declaring their sections with #pragma
section. MinGW GCC uses the section attribute instead, so select the
appropriate spelling for each compiler.
Co-authored-by: Hannes Domani <ssbssa at yahoo.de>
[compiler-rt][asan] Include intrin.h for MinGW GCC (#222709)
asan_globals_win.cpp calls __debugbreak in the runtime thunk
configurations. Include MinGW's intrinsic header so the function is
declared when this file is compiled with GCC.
Co-authored-by: Hannes Domani <ssbssa at yahoo.de>
[compiler-rt] Handle weak interfaces with MinGW GCC (#222706)
Windows weak-function emulation uses MSVC linker /alternatename
directives, which GNU ld does not support. Use direct exported
definitions, avoid registering unsupported DLL weak aliases, and
reference UBSan's real C++ implementation.
Co-authored-by: Hannes Domani <ssbssa at yahoo.de>
[clang] Support DecompositionDecl in -ast-print (#221711)
`DeclPrinter` had no `VisitDecompositionDecl`, so `auto [a, b] = get();`
printed as `auto = get();`, silently dropping the binding list (worse
at namespace scope, where it also produced a stray empty statement per
binding).
Add `DeclPrinter::VisitDecompositionDecl`, printing the full
`type [bindings] = init;` form for all three decomposition kinds
(aggregate/member, array, tuple-like), matching what `VisitVarDecl` does
for an ordinary declaration. Specifier and initializer printing is
shared between the two via two helpers (`printVarDeclSpecifiers`,
`printVarInitializer`) so they can't drift apart.
Each binding prints correctly, including a pack's leading `...` and
per-binding attributes. `BindingDecls` are skipped when walking a
`DeclContext` directly, since each is already printed as part of its
`DecompositionDecl;` a decomposition declaration is likewise kept out of
the tag-declaration grouping in `VisitDeclContext`, which would
[2 lines not shown]
[libc] Enable full-build code coverage (#221802)
Extended LIBC_ENABLE_COVERAGE to support LLVM_LIBC_FULL_BUILD=ON and
added the LIBC_ENABLE_COVERAGE_MCDC CMake option for MC/DC coverage.
This enables developers and CI pipelines to measure source-level and
MC/DC coverage directly on hermetic tests in full-build configurations
without relying on the host C library.
Updated add_libc_hermetic in LLVMLibCTestRules.cmake to link hermetic
tests with -noprofilelib, -u__llvm_profile_runtime, and compiler-rt's
profiling library. Replaced internal entrypoint objects in
link_object_files with public entrypoint objects for the C functions
referenced by libclang_rt.profile.a.
Added calloc and __errno_location to HermeticTestUtils.cpp to satisfy
remaining freestanding profiling runtime dependencies. Updated
libc/docs/dev/code_coverage.md with full-build instructions.
Assisted-by: Automated tooling, human reviewed.
[libFuzzer] Use uppercase "B" for byte units in output (#220828)
Fixes issue #56766. libFuzzer printed data sizes as "b", "Kb" and "Mb",
which denote bits. Use "B", "KB" and "MB" instead.
[ConstantTime] Use ARITH_FENCE as the combine barrier in CT_SELECT expansion
Replace the CopyToReg/CopyFromReg vreg barrier in ExpandCTSELECT with
ISD::ARITH_FENCE. The legalizer no longer creates vregs or picks register
classes via getRegClassFor, and scalable vectors are now covered too.
Codegen tests regenerated; output stays branchless.
PPC: Replace EnableAIXExtendedAltivecABI with "target-abi" module flag
Continue purging ABI-influencing TargetOptions fields. Eliminate this case
by migrating to a module flag, reusing the generic target-abi module flag
with a new value.
Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
PPC: Read the ELF ABI from the "target-abi" module flag
Resolve the ELFv2 ABI from the effective ABI name module flag,
rather than strictly relying on the -target-abi flag.
Also start emitting "target-abi" for PPC from clang.
Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>