iOS Development-Interview Summary (16)

Source: Internet
Author: User

Memory issues

One: Cell phone memory capacity

  • The latest Apple phone iphone6s (plus) now has 2GB of running memory.
  • IPhone5, IPhone5S, and IPhone6 (plus) run memory at 1GB.
  • IPhone4 and Iphone4s run memory at 512MB.

Two: App running memory

  • It is recommended not to exceed 10M. If the user only runs a program memory is used can be around 30M.
  • But the odds are almost impossible.
  • Generally more than 10M will be memory warning L1 system will kill some of the unused view


Test results of foreign Daniel
So it turns out if you allocate (and use!) around 46-50 MB in your iPhone application it'll just get terminated.

How to keep memory (running) occupied not too high?

    • 1. Tableviewcell in the icon image to be trimmed, do not put those 1M or so images directly from the web side to transfer over
    • 2. Some of the more deep, or more loop code block, as far as possible in the outer layer autorelease pool, after execution directly [pool drain]
    • 3. TableView cell must be reuse, other similar view to reuse.

iOS Development-Interview Summary (16)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.