CFArray vs NSArray Performance on iOS
An application that I’m currently working requires making the drop to the CoreFoundation level so out of curiosity I decided to contrast and compare the performance difference associated with using the Foundation-level
NSArray object versus its CoreFoundation counterpart –
CFArray. To be more precise, in this test we are exploring the performance difference of iterating over the mutable version of both objects, inserting a string, getting the array count (to replicate a real-world scenario where the array size is not given) and retrieving the element at index. This is a brutally simple test, but will hopefully provide at least some insight into how fast each method really is in comparison.