Replacing drive won't help much as the problem lies within gradle build process which takes huge time to rebuild project every time you run it.
Here is the link to update your gradle settings for faster build processing :
https://medium.com/@101/speed-up-gradle-build-in-android-studio-80a5f74ac9ed#.x2w5e5efk
In case link is dead, here are some steps to speed up your gradle process:
Step 1: Update Gradle version
NOTE:You should use updated gradle version for above two steps
- Copy above file to AndroidStudio/gradle folder
- Last step is to add your distribution in Android Studio Settings > Gradle (Use local gradle distribution and set it to above pasted zip file)
Step 2: Enable Offline mode, Gradle daemon and parallel build for the project
- Go to Gradle from android studio Setting and click in Offline work box.
- Go to Compiler from android studio Setting and add
“— offline”
in command-line box and click Compile independent modules in parallel.
Step 3: The next step is to enable the Gradle daemon and parallel build for your project
org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
Step 4: Tweek Memory settings
Here 4g is 4 GB of memory.
Hope it helps.