Are there any good JOSM-like editors with decent performance for Apple Silicon (M1)?

Since 2022, I am using an Apple iMac M1 (2021) which is fine for most tasks, but there is one thing I really feel blocked from doing nowadays: OpenStreetMap editing. :disappointed:

I really want to use and love JOSM (I had some good times with it many years ago), but (partly due to a lack of Apple Silicon support), the performance is absolutely horrible: CPU and RAM usage is really high (and extremely fluctuant) and the application is stuttering in general; lowering the max heap size doesn’t help, it just causes an out-of-memory bug when loading imagery. I am running josm-tested.jar (February 2024) from the command line using this Java version:

openjdk 17.0.7 2023-04-18 LTS
OpenJDK Runtime Environment Zulu17.42+19-CA (build 17.0.7+7-LTS)
OpenJDK 64-Bit Server VM Zulu17.42+19-CA (build 17.0.7+7-LTS, mixed mode, sharing)

Because of this blockade, during the last few years, I pretty much only used iD for editing (which is only lightly to moderately heavy on RAM and CPU, except when I enable street-level imagery overlays) – but I miss the advanced features of JOSM and editing feels a bit too tedious for me with it.

I never tried out Potlatch 3 (running in the Adobe AIR) and its performance so far. Does it run well on Apple Silicon? If yes, it might be a good alternative as it is also intended for advanced users.

Also, I never tried out Merkaartor … Is this editor any good? Isn’t it outdated? Does it run well on Apple Silicon?

On an OSM Help article from 2016 (which is not about Apple Silicon, but indeed about the arm64 architecture which Apple Silicon is based on), I read that the proprietary Oracle JDK has a much better performance in this case compared to OpenJDK. However, I cannot install the x86_64 (Intel) version of Oracle JDK (“wrong installation program architecture”) even though JOSM only supports x86_64 with Apple Silicon using Rosetta 2 emulation.

And no, buying a new computer just for OSM editing is not a viable option!

There will be (hopefully soon) official JOSM support to Silicon-based machines: #21533 (Native Apple Silicon Support) – JOSM

However, you should be able to run it (I do, for example) without problems, using this simple tutorial: darkonus's Diary | How to properly install JOSM on a Mac with Apple Silicon | OpenStreetMap

How long has it been since you tried JOSM on your M1 Mac?

I ask only because I have been using JOSM on my M1 Mac without issues. Maybe that is because I am typically editing smaller areas that is not stressing the machine too much.

Or maybe there is something in your Java setup that is not correct for the M1.

Wow, these were some quick :dash: replies! Thanks for the link to the M1 guide, however, I’ll do the attempt tomorrow.

I’ve had good experience with the Adoptium JDK (on Windows & Linux).
The M1’s specs seem fine for JOSM, unless you’re editing massive areas.

Maybe you are using java in the emulated x86 mode? You can see this if you start Josm, then open the “activity monitor” app, in “all processes” there should be a column “kind” with values “Intel” and “Apple” (if you do not see it by default you have to activate it in the “View” menu). Josm should be marked as “Apple”. I am using Josm on a M1 mac with no issues, Java version: 21.0.1, Homebrew, OpenJDK 64-Bit Server VM

I’m using an Intel Mac, but generally installing software via homebrew works nicely and also takes care of dependencies.
Have you tried installing JOSM via josm — Homebrew Formulae, too?

Thanks so much for the help! Installing the Oracle JDK (aarch64 version) improved the performance severely!
java --version is now:

java 21.0.2 2024-01-16 LTS
Java(TM) SE Runtime Environment (build 21.0.2+13-LTS-58)
Java HotSpot(TM) 64-Bit Server VM (build 21.0.2+13-LTS-58, mixed mode, sharing)

I have switched again, this time to Temurin OpenJDK as recommended. I also did some trickery (renaming Oracle JDK’s Info.plist to Info.plist.disabled-because-proprietary.plist) so that /usr/bin/java uses Temurin OpenJDK:

openjdk 21.0.2 2024-01-16 LTS
OpenJDK Runtime Environment Temurin-21.0.2+13 (build 21.0.2+13-LTS)
OpenJDK 64-Bit Server VM Temurin-21.0.2+13 (build 21.0.2+13-LTS, mixed mode)

The performance should be the same as Oracle JDK, but you never know … I’ll try it out tomorrow.