[BOLT][NFC] Remove BB::getBranchInfo accepting MCSymbol ptr

Reviewed By: #bolt, rafauler

Differential Revision: https://reviews.llvm.org/D144924
This commit is contained in:
Amir Ayupov
2023-03-14 15:34:08 -07:00
parent 2f5fe16e6d
commit 16e67e6932
3 changed files with 3 additions and 20 deletions

View File

@@ -593,19 +593,6 @@ BinaryBasicBlock::getBranchInfo(const BinaryBasicBlock &Succ) const {
return std::get<1>(*Result);
}
BinaryBasicBlock::BinaryBranchInfo &
BinaryBasicBlock::getBranchInfo(const MCSymbol *Label) {
auto BI = branch_info_begin();
for (BinaryBasicBlock *BB : successors()) {
if (BB->getLabel() == Label)
return *BI;
++BI;
}
llvm_unreachable("Invalid successor");
return *BI;
}
BinaryBasicBlock *BinaryBasicBlock::splitAt(iterator II) {
assert(II != end() && "expected iterator pointing to instruction");