summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/MachineModuleInfoImpls.cpp
diff options
context:
space:
mode:
authorMichael Gottesman <mgottesman@apple.com>2013-04-03 02:57:24 +0000
committerMichael Gottesman <mgottesman@apple.com>2013-04-03 02:57:24 +0000
commitb8c8836594f75280ff7f632846e8f48c027afabe (patch)
treee48a0f7bae0b62904eebb6f457f2a8e37e0bf4b1 /llvm/lib/CodeGen/MachineModuleInfoImpls.cpp
parentbcd06c0220b2e3524aeefa4a7bf8f7f8d83db706 (diff)
downloadbcm5719-llvm-b8c8836594f75280ff7f632846e8f48c027afabe.tar.gz
bcm5719-llvm-b8c8836594f75280ff7f632846e8f48c027afabe.zip
Remove an optimization where we were changing an objc_autorelease into an objc_autoreleaseReturnValue.
The semantics of ARC implies that a pointer passed into an objc_autorelease must live until some point (potentially down the stack) where an autorelease pool is popped. On the other hand, an objc_autoreleaseReturnValue just signifies that the object must live until the end of the given function at least. Thus objc_autorelease is stronger than objc_autoreleaseReturnValue in terms of the semantics of ARC* implying that performing the given strength reduction without any knowledge of how this relates to the autorelease pool pop that is further up the stack violates the semantics of ARC. *Even though objc_autoreleaseReturnValue if you know that no RV optimization will occur is more computationally expensive. llvm-svn: 178612
Diffstat (limited to 'llvm/lib/CodeGen/MachineModuleInfoImpls.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud