News for hackers. Stuff that matters.
Re:We’ve built a towering pile of shite by jeroenhd on Saturday June 06, 2020 @09:18AM (#23438974)
> Android provides an emulator that gobbles up RAM and is painfully slow to use.

That's not my experience. The official Android emulator works just like any emulator and will take the RAM it needs to run like a real device. If you don't have the RAM to emulate a smart phone (which these days contains anywhere between 6 and 10GB of RAM it seems) while also running the debug tools, you can always lower the RAM you give the virtual device. Android will run on 1GB of RAM though it won't be pretty if you want to emulate interacting between different apps and such.

Oh, and there's a potential gotcha in that Android does a lot of stuff on the mobile GPU, so GPU acceleration will make a huge difference. You don't need a 2080Ti to run the emulator, but integrated Intel graphics are often not up for the task. On my laptop the Intel drivers were also flagged for incompatibilities because of unresolved issues with the driver themselves, making Android run on software rendering and oh boy what a drama that was.

The big problem isn't so much the emulator, it's the IntelliJ-based IDE combined with the java compilers that gobble up RAM worse than Chrome. Each compilation process can quickly grow to 2GB and release it soon after, torturing your OS's memory manager.

My experience running and debugging the emulator with 16GB of RAM have been quite good. 8GB is doable if you don't have too many tabs open and tune your emulator.

The biggest problem I have with Android development is that compiling even a small app takes over a minute in my 7700k.

As a fan of IntelliJ, I applaud their choice of IDE. They used to base their IDE on Eclipse and that was clearly not worth it. As for dedicated IDEs, unlike Microsoft and Apple, Google didn't have an existing IDE lying around for their purposes. When someone did make an IDE from scratch, Xamarin, I found it worse in every single aspect aside from language support. And let's be honest, while Visual Studio is probably one of the best end-user facing pieces of software Microsoft still maintains in-house, it wasn't that great. Typing latency is high, configuration is painful and error messages are vague. Many, if not most, dotnet devs run the Jetbrains tools to enhance their VS experience.

Re:We’ve built a towering pile of shite by ohgodplsno on Saturday June 06, 2020 @10:15AM (#23439328)
>The big problem isn't so much the emulator, it's the IntelliJ-based IDE combined with the java compilers that gobble up RAM worse than Chrome. Each compilation process can quickly grow to 2GB and release it soon after, torturing your OS's memory manager.

Android Studio isn't necessarily that bad. On a very large project, my AS instance eats up, at the absolute worst, 4GB of RAM. Which, compared to all other IDEs is not that awful.

Gradle however will eat memory and balloon to 8GB on its daemon

>The biggest problem I have with Android development is that compiling even a small app takes over a minute in my 7700k.

Make sure incremental compilation is setup. For small changes, this means that recompiling is lower than 10 seconds.

Re:We’ve built a towering pile of shite by me551ah on Saturday June 06, 2020 @09:27AM (#23439034)
I agree that it works just like any other emulator, but the competition offers simulators which take up far less resources. Google did start work on a simulator which went by the name of 'Arc Welder' and while it seemed promising it was discontinued soon after.

And I wholeheartedly agree with your point about compile times and have added it to my comment.

Re:We’ve built a towering pile of shite by jeroenhd on Saturday June 06, 2020 @09:46AM (#23439134)
Windows Phone used the same model as Android, only Windows Phone devices never got to the point where they came out with over 4GB of RAM.

iOS doesn't actually emulate most of the system though, which is why it can run on so little RAM. Apple repurposes the shared components running on macOS to do the heavy lifting of iOS emulation. Their approach, in my opinion, is closer to a Docker container with a display than to a traditional emulator.

This is also why it's technically impossible to port the iOS emulator to Windows or Linux even if they were willing to give up their vendor lock-in.

I haven't worked with the iOS simulator for long, but I found some features the Android emulator offered missing in iOS. There was no installing apps (like WhatsApp, to test sharing) and the tooling for faking following a recorded or generated GPS path were either impossible for me to find or just not there. I also found that the "OS" inside the simulator felt bare-bones and incomplete whereas the Android emulator comes with the complete toolkit, including Google Play. iOS simulation is faster than Android emulation, but in my opinion that comes at a cost.

It's possible to do the same thing on Linux through Anbox, though that might not have all the same API's. The Android kernel is quite different from the Linux kernel it was once just a fork of and on Windows you'll never see the same level of integration with Android that iOS has.

Re:We’ve built a towering pile of shite by ptx on Saturday June 06, 2020 @06:42PM (#23442963)
> Many, if not most, dotnet devs run the Jetbrains tools to enhance their VS experience.

In fact, you don't even need VS as part of the experience anymore – Jetbrains Rider has most of the Resharper features (including "extract class" in the latest version) in an IDE based on the IntelliJ platform. It feels much faster than VS + Resharper.

Re:We’ve built a towering pile of shite by entha_saava on Sunday June 07, 2020 @11:33PM (#23453352)
Yeah but to me Android dev seems to be too much dependent on IDE which I'd say a bad choice and impedes development.

Why can't it be as simple as a bunch of files in a folder, a build file, a manifest, and an asset directory? That's what most apps need.