4

Are the screenshots of apps in the app switcher stored in RAM, or are they instead stored in flash, and streamed directly to the GPU via some kind of DMA (direct memory access) connection?

RAM is precious, and after a few days I end up with a lot of apps in my app switcher. Are all those snapshots constantly using up RAM?

  • Your question is a bit unclear right now. Are you referring to another post and ask a followup question, are you offering an explanation and look for approval/references, or something else altogether? – nohillside Aug 5 '17 at 6:57
  • Feel free to roll back to the first version if you wish - it’s clear you don’t like the edits so let’s have this stand on your words, vonlost. – bmike Aug 5 '17 at 16:14
  • 1
    I’ve reverted this question to an earlier revision that better reflects the spirit of the original question. I get what @vonlost is getting at. Modern GPU’s can operate independently of the CPU, and vice versa. There are many applications (including 3D games, and any other applications that process large datasets on the GPU) that stream data directly from storage into the GPU’s internal memory or framebuffer (bypassing central RAM). I wouldn’t be surprised if this was an integral part of Metal, due to its clear performance benefits for all Metal apps. – user11633 Aug 5 '17 at 20:43
1

They survive a restart so they canonically exist in storage.

Of course, everything you see on screen has to be in RAM, too; so the answer is both.

  • 2
    We should also point out such small PNGs take up about 30kiB of memory, and I expect Apple compresses them. So even with 100 app snapshots in the app switcher, we’re talking about 3 MiB of memory at most. Not exactly worth micro-managing, as an end-user. – user11633 Aug 5 '17 at 14:35
  • "everything you see on screen has to be in RAM" – vonlost Aug 5 '17 at 15:49
  • "everything you see on screen has to be in RAM" This was the gist of my question (which was edited out): Is there a "DMA" path from flash to GPU; apparently not. Thanks. – vonlost Aug 5 '17 at 15:55
  • The title seems to have always asked where is it stored and not how it gets composited / processed / rendered. You might need a second question with some details if you’re going to get into the layers of composition that take images and the transform them into a graphics buffer. – bmike Aug 5 '17 at 16:02
  • 1
    My look at the first draft is the first post had no details, just conjecture that somehow stored images use RAM @vonlost . My point is you have one screen buffer in RAM and it doesn’t matter what makes up the content of that buffer from moment to moment at a high level. Details like “this screenshot shows me running instruments on a specific hardware with a specific iOS” would set the stage for a more productive Q&A since we could all focus on what you seek to learn. – bmike Aug 5 '17 at 16:11
1

I forgot the precise location, but they are either stored in the data folder of the application, or the app's cache folder in the filesystem (probably was both on iOS 9 – can't speak for newer iOS versions). This is possible to see if you have read access to the filesystem (such as when you are jailbroken)

0

From what I remember the state should be saved under the user library directory (probably only accessible jailbroken) and, if following the OS X method, should be stored in a parent directory called SavedApplicationState and children directories inside it will be named after their identifiers (e.g., com.apple.Safari).

The preview png should be in there but I'm not totally sure of the name/location.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .