[llvm] r230132 - Turn an if+llvm_unreachable into an assert and reword comment.
Eric Christopher
echristo at gmail.com
Sat Feb 21 00:32:38 PST 2015
Author: echristo
Date: Sat Feb 21 02:32:38 2015
New Revision: 230132
URL: http://llvm.org/viewvc/llvm-project?rev=230132&view=rev
Log:
Turn an if+llvm_unreachable into an assert and reword comment.
Modified:
llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp
Modified: llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp?rev=230132&r1=230131&r2=230132&view=diff
==============================================================================
--- llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp (original)
+++ llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp Sat Feb 21 02:32:38 2015
@@ -976,13 +976,10 @@ void MipsAsmPrinter::EmitFPCallStub(
OutContext.GetOrCreateSymbol("__call_stub_fp_" + Twine(Symbol));
OutStreamer.EmitSymbolAttribute(MType, MCSA_ELF_TypeFunction);
OutStreamer.EmitLabel(Stub);
- //
- // we just handle non pic for now. these function will not be
- // called otherwise. when the full stub generation is moved here
- // we need to deal with pic.
- //
- if (TM.getRelocationModel() == Reloc::PIC_)
- llvm_unreachable("should not be here if we are compiling pic");
+
+ // Only handle non-pic for now.
+ assert(TM.getRelocationModel() != Reloc::PIC_ &&
+ "should not be here if we are compiling pic");
TS.emitDirectiveSetReorder();
//
// We need to add a MipsMCExpr class to MCTargetDesc to fully implement
More information about the llvm-commits
mailing list