diff options
| author | 2017-01-14 19:55:43 +0000 | |
|---|---|---|
| committer | 2017-01-14 19:55:43 +0000 | |
| commit | bd3306aecb3a15e8967143b8cdbbccf2b1b19b74 (patch) | |
| tree | 309a8132b44564b9e634c0da6815187ce8eab27c /gnu/llvm/utils/TableGen/CodeEmitterGen.cpp | |
| parent | killp -a should not kill the window if only one pane. (diff) | |
| download | wireguard-openbsd-bd3306aecb3a15e8967143b8cdbbccf2b1b19b74.tar.xz wireguard-openbsd-bd3306aecb3a15e8967143b8cdbbccf2b1b19b74.zip | |
Import LLVM 3.9.1 including clang and lld.
Diffstat (limited to 'gnu/llvm/utils/TableGen/CodeEmitterGen.cpp')
| -rw-r--r-- | gnu/llvm/utils/TableGen/CodeEmitterGen.cpp | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/gnu/llvm/utils/TableGen/CodeEmitterGen.cpp b/gnu/llvm/utils/TableGen/CodeEmitterGen.cpp index 46fcdf5e96f..400913e3274 100644 --- a/gnu/llvm/utils/TableGen/CodeEmitterGen.cpp +++ b/gnu/llvm/utils/TableGen/CodeEmitterGen.cpp @@ -15,7 +15,6 @@ #include "CodeGenTarget.h" #include "llvm/ADT/StringExtras.h" -#include "llvm/Support/CommandLine.h" #include "llvm/Support/Debug.h" #include "llvm/TableGen/Record.h" #include "llvm/TableGen/TableGenBackend.h" @@ -227,7 +226,7 @@ void CodeEmitterGen::run(raw_ostream &o) { // For little-endian instruction bit encodings, reverse the bit order Target.reverseBitsForLittleEndianEncoding(); - const std::vector<const CodeGenInstruction*> &NumberedInstructions = + ArrayRef<const CodeGenInstruction*> NumberedInstructions = Target.getInstructionsByEnumValue(); // Emit function declaration @@ -238,11 +237,7 @@ void CodeEmitterGen::run(raw_ostream &o) { // Emit instruction base values o << " static const uint64_t InstBits[] = {\n"; - for (std::vector<const CodeGenInstruction*>::const_iterator - IN = NumberedInstructions.begin(), - EN = NumberedInstructions.end(); - IN != EN; ++IN) { - const CodeGenInstruction *CGI = *IN; + for (const CodeGenInstruction *CGI : NumberedInstructions) { Record *R = CGI->TheDef; if (R->getValueAsString("Namespace") == "TargetOpcode" || |
