From 232778a7a06a57709591eb28c6475026197b0d09 Mon Sep 17 00:00:00 2001 From: Daniel Jasper Date: Thu, 30 Apr 2015 09:01:21 +0000 Subject: [PATCH] Silence unused warning in non-assert builds. llvm-svn: 236213 --- llvm/lib/Target/X86/X86ISelDAGToDAG.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp b/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp index 5bbe18e..ca1a30c 100644 --- a/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp +++ b/llvm/lib/Target/X86/X86ISelDAGToDAG.cpp @@ -1344,8 +1344,9 @@ bool X86DAGToDAGISel::SelectVectorAddr(SDNode *Parent, SDValue N, SDValue &Base, Scale = getI8Imm(ScalarSize/8, DL); // If Base is 0, the whole address is in index and the Scale is 1 - if (ConstantSDNode *C = dyn_cast(Base)) { - assert(C->isNullValue() && "Unexpected base in gather/scatter"); + if (isa(Base)) { + assert(dyn_cast(Base)->isNullValue() && + "Unexpected base in gather/scatter"); Scale = getI8Imm(1, DL); Base = CurDAG->getRegister(0, MVT::i32); } -- 2.7.4