Skip to content

Commit

Permalink
InstSimplify: strip bad TODO (NFC) (#92754)
Browse files Browse the repository at this point in the history
foldIdentityShuffles requires two sets of canceling shuffles. If there
are any intervening instructions, they are feeding in the result of the
first set of shuffles. To eliminate the two sets of shuffles, you'd have
to rewrite the head of the intervening instructions to feed in the
operand of the first set of shuffles. Since modifying the IR in any way
is disallowed by an analysis, strip this bad TODO.
  • Loading branch information
artagnon authored May 21, 2024
1 parent 56a1f0a commit c4d6867
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions llvm/lib/Analysis/InstructionSimplify.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5346,9 +5346,6 @@ static Value *foldIdentityShuffles(int DestElt, Value *Op0, Value *Op1,
SourceShuf->getMaskValue(RootElt), RootVec, MaxRecurse);
}

// TODO: Look through bitcasts? What if the bitcast changes the vector element
// size?

// The source operand is not a shuffle. Initialize the root vector value for
// this shuffle if that has not been done yet.
if (!RootVec)
Expand Down

0 comments on commit c4d6867

Please sign in to comment.