[libc] Build with -Wshadow (#197516)
This relands #196519. It now only enables the warning for
clang 22 and newer, since older versions had false positives.
[Instrumentor] Allow multiple config files with different filters
To instrument different functions in different ways we allow to provide
multiple config files now. Each file will result in one instrumentation
run. Multiple files can be passed via command line option or listed in
a "summary" file that is passed via command line option (to keep the
command length managable).
[clang] make evaluation of type constraint a SFINAE context
Otherwise, errors when substituting a type constraint could unintentionally make
the program ill-formed.
This also strenghtens the assert which checks, when we are instantiating templates,
that we either have a code synthesis context, or that we are in a SFINAE
context.
[mlir][OpenMP] Add iterator support to map/motion clause
Extend map/motion clause to support `!omp.iterated<Ty>` handles
alongside map/motion locators.
This is part of feature work for #188061
Assisted with copilot
Require explicit yield in iterator op
Remove the implicit terminator trait from omp.iterator so iterator
modifiers must explicitly yield the value used to form the iterated list.
Add and update verfier and test accordingly.
Simplify map iterator clause assembly
- Split MLIR map syntax into separate map_entries(...) and map_iterated(...),
removing the custom MapEntryList parser/printer.
- Moved omp.target map_iterated out of TargetOpRegion
- it now prints before the target region instead of as map_iterated_entries(...) after the region.
- Renamed LLVMIR TODO helper to clause-style checkMap.
- Added DeclareMapperInfoOp builder from DeclareMapperInfoOperands
and updated Flang call sites so they do not need to spell out newly
added operands..
[NRC][IR] Use `isa<ConstantPointerNull>` instead of `isNullValue` for pointer null checks
This PR replaces `isNullValue()` with `isa<ConstantPointerNull>()` in core IR
files where the check is semantically testing for a null pointer rather than a
generic zero value. This makes the intent explicit and prepares for future
non-zero null pointer support.
Restore line whose content vanished in previous
Somehow in the previous version, the content of one line was
removed, leaving just the indentation tabs... restore that line.
While here, and inspired by that line remnant, check for trailing
whitespace, and obliterate all of it that is unintentional (there
is one space in an EDIT_ME in a here-doc which is intended).
Also, in the rarely used "zones added"/"zones removed" commit message,
for the set lists, add some vertical white space before the listings
of any zones added or removed (happens so rarely, I'm not sure that
code has ever been used).
[CIR] Lower builtin_launder (#197252)
This patch introduces a cir.launder operation to represent a call to
__builtin_launder, which is an optimization barrier. This cir.launder
lowers directly to the LLVM-IR launder.invariant.group.
This patch also moves the existing check to see if a type needs
laundering to QualType from classic-codegen so it can be shared, however
the CodeGenOpt check is still left in codegen/duplicated between the two
implementations.
[Bazel]: Replace deprecated use of `@bazel_tools//` (#197323)
The platform configs in `@bazel_tools` are deprecated. This change
introduces local configs and refers to
[bazelbuild/platforms](https://github.com/bazelbuild/platforms) for the
constraints.
[Instrumentor] Add a global function regexp to limit the instrumentation
Only functions that match the "function_regex" will be instrumented,
or if they have the instrumentation attribute.
bq_insert: delay the BUF_UNLOCK if not bd_flush()ing
Reduce bufqueue lock contention by delaying the BUF_UNLOCK to after
dropping the bufqueue lock. Still do the early BUF_UNLOCK if we
actually have to bd_flush.
Reviewed by: kib, markj
Sponsored by: Dell Inc.
Differential Revision: https://reviews.freebsd.org/D56948