[PATCH] D34730: [AArch64] Make assert messages uniform [NFC]
Mandeep Singh Grang via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 27 17:34:29 PDT 2017
mgrang created this revision.
Herald added subscribers: kristof.beyls, javed.absar, rengolin, aemerson.
Make assert messages related to Darwin, ELF and COFF uniform.
Repository:
rL LLVM
https://reviews.llvm.org/D34730
Files:
lib/Target/AArch64/AArch64MCInstLower.cpp
lib/Target/AArch64/AArch64RegisterInfo.cpp
lib/Target/AArch64/MCTargetDesc/AArch64AsmBackend.cpp
lib/Target/AArch64/MCTargetDesc/AArch64MCTargetDesc.cpp
Index: lib/Target/AArch64/MCTargetDesc/AArch64MCTargetDesc.cpp
===================================================================
--- lib/Target/AArch64/MCTargetDesc/AArch64MCTargetDesc.cpp
+++ lib/Target/AArch64/MCTargetDesc/AArch64MCTargetDesc.cpp
@@ -63,7 +63,8 @@
else if (TheTriple.isOSBinFormatCOFF())
MAI = new AArch64MCAsmInfoCOFF();
else {
- assert(TheTriple.isOSBinFormatELF() && "Only expect Darwin, ELF or COFF");
+ assert(TheTriple.isOSBinFormatELF() &&
+ "Only expect Darwin, ELF or COFF targets");
MAI = new AArch64MCAsmInfoELF(TheTriple);
}
@@ -79,7 +80,7 @@
CodeModel::Model &CM) {
assert((TT.isOSBinFormatELF() || TT.isOSBinFormatMachO() ||
TT.isOSBinFormatCOFF()) &&
- "Only expect Darwin, ELF and COFF targets");
+ "Only expect Darwin, ELF or COFF targets");
if (CM == CodeModel::Default)
CM = CodeModel::Small;
Index: lib/Target/AArch64/MCTargetDesc/AArch64AsmBackend.cpp
===================================================================
--- lib/Target/AArch64/MCTargetDesc/AArch64AsmBackend.cpp
+++ lib/Target/AArch64/MCTargetDesc/AArch64AsmBackend.cpp
@@ -591,7 +591,7 @@
return new COFFAArch64AsmBackend(T, TheTriple);
assert(TheTriple.isOSBinFormatELF() &&
- "Expect either MachO, ELF or COFF target");
+ "Only expect Darwin, ELF or COFF targets");
uint8_t OSABI = MCELFObjectTargetWriter::getOSABI(TheTriple.getOS());
bool IsILP32 = Options.getABIName() == "ilp32";
Index: lib/Target/AArch64/AArch64RegisterInfo.cpp
===================================================================
--- lib/Target/AArch64/AArch64RegisterInfo.cpp
+++ lib/Target/AArch64/AArch64RegisterInfo.cpp
@@ -94,7 +94,7 @@
if (TT.isOSDarwin())
return CSR_AArch64_TLS_Darwin_RegMask;
- assert(TT.isOSBinFormatELF() && "only expect Darwin or ELF TLS");
+ assert(TT.isOSBinFormatELF() && "Only expect Darwin or ELF TLS");
return CSR_AArch64_TLS_ELF_RegMask;
}
Index: lib/Target/AArch64/AArch64MCInstLower.cpp
===================================================================
--- lib/Target/AArch64/AArch64MCInstLower.cpp
+++ lib/Target/AArch64/AArch64MCInstLower.cpp
@@ -169,7 +169,7 @@
return lowerSymbolOperandCOFF(MO, Sym);
assert(Printer.TM.getTargetTriple().isOSBinFormatELF() &&
- "Expect Darwin, ELF or COFF target");
+ "Only expect Darwin, ELF or COFF targets");
return lowerSymbolOperandELF(MO, Sym);
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D34730.104324.patch
Type: text/x-patch
Size: 2505 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170628/16948446/attachment.bin>
More information about the llvm-commits
mailing list