Skip to content

Commit

Permalink
[X86][NFC] Rename lookupBroadcastFoldTable to lookupBroadcastFoldTabl…
Browse files Browse the repository at this point in the history
…eBySize

Address RKSimon's comments in #79761
  • Loading branch information
KanRobert committed Jan 29, 2024
1 parent 8b429fc commit cfb7026
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions llvm/lib/Target/X86/X86FixupVectorConstants.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -406,14 +406,14 @@ bool X86FixupVectorConstantsPass::processInstruction(MachineFunction &MF,
unsigned OpNoBcst32 = 0, OpNoBcst64 = 0;
if (OpSrc32) {
if (const X86FoldTableEntry *Mem2Bcst =
llvm::lookupBroadcastFoldTable(OpSrc32, 32)) {
llvm::lookupBroadcastFoldTableBySize(OpSrc32, 32)) {
OpBcst32 = Mem2Bcst->DstOp;
OpNoBcst32 = Mem2Bcst->Flags & TB_INDEX_MASK;
}
}
if (OpSrc64) {
if (const X86FoldTableEntry *Mem2Bcst =
llvm::lookupBroadcastFoldTable(OpSrc64, 64)) {
llvm::lookupBroadcastFoldTableBySize(OpSrc64, 64)) {
OpBcst64 = Mem2Bcst->DstOp;
OpNoBcst64 = Mem2Bcst->Flags & TB_INDEX_MASK;
}
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Target/X86/X86InstrFoldTables.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ static bool matchBroadcastSize(const X86FoldTableEntry &Entry,
}

const X86FoldTableEntry *
llvm::lookupBroadcastFoldTable(unsigned MemOp, unsigned BroadcastBits) {
llvm::lookupBroadcastFoldTableBySize(unsigned MemOp, unsigned BroadcastBits) {
static X86BroadcastFoldTable BroadcastFoldTable;
auto &Table = BroadcastFoldTable.Table;
for (auto I = llvm::lower_bound(Table, MemOp);
Expand Down
4 changes: 2 additions & 2 deletions llvm/lib/Target/X86/X86InstrFoldTables.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ const X86FoldTableEntry *lookupUnfoldTable(unsigned MemOp);

// Look up the broadcast folding table entry for this instruction from
// the regular memory instruction.
const X86FoldTableEntry *lookupBroadcastFoldTable(unsigned MemOp,
unsigned BroadcastBits);
const X86FoldTableEntry *lookupBroadcastFoldTableBySize(unsigned MemOp,
unsigned BroadcastBits);

} // namespace llvm

Expand Down

0 comments on commit cfb7026

Please sign in to comment.