Seriously words I never imagined I would hear coming from a developer ?battery only lasts around 8 to 10 hours
Seriously words I never imagined I would hear coming from a developer ?battery only lasts around 8 to 10 hours
but youtubers say it doesn't matter!From the very beginning, rule #1 with Mac: get RAM as much as possible!
Power PC, Intel, M1, no difference, macOS always is RAM lover.
Currently, on MBPro 15 (2019, 32GB RAM):
1. Opened Safari (5 tabs)
2. Opened Mail
3. Opened iMessages
4. Calendar
5. Apple Music (streaming radio)
6. Notes
7. Endpoint security
8. Microsoft Remote Desktop
Guess, how much RAM is used? This, where even Swap is created:
View attachment 1680872
Mmm... The OP is a smart enough cookie to know that this was going to happen and even if they didn't, then it was easily explainable with the memory hogs applications that are still running via R2. I think the OP just wanted to mitch and boan about it. The OP could quite easily have posted this in a different way and got to the bottom of the issue, so that's why I'm calling it a troll.Oh, I don't think so. Just discovering that their past usage won't fit their new equipment in every respect. Looks like they've narrowed down the main issue to one particular program.
The guy you're replying to isn't proving anything except that MacOS doesn't like to waste memory by having it sit idle, which has been known for a long time.but youtubers say it doesn't matter!
There is nothing magical about the M1's RAM usage, 16GB is 16GB which is on the low side for a developer's machine. I think an M1 with 16GB of Ram is fine for an iOS or MacOS developer just using Xcode but for Android developers or full stack Web developers not so much. The Jet Brains IDEs are RAM hungry Java based IDEs that use a JVM built for Intel.Based on the m1 benchmark results, it already beat 16'' mac pro 2019. the CPU and SSD performances are much higher than my 3-year old ThinkPad L570.
IMO, it should not be considered as a low-end machine except only 16GB ram
Using the very fast swap to preserve the lifespan of the SSD would be a damn good reason for it.Swap gets used because there is no reason in storing a bunch of data in the very fast ram when the system knows it doesn't need it any time soon.
Look at his memory pressure. It's non existent. There's no actual demand for memory at all.
Swap gets used because there is no reason in storing a bunch of data in the very fast ram when the system knows it doesn't need it any time soon.
Just to be clear though, those Linux VMs will run ARM linux. Most of the internet is running on x86 Linux.M1 supports virtualisation so Linux VMs and even Android simulator should hopefully be coming once the software is updated. VMs are another thing you need lots of RAM for, though!
Except for Amazon and their custom Graviton cloud servers. And the hundreds of millions of devices which use a variation of Linux called Android. And the 30 million+ Raspberry Pi computers. And then there is Google’s Whitechapel.Just to be clear though, those Linux VMs will run ARM linux. Most of the internet is running on x86 Linux.
Ironically, running an Android emulator on a Mac requires x86 virtualization. No doubt that will change soon enough but when I say "Most of the internet is running on x86 Linux" I am referring to the servers not embedded or mobile devices.Except for Amazon and their custom Graviton cloud servers. And the hundreds of millions of devices which use a variation of Linux called Android. And the 30 million+ Raspberry Pi computers. And then there is Google’s Whitechapel.
Not trying to be a jerk here, but just pointing out that there is an industry-wide migration from X86 to ARM for Linux. It won’t be long before the majority of Linux is running on ARM; and arguably it has already happened if you count embedded. So much optimization has gone into the Linux kernel for ARM already; the userspace tools will catch up quickly.
I think even Microsoft would tell you privately they expect their future servers to run on ARM more than X86, although they will likely be the last to jump ship.
X86 just isn’t cost competitive anymore. Nor is it energy competitive.
Apple’s timing here is especially good. All those Silicon Valley developers can now carry their MacBooks proudly again, knowing they have a fast ARM toolchain onboard. It will be bumpy for a few months for sure, but this is the moment.
Swapping is the first sign you are running out of memory, and most operating systems avoid it by default until they have no other reasonable options. macOS often starts swapping before memory pressure leaves green, which makes memory pressure an unreliable indicator for some applications.And I'm less clear on this but I'm reasonably certain: even a system with no appreciable memory pressure will swap some stuff out from time to time (increasing with uptime), and even some swapping in. You load an app that loads various frameworks and data, some of which are potentially shared; you stop using it actively but (acc to some system rules) it makes more sense to keep that in 'active swapped' rather than close it out and reload completely. If the swap drive is a fast SSD, this occasional swapping may not be noticeable (depending on task and other load); with an HDD, you notice all disk access/swap as slow.
true. been explaining this before to lot of people. swap and page is bad. If we can reduce default service not importantSwapping is the first sign you are running out of memory, and most operating systems avoid it by default until they have no other reasonable options. macOS often starts swapping before memory pressure leaves green, which makes memory pressure an unreliable indicator for some applications.
Caching and swapping are based on very similar heuristics, and sometimes those heuristics guess wrong. The reason why dropping pages from cached files is more acceptable than swapping out memory pages is mostly semantics. When a program reads from a file, the developer expects that there can be delays. If the caching heuristic guesses wrong and drops a page that is soon accessed again, there will be an expected delay. On the other hand, if something is placed in memory, the developer expects it can be accessed without substantial delays. If the swapping heuristic guesses wrong, the results can be much more severe.
Modern SSDs are 10-20x slower than RAM by transfer rate but at least 1000x slower by latency. Some applications keep large indexes in memory and access them in unpredictable patterns. If the index is sufficiently large, most of its memory pages always show up as "not recently used", which makes them prime candidates for swapping out. Because SSD is at least 1000x slower than memory, swapping out even a few percent of the index may result in a massive drop in performance. Once this starts, memory pressure will often quickly jump from green to yellow or red, while actual memory usage remains the same.
I use and develop software that behaves like this, and I find the memory pressure indicator mostly useless. I would prefer memory pressure to jump to yellow as soon as the OS starts swapping pages out, telling the user that something may be wrong. (I would also prefer higher memory pressure impact from compressed memory, because it increases latency in a similar way.)
Imo 10 hours battery life with that kind of load (with plenty of emulated apps) is amazing. I have yet seen a Windows laptop with more than 5 to 6 hours of battery life with normal use, let alone that kind of load.My mac: 16GB m1 pro with 512ssd, booked online and got it 4 days ago
Main Payload: terminal+react native + ios simulator, chrome 10+ tabs, firefox 10+ tabs, vscode, android studio and an extra monitor
Result: it hot than my windows10 ThinkPad L570 laptop(32GB,i7) and the fan is running sometimes
And the battery only lasts around 8 to 10 hours if using the battery with the same payload.
This is around 75% of my normal workload as a full stack developer and I feel this pro mac almost reach its limit.
Does anyone have similar feelings? or is there something wrong of this mac?
View attachment 1680414
What kind of software is this?Some applications keep large indexes in memory and access them in unpredictable patterns. If the index is sufficiently large, most of its memory pages always show up as "not recently used", which makes them prime candidates for swapping out. Because SSD is at least 1000x slower than memory, swapping out even a few percent of the index may result in a massive drop in performance. ....
I use and develop software that behaves like this, and I find the memory pressure indicator mostly useless.
In my case it's bioinformatics, but the pattern is also used in other kinds of data science. When comparing two datasets, it's common to index one of them, keep the index in memory, and stream the second dataset from disk. This is not a common use case for consumer laptops, but it's common enough for student laptops, and students often buy entry-level Macs.What kind of software is this?
Does not sound like a typical use case for entry level laptop or macmini level.
Memory pressure feels misleading in the same sense as signal strength indicators in many consumer devices. Old phones generally had useful and informative indicators. Then somebody decided that users don't like seeing less-than-perfect signal strength when the connection is working properly and recalibrated what is shown to the user. In this case, it would be more informative to use yellow memory pressure as a warning against opening more apps/files, but users may not want to see such warnings if the system is still running without noticeable performance loss.Memory pressure is of course a simplified representation that won't apply to all use cases. What it seems reasonably useful for is 'consumer' use, where some modest swapping is often acceptable (and for many may not even noticeable).
I would 100% agree with you almost all of the time on this but something different is going on with the way these M1 Macs are managing memory that seems atypical and I just can't explain it. Even with whatever buffers and caches are being used ive had instances where I am nowhere near full RAM usage but I am seeing significant swap usage.Swapping is the first sign you are running out of memory, and most operating systems avoid it by default until they have no other reasonable options.
. Will android emulator run ? building either pod/ brew/node/npm working? (dependency) .
some test for android studio also
but youtubers say it doesn't matter!
I would 100% agree with you almost all of the time on this but something different is going on with the way these M1 Macs are managing memory that seems atypical and I just can't explain it. Even with whatever buffers and caches are being used ive had instances where I am nowhere near full RAM usage but I am seeing significant swap usage.
If I was seeing this level of swapping on a Linux server it would be game over for performance as it would be indicative of the system actually being out of RAM but that's not the case here and there is absolutely no performance degradation.
I have no answers *shru
Isn’t the real thing that a person bought a beta (M1 without full native software support) and expected it to run as good as product line with years of experience based upon a keynote and YouTube videos?Seriously words I never imagined I would hear coming from a developer ?
I think it makes great sense for them to charge $400. Most people don’t need it and if they actually do then they will pay (you invest in things that make you more productive). If they offer a ton of Ram developers could write lazy code. If the believe in minimalism and environment, then keep Ram low and force developers to keep innovating. While they are at it make a nice profit and don’t give into the dogma that more is better. To give in and offer lots of Ram is to make a race for the bottom and that is poor business. Honestly it won’t work for everyone, nothing wrong for those who enjoy eating at a cheap buffet.I believe you're absolutely correct in that by design the system will use RAM for anything at all if it thinks it may re-use data without having to go to disk again - whether swap or cache or whatever. So memory used doesn't say much. Likewise I think most modern operating systems will keep some buffer (smallish) of 'free' memory regardless (cached files not that much different) - so that when there's a request for more memory space, it doesn't have to first unload/swap anything first.
And I'm less clear on this but I'm reasonably certain: even a system with no appreciable memory pressure will swap some stuff out from time to time (increasing with uptime), and even some swapping in. You load an app that loads various frameworks and data, some of which are potentially shared; you stop using it actively but (acc to some system rules) it makes more sense to keep that in 'active swapped' rather than close it out and reload completely. If the swap drive is a fast SSD, this occasional swapping may not be noticeable (depending on task and other load); with an HDD, you notice all disk access/swap as slow.
For an example: open all the apps on your computer just for fun and don't actually use them - you'll probably see some swapouts, but since most of them are dormant, doesn't really matter.
The real hit to performance for modern systems (memory pressure red or close to it, probably some of the yellow as well) is when the system is actively swapping in and out _simultaneously_. This is the main meaning of running out of memory - there's too much in active use and swapping / compression is no longer a periodic or background task, but constant. This is when, for example, switching between apps - esp one you haven't used in a while - becomes excruciatingly slow.
Personally I find the memory pressure picture is pretty accurate - closest perhaps in meaning is the bracketed (x) swapin/swapout number in top (terminal), which roughly means "recent swapin/swapout." If both are zero, no issue; if both are large numbers and changing rapidly, Houston, we have a problem . But because it's an unadjusted number, it's a bit more opaque and difficult to interpret - scale, rate of change, etc are not obvious from quick glances. (The unbracketed number is historical and just tells you the system did some swap at some time in the past).
Roughly for memory pressure: if you're always in the green and never see yellow, you have enough memory (arguably more than enough) - recent swapins/outs probably always close to zero. If you only go into yellow rarely when hou do heavy work (recent swapin/out numbers occasionally go up and down and then go back to zero), well, you occasionally may notice some slight slowdowns - probably fine, unless you have free money.
If you're constantly in yellow doing what you consider a 'normal' heavy workload, you're at the edge and would probably benefit from more memory and will notice some slowdowns. And if you go into red, either there's a system problem (some runaway process/memory leak), or you are way short of what memory you need - red in memory pressure should be very rare. (Don't scrap your system because it went into red once though - may have been an error). Red you may experience as a system becoming glacially slow - so if it happens doing things you expect to do more than once in a blue moon, you do need more memory.
If you're really disciplined and you're okay with (for example) shutting down most other programs - browsers, mail, office programs, etc - when you do a big task, like editing photos - that's up to you. It might be okay if you have 'tasks' that you set the computer to do at night and you can just quit all other programs while they're running, or it's okay with you if those tasks go slowly while you're away from the computer.
For me that mostly doesn't work - using a computer for productive work means as many programs and browsers open as I want and I don't want to think about closing programs or windows. (Doesn't mean I don't do it, but I clsoe them for my mental space/comfort, not ram pages). And mostly, waiting for programs to switch for periods of time I can notice isn't acceptable. (Some adjustment here for when I do infrequent tasks, of course)
I recently upgraded memory in an NAS, and then a friend's window laptop - both more than they need - but at ~$40 for 8gb (net new additional), was cheap and made a big difference in performance. Both had too-frequent bouts of becoming almost unusable (deep yellow memory pressure equivalent).
That said, for me 16gb is a bit less than I'd like, but if 32gb was a reasonable additional price, I'd pay it. Personally I'm a bit disappointed apple wants $400 for that 16b-32gb jump. But the argument I'd make to apple is that 'too much' memory by some measures would increase perception of system value and their high ram prices harm the image of their computers. (And that 8gb for even base models is harming them in long term - people get impression their macs are slow because of too little memory). I freely admit though - I can see why people would disagree, and lots of people objectively don't need more than 8 for a home laptop like the air. (And I can see many reasons why apple doesn't make the jump that I'd like - profit margins esp)