How can I get the iOS device CPU architecture in runtime

前端 未结 3 1549
后悔当初
后悔当初 2020-12-04 23:19

Is there a way to identify the iOS device CPU architecture in runtime?

Thank you.

3条回答
  •  佛祖请我去吃肉
    2020-12-04 23:30

    I think this is the better way,

    #import 
    
    NXArchInfo *info = NXGetLocalArchInfo();
    NSString *typeOfCpu = [NSString stringWithUTF8String:info->description];
    //typeOfCpu = "arm64 v8"
    

提交回复
热议问题