IOS RAM usage and Framework -


i working on ios , performances , have question!

first, have implemented complete application native sdk. added source code in main bundle of application.

then, have implemented same application 5 custom frameworks (.framework). have extracted source code independent application. example, have framework manages http requests (sending, getting response ...).

finally, have examined ram used 2 applications. that, closed applications in background on iphone 5s. then, have launched each application version , have examined free ram. when compared 2 results, note when first application launched, free ram 272,39 mo (the second 1 closed). whereas, when second application launched, free ram 325,33 mo (the first 1 closed).

to free memory. used method:

vm_size_t freememory(void) {    mach_port_t host_port = mach_host_self();    mach_msg_type_number_t host_size = sizeof(vm_statistics_data_t) / sizeof(integer_t);    vm_size_t pagesize;    vm_statistics_data_t vm_stat;     host_page_size(host_port, &pagesize);    (void) host_statistics(host_port, host_vm_info, (host_info_t)&vm_stat, &host_size);    return vm_stat.free_count * pagesize; } 

so, don't understand difference. think frameworks loaded in ram when use them in application , not when application launched first time. right? if right. when use framework, how load time of framework? try use instrument time profiler don't see seems framework loading.

thanks advance answer. best regards.

ps: sorry english, french!


Comments

Popular posts from this blog

python - Subclassed QStyledItemDelegate ignores Stylesheet -

java - HttpClient 3.1 Connection pooling vs HttpClient 4.3.2 -

SQL: Divide the sum of values in one table with the count of rows in another -