Codegen: [PPC] Silence false-positive initialization warning. NFC

Some compilers don't do exhaustive switch checking. For those compilers,
add an initialization to prevent un-initialized variable warnings from
firing. For compilers with exhaustive switch checking, we still get a
guarantee that the switch is exhaustive, and hence the initializations
are redundant, and a non-functional change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@257923 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Kyle Butt 2016-01-15 19:20:06 +00:00
parent 48b8a6c6a9
commit 644d34b2d4

View File

@ -746,8 +746,8 @@ void PPCInstrInfo::insertSelect(MachineBasicBlock &MBB,
unsigned OpCode = Is64Bit ? PPC::ISEL8 : PPC::ISEL;
auto SelectPred = static_cast<PPC::Predicate>(Cond[0].getImm());
unsigned SubIdx;
bool SwapOps;
unsigned SubIdx = 0;
bool SwapOps = false;
switch (SelectPred) {
case PPC::PRED_EQ:
case PPC::PRED_EQ_MINUS: