[llvm] a954ade - [X86][NFC] Generate mnemonic tables
Amir Ayupov via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 18 01:46:52 PDT 2022
Author: Amir Ayupov
Date: 2022-03-18T01:46:48-07:00
New Revision: a954ade8ed414ffee12fa7233bef049aea2ed75b
URL: https://github.com/llvm/llvm-project/commit/a954ade8ed414ffee12fa7233bef049aea2ed75b
DIFF: https://github.com/llvm/llvm-project/commit/a954ade8ed414ffee12fa7233bef049aea2ed75b.diff
LOG: [X86][NFC] Generate mnemonic tables
Produce mnemonic tables, adding the functions to llvm::X86 namespace.
Reviewed By: MaskRay, skan
Differential Revision: https://reviews.llvm.org/D121572
Added:
llvm/lib/Target/X86/MCTargetDesc/X86MnemonicTables.cpp
Modified:
llvm/lib/Target/X86/CMakeLists.txt
llvm/lib/Target/X86/MCTargetDesc/CMakeLists.txt
llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h
Removed:
################################################################################
diff --git a/llvm/lib/Target/X86/CMakeLists.txt b/llvm/lib/Target/X86/CMakeLists.txt
index 5dc4920f58245..1438da0a457b8 100644
--- a/llvm/lib/Target/X86/CMakeLists.txt
+++ b/llvm/lib/Target/X86/CMakeLists.txt
@@ -13,6 +13,7 @@ tablegen(LLVM X86GenExegesis.inc -gen-exegesis)
tablegen(LLVM X86GenFastISel.inc -gen-fast-isel)
tablegen(LLVM X86GenGlobalISel.inc -gen-global-isel)
tablegen(LLVM X86GenInstrInfo.inc -gen-instr-info)
+tablegen(LLVM X86GenMnemonicTables.inc -gen-x86-mnemonic-tables -asmwriternum=1)
tablegen(LLVM X86GenRegisterBank.inc -gen-register-bank)
tablegen(LLVM X86GenRegisterInfo.inc -gen-register-info)
tablegen(LLVM X86GenSubtargetInfo.inc -gen-subtarget)
diff --git a/llvm/lib/Target/X86/MCTargetDesc/CMakeLists.txt b/llvm/lib/Target/X86/MCTargetDesc/CMakeLists.txt
index cb76702984361..36f7bf1f9d073 100644
--- a/llvm/lib/Target/X86/MCTargetDesc/CMakeLists.txt
+++ b/llvm/lib/Target/X86/MCTargetDesc/CMakeLists.txt
@@ -10,6 +10,7 @@ add_llvm_component_library(LLVMX86Desc
X86MCAsmInfo.cpp
X86MCCodeEmitter.cpp
X86MachObjectWriter.cpp
+ X86MnemonicTables.cpp
X86ELFObjectWriter.cpp
X86WinCOFFObjectWriter.cpp
X86WinCOFFStreamer.cpp
diff --git a/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h b/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h
index 9c927c7c76e2a..d0530bd4d6505 100644
--- a/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h
+++ b/llvm/lib/Target/X86/MCTargetDesc/X86MCTargetDesc.h
@@ -163,4 +163,7 @@ MCRegister getX86SubSuperRegisterOrZero(MCRegister, unsigned,
#define GET_SUBTARGETINFO_ENUM
#include "X86GenSubtargetInfo.inc"
+#define GET_X86_MNEMONIC_TABLES_H
+#include "X86GenMnemonicTables.inc"
+
#endif
diff --git a/llvm/lib/Target/X86/MCTargetDesc/X86MnemonicTables.cpp b/llvm/lib/Target/X86/MCTargetDesc/X86MnemonicTables.cpp
new file mode 100644
index 0000000000000..39b7f0f4160e9
--- /dev/null
+++ b/llvm/lib/Target/X86/MCTargetDesc/X86MnemonicTables.cpp
@@ -0,0 +1,16 @@
+//===-- X86MnemonicTables.cpp - X86 Mnemonic Tables -------------*- C++ -*-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+//
+// This file provides X86 mnemonic tables.
+//
+//===----------------------------------------------------------------------===//
+
+#include "X86InstrInfo.h"
+
+#define GET_X86_MNEMONIC_TABLES_CPP
+#include "X86GenMnemonicTables.inc"
More information about the llvm-commits
mailing list