diff --git a/lib/SILPasses/SILCodeMotion.cpp b/lib/SILPasses/SILCodeMotion.cpp index 2ee39e0543e..337e5186a5c 100644 --- a/lib/SILPasses/SILCodeMotion.cpp +++ b/lib/SILPasses/SILCodeMotion.cpp @@ -133,12 +133,10 @@ static bool canSinkInstruction(SILInstruction *Inst) { /// we can't sink other instructions past it. static bool isSinkBarrier(SILInstruction *Inst) { // We know that some calls do not have side effects. - if (const ApplyInst *AI = dyn_cast(Inst)) { + if (const ApplyInst *AI = dyn_cast(Inst)) if (BuiltinFunctionRefInst *FR = - dyn_cast(AI->getCallee().getDef())) { + dyn_cast(AI->getCallee().getDef())) return !isSideEffectFree(FR); - } - } if (isa(Inst)) return false;