[CAS] Fix build with LLVM_ENABLE_PIC=OFF (#215351)
libCASPluginTest, added in #213331, is a shared library, which cannot be
built without PIC. Skip it and the tests that need it in that case.
[mlir][EmitC] Make function name placeholder optional in `wrap-emitc-func-in-class` (#214602)
Allow `class-name-format` in `wrap-emitc-func-in-class` to accept format
strings without a `{}` by disabling format validation in
`llvm::formatv`. Prevents assertion failures.
[AMDGPU][GlobalISel] Fix wide multiply with known-zero parts
Materialize a zero accumulator when all partial products for a destination part are skipped, avoiding an invalid null register during legalization.
Change-Id: I05294cf68ddd4363ccb20df7159981280e7c9c4e
[CIR] Evaluate VLA bounds for a static local of variably modified type (#214926)
emitStaticVarDecl bailed with errorNYI whenever a `static` local had a
variably modified type -- in practice a pointer to a VLA, since the
static itself can't be one. CIRGenFunction::emitVariablyModifiedType
already exists and already handles this walk, so this is the same
one-liner classic CodeGen uses in CodeGenFunction::EmitStaticVarDecl.
Found when building binutils. This is autoconf's AC_C_VARARRAYS probe,
so the NYI was quietly changing what configure-based projects build: the
probe failed under -fclangir, config.h came out with HAVE_C_VARARRAYS
undefined and __STDC_NO_VLA__ defined, and gnulib took its non-VLA
fallback paths. Nothing errored -- the CIR build just compiled different
source than the baseline.
[SandboxVec][Scheduler][DAG] Fix the update of DGNode on setOperand (#214110)
The callback for updating the DAG when a Use is set was part of the DAG.
But the DAG is not aware of the scheduling direction so it would try to
update the UnscheduledPreds even in the bottom-up direction, which would
cause an assertion failure.
The fix is to make the DAG aware of the scheduling direction and guard
the Unscheduled counters based on the direction.
[HLSL] Move `step` implementation to header files (#214604)
Closes #213098.
This PR replaces the previous implementation of `step` with a new one
inside the header files.
Assisted-by: Claude Opus 4.8
[PassInstrumentation] Pass Any as const &. (NFC) (#215120)
llvm::Any has a heap allocation on every copy and pass instrumentations
take the IR unit to instrument as llvm::Any. In the default pipeline
without any additional options, OptNoneInstrumentation is registered and
runs on each executed pass.
Update to take llvm::Any as const &, to avoid unnecessary heap
allocations and improves compile-time:
* stage1-O3: -0.25%
* stage1-ReleaseThinLTO: -0.26%
* stage1-ReleaseLTO-g: -0.20%
* stage1-aarch64-O3: -0.22%
* stage2-O3: -0.26%
* clang: -0.46%
https://llvm-compile-time-tracker.com/compare.php?from=5371bcaa368e59a99a03f6a726949ee52e07fb65&to=a4544f9d91d9f806791f2ba74cd93b0685fc3f75&stat=instructions:u
[5 lines not shown]
NAS-142059 / 27.0.0-BETA.1 / Directory services cache fixes (#19477)
insert_cache_entry() built the NAME_ key from the numeric id rather than
the name, so entries added by the lazy insertion path were only
reachable by id. A by-name lookup for such an entry missed the cache and
fell through to NSS plus idmap.synthetic_user. The bulk fill path was
unaffected, and query_cache_entries() reads only ID_-prefixed keys, so
enumeration results did not change.
DSCacheFill did not remove its temporary files when `fill_cache()`
raised `before _commit()`, so a failed fill can leave
`directory_service_cache_tmp_*` files behind in the cache `directory.
fill_cache()` documents NssError, WBCErr and job abort as reachable, and
nothing else removes those files. Cleanup now also covers a failure
partway through `__enter__`, which does not invoke `__exit__`.
expire_cache() now writes a timezone-aware UTC timestamp, matching
fill_cache() and check_cache_expired().
[9 lines not shown]
[CIR] Fix crash calling a variadic pass_object_size function with no varargs (#214928)
arrangeFreeFunctionLikeCall added getNumPassObjectSizeParams(proto) to
the extra-slot count it passed to
RequiredArgs::getFromProtoWithExtraSlots, which adds that same count
itself. The pass_object_size slots were therefore counted twice, and the
resulting signature claimed more required arguments than the CallArgList
held.
requiredArguments() builds an ArrayRef of getNumRequiredArgs() entries
over the trailing-object array, so the over-count read past the end and
handed a null QualType to convertType -- a segfault in release, an
assertion in +asserts. The call had to supply zero variadic arguments
for the counts to disagree; one or more explicit varargs padded the
array back over the required count and hid it.
```
extern int f(const char *__attribute__((pass_object_size(1))) s, ...);
int main(void) { f("x"); return 0; } // crashed in every -fclangir mode
[16 lines not shown]
riscv/atomic: Provide some additional aliases
These are already available and having them defined helps keep the KASAN
atomic(9) interceptors uniform.
Reviewed by: mhorne
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D58680
riscv/atomic: Provide some additional aliases
These are already available and having them defined helps keep the KASAN
atomic(9) interceptors uniform.
Reviewed by: mhorne
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D58680