OSDN Git Service

Remove unused variables. No functionality change.
authorBenjamin Kramer <benny.kra@googlemail.com>
Sun, 8 Oct 2017 19:11:02 +0000 (19:11 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Sun, 8 Oct 2017 19:11:02 +0000 (19:11 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@315185 91177308-0d34-0410-b5e6-96231b3b80d8

12 files changed:
lib/AsmParser/LLParser.cpp
lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp
lib/MC/MCParser/AsmParser.cpp
lib/MC/MCParser/ELFAsmParser.cpp
lib/Support/FormatVariadic.cpp
lib/Target/AArch64/InstPrinter/AArch64InstPrinter.cpp
lib/Target/Hexagon/HexagonISelDAGToDAG.cpp
lib/Target/Hexagon/HexagonISelLowering.cpp
lib/Target/PowerPC/PPCISelDAGToDAG.cpp
tools/llvm-readobj/ELFDumper.cpp
unittests/Support/BinaryStreamTest.cpp

index 52c5b9f..b9b66ba 100644 (file)
@@ -4778,7 +4778,6 @@ bool LLParser::ParseFunctionHeader(Function *&Fn, bool isDefine) {
   unsigned Alignment;
   std::string GC;
   GlobalValue::UnnamedAddr UnnamedAddr = GlobalValue::UnnamedAddr::None;
-  LocTy UnnamedAddrLoc;
   Constant *Prefix = nullptr;
   Constant *Prologue = nullptr;
   Constant *PersonalityFn = nullptr;
@@ -5572,7 +5571,6 @@ bool LLParser::ParseCatchRet(Instruction *&Inst, PerFunctionState &PFS) {
 ///   ::= 'catchswitch' within Parent
 bool LLParser::ParseCatchSwitch(Instruction *&Inst, PerFunctionState &PFS) {
   Value *ParentPad;
-  LocTy BBLoc;
 
   if (ParseToken(lltok::kw_within, "expected 'within' after catchswitch"))
     return true;
index 1294228..3d320a9 100644 (file)
@@ -3908,7 +3908,6 @@ void SelectionDAGLegalize::ConvertNodeToLibcall(SDNode *Node) {
   DEBUG(dbgs() << "Trying to convert node to libcall\n");
   SmallVector<SDValue, 8> Results;
   SDLoc dl(Node);
-  SDValue Tmp1, Tmp2, Tmp3, Tmp4;
   unsigned Opc = Node->getOpcode();
   switch (Opc) {
   case ISD::ATOMIC_FENCE: {
index b283941..fa35b31 100644 (file)
@@ -1955,7 +1955,7 @@ SDValue DAGTypeLegalizer::SplitVecOp_MSCATTER(MaskedScatterSDNode *N,
   else
     std::tie(IndexLo, IndexHi) = DAG.SplitVector(Index, DL);
 
-  SDValue Lo, Hi;
+  SDValue Lo;
   MachineMemOperand *MMO = DAG.getMachineFunction().
     getMachineMemOperand(N->getPointerInfo(),
                          MachineMemOperand::MOStore, LoMemVT.getStoreSize(),
index 9568394..186f339 100644 (file)
@@ -3617,7 +3617,6 @@ bool AsmParser::parseDirectiveCVInlineSiteId() {
 /// optional items are .loc sub-directives.
 bool AsmParser::parseDirectiveCVLoc() {
   SMLoc DirectiveLoc = getTok().getLoc();
-  SMLoc Loc;
   int64_t FunctionId, FileNumber;
   if (parseCVFunctionId(FunctionId, ".cv_loc") ||
       parseCVFileId(FileNumber, ".cv_loc"))
index 8b8e96a..38720c2 100644 (file)
@@ -488,7 +488,6 @@ bool ELFAsmParser::ParseSectionArguments(bool IsPush, SMLoc loc) {
   unsigned Flags = 0;
   const MCExpr *Subsection = nullptr;
   bool UseLastGroup = false;
-  StringRef UniqueStr;
   MCSymbolELF *Associated = nullptr;
   int64_t UniqueID = ~0;
 
index de61dae..6dd133e 100644 (file)
@@ -91,8 +91,6 @@ formatv_object_base::parseReplacementItem(StringRef Spec) {
 
 std::pair<ReplacementItem, StringRef>
 formatv_object_base::splitLiteralAndReplacement(StringRef Fmt) {
-  StringRef Rep;
-  StringRef Remainder;
   std::size_t From = 0;
   while (From < Fmt.size() && From != StringRef::npos) {
     std::size_t BO = Fmt.find_first_of('{', From);
index 1e18a5c..62e5d02 100644 (file)
@@ -689,7 +689,7 @@ void AArch64AppleInstPrinter::printInst(const MCInst *MI, raw_ostream &O,
                                         StringRef Annot,
                                         const MCSubtargetInfo &STI) {
   unsigned Opcode = MI->getOpcode();
-  StringRef Layout, Mnemonic;
+  StringRef Layout;
 
   bool IsTbx;
   if (isTblTbxInstruction(MI->getOpcode(), Layout, IsTbx)) {
index 7440537..2c40a1b 100644 (file)
@@ -1319,7 +1319,6 @@ bool HexagonDAGToDAGISel::DetectUseSxtw(SDValue &N, SDValue &R) {
 
   if (N.getValueType() != MVT::i64)
     return false;
-  EVT SrcVT;
   unsigned Opc = N.getOpcode();
   switch (Opc) {
     case ISD::SIGN_EXTEND:
index 0d2b27f..ef0536a 100644 (file)
@@ -978,7 +978,6 @@ bool HexagonTargetLowering::getPostIndexedAddressParts(SDNode *N, SDNode *Op,
                                                        SelectionDAG &DAG) const
 {
   EVT VT;
-  SDValue Ptr;
 
   if (LoadSDNode *LD = dyn_cast<LoadSDNode>(N)) {
     VT  = LD->getMemoryVT();
index 9454ed8..8ea3689 100644 (file)
@@ -579,8 +579,6 @@ bool PPCDAGToDAGISel::tryBitfieldInsert(SDNode *N) {
 
     unsigned MB, ME;
     if (isRunOfOnes(InsertMask, MB, ME)) {
-      SDValue Tmp1, Tmp2;
-
       if ((Op1Opc == ISD::SHL || Op1Opc == ISD::SRL) &&
           isInt32Immediate(Op1.getOperand(1), Value)) {
         Op1 = Op1.getOperand(0);
index 2619121..037ffd2 100644 (file)
@@ -2396,7 +2396,6 @@ template <class ELFT> void ELFDumper<ELFT>::printStackMap() const {
   if (!StackMapSection)
     return;
 
-  StringRef StackMapContents;
   ArrayRef<uint8_t> StackMapContentsArray =
       unwrapOrError(Obj->getSectionContents(StackMapSection));
 
index e257583..005ec9f 100644 (file)
@@ -535,7 +535,6 @@ TEST_F(BinaryStreamTest, StreamReaderEnum) {
 
     BinaryStreamReader Reader(*Stream.Input);
 
-    ArrayRef<MyEnum> Array;
     FixedStreamArray<MyEnum> FSA;
 
     for (size_t I = 0; I < Enums.size(); ++I) {