Skip to content

Conversation

@jorickert
Copy link

No description provided.

llvmgnsyncbot and others added 30 commits January 14, 2025 09:26
…lvm#122643)

Use SmallSetVector instead of SmallVector to avoid duplication,
so that dead nodes get erased/deleted only once.
Add some release notes for the Minidump work I did over the last few
months.
See the comment in Compiler<>::VisitCXXThisExpr.
We need to mark the InitList explicitly, so we later know what to refer
to when the init chain is active.
This was useful to test metrics before we had an actual workflow, now it
generates noise.

Signed-off-by: Nathan Gauër <brioche@google.com>
This patch adds the definition of a new entry block argument-defining
`host_eval` clause. This is intended to implement the passthrough
approach discussed in [this
RFC](https://discourse.llvm.org/t/rfc-openmp-dialect-representation-of-num-teams-thread-limit-and-target-spmd/81106),
for supporting host-evaluated clauses that apply to operations nested
inside of `omp.target`.
This patch adds the `host_eval` clause to the `omp.target` operation.
Additionally, it updates its op verifier to make sure all uses of block
arguments defined by this clause fall within one of the few cases where
they are allowed.

MLIR to LLVM IR translation fails on translation of this clause with a
not-yet-implemented error.
…other)), undef" --> "binop (shuffle), (shuffle)". (llvm#122118)

foldPermuteOfBinops currently requires both binop operands to be oneuse shuffles to fold the shuffles across the binop, but there will be cases where its still profitable to fold across the binop with only one foldable shuffle.
…lvm#116050)

This patch introduces the `OpenMPIRBuilder::TargetKernelDefaultAttrs`
structure used to simplify passing default and constant values for
number of teams and threads, and possibly other target kernel-related
information in the future.

This is used to forward values passed to `createTarget` to
`createTargetInit`, which previously used a default unrelated set of
values.
As in llvm#121565 we need to mark all stores as mayStore, hasSideEffects is not
enough to prevent moving loads past the instructions. And marking the
instructions as mayStore is a sensible thing to do on its own.
Follow up on 4a0d53a (PatternMatch: migrate to CmpPredicate) to get rid
of the FIXME it introduced in SLPVectorizer: the FIXME is bad, and we'd
get no testable impact by using CmpPredicate::getMatching here.
Follow up on 4a0d53a (PatternMatch: migrate to CmpPredicate) to get rid
of one of the FIXMEs it introduced by replacing a predicate comparison
with CmpPredicate::getMatching.
Improve a test by replacing undef with poison, and regenerate it using
UpdateTestChecks.
…mode (llvm#116051)

This patch introduces a `TargetKernelRuntimeAttrs` structure to hold
host-evaluated `num_teams`, `thread_limit`, `num_threads` and trip count
values passed to the runtime kernel offloading call.

Additionally, kernel type information is used to influence target device
code generation and the `IsSPMD` flag is replaced by `ExecFlags`, which
provides more granularity.
…117875)

This patch copies the target-cpu and target-features attributes of
functions containing target regions into the corresponding outlined
function holding the target region.

This mirrors what is currently being done for all other outlined
functions through the `CodeExtractor` in `OpenMPIRBuilder::finalize()`.
Extra semicolons were emitted for operations that should never have
them, since not every place was checking whether semicolon would be
actually needed.

Thus change the emitOperation to ignore trailingSemicolon field for such
operations.
…lvm#122329)

This fixes a conflict between the version of LLVM linked against by the
runner and the unrelated version of LLVM that may be dynamically loaded
by a graphics driver. (Relevant to llvm#73457: fixes loading certain Vulkan
drivers.)
…d taskloop simd. (llvm#121746)

Added codegen support for combined masked constructs `Parallel masked
taskloop simd`.
Added implementation for `EmitOMPParallelMaskedTaskLoopSimdDirective`.

Co-authored-by: Chandra Ghale <ghale@pe31.hpc.amslabs.hpecorp.net>
This patch adds support for processing the `host_eval` clause of
`omp.target` to populate default and runtime kernel launch attributes.
Specifically, these related to the `num_teams`, `thread_limit` and
`num_threads` clauses attached to operations nested inside of
`omp.target`. As a result, the `thread_limit` clause of `omp.target` is
also supported.

The implementation of `initTargetDefaultAttrs()` is intended to reflect
clang's own processing of multiple constructs and clauses in order to
define a default number of teams and threads to be used as kernel
attributes and to populate global variables in the target device module.

One side effect of this change is that it is no longer possible to
translate to LLVM IR target device MLIR modules unless they have a
supported target triple. This is because the local `getGridValue()`
function in the `OpenMPIRBuilder` only works for certain architectures,
and it is called whenever the maximum number of threads has not been
explicitly defined. This limitation also matches clang.

Evaluating the collapsed loop trip count of SPMD and Generic-SPMD
kernels remains unsupported.
… the CONCAT is free (llvm#122750)

Minor followup to llvm#122485 - if the source operands were widened half-size subvectors, then attempt to concatenate the subvectors directly, and then adjust the shuffle mask so references to the second operand now refer to the upper half of the concat result.
No difference in semantics here as byval is already handled
separately. This simplifies migration to the captures attribute.
Base automatically changed from bump_to_1d4b5c16 to bump_to_72086490 April 14, 2025 07:39
[AutoBump] Merge with 412e1af (Dec 20) (25) [Only tested MLIR]
[AutoBump] Merge with 4b22ef7 (Jan 02) (27) [Only tested MLIR]
[AutoBump] Merge with 89b34ec (Dec 18) (23) [Only tested MLIR]
[AutoBump] Merge with 465a3ce (Jan 09) (33)
[AutoBump] Merge with 67efbd0 (Jan 08) (31) [Only tested MLIR]
[AutoBump] Merge with d0373db (Jan 09) (35)
[AutoBump] Merge with e7244d8 (Jan 08) (29)
Base automatically changed from bump_to_72086490 to bump_to_1b2c8f10 April 14, 2025 07:45
[AutoBump] Merge with fixes of b56d1ec (Dec 18) (24) [Only tested MLIR]
[AutoBump] Merge with 57447d3 (Jan 09) (37)
[AutoBump] Merge with fixes of 09dfc57 (Dec 20) (26) [Only tested MLIR]
[AutoBump] Merge with fixes of d622b66 (Jan 02) (28)[Only tested MLIR]
[AutoBump] Merge with fixes of c1d01b2 (Jan 08) (30) [Only tested MLIR]
[AutoBump] Merge with fixes of 360a03c (Jan 08) (32)[Only tested MLIR]
[AutoBump] Merge with fixes of a759176 (Jan 09) (34)[Only tested MLIR]
[AutoBump] Merge with fixes of 6d72bf4 (Jan 09) (36) [Only tested MLIR]
[AutoBump] Merge with 2d10b7b (Jan 09) (38)
[AutoBump] Merge with fixes of 9190e1c (Jan 09) (39) [Only tested MLIR]
[AutoBump] Merge with d0b641b (Jan 14) (40)
[AutoBump] Merge with fixes of be96bd7 (Jan 14) (41) [Only tested MLIR]
[AutoBump] Merge with 31249e2 (Jan 14) (42)
[AutoBump] Merge with fixes of f09db6a (Jan 14) (43) [Only tested MLIR]
[AutoBump] Merge with 3986cff (Jan 15) (44)
@jorickert jorickert merged commit c6117c1 into bump_to_1b2c8f10 Apr 14, 2025
50 checks passed
@jorickert jorickert deleted the bump_to_392622d0 branch April 14, 2025 08:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.