Removing an unused switch statement that has only a default label. This happens to also eliminate an instance of switchception. NFC intended.

llvm-svn: 273161
This commit is contained in:
Aaron Ballman 2016-06-20 15:37:15 +00:00
parent 1c28b6d733
commit 86100fc8be
1 changed files with 16 additions and 22 deletions

View File

@ -26,29 +26,23 @@ using namespace llvm;
MCOperand ARMAsmPrinter::GetSymbolRef(const MachineOperand &MO,
const MCSymbol *Symbol) {
const MCExpr *Expr;
unsigned Option = MO.getTargetFlags() & ARMII::MO_OPTION_MASK;
switch (Option) {
default: {
Expr = MCSymbolRefExpr::create(Symbol, MCSymbolRefExpr::VK_None,
OutContext);
switch (Option) {
default: llvm_unreachable("Unknown target flag on symbol operand");
case ARMII::MO_NO_FLAG:
break;
case ARMII::MO_LO16:
Expr = MCSymbolRefExpr::create(Symbol, MCSymbolRefExpr::VK_None,
OutContext);
Expr = ARMMCExpr::createLower16(Expr, OutContext);
break;
case ARMII::MO_HI16:
Expr = MCSymbolRefExpr::create(Symbol, MCSymbolRefExpr::VK_None,
OutContext);
Expr = ARMMCExpr::createUpper16(Expr, OutContext);
break;
}
const MCExpr *Expr =
MCSymbolRefExpr::create(Symbol, MCSymbolRefExpr::VK_None, OutContext);
switch (MO.getTargetFlags() & ARMII::MO_OPTION_MASK) {
default:
llvm_unreachable("Unknown target flag on symbol operand");
case ARMII::MO_NO_FLAG:
break;
case ARMII::MO_LO16:
Expr =
MCSymbolRefExpr::create(Symbol, MCSymbolRefExpr::VK_None, OutContext);
Expr = ARMMCExpr::createLower16(Expr, OutContext);
break;
case ARMII::MO_HI16:
Expr =
MCSymbolRefExpr::create(Symbol, MCSymbolRefExpr::VK_None, OutContext);
Expr = ARMMCExpr::createUpper16(Expr, OutContext);
break;
}
}
if (!MO.isJTI() && MO.getOffset())