-
Notifications
You must be signed in to change notification settings - Fork 13.5k
[NFC] Remove adhoc definition of MDMapT in IRMover #118626
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
artempyanykh
wants to merge
6
commits into
users/artempyanykh/fast-coro-upstream/6
from
users/artempyanykh/fast-coro-upstream/7
Closed
[NFC] Remove adhoc definition of MDMapT in IRMover #118626
artempyanykh
wants to merge
6
commits into
users/artempyanykh/fast-coro-upstream/6
from
users/artempyanykh/fast-coro-upstream/7
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…neFunctionInto Summary: Moving the cloning of BBs after the metadata makes the flow of the function a bit more straightforward and makes it easier to extract more into helper functions. Test Plan: ninja check-llvm-unit check-llvm stack-info: PR: #118621, branch: users/artempyanykh/fast-coro-upstream/2
Summary: Extract the logic to build up a metadata map to use in metadata cloning into a separate function. Test Plan: ninja check-llvm-unit check-llvm stack-info: PR: #118622, branch: users/artempyanykh/fast-coro-upstream/3
Summary: The new API expects the caller to populate the VMap. We need it this way for a subsequent change around coroutine cloning. Test Plan: ninja check-llvm-unit check-llvm stack-info: PR: #118623, branch: users/artempyanykh/fast-coro-upstream/4
Summary: This and previously extracted `CloneFunction*Into` functions will be used in later diffs. Test Plan: ninja check-llvm-unit check-llvm stack-info: PR: #118624, branch: users/artempyanykh/fast-coro-upstream/5
Summary: Previously, we'd add all SPs distinct from the cloned one into a set. Then when cloning a local scope we'd check if it's from one of those 'distinct' SPs by checking if it's in the set. We don't need to do that. We can just check against the cloned SP directly and drop the set. Test Plan: ninja check-llvm-unit check-llvm stack-info: PR: #118625, branch: users/artempyanykh/fast-coro-upstream/6
Summary: The typedef was there probably because the type alias in ValueMap was private. Test Plan: ninja check-llvm-unit check-llvm stack-info: PR: #118626, branch: users/artempyanykh/fast-coro-upstream/7
@llvm/pr-subscribers-lto Author: Artem Pianykh (artempyanykh) Changes[NFC] Remove adhoc definition of MDMapT in IRMover Summary: Test Plan: Full diff: https://github.com/llvm/llvm-project/pull/118626.diff 2 Files Affected:
diff --git a/llvm/include/llvm/Linker/IRMover.h b/llvm/include/llvm/Linker/IRMover.h
index 1e3c5394ffa2af..89e9cbe0be18e1 100644
--- a/llvm/include/llvm/Linker/IRMover.h
+++ b/llvm/include/llvm/Linker/IRMover.h
@@ -12,6 +12,7 @@
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/DenseSet.h"
#include "llvm/ADT/FunctionExtras.h"
+#include "llvm/IR/ValueMap.h"
#include <functional>
namespace llvm {
@@ -41,9 +42,6 @@ class IRMover {
static bool isEqual(const StructType *LHS, const StructType *RHS);
};
- /// Type of the Metadata map in \a ValueToValueMapTy.
- typedef DenseMap<const Metadata *, TrackingMDRef> MDMapT;
-
public:
class IdentifiedStructTypeSet {
// The set of opaque types is the composite module.
diff --git a/llvm/lib/Linker/IRMover.cpp b/llvm/lib/Linker/IRMover.cpp
index a0c3f2c5b0baf6..76af83df00cba2 100644
--- a/llvm/lib/Linker/IRMover.cpp
+++ b/llvm/lib/Linker/IRMover.cpp
@@ -373,9 +373,6 @@ class LocalValueMaterializer final : public ValueMaterializer {
Value *materialize(Value *V) override;
};
-/// Type of the Metadata map in \a ValueToValueMapTy.
-typedef DenseMap<const Metadata *, TrackingMDRef> MDMapT;
-
/// This is responsible for keeping track of the state used for moving data
/// from SrcM to DstM.
class IRLinker {
|
7986937
to
b698e06
Compare
e74ea37
to
302580a
Compare
This was referenced Dec 4, 2024
Merged
jollaitbot
pushed a commit
to sailfishos-mirror/llvm-project
that referenced
this pull request
Dec 4, 2024
Summary: The typedef was there probably because the type alias in ValueMap was private. Test Plan: ninja check-llvm-unit check-llvm stack-info: PR: llvm/llvm-project#118626, branch: users/artempyanykh/fast-coro-upstream/7
302580a
to
1b7941e
Compare
b698e06
to
f0e2d2b
Compare
1b7941e
to
51e786e
Compare
Abandoned due to a change in #118622. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Stacked PRs:
[NFC] Remove adhoc definition of MDMapT in IRMover
Summary:
The typedef was there probably because the type alias in ValueMap was private.
Test Plan:
ninja check-llvm-unit check-llvm