diff options
author | Eugene Zelenko <eugene.zelenko@gmail.com> | 2017-08-03 22:12:30 +0000 |
---|---|---|
committer | Eugene Zelenko <eugene.zelenko@gmail.com> | 2017-08-03 22:12:30 +0000 |
commit | 79220eaeecccf77591c0a1bdfbd2ecd3ec015e21 (patch) | |
tree | e3dd13872a6da5e46bde3a5aa89baa5fde9a99d4 /llvm/lib/Target/Mips/Disassembler/MipsDisassembler.cpp | |
parent | 1046aa31488b9c7cc6cfbe8847af699c7afb6887 (diff) | |
download | llvm-79220eaeecccf77591c0a1bdfbd2ecd3ec015e21.zip llvm-79220eaeecccf77591c0a1bdfbd2ecd3ec015e21.tar.gz llvm-79220eaeecccf77591c0a1bdfbd2ecd3ec015e21.tar.bz2 |
[Mips] Fix some Clang-tidy modernize-use-using and Include What You Use warnings; other minor fixes (NFC).
llvm-svn: 309993
Diffstat (limited to 'llvm/lib/Target/Mips/Disassembler/MipsDisassembler.cpp')
-rw-r--r-- | llvm/lib/Target/Mips/Disassembler/MipsDisassembler.cpp | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/llvm/lib/Target/Mips/Disassembler/MipsDisassembler.cpp b/llvm/lib/Target/Mips/Disassembler/MipsDisassembler.cpp index b0b9943..41b9657 100644 --- a/llvm/lib/Target/Mips/Disassembler/MipsDisassembler.cpp +++ b/llvm/lib/Target/Mips/Disassembler/MipsDisassembler.cpp @@ -11,6 +11,7 @@ // //===----------------------------------------------------------------------===// +#include "MCTargetDesc/MipsMCTargetDesc.h" #include "Mips.h" #include "llvm/ADT/ArrayRef.h" #include "llvm/MC/MCContext.h" @@ -32,7 +33,7 @@ using namespace llvm; #define DEBUG_TYPE "mips-disassembler" -typedef MCDisassembler::DecodeStatus DecodeStatus; +using DecodeStatus = MCDisassembler::DecodeStatus; namespace { @@ -286,10 +287,8 @@ static DecodeStatus DecodeLoadByte15(MCInst &Inst, uint64_t Address, const void *Decoder); -static DecodeStatus DecodeCacheOp(MCInst &Inst, - unsigned Insn, - uint64_t Address, - const void *Decoder); +static DecodeStatus DecodeCacheOp(MCInst &Inst, unsigned Insn, uint64_t Address, + const void *Decoder); static DecodeStatus DecodeCacheeOp_CacheOpR6(MCInst &Inst, unsigned Insn, @@ -367,17 +366,14 @@ static DecodeStatus DecodeFMemMMR2(MCInst &Inst, unsigned Insn, uint64_t Address, const void *Decoder); -static DecodeStatus DecodeFMem2(MCInst &Inst, unsigned Insn, - uint64_t Address, - const void *Decoder); +static DecodeStatus DecodeFMem2(MCInst &Inst, unsigned Insn, uint64_t Address, + const void *Decoder); -static DecodeStatus DecodeFMem3(MCInst &Inst, unsigned Insn, - uint64_t Address, - const void *Decoder); +static DecodeStatus DecodeFMem3(MCInst &Inst, unsigned Insn, uint64_t Address, + const void *Decoder); static DecodeStatus DecodeFMemCop2R6(MCInst &Inst, unsigned Insn, - uint64_t Address, - const void *Decoder); + uint64_t Address, const void *Decoder); static DecodeStatus DecodeFMemCop2MMR6(MCInst &Inst, unsigned Insn, uint64_t Address, @@ -581,7 +577,8 @@ static unsigned getReg(const void *D, unsigned RC, unsigned RegNo) { template <typename InsnType> static DecodeStatus DecodeINSVE_DF(MCInst &MI, InsnType insn, uint64_t Address, const void *Decoder) { - typedef DecodeStatus (*DecodeFN)(MCInst &, unsigned, uint64_t, const void *); + using DecodeFN = DecodeStatus (*)(MCInst &, unsigned, uint64_t, const void *); + // The size of the n field depends on the element size // The register class also depends on this. InsnType tmp = fieldFromInstruction(insn, 17, 5); |