Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
@github
I actually think its the second one.
If I recall correctly,
Linux uses optimistic memory management.
Meaning if a program mallocs something but doesn't use the memory there, it is only allocated in software, not in hardware.
So even if AS allocates a fuckton of memory for caching and everything,
If it doesn't use it, it stays free and usable for other processes. -
@metamourge that's something new I learned today, thank you :)
If you don't mind asking, I sometimes reach a point where Android Studio stops responding to keyboard at all, no key click will do anything I searched for it and someone said it is related to not receiving signals due to driver bug?
But it only happens in Android studio so I'm not sure -
@metamourge you recall correctly.
Look at htop. "VIRT" vs "RES". VIRT is what the program allocates, RES is what's actually used. -
@irene I like to blame Java, but that's just some noob execution that is not backed up by anything. Just hate memory management when dealing with Java
-
@irene Ya you remind me, I used to use Community edition and had no issues, not sure why AS is like that ...
-
@gitpush interesting. It's the thing I love when dealing with Java :)
Try comparing jvm stats (heap usage) on Lin and Win. I guess you'll see a vast difference there ;)
This will rule out OS memory mgmt nuances -
Optimistic memory can actually be abused in macos and Linux to create memory ballasts, decreasing the aggressiveness of the GC. Search for golang ballast.
-
@Techno-Wizard Which is why you shouldn't run everything you find on the internet.
Duh.
I find it funny on Windows, Android studio reaches as much as 12GB of ram usage, while on Linux two instances barely take up to 3GB
Either java sucks on Windows or AS sucks in memory usage but happened to be saved by Linux
random