History log of /llvm-project/llvm/lib/Transforms/Coroutines/MaterializationUtils.cpp (Results 1 – 5 of 5)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: llvmorg-21-init
# 6292a808 24-Jan-2025 Jeremy Morse <jeremy.morse@sony.com>

[NFC][DebugInfo] Use iterator-flavour getFirstNonPHI at many call-sites (#123737)

As part of the "RemoveDIs" project, BasicBlock::iterator now carries a
debug-info bit that's needed when getFirstNo

[NFC][DebugInfo] Use iterator-flavour getFirstNonPHI at many call-sites (#123737)

As part of the "RemoveDIs" project, BasicBlock::iterator now carries a
debug-info bit that's needed when getFirstNonPHI and similar feed into
instruction insertion positions. Call-sites where that's necessary were
updated a year ago; but to ensure some type safety however, we'd like to
have all calls to getFirstNonPHI use the iterator-returning version.

This patch changes a bunch of call-sites calling getFirstNonPHI to use
getFirstNonPHIIt, which returns an iterator. All these call sites are
where it's obviously safe to fetch the iterator then dereference it. A
follow-up patch will contain less-obviously-safe changes.

We'll eventually deprecate and remove the instruction-pointer
getFirstNonPHI, but not before adding concise documentation of what
considerations are needed (very few).

---------

Co-authored-by: Stephen Tozer <Melamoto@gmail.com>

show more ...


# 6a5a795c 19-Jan-2025 Kazu Hirata <kazu@google.com>

[Coroutines] Avoid repeated hash looksup (NFC) (#123501)


Revision tags: llvmorg-19.1.7, llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4, llvmorg-19.1.3
# 4db57ab9 16-Oct-2024 Tyler Nowicki <tyler.nowicki@amd.com>

[Coroutines] Improve dump of BB label to avoid str copies (#112374)

* This avoids the need to call printAsOperand that requires use of an
ostream and thus avoids a str copy.
* ModuleSlotTracker is u

[Coroutines] Improve dump of BB label to avoid str copies (#112374)

* This avoids the need to call printAsOperand that requires use of an
ostream and thus avoids a str copy.
* ModuleSlotTracker is used to get a BB # for BB's without names when
dumping SuspendCrossingInfo and materialization info.
* getBasicBlockLabel() is changed to dumpBasicBlockLabel() that directly
prints the label to dbgs()
* The label corresponds with the print-before BB #s.
* This change does not require any additional arguments to be added to
dump() methods, at least those that currently do not require any args.

Co-authored-by: tnowicki <tnowicki.nowicki@amd.com>

show more ...


Revision tags: llvmorg-19.1.2
# e82fcda1 09-Oct-2024 Tyler Nowicki <tyler.nowicki@amd.com>

[Coroutines] Move util headers to include/llvm (#111599)

Plugin libraries that use coroutines can do so right now, however, to
provide their own ABI they need to be able to use various headers, som

[Coroutines] Move util headers to include/llvm (#111599)

Plugin libraries that use coroutines can do so right now, however, to
provide their own ABI they need to be able to use various headers, some
of which such are required (such as the ABI header). This change exposes
the coro utils and required headers by moving them to
include/llvm/Transforms/Coroutines. My experience with our out-of-tree
plugin ABI has been that at least these headers are needed. The headers
moved are:
* ABI.h (ABI object)
* CoroInstr.h (helpers)
* Coroshape.h (Shape object)
* MaterializationUtils.h (helpers)
* SpillingUtils.h (helpers)
* SuspendCrossingInfo.h (analysis)

This has no code changes other than those required to move the headers
and these are:
* include guard name changes
* include path changes
* minor clang-format induced changes
* removal of LLVM_LIBRARY_VISIBILITY

show more ...


Revision tags: llvmorg-19.1.1, llvmorg-19.1.0
# 2670565a 12-Sep-2024 Tyler Nowicki <tyler.nowicki@amd.com>

[Coroutines] Move materialization code into its own utils (#108240)

* Move materialization out of CoroFrame to MaterializationUtils.h
* Move spill related utilities that were used by materializatio

[Coroutines] Move materialization code into its own utils (#108240)

* Move materialization out of CoroFrame to MaterializationUtils.h
* Move spill related utilities that were used by materialization to
SpillUtils
* Move isSuspendBlock (needed by materialization) to CoroInternal

See RFC for more info:
https://discourse.llvm.org/t/rfc-abi-objects-for-coroutines/81057

show more ...