[llvm-mca] Fix total execution count in Average Wait times (#199500)
Fix the column `0` for the `<total>` row in llvm-mca's `Average Wait times` report. The `total`
row now represents the total dynamic execution count used to normalize the averages,
instead of the per-instruction iteration count. Update the timeline view docs and autogenerated
test expectations accordingly.
Co-authored-by: liuxiaodong <liuxiaodong at sunmmio.com>
Compute GUIDs once and store in metadata (#184065)
This allows us to keep GUIDs consistent across compilation phases which
may change the name or linkage type.
See https://discourse.llvm.org/t/rfc-keep-globalvalue-guids-stable/84801
This is a large change since the addition of metadata breaks many tests.
The test changes are mostly just trivial changes to checks to get them
passing.
[Clang] Emit prefix map normalization before generating hashes for the unique linkage names. (#198667)
Use normalized path from the macro prefix map to generate the unique ids
for the internal linkage names. That allows a reproducible hash on any
build system. Regularly the macro prefix map gets normalized in favor of
the target system before the path substitution.
[LV] Add support for partial alias masking with tail folding (#182457)
This patch adds basic support for partial alias masking, which allows
entering the vector loop even when there is aliasing within a single
vector iteration. It does this by clamping the VF to the safe distance
between pointers. This allows the runtime VF to be anywhere from 2 to
the "static" VF.
Conceptually, this transform looks like:
```
// `c` and `b` may alias.
for (int i = 0; i < n; i++) {
c[i] = a[i] + b[i];
}
```
->
[33 lines not shown]
[lit][NFC] remove new-style class opt-ins (#199784)
In Python 3.0 and later it is no longer necessary to explicitly derive
from `object` to opt into "new-style" classes, they are the default.
Since the current minimum Python version is 3.8, this is no longer
required. This patch removes `object` from the base class lists of all
affected classes in lit.
Fixes for buildbot breaks in #183153
Attempt at fixing issues in #183153 caught by buildbots, specifically
no-assert and windows builds.
Not sure how to run those bots ahead of landing this?
Change-Id: I285adf09ac2df239d0ab05459f7388b6970247ad
[AArch64] Fix hasNearbyPairedStore to handle non-inbounds GEPs (#199137)
Problem: `hasNearbyPairedStore` uses
`stripAndAccumulateInBoundsConstantOffsets` to decompose store pointers
into (base, offset) pairs and check whether two stores are 16 bytes
apart. This fails when LSR has rewritten pointer arithmetic into
non-inbounds GEPs because the function refuses to look through them. The
two stores then appear to have different base pointers and the check
returns false. When this happens, `lowerInterleavedStore` proceeds to
emit `ST2` for a pattern that would be more profitable as `zip+stp`,
since the load-store optimizer can pair adjacent stores into `STP` but
cannot merge `ST2` with anything. On a bf16-to-fp32 NEON conversion loop
this causes a regression from 11 to 17 instructions per iteration.
Note: Interleaved stores support was added for RISCV in
https://github.com/llvm/llvm-project/pull/115354. Turning this off
produces the desired STP instructions.
https://godbolt.org/z/1afsjPd3e
[7 lines not shown]
[flang] Enabled pulling of rebox into array_coor. (#199161)
This patch enables pulling slicing `fir.rebox` operations
into `fir.array_coor`. This helps preserve information about
the original rank of the array being accessed.
`FIRToMemRef` and later passes may benefit from this.
Assisted by: Claude
[flang][FIRToMemRef] Get strides from descriptor for some array_coor cases. (#199158)
This is a follow-up on Jean's comment
https://github.com/llvm/llvm-project/pull/198933#discussion_r3279535746
This patch makes use of the descriptor strides when `fir.array_coor`'s
memref is a `fir.box` that is not a fir.embox result.
[LoopFusion] Do not fuse loops with different guards (#199724)
The testcase that was originally contributed to #193641 exposed a
functional issue in which loop fusion can fuse functions with different
loop guards. There seem to two distinct bugs and each of them alone is
enough to let this happen.
- The condition that checks loop guards are identical, intends to
exclude loops that require peeling. But the condition is not correct and
it allows some loops that do not require peeling to pass.
- The condition that checks two guards are identical implicitly assume
conditions of guard branches are instructions, but this is not
necessarily always correct.
This patch fixes the problem for the loops that do not require peeling.
The issue still exists for loops that require peeling and will be fixed
separately.
[lldb] New expedited register specfication for unavailable regs (#193894)
When lldb-server/debugserver send a stop packet, they expedite the
vaLues of many of the general purpose registers in the stop packet, so
lldb doesn't need to fetch them separately.
On Darwin systems using an AArch64 M4 or newer SOC with SME, we need to
fetch the streaming vector length (svl) register when in Streaming SVE
Mode to correctly size the registers in lldb. On Darwin systems, when we
are not in SSVE mode, svl is undefined -- it is not included in the
expedited registers. However, lldb will still try to fetch the value, so
we get a register-read packet at every stop on M4 and newer systems,
trying to fetch the value.
This patch adds a new format for the expedited registers. They are
normally a `;` separated series of `{regnum}:{native endian bytes}`.
This allows for `{regnum}:` alone, indicating that the register value
for regnum cannot be fetched at this stop.
[42 lines not shown]
Reland "[libc] Enable baremetal float printf using modular format" (#199758)
Reverts llvm/llvm-project#199114
#199118 fixed the issue uncovered in the Fuchsia CI build.
[lldb] Fix vtable support on arm64e (#199116)
There were 2 small issues.
1. ValueObjectVTableChild was not fixing the addresses it was pulling
from signed pointers. This broke things like `SBValue::GetLoadAddress`
and identifying the function pointer type from debug info.
2. TestVTableValue.py made a lot of assumptions that did not hold on
arm64e. a. GetValueAsUnsigned will return a raw pointer value. Most of
the time, we needed GetValueAsAddress. b. The test was reading pointers
out of memory without fixing them up. c. The summary for a function
pointer on arm64e includes the load address. This isn't true on other
platforms.