[PATCH] D11567: WebAssembly: MCAsmInfo only has one syntax variant for now.
JF Bastien
jfb at chromium.org
Tue Jul 28 10:21:39 PDT 2015
jfb created this revision.
jfb added subscribers: sunfish, llvm-commits.
Herald added a subscriber: jfb.
MCAsmInfo is set up with the default AssemblerDialect, which is zero.
http://reviews.llvm.org/D11567
Files:
lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCTargetDesc.cpp
Index: lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCTargetDesc.cpp
===================================================================
--- lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCTargetDesc.cpp
+++ lib/Target/WebAssembly/MCTargetDesc/WebAssemblyMCTargetDesc.cpp
@@ -37,17 +37,15 @@
static MCAsmInfo *createWebAssemblyMCAsmInfo(const MCRegisterInfo &MRI,
const Triple &TT) {
- MCAsmInfo *MAI = new WebAssemblyMCAsmInfo(TT);
- return MAI;
+ return new WebAssemblyMCAsmInfo(TT);
}
static MCInstPrinter *
createWebAssemblyMCInstPrinter(const Triple &T, unsigned SyntaxVariant,
const MCAsmInfo &MAI, const MCInstrInfo &MII,
const MCRegisterInfo &MRI) {
- if (SyntaxVariant == 0 || SyntaxVariant == 1)
- return new WebAssemblyInstPrinter(MAI, MII, MRI);
- return nullptr;
+ assert(SyntaxVariant == 0);
+ return new WebAssemblyInstPrinter(MAI, MII, MRI);
}
// Force static initialization.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D11567.30835.patch
Type: text/x-patch
Size: 1027 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150728/3c13ec49/attachment.bin>
More information about the llvm-commits
mailing list