[LoongArch] Add DAG combine for horizontal widening add/sub (#201488)
Add a DAG combine to recognize horizontal widening add/subtract patterns
and lower them to the corresponding LSX/LASX instructions.
The following pattern is matched for both signed and unsigned variants:
```
ADD/SUB(SEXT/ZEXT(BUILD_VECTOR(extract_elt(vj, 1), extract_elt(vj, 3), ...)),
SEXT/ZEXT(BUILD_VECTOR(extract_elt(vk, 0), extract_elt(vk, 2), ...)))
```
This covers the following instructions:
```
LSX: VHADDW.H.B, VHADDW.W.H, VHADDW.D.W
VHADDW.HU.BU, VHADDW.WU.HU, VHADDW.DU.WU
VHSUBW.H.B, VHSUBW.W.H, VHSUBW.D.W
VHSUBW.HU.BU, VHSUBW.WU.HU, VHSUBW.DU.WU
[9 lines not shown]
nrelease: Add root_rw_mount="NO" to rc.conf to fix ISO boot
The ISO root filesystem is obviously readonly and cannot be remounted to
'rw'. Without setting 'root_rw_mount=NO', the ISO boot would abort
after failing to remount the root filesystem.
This is a follow-up fix to my previous commit
31b00396377857ebb62259aa944f9351fa62ea44.
Reported-by: Sergey Zigachev (servik)
nrelease: Simplify the adjustments to loader.conf for IMG boot
Use 'sed' similar to fstab adjustments instead of grep+echo to adjust
'boot/loader.conf' to the IMG boot.
rc.conf: Add and document the missing root_rw_mount=YES
The 'root_rw_mount' variable was missing, and it caused the rc.d/root
script to always ignore the 'mount -u -o rw /' command. Nevertheless,
the '/' root filesystem was still remounted to be 'rw' because the later
'mount -a' command, according to /etc/fstab.
With this 'root_rw_mount=YES' placed, the '/' entry should now be
optional in /etc/fstab because the '/' root filesystem can be correctly
remounted to be 'rw'.
Obtained-from: FreeBSD (commit 6e1b226)
Reported-by: robstinge (IRC)
nrelease: Adjust fstab and reuse it for IMG boot
The root '/' filesystem is mounted by the kernel, so it can be omitted
from 'etc/fstab'. This also makes the 'fstab' file be used by the IMG
boot, so just reuse it.
nrelease: Adjust fstab to remove '-C' option for /tmp tmpfs mount
For the /tmp mount, no need to copy the origin contents; also, there
shouldn't be any contents at this early boot stage.
[LoongArch] Add DAG combine for horizontal widening add/sub
Add a DAG combine to recognize horizontal widening add/subtract patterns
and lower them to the corresponding LSX/LASX instructions.
The following pattern is matched for both signed and unsigned variants:
```
ADD/SUB(SEXT/ZEXT(BUILD_VECTOR(extract_elt(vj, 1), extract_elt(vj, 3), ...)),
SEXT/ZEXT(BUILD_VECTOR(extract_elt(vk, 0), extract_elt(vk, 2), ...)))
```
This covers the following instructions:
```
LSX: VHADDW.H.B, VHADDW.W.H, VHADDW.D.W
VHADDW.HU.BU, VHADDW.WU.HU, VHADDW.DU.WU
VHSUBW.H.B, VHSUBW.W.H, VHSUBW.D.W
VHSUBW.HU.BU, VHSUBW.WU.HU, VHSUBW.DU.WU
[10 lines not shown]
[Clang] Implement CWG 2282
Link: https://wg21.link/cwg2282
For non-overaligned types, overload resolution now falls back to aligned
allocation functions in C++20 and later.
[Clang][Sema][NFCI] Simplify `resolveAllocationOverload()`
`resolveAllocationOverload()` performs multiple rounds of overload
resolution (typed and untyped, aligned and unaligned), each requiring a
slightly different argument list. Previously, the argument vector was
mutated in-place, which made the flow hard to follow.
This refactor prepares the list of arguments before calling
`resolveAllocationOverload()`. The preferred argument list is passed in
`PrefArgs`, while the fallback arguments are passed in `FallbackArgs`.
If the fallback resolution is not required, `FallbackArgs` is empty.
When making a nested call to perform the resolution with the fallback
arguments, the current set of candidates is passed in `PrefCandidates`
(formerly, `AlignedCandidates`). This argument also serves as a flag
used to distinguish the top-level call from nested fallback calls.
[Clang] Implement CWG 2282
Link: https://wg21.link/cwg2282
For non-overaligned types, overload resolution now falls back to aligned
allocation functions.
[NFC][OpenMP] Add mapper-specific tests exercising pointee seciton mapping.
Also add a couple of tests that require correct propagation of map-type-modifier
bits into the mapper.