diff --git a/lib/Transforms/ObjCARC/ObjCARCOpts.cpp b/lib/Transforms/ObjCARC/ObjCARCOpts.cpp index e6c5928375f..a045582d532 100644 --- a/lib/Transforms/ObjCARC/ObjCARCOpts.cpp +++ b/lib/Transforms/ObjCARC/ObjCARCOpts.cpp @@ -2581,6 +2581,11 @@ ObjCARCOpt::ConnectTDBUTraversals(DenseMap // long as the existing imbalances are maintained. if (OldDelta != 0) return false; + +#ifdef ARC_ANNOTATIONS + // Do not move calls if ARC annotations are requested. + return false; +#endif // ARC_ANNOTATIONS Changed = true; assert(OldCount != 0 && "Unreachable code?"); @@ -2644,12 +2649,6 @@ ObjCARCOpt::PerformCodePlacement(DenseMap ReleasesToMove, Arg, KnownSafe, AnyPairsCompletelyEliminated); -#ifdef ARC_ANNOTATIONS - // Do not move calls if ARC annotations are requested. If we were to move - // calls in this case, we would not be able - PerformMoveCalls = PerformMoveCalls && !EnableARCAnnotations; -#endif // ARC_ANNOTATIONS - if (PerformMoveCalls) { // Ok, everything checks out and we're all set. Let's move/delete some // code!