diff options
author | Craig Topper <craig.topper@gmail.com> | 2012-02-07 05:05:23 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2012-02-07 05:05:23 +0000 |
commit | a2886c21d9a08d63c324cc61aa91ae0893507a31 (patch) | |
tree | 26343892cf0ad93e83448d53dc0448e7ad413412 /llvm/lib/MC/MCELFStreamer.cpp | |
parent | a767941651945183cc3665173fd850a6b057c018 (diff) | |
download | bcm5719-llvm-a2886c21d9a08d63c324cc61aa91ae0893507a31.tar.gz bcm5719-llvm-a2886c21d9a08d63c324cc61aa91ae0893507a31.zip |
Convert assert(0) to llvm_unreachable
llvm-svn: 149967
Diffstat (limited to 'llvm/lib/MC/MCELFStreamer.cpp')
-rw-r--r-- | llvm/lib/MC/MCELFStreamer.cpp | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/llvm/lib/MC/MCELFStreamer.cpp b/llvm/lib/MC/MCELFStreamer.cpp index 42a7ebf7d4d..607e01cd821 100644 --- a/llvm/lib/MC/MCELFStreamer.cpp +++ b/llvm/lib/MC/MCELFStreamer.cpp @@ -60,24 +60,24 @@ public: virtual void EmitWeakReference(MCSymbol *Alias, const MCSymbol *Symbol); virtual void EmitSymbolAttribute(MCSymbol *Symbol, MCSymbolAttr Attribute); virtual void EmitSymbolDesc(MCSymbol *Symbol, unsigned DescValue) { - assert(0 && "ELF doesn't support this directive"); + llvm_unreachable("ELF doesn't support this directive"); } virtual void EmitCommonSymbol(MCSymbol *Symbol, uint64_t Size, unsigned ByteAlignment); virtual void BeginCOFFSymbolDef(const MCSymbol *Symbol) { - assert(0 && "ELF doesn't support this directive"); + llvm_unreachable("ELF doesn't support this directive"); } virtual void EmitCOFFSymbolStorageClass(int StorageClass) { - assert(0 && "ELF doesn't support this directive"); + llvm_unreachable("ELF doesn't support this directive"); } virtual void EmitCOFFSymbolType(int Type) { - assert(0 && "ELF doesn't support this directive"); + llvm_unreachable("ELF doesn't support this directive"); } virtual void EndCOFFSymbolDef() { - assert(0 && "ELF doesn't support this directive"); + llvm_unreachable("ELF doesn't support this directive"); } virtual void EmitELFSize(MCSymbol *Symbol, const MCExpr *Value) { @@ -90,11 +90,11 @@ public: virtual void EmitZerofill(const MCSection *Section, MCSymbol *Symbol = 0, unsigned Size = 0, unsigned ByteAlignment = 0) { - assert(0 && "ELF doesn't support this directive"); + llvm_unreachable("ELF doesn't support this directive"); } virtual void EmitTBSSSymbol(const MCSection *Section, MCSymbol *Symbol, uint64_t Size, unsigned ByteAlignment = 0) { - assert(0 && "ELF doesn't support this directive"); + llvm_unreachable("ELF doesn't support this directive"); } virtual void EmitBytes(StringRef Data, unsigned AddrSpace); virtual void EmitValueToAlignment(unsigned ByteAlignment, int64_t Value = 0, @@ -180,7 +180,7 @@ void MCELFStreamer::EmitAssemblerFlag(MCAssemblerFlag Flag) { return; } - assert(0 && "invalid assembler flag!"); + llvm_unreachable("invalid assembler flag!"); } void MCELFStreamer::EmitThumbFunc(MCSymbol *Func) { @@ -250,8 +250,7 @@ void MCELFStreamer::EmitSymbolAttribute(MCSymbol *Symbol, case MCSA_WeakDefAutoPrivate: case MCSA_Invalid: case MCSA_IndirectSymbol: - assert(0 && "Invalid symbol attribute for ELF!"); - break; + llvm_unreachable("Invalid symbol attribute for ELF!"); case MCSA_ELF_TypeGnuUniqueObject: // Ignore for now. |