JakeWharton/diffuse

java.lang.OutOfMemoryError: GC overhead limit exceeded

johnsonlee opened this issue · 0 comments

OOM occurred when diff two apks by using the following command:

$ diffuse diff a.apk b.apk

The stack trace shows as following

Exception in thread "main" java.lang.OutOfMemoryError: GC overhead limit exceeded
	at java.util.Arrays.copyOfRange(Arrays.java:3664)
	at java.lang.String.<init>(String.java:207)
	at com.android.dex.Mutf8.decode(Mutf8.java:39)
	at com.android.dex.Dex$Section.readString(Dex.java:408)
	at com.android.dex.Dex$StringTable.get(Dex.java:718)
	at com.android.dex.Dex$TypeIndexToDescriptorTable.get(Dex.java:742)
	at com.android.dex.Dex$TypeIndexToDescriptorTable.get(Dex.java:738)
	at com.jakewharton.diffuse.DexKt.getField(Dex.kt:62)
	at com.jakewharton.diffuse.DexKt.access$getField(Dex.kt:1)
	at com.jakewharton.diffuse.Dex$Companion$toDex$4.invoke(Dex.kt:43)
	at com.jakewharton.diffuse.Dex$Companion$toDex$4.invoke(Dex.kt:28)
	at com.jakewharton.diffuse.ExtensionsKt.mapEach(extensions.kt:39)
	at com.jakewharton.diffuse.Dex$Companion.parse(Dex.kt:43)
	at com.jakewharton.diffuse.Apk$Companion.parse(Apk.kt:34)
	at com.jakewharton.diffuse.DiffCommand$inputOptions$2.parse(diffuse.kt:76)
	at com.jakewharton.diffuse.DiffCommand.run(diffuse.kt:135)
	at com.github.ajalt.clikt.parsers.Parser.parse(Parser.kt:139)
	at com.github.ajalt.clikt.parsers.Parser.parse(Parser.kt:14)
	at com.github.ajalt.clikt.core.CliktCommand.parse(CliktCommand.kt:215)
	at com.github.ajalt.clikt.core.CliktCommand.parse$default(CliktCommand.kt:212)
	at com.github.ajalt.clikt.core.CliktCommand.main(CliktCommand.kt:230)
	at com.jakewharton.diffuse.Diffuse.main(diffuse.kt:41)