[clangd] [C++20] [Modules] Introduce persistent cache for clangd built module file (#193883)
Currently clangd lacks a persistent cache for clangd built module file.
It implies that every time a new clangd process starts, or a user close
all tabs and opening all a new tab. Clangd will build all the module
files required. This is a slow process. Especially, the building happens
in the building thread for the opening tab. That is, if the user only
opens a single tab, clangd needs to build all the module file in a
single thread. This is very slow in practice.
As clangd is basically a wrapper for clang, we can't do nothing to speed
the building process actually and the only thing we can do is to
introduce a better cache mechanism.
So everytime the user opens a new tab, now clangd won't try to build all
the needed module file at first but try to see if these module files are
already built and up-to-date. So clangd can try to avoid a lot of time
to rebuilding the same thing.
[26 lines not shown]
pseries/llan: call init when ioctl sets interface UP
This should fix dhcp on an unitialized interface. This solution was
found while comparing against another driver, SIOCSIFFLAGS is used by
dhclient to force the interface up before it has an IP address.
However, all setup work is done in llan_init(), so the interface would
not be enabled if configured via only the SIOCSIFFLAGS ioctl. By
running llan_init() when the interface is forced up via SIOCSIFFLAGS,
the interface is initialized properly.
PR: 292164
[clang-scan-deps] Fixes an assertion in clang-scan-deps (#193619)
Please see ticket #191921 for detailed description of the issue and a reproducer.
clang-scan-deps crashes with an assertion failure if a compile_commands.json entry contains a depfile path (-MF) whose parent directory does not exist.
The fix is made so that clang-scan-deps tool create the directory if it doesn't exist and finish execution without failing.
[RISCV] Remove codegen for vp_fneg, vp_fma. NFC (#193214)
Part of the work to remove trivial VP intrinsics from the RISC-V
backend, see
https://discourse.llvm.org/t/rfc-remove-codegen-support-for-trivial-vp-intrinsics-in-the-risc-v-backend/87999
We began expanding these nodes in #190589 since vp_fadd/vp_fmul/vp_fsub
could be combined into them. Now that these intrinsics are expanded too,
the lowering for these is dead and can be removed.
[VPlan] Fold lhs | (headermask && rhs) -> vp.merge rhs, true, lhs, evl (#193511)
This is a combine on mask vectors that can show up with EVL tail
folding.
Split off from #190196
packages: Register pkgconf
This should fix the creation of the new packages introduced by the
import of pkgconf into the base system.
Fixes: b8352da33f34 ("pkgconf: import into the base system")
PR: 294724
Reviewed by: ivy, ngie
Approved by: ngie
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D56589
ping6: treat setsockopt failures as fatal
ping6 needs IPV6_RECVPKTINFO and IPV6_RECVHOPLIMIT to process
incoming replies. When these options fail, replies are silently
dropped and ping6 appears to hang. Use err(3) instead of warn(3)
so the user gets a clear error and immediate exit.
Signed-off-by: Christos Longros <chris.longros at gmail.com>
Reviewed by: pouria, jlduran, glebius
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D56237
(cherry picked from commit 9a4a9f623bbaf991b3ba580593d47f2ee9f7b03b)
ping6: treat setsockopt failures as fatal
ping6 needs IPV6_RECVPKTINFO and IPV6_RECVHOPLIMIT to process
incoming replies. When these options fail, replies are silently
dropped and ping6 appears to hang. Use err(3) instead of warn(3)
so the user gets a clear error and immediate exit.
Signed-off-by: Christos Longros <chris.longros at gmail.com>
Reviewed by: pouria, jlduran, glebius
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D56237
(cherry picked from commit 9a4a9f623bbaf991b3ba580593d47f2ee9f7b03b)
ping6: treat setsockopt failures as fatal
ping6 needs IPV6_RECVPKTINFO and IPV6_RECVHOPLIMIT to process
incoming replies. When these options fail, replies are silently
dropped and ping6 appears to hang. Use err(3) instead of warn(3)
so the user gets a clear error and immediate exit.
Signed-off-by: Christos Longros <chris.longros at gmail.com>
Reviewed by: pouria, jlduran, glebius
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D56237
(cherry picked from commit 9a4a9f623bbaf991b3ba580593d47f2ee9f7b03b)
[OpenCL] Diagnose error for zero-length array (#193163)
OpenCL C is based on C99 and C11, which don't support zero-length array.
Update clang/docs/ReleaseNotes.rst for potential breaking change.
[Clang][CodeGen] Fix sret lifetime marker AS mismatch after #186275 (#193850)
After #186275, the sret address space can differ from the alloca address
space (e.g., AS 0 vs AS 5 on AMDGPU). In CGCall.cpp EmitCall(), when a
discarded-value sret temporary is created, SRetPtr is allocated in the
alloca AS and a lifetime.start is emitted. The pointer is then
addrspacecast'd to match the sret AS, but the CallLifetimeEnd cleanup
was using the addrspacecast'd pointer, triggering an assertion in
EmitLifetimeEnd ("Pointer should be in alloca address space").
Saves the original alloca pointer before the addrspacecast and uses it
for the lifetime-end cleanup.
Fixes buildbot failure: hip-third-party-libs-tests
[libclc] Allow testing unresolved symbols on multiple libraries (#193647)
Our downstream generates multiple libraries for a single target. This
change allows testing multiple libraries.
[libclc][CMake] Remove CMAKE_C_COMPILER_ID check (#186717)
When LLVM_TARGETS_TO_BUILD does not contain the host target, runtime
build can not identify a compatible target triple for the host compiler.
CMAKE_C_COMPILER is set to clang, and CMAKE_C_COMPILER_ID is empty
although the compiler is functional.
Remove CMAKE_C_COMPILER_ID check. CMakeTestCLCCompiler.cmake already
provides a real functional guard.
This change ensures valid configurations can proceed, e.g.:
LLVM_TARGETS_TO_BUILD=AMDGPU;
RUNTIMES_amdgcn-amd-amdhsa-llvm_LLVM_ENABLE_RUNTIMES=libclc;
LLVM_RUNTIME_TARGETS="amdgcn-amd-amdhsa-llvm".
Note CMAKE_C_COMPILER_WORKS is always true after `project(Runtimes C CXX
ASM)` in runtimes/CMakeLists.txt.
[LazyValueInfo] Support vector types in ICmp condition handling (#192900)
Use m_APInt matcher instead of ConstantInt dyn_cast so splat vector
constants are handled, and relax the integer type check to accept
integer vector types.
Fixes https://github.com/llvm/llvm-project/issues/192094
[NFC][Clang][Sema] Apply rule of three to Sema helper classes (#193835)
Static analysis flagged these classes. They declared a destructor but
not copy constructor or copy assignment. Since these classes don't need
them, this change declares them deleted.
Merge tag 'vfs-7.1-rc1.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs
Pull vfs fixes from Christian Brauner:
- eventpoll: fix ep_remove() UAF and follow-up cleanup
- fs: aio: set VMA_DONTCOPY_BIT in mmap to fix NULL-pointer-dereference
error
- writeback: Fix use after free in inode_switch_wbs_work_fn()
- fuse: reject oversized dirents in page cache
- fs: aio: reject partial mremap to avoid Null-pointer-dereference
error
- nstree: fix func. parameter kernel-doc warnings
- fs: Handle multiply claimed blocks more gracefully with mmb
[19 lines not shown]
Merge tag 'v7.1-rc-part2-ksmbd-fixes' of git://git.samba.org/ksmbd
Pull more smb server updates from Steve French:
- move fs/smb/common/smbdirect to fs/smb/smbdirect
- change signature calc to use AES-CMAC library, simpler and faster
- invalid signature fix
- multichannel fix
- open create options fix
- fix durable handle leak
- cap maximum lock count to avoid potential denial of service
- four connection fixes: connection free and session destroy IDA fixes,
[30 lines not shown]
Merge tag 'v7.1-rc1-part3-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6
Pull smb client fixes from Steve French:
- Four bug fixes: OOB read in ioctl query info, 3 ACL fixes
- SMB1 Unix extensions mount fix
- Four crypto improvements: move to AES-CMAC library, simpler and faster
- Remove drop_dir_cache to avoid potential crash, and move to /procfs
- Seven SMB3.1.1 compression fixes
* tag 'v7.1-rc1-part3-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6:
smb: client: Drop 'allocate_crypto' arg from smb*_calc_signature()
smb: client: Make generate_key() return void
smb: client: Remove obsolete cmac(aes) allocation
smb: client: Use AES-CMAC library for SMB3 signature calculation
[14 lines not shown]
[clang] NFC: Add test case for #178324 and mark it as fixed (#190490)
Issue #178324 was actually fixed by #187755
We lost the "declaration does not declare anything" warning since the
regression was introduced, but that was because:
1) Since #78436 we treat __builtin_FUNCSIG in a dependent context
effectivelly as if it contained a template parameter.
2) Our decltype implementation treats eexpressions containing template
parameters as if they were completely opaque (but alas this goes against
the spec, which says in [temp.type]p4 this should be looking only at
type dependence).
3) Since the decltype is opaque, we don't know what lookup will find, so
we can't issue the warning because we don't know if we are going to end
up with a type or an expression.
Fixes #178324