[compiler-rt][Darwin] Add SANITIZER_IPHONEOS/VISIONOS, use in GetOSMajorKernelOffset
SANITIZER_IOS remains "iOS and iOS-like" (TARGET_OS_IPHONE). Add
SANITIZER_IPHONEOS (TARGET_OS_IOS, iOS only) and SANITIZER_VISIONOS
(TARGET_OS_VISION), and use the SANITIZER_* macros in
GetOSMajorKernelOffset.
Assisted-By: Claude
[lldb-dap] Report isOptimized on compileUnits (#235981)
Add isOptimized to the CompileUnit type in the compileUnits response, so
a client can tell whether a frame's code was built with optimizations.
Clients look the compile unit up with the frame's moduleId and
compileUnitId.
rdar://190656814
[clang] Implement fast isOutOfLine() for static data members. (#237773)
Taking advantage of C++ standard rules, we can take a shortcut to
determine if a static data member is out-of-line. Use this to speed up
VarDecl::isThisDeclarationADefinition.
Expected ctt improvement around 0.4%.
[llvm-profgen] Make missing frame inference deterministic (#235079)
Missing frame inference memoized the results of a DFS for tail call
paths. Inside a cycle, a result depends on the functions already on
the searched path, so reusing it made the inferred frames depend on
the order of searches. That order follows pointer-keyed containers,
so profiles differed from run to run.
Fix: cache only complete searches. Keep functions visited for the
whole search, so each is walked once, and check that a single path
found is the only one in extra pass: another simple path leaves it
through another tail call and rejoins it at a later function, so
walking from the functions of the path in order, keeping functions
visited, finds it. Each search takes linear time, so remove
max-search-depth, which only capped it.
On XL AArch64 binary with cycles of tail calls, it caused run-to-run
difference in 5..11 of 162,664 top-level profiles. With the fix,
profiles are identical across runs and allocators (jemalloc/glibc).
[4 lines not shown]
Expand testing for global merge symbol table info on AIX. (#224099)
Add a test that checks the symbol table info for merged global symbols
when they do not have an explicit section attribute. Uses the option
nozero-initialized-in-bss so we get symbol table entries for the zero
initialized globals as well.
[RISCV][P-ext] Combine riscv.pmhacc.b0 and riscv.pmhacc.h0 into a single intrinsic.
Similar for riscv.pmulh.b0 and riscv.pmulh.h0. This includes
different signedness and different half number.
The underlying RISCVISD opcodes were already combined.
I added ".half." to the intrinsic name to better separate from
the riscv.pmulh intrinsic.
Assisted-by: Claude
[profile] Preserve device instrumentation layout flags when writing profiles (#236081)
The LLVM options -pgo-instrument-entry and -pgo-instrument-loop-entries
control whether function entries and edges entering loops must be
instrumented. Both default to false for ordinary IR PGO. These settings
affect counter placement and are recorded as flags in the raw profile
header so profile use can reconstruct the same counter layout.
HIP users can specify different values for host and device compilation.
For example, -Xarch_device -mllvm=-pgo-instrument-entry=true enables
explicit entry counters for the device while the host keeps the default.
The host and device profiles then need different entry flags.
The ROCm collector currently writes device counters with the host runtime's
version flags. In this example, it incorrectly marks the device profile
as having entry instrumentation disabled. Profile use can then reconstruct
the wrong layout and associate counts with the wrong blocks.
Read and validate the device's profile-version variable separately from
[2 lines not shown]
[CIR] Narrow GPURelocatableDeviceCode NYI check to CUDA/HIP externalization (#236592)
The NYI check for `GPURelocatableDeviceCode` previously had a blanket
`!isSYCL() ` exclusion. This patch narrows it down to match the
condition the classic codegen uses for externalizing HIP/CUDA
device-side static file-scope variables, gated on CUDA.
Fix the default password of async_SSH_start
The default was the password function itself. It was a string before
the helper moved from tests/functions.py. do_failover(abusive=True) uses
the default, so it failed with a TypeError from Popen. Call password()
when no password is given, as ssh() does.
[SelectionDAG] Fold scalar_to_vector concatenations
Handle SCALAR_TO_VECTOR operands in foldCONCAT_VECTORS by collecting
the scalar followed by poison upper lanes. Reuse the existing scalar
type normalization for BUILD_VECTOR operands. The fold remains limited
to fixed-length vectors.
Revisit construction-time folds before operation legalization after
concat operands change during DAG combining. This preserves the
codegen improvements when operands become foldable after construction.
Add AMDGPU FP coverage and update the affected AArch64, RISC-V, and X86
codegen checks.
[SPIRV] Drop --verify-machineinstrs from new forward-ref tests.
The machine verifier already runs on the buildbots.
Co-authored-by: Cursor <cursoragent at cursor.com>
[SPIRV] Expect no unlisted DebugTypeMember in the self-pointer forward-refs test.
Without forward references, member next is no longer emitted after S and
its pointer, since S cannot list it.
Co-authored-by: Cursor <cursoragent at cursor.com>