[regalloc] Fix merging a bundle with itself
When merging a bundle with itself, we should consider the merge a success even though we do not merge anything. The result is used to determine whether the backward spilling heuristic might introduce a stack to stack move. For this purpose, it only matters whether the phi and its input end up in the same bundle. R=sigurds@chromium.org Bug: chromium:1158088 Change-Id: Icdcfe81d58bce5916b87a34a46c9611f5978bf27 Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2625876 Reviewed-by: Sigurd Schneider <sigurds@chromium.org> Commit-Queue: Thibaud Michaud <thibaudm@chromium.org> Cr-Commit-Position: refs/heads/master@{#72066}
This commit is contained in:
parent
458f7ad06f
commit
bbcb20a13e
@ -2650,7 +2650,7 @@ bool LiveRangeBundle::TryAddRange(LiveRange* range) {
|
||||
LiveRangeBundle* LiveRangeBundle::TryMerge(LiveRangeBundle* lhs,
|
||||
LiveRangeBundle* rhs,
|
||||
bool trace_alloc) {
|
||||
if (rhs == lhs) return nullptr;
|
||||
if (rhs == lhs) return lhs;
|
||||
|
||||
auto iter1 = lhs->uses_.begin();
|
||||
auto iter2 = rhs->uses_.begin();
|
||||
|
Loading…
Reference in New Issue
Block a user