summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/include/llvm/MC/MCStreamer.h2
-rw-r--r--llvm/lib/MC/MCAsmStreamer.cpp6
-rw-r--r--llvm/lib/MC/MCSectionXCOFF.cpp12
-rw-r--r--llvm/lib/MC/MCXCOFFStreamer.cpp4
4 files changed, 12 insertions, 12 deletions
diff --git a/llvm/include/llvm/MC/MCStreamer.h b/llvm/include/llvm/MC/MCStreamer.h
index cd3795a55a3..f20324f853a 100644
--- a/llvm/include/llvm/MC/MCStreamer.h
+++ b/llvm/include/llvm/MC/MCStreamer.h
@@ -544,7 +544,7 @@ public:
/// \param ByteAlignment - The alignment of the symbol in bytes. Must be a power
/// of 2.
virtual void EmitXCOFFLocalCommonSymbol(MCSymbol *Symbol, uint64_t Size,
- unsigned ByteAlignment);
+ unsigned ByteAlignment);
/// Emit an ELF .size directive.
///
diff --git a/llvm/lib/MC/MCAsmStreamer.cpp b/llvm/lib/MC/MCAsmStreamer.cpp
index 967ee8b3c5f..81a57c67d37 100644
--- a/llvm/lib/MC/MCAsmStreamer.cpp
+++ b/llvm/lib/MC/MCAsmStreamer.cpp
@@ -759,14 +759,14 @@ void MCAsmStreamer::EmitCOFFImgRel32(MCSymbol const *Symbol, int64_t Offset) {
EmitEOL();
}
-// We need an XCOFF specific version of this directive as the AIX syntax
+// We need an XCOFF-specific version of this directive as the AIX syntax
// requires a QualName argument identifying the csect name and storage mapping
// class to appear before the alignment if we are specifying it.
void MCAsmStreamer::EmitXCOFFLocalCommonSymbol(MCSymbol *Symbol, uint64_t Size,
unsigned ByteAlignment) {
assert(MAI->getLCOMMDirectiveAlignmentType() == LCOMM::Log2Alignment &&
- "We only support writing log base-2 alignment format with XCOFF");
- assert(isPowerOf2_32(ByteAlignment) && "alignment must be a power of 2");
+ "We only support writing log base-2 alignment format with XCOFF.");
+ assert(isPowerOf2_32(ByteAlignment) && "Alignment must be a power of 2.");
OS << "\t.lcomm\t";
Symbol->print(OS, MAI);
diff --git a/llvm/lib/MC/MCSectionXCOFF.cpp b/llvm/lib/MC/MCSectionXCOFF.cpp
index a3f79c35e84..d00a435b625 100644
--- a/llvm/lib/MC/MCSectionXCOFF.cpp
+++ b/llvm/lib/MC/MCSectionXCOFF.cpp
@@ -29,12 +29,12 @@ void MCSectionXCOFF::PrintSwitchToSection(const MCAsmInfo &MAI, const Triple &T,
}
if (getKind().isBSSLocal() || getKind().isCommon()) {
- if (getMappingClass() != XCOFF::XMC_RW &&
- getMappingClass() != XCOFF::XMC_BS)
- llvm_unreachable("Generated a storage-mapping class for a common/bss "
- "csect we don't understand how to switch to.");
- if (getCSectType() != XCOFF::XTY_CM)
- llvm_unreachable("wrong csect type for .bss csect");
+ assert((getMappingClass() == XCOFF::XMC_RW ||
+ getMappingClass() == XCOFF::XMC_BS) &&
+ "Generated a storage-mapping class for a common/bss csect we don't "
+ "understand how to switch to.");
+ assert(getCSectType() == XCOFF::XTY_CM &&
+ "wrong csect type for .bss csect");
// Don't have to print a directive for switching to section for commons.
// '.comm' and '.lcomm' directives for the variable will create the needed
// csect.
diff --git a/llvm/lib/MC/MCXCOFFStreamer.cpp b/llvm/lib/MC/MCXCOFFStreamer.cpp
index 7d526cc3c04..960791910c5 100644
--- a/llvm/lib/MC/MCXCOFFStreamer.cpp
+++ b/llvm/lib/MC/MCXCOFFStreamer.cpp
@@ -60,5 +60,5 @@ MCStreamer *llvm::createXCOFFStreamer(MCContext &Context,
void MCXCOFFStreamer::EmitXCOFFLocalCommonSymbol(MCSymbol *Symbol, uint64_t Size,
unsigned ByteAlign) {
- llvm_unreachable("Not implemented yet.");
-} \ No newline at end of file
+ report_fatal_error("Emission of local commons not implemented yet.");
+}
OpenPOWER on IntegriCloud