clang-format a bit of code to make the next patch easier to read.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203203 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Rafael Espindola 2014-03-07 05:32:03 +00:00
parent 49dd5e831b
commit ec7ab53570
3 changed files with 99 additions and 115 deletions

View File

@ -22,7 +22,7 @@ namespace llvm {
/// must be the same as in CodeGenTarget.cpp. /// must be the same as in CodeGenTarget.cpp.
/// ///
namespace TargetOpcode { namespace TargetOpcode {
enum { enum {
PHI = 0, PHI = 0,
INLINEASM = 1, INLINEASM = 1,
PROLOG_LABEL = 2, PROLOG_LABEL = 2,
@ -105,7 +105,7 @@ namespace TargetOpcode {
/// rewrite calls to runtimes with more efficient code sequences. /// rewrite calls to runtimes with more efficient code sequences.
/// This also implies a stack map. /// This also implies a stack map.
PATCHPOINT = 18 PATCHPOINT = 18
}; };
} // end namespace TargetOpcode } // end namespace TargetOpcode
} // end namespace llvm } // end namespace llvm

View File

@ -294,27 +294,11 @@ GetInstByName(const char *Name,
void CodeGenTarget::ComputeInstrsByEnum() const { void CodeGenTarget::ComputeInstrsByEnum() const {
// The ordering here must match the ordering in TargetOpcodes.h. // The ordering here must match the ordering in TargetOpcodes.h.
static const char *const FixedInstrs[] = { static const char *const FixedInstrs[] = {
"PHI", "PHI", "INLINEASM", "PROLOG_LABEL", "EH_LABEL",
"INLINEASM", "GC_LABEL", "KILL", "EXTRACT_SUBREG", "INSERT_SUBREG",
"PROLOG_LABEL", "IMPLICIT_DEF", "SUBREG_TO_REG", "COPY_TO_REGCLASS", "DBG_VALUE",
"EH_LABEL", "REG_SEQUENCE", "COPY", "BUNDLE", "LIFETIME_START",
"GC_LABEL", "LIFETIME_END", "STACKMAP", "PATCHPOINT", 0};
"KILL",
"EXTRACT_SUBREG",
"INSERT_SUBREG",
"IMPLICIT_DEF",
"SUBREG_TO_REG",
"COPY_TO_REGCLASS",
"DBG_VALUE",
"REG_SEQUENCE",
"COPY",
"BUNDLE",
"LIFETIME_START",
"LIFETIME_END",
"STACKMAP",
"PATCHPOINT",
0
};
const DenseMap<const Record*, CodeGenInstruction*> &Insts = getInstructions(); const DenseMap<const Record*, CodeGenInstruction*> &Insts = getInstructions();
for (const char *const *p = FixedInstrs; *p; ++p) { for (const char *const *p = FixedInstrs; *p; ++p) {
const CodeGenInstruction *Instr = GetInstByName(*p, Insts, Records); const CodeGenInstruction *Instr = GetInstByName(*p, Insts, Records);