Reputation: 57
Android studio is too slow when it starts. It is needed to wait few minutes before the loading pops up. I'm not talking about the gradle building, but android itself... This is not my first android studio... I also used android studio(maybe 2.2.1 or 2.2.0) before I formatted my laptop, thus I know how much time it needs to show that loading screen.
For details I use 6th generation I5 cpu, 8GB Ram, and ssd.
Upvotes: 0
Views: 4289
Reputation: 617
In order to increase the speed of the android studio you need to allocated extra RAM memory to android studio(Vm option) as mentioned in the link ---> config android studio vm option.In the official blog it state that you can not edit it directly.
Note that you should never directly edit the studio.vmoptions file found inside the Android Studio program folder. While you can access the file to view Studio's default VM options, editing only your own studio.vmoptions file ensures that you don't override important default settings for Android Studio. Therefore, in your studio.vmoptions file, override only the attributes you care about and allow Android Studio to continue using default values for any attributes you have not changed
Upvotes: 2
Reputation: 1012
You need to upgrade your PC though but there are few things you can do to make it faster
Open the file located at /bin/studio.vmoptions and Change the content from
-Xms128m
-Xmx800m
to
-Xms256m
-Xmx1024m
Xms specifies the initial memory allocation pool. Your JVM will be started with Xms amount of memory and will be able to use a maximum of Xmx amount of memory.
Save the studio.vmoptions file and restart Android Studio.
Create a file named gradle.properties in
/home/<username>/.gradle/ (Linux)
/Users/<username>/.gradle/ (Mac)
C:\Users\<username>\.gradle (Windows)
and add the line:
org.gradle.daemon=true
This helps a lot, with org.gradle.daemon
set to true Gradle
reuses computations from previous builds and cache information about project structure, files, tasks etc. in memory so it won’t have to start up the entire Gradle
application every time.
Upvotes: 5