[CodeGen] Introduce MI flag for Live Range split instructions
For some targets, it is required to identify the COPY instruction
corresponds to the RA inserted live range split. Adding the new
flag `MachineInstr::LRSplit` to serve the purpose.
[AMDGPU] Regenerate all MC checks after #164424 (#175156)
Includes one manual fix to add -filetype=null to a RUN line in
test/MC/AMDGPU/gfx1250_asm_sop1.s. Everything else is autogenerated.
[OpenMP][flang] Move `todo` for checking reduction support status on the GPU
Moves a `todo` to check for the current level of support for by-ref
reductions to the `FunctionFiltering` pass. This guarantees that the
check does not trigger when the same module is compiled twice: on the
CPU and on the GPU.
[CodeGen] Introduce MI flag for Live Range split instructions
For some targets, it is required to identify the COPY instruction
corresponds to the RA inserted live range split. Adding the new
flag `MachineInstr::LRSplit` to serve the purpose.
[mlir][Analysis][NFC] Improve `RegionBranchOpInterface` API usage (#173983)
Remove a helper function and query the `RegionBranchOpInterface`
instead. (Which does the same thing.) Also add a TODO for a bug in the
implementation of `SliceWalk.cpp`. (The bug is not fixed yet.)
[CodeGen] Introduce MI flag for Live Range split instructions
For some targets, it is required to identify the COPY instruction
corresponds to the RA inserted live range split. Adding the new
flag `MachineInstr::LRSplit` to serve the purpose.
[clang] Fix string literal parsing on some attributes (#171017)
At the time ParseAttributeArgumentList is called, the first argument
of an attribute may have already been parsed. We need to take this into
account when accessing ParsedAttributeArgumentsProperties mask, which
specifies which of the attribute arguments are string literals.
Pull Request: https://github.com/llvm/llvm-project/pull/171017
[CodeGen] Introduce MI flag for Live Range split instructions
For some targets, it is required to identify the COPY instruction
corresponds to the RA inserted live range split. Adding the new
flag `MachineInstr::LRSplit` to serve the purpose.
[flang-rt][build] Disable build-time warning of '-Wshift-count-negative' from g++ compiler and remove unsupported floating-point data. (#174915)
When building the flang-rt project with the g++ compiler on Linux-X86_64
machine, the compiler gives the following warning:
```
llvm-project/flang-rt/lib/runtime/extensions.cpp:455:26: warning: left shift count is negative [-Wshift-count-negative]
455 | mask = ~(unsigned)0u << ((8 - digits) * 4 + 1);
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
```
All the discussion records see:
https://github.com/llvm/llvm-project/pull/173955
Co-authored-by: liao jun <liaojun at ultrarisc.com>
[CodeGen] Introduce MI flag for Live Range split instructions
For some targets, it is required to identify the COPY instruction
corresponds to the RA inserted live range split. Adding the new
flag `MachineInstr::LRSplit` to serve the purpose.
[AllocToken] Fix attribute mismatch in AllocTokenPass (#174959)
Fixes an attribute mismatch error in `AllocTokenPass` that occurs during
ThinLTO builds at OptimizationLevel::O0.
The `getTokenAllocFunction` in `AllocTokenPass` was incorrectly copying
attributes from the instrumented function (`Callee`) to an *existing*
`void()` alloc-token function retrieved by `Mod.getOrInsertFunction`.
This resulted in arg attributes being added to a function with no
parameters, causing `VerifyPass` to fail with "Attribute after last
parameter!".
The fix modifies `getTokenAllocFunction` to pass the `Callee`'s
attributes directly to the `Mod.getOrInsertFunction` overload. This
ensures attributes are only applied when the alloc-token function is
*newly inserted*, preventing unintended attribute modifications on
already existing function declarations.
See https://g-issues.chromium.org/issues/474289092 for detailed
[2 lines not shown]
[CodeGen] Introduce MI flag for Live Range split instructions
For some targets, it is required to identify the COPY instruction
corresponds to the RA inserted live range split. Adding the new
flag `MachineInstr::LRSplit` to serve the purpose.
[MLIR][NVVM] Fix crash on invalid optimization level in NVVMTargetAttr (#173280)
Update `NVVMTargetAttr` builder in `NVVMOps.td` to use `$_get` instead
of `Base::get`.
Now the auto-generated parser calls `getChecked`, allowing graceful
error handling for invalid parameters (e.g., `O=4`) instead of crashing
with an assertion failure.
Add a regression test in
`mlir/test/Dialect/LLVMIR/nvvm-target-invalid.mlir`.
Fixes: https://github.com/llvm/llvm-project/issues/130014
[CodeGen] Introduce MI flag for Live Range split instructions
For some targets, it is required to identify the COPY instruction
corresponds to the RA inserted live range split. Adding the new
flag `MachineInstr::LRSplit` to serve the purpose.
[flang] Fix homonymous interface and procedure warning (#171696)
When emitting an homonymous generic interface and procedure warning,
the source locations of the interface and the procedure were being
compared to find the one that occurred later in the source file.
The problem is that they could be in different source/module files,
which makes the comparison invalid.
Fix it by using parser::AllCookedSources::Precedes() instead, that
correctly handle names in different source files.
[CodeGen] Generalise Hexagon flags for memop inline thresholds (#172829)
Generalise the Hexagon cmdline options to control if memset, memcpy or memmove intrinsics should be inlined versus calling library functions, so they can be used by all backends:
• -max-store-memset
• -max-store-memcpy
• -max-store-memmove
These flags override the target-specific defaults set in TargetLowering (e.g., MaxStoresPerMemcpy) and allow fine-tuning of the inlining threshold for performance analysis and optimization.
The optsize variants (-max-store-memset-Os, -max-store-memcpy-Os, max-store-memmove-Os) from the Hexagon backend were removed, and now the above options control both.
The threshold is specified as a number of store operations, which is backend-specific. Operations requiring more stores than the threshold will call the corresponding library function instead of being inlined.
[PPC] Disable some ORC-powerpc64le-linux tests. (#175100)
Tests fail to link when using LLVM C++ library. Disabling the tests
until they can be investigated and the underlying cause identified and
fixed.
[MLIR][OpenMP] Support cancel taskgroup inside of taskloop (#174815)
Implementation follows exactly what is done for omp.wsloop and omp.task.
See #137841.
The change to the operation verifier is to allow a taskgroup
cancellation point inside of a taskloop. This was already allowed for
omp.cancel.
[X86][InstCombine] Generalize SSE/AVX fp MAX/MIN intrinsics to maxnum/minnum (#174806)
Fixes #173270
For x86 SSE/AVX floating point MAX/MIN intrinsics, attempt to generalize
them down into `Intrinsic::maxnum` and `Intrinsic::minnum` given that we
can verify that the inputs are either (PosNormal, NegNormal, PosZero).
This PR uses the `llvm::computeKnownFPClass` to generate the FPClass
bitset to verify if the inputs are of the other FP types (NaN, Inf,
Subnormal, NegZero).
[llvm-exegesis] Fix intermittent failure in setReg_init_check.s (#175148)
Test is failing intermittently after #174944. The issue this time is the
`WSeqPair`/`XSeqPair` tests fail if the same pair is used as there's
fewer MOVs.
The test was expecting:
```
0000000000000000 <foo>:
0: f81e0ffb str x27, [sp, #-0x20]!
4: a90163fa stp x26, x24, [sp, #0x10]
8: d2800006 mov x6, #0x0 // =0
c: d2800007 mov x7, #0x0 // =0
10: d280001a mov x26, #0x0 // =0
14: d280001b mov x27, #0x0 // =0
18: d2800018 mov x24, #0x0 // =0
1c: 48267f1a casp x6, x7, x26, x27, [x24]
```
but this can occur:
[8 lines not shown]