官方: https://developer.apple.com/library/ios/documentation/General/Conceptual/CocoaTouch64BitGuide/Introduction/Introduction.html https://developer.apple.com/library/ios/documentation/General/Conceptual/CocoaTouch64BitGuide/OptimizingMemoryPerformance/OptimizingMemoryPerformance.html#//apple_ref/doc/uid/TP40013501-CH4-SW1 目前ios的指令集有以下几种:
================================================ Architecture : 指你想支持的指令集。 Valid architectures : 指即将编译的指令集。 Build Active Architecture Only : 只是否只编译当前适用的指令集。 ================================================ 现在是2014年初,其实4和4S的用户还是蛮多的,而iphone3之类的机器几乎没有了,所以我们的指令集最低必须基于armv7. 因此,Architecture的值选择:armv7 armv7s arm64 PS:选arm64时需要最低支持5.1.1: Convert Your App to a 64-Bit Binary After Updating It for iOS 7 Xcode 5.0.1 can build your app with both 32-bit and 64-bit binaries included. This combined binary requires a minimum deployment target of iOS 5.1.1 or later. The 64-bit binary runs only on 64-bit devices running iOS 7.0.3 and later. If you have an existing app, you should first update your app for iOS 7 and then port it to run on 64-bit processors. By updating it first for iOS 7, you can remove deprecated code paths and use modern practices. If you’re creating a new app, target iOS 7 and compile 32-bit and 64-bit versions of your app. The architecture for 64-bit apps on iOS is almost identical to the architecture for OS X apps, making it easy to create a common code base that runs in both operating systems. Converting a Cocoa Touch app to 64-bit follows a similar transition process as the one for Cocoa apps on OS X. Pointers and some common C types change from 32 bits to 64 bits. Code that relies on the NSInteger and CGFloat types needs to be carefully examined. Start by building the app for the 64-bit runtime, fixing any warnings that occur as well as searching your code for specific 64-bit issues. For example:
2,如果想让app体积保持最小,则现阶段应该选择Valid architectures为armv7,这样Build Active Architecture Only选YES或NO就无所谓了 |
xcode armv6 armv7 armv7s arm64
最新推荐文章于 2024-07-19 18:21:24 发布