Add the following flag to idea.vmoptions By going to Help → Edit Custom VM Options:

-Dawt.toolkit.name=WLToolkit
-Xmx4096m

To improve sluggish like performance of intellij on Asahi Linux running on Mac.