simplify icon indicating copy to clipboard operation
simplify copied to clipboard

jadx fails to decompile methods optimized by simplify

Open axnsan12 opened this issue 7 years ago • 3 comments
trafficstars

Using the master branch.

Ran as:

java -Xmx512M -Xms256M -jar simplify/build/libs/simplify.jar btpay-1.dex --max-address-visits 100000 --max-call-depth 150 --max-method-visits 10000000 --output btpay-dex-1-simplify-2.dex -ie | tee simplify-dex-1.log

Using jadx to decompile, I get errors such as

/*
Error: jadx.core.utils.exceptions.JadxRuntimeException: Unreachable block: B:9:0x001c
	at jadx.core.dex.visitors.blocksmaker.BlockProcessor.modifyBlocksTree(BlockProcessor.java:248)
	at jadx.core.dex.visitors.blocksmaker.BlockProcessor.processBlocksTree(BlockProcessor.java:52)
	at jadx.core.dex.visitors.blocksmaker.BlockProcessor.visit(BlockProcessor.java:38)
	at jadx.core.dex.visitors.DepthTraversal.visit(DepthTraversal.java:31)
	at jadx.core.dex.visitors.DepthTraversal.visit(DepthTraversal.java:17)
	at jadx.core.ProcessClass.process(ProcessClass.java:34)
	at jadx.api.JadxDecompiler.processClass(JadxDecompiler.java:282)
	at jadx.api.JavaClass.decompile(JavaClass.java:62)
*/

The attached archive contains the original .dex, the simplified.dex and the simplify log https://drive.google.com/file/d/1DO2vDddorcNPItxJ9MITVTrHU7yLlgda/view?usp=sharing

axnsan12 avatar Jul 13 '18 14:07 axnsan12

Thanks for the issue. I think you have enough here to try and reproduce. Btw, what version of jadx are you using?

My day job is keeping me pretty busy, but I occasionally reward myself with time to work on simplify issues. :D

CalebFenton avatar Jul 13 '18 16:07 CalebFenton

Got the same behavior some time ago.

enovella avatar Jul 13 '18 17:07 enovella

@axnsan12 I can decompile your simplified.dex file with my GDA. probably your tool has problems.

charles2gan avatar Oct 25 '18 09:10 charles2gan