[clang] Allow enabling sandbox for direct `-cc1` invocations (#174653)
This PR enables the FS sandbox for direct `clang -cc1` invocations.
https://github.com/llvm/llvm-project/pull/165350 unintentionally
implemented the sandbox only for the code path where `clang -cc1` gets
invoked after being expanded from a driver command line, which reduced
the expected test coverage.
[LLDB] Add type casting to DIL, part 2 or 3 (#170332)
This PR implements the actual type casting part. With this, type casting
to builtin types should work. The third PR, which will be put up after
this one is merged, will expand the type name parsing to allow casting
to user-defined types.
[lldb][TypeSystemClang] Set access specifier for EnumConstantDecl's (#174865)
LLDB was already setting the access specifier on `EnumDecl`s
unconditionally to `AS_public`. But it wasn't doing so for the
`EnumConstantDecl`s. This triggered a Clang assertion during
auto-completion of expressions
(https://github.com/llvm/llvm-project/issues/171913).
Ideally the code-completion accessibility check would honor the
`AccessControl` language option, but that change is harder to
test/justify. Since this is a pretty straight-forward change I want to
land this before trying to do that.
There is no test coverage for this because it relies on the order in
which Clang decides to check the decls in scope for auto-completion,
which seems fragile. It's also consistent with how we handle access to
other decls in `TypeSystemClang`.
Fixes https://github.com/llvm/llvm-project/issues/171913
[CIR] Implement simple folding for integer casts (#174861)
This extends the CastOp folder to handle integral casts between
different integer types. This only handles scalar values at this time.
This is in preparation for a change that will attempt to fold casts as
they are generated, but this change only performs the folding via the
cir-canonicalize pass.
Revert previous: Don't compile with -std=gnu2x. static_assert in pre 2023
environments is defined in assert.h. In 2013 assert.h was added to localtime.c
because a _DIAGASSERT was added which is no longer there. Remove assert.h since
it is no longer needed and the clang error goes away since static_assert is
no longer defined in pre-2023 environments. Thanks Paul Eggert.
linuxkpi: Add `rol32()`
`rol64()` and `rol32()` are used by <linux/siphash.h>. The former was
added previously, before <linux/siphash.h> was added. However the latter
was not, and it broke the build on armv7.
Reported by: adrian
Reviewed by: adrian, rpokala
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54588
use statx provided by truenas_pyos
This commit removes the ctypes definition for statx and replaces
with the implemntatoin from truenas_pyos (cpython).
[clang-doc] Add protected members to class template
There were already tags for protected members in the Mustache template,
but didn't use the proper tags for the newer JSON scheme.
use statx provided by truenas_pyos
This commit removes the ctypes definition for statx and replaces
with the implemntatoin from truenas_pyos (cpython).
Add a filegroup containing _all_ sources to the libc build rules (#169155)
These rules already expose a filegroup containing the _dependencies_,
but that misses the source files directly in the top level library.
Without this filegroup, there isn't a way to access the source files
used by libcxx when building it, etc.
use statx provided by truenas_pyos
This commit removes the ctypes definition for statx and replaces
with the implemntatoin from truenas_pyos (cpython).
NAS-139204 / 26.04 / Use improved os API for mount information (#17962)
* statmount -- retrieve information on mountpoint by path or fd
directly. Implemented using statx(2) and statmount(2).
* iter_mountinfo -- iterator for mount info using listmounts(2) and
statmount(2)
* getmntinfo() - wraps around iter_mountinfo and is present for legacy /
compatibility reasons
* remove getmnttree() - this is now redundant due improvements in
iter_mountinfo (being able to select a mnt_id).
sysutils/cpu-microcode-intel: Dont depend on cpu-microcode-rc
All Intel systems running 15.0 or 14.3 support loading at boot time
without cpu-microcode-rc, therefore, do not depend on it by default.
Update the package message with the current up-to-date instructions.
Approved by: jrm (maintainer)
Differential Revision: https://reviews.freebsd.org/D54515
linuxkpi: Add <linux/kmsg_dump.h>
This header declares register/unregister functions to allow a piece of
code to tell what function to call in case of a panic. Several panic
handlers may be registered.
The DRM generic code started to use it in Linux 6.10 as part of the
panic handler.
Reviewed by: bz, christos
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54492
linuxkpi: Add WARN_RATELIMIT()
The i915 DRM driver started to use it in Linux 6.10.
Reviewed by: bz, christos
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54493