Skip to content

Comment on John Gruber: The iPadparent

Comments

Virtual memory (memory paging and segmentation) is the foundation for being able to start and stop apps. Otherwise memory would have to be defragmented. Both don't require the ability to store somewhere, they both are useful in physical memory only situations.

I think what he means in the article is that Apple disabled Mach's ability to store memory pages on disk in order to free room for more physical memory. The most probable reason being that Apple does not trust the lifetime write capacity of their Flash disk. (And depending on your chicken and egg, the current App situation does not require swapping memory pages to disk since you can only run one App at a time. Which caused the other I don't know.)

I'd guess the most probable reason is to reduce interface stuttering.

Interface stuttering due to swap is an issue on PC's due to hard drive latency, but would it be as much of an issue with solid state storage?

Well, even assuming that they're using top quality solid state storage, you're going from (at worst) hundreds of nanoseconds per retrieval to (at best) a hundred microseconds per (page) retrieval. Still very significant for some data access patterns.

My question wasn't about the article.

My question was how much fragmentation is there on iPhone to warrant VM. It has fixed memory and runs only one app at a time (mostly).

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.