Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

zhaoxin

macrumors 6502
Original poster
Jan 28, 2015
309
65
I thought memory pressure would only turns yellow after swap was used. But I was wrong. Today, memory pressure turned yellow but the swap was zero.

截屏2023-05-20 20.25.06.png


It was caused by Xcode when I was previewing an iOS app's SwiftUI view.

So it means that my system encounter its limit? My Mac: Mac mini M1 16GB 512GB.
 
Given that Xcode is using just over 1/3 the memory of the top entry on that list (and less that 1/5th of the threads), I don't think it is the cause of that issue...
 
Given that Xcode is using just over 1/3 the memory of the top entry on that list (and less that 1/5th of the threads), I don't think it is the cause of that issue...
I don't think the amount of memory bother here. If the amount is the reason, the memory pressure should never be yellow as the memory is more than sufficient as the swap is zero. Memory pressure is said basing on over thousands of parameters of the kernel. My theory is that iOS simulator Xcode created in memory made some parts of the memory slow down, which causing the issue.

But I don't know whether this should be considered as a bug. As the memory used by iOS simulator is only accessed by Xcode. So it should have no slow-down effects of the whole system. And the memory pressure should not be yellow in this situation.
 
The most significant affect of memory changing is the compressed memory. After Xcode runs iOS simulator to preview SwiftUI View, the compressed memory will increase over 3GB to nearly 6GB and the memory pressure turns yellow. So I guess the radio of compressed memory to the total memory is something important to the memory pressure.
 
yeah that graph is questionable at times. Ive had 20gb+ of swap and it would still be tiny strip of green even though the system was chugging. I take you have plenty of free space on the startup drive?
 
yeah that graph is questionable at times. Ive had 20gb+ of swap and it would still be tiny strip of green even though the system was chugging. I take you have plenty of free space on the startup drive?
Yes. I have over 200GB free space on my SSD.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.