Obfuscation - optimisation?
Tue Dec 7 18:04:00 GMT 2004
> But proguard does things like removing unsused stuff VERY efficient or
> making methods that are never orverridden final. removes code withought
Actually, I've found very sever side effects from pro-guards. It
seems any dynamically loaded class will be completely removed. This
can be manually overridden, but then the methods the dynamic classes
call will still be removed if no other classes call the same methods.
In the end no matter how much I specified to keep, there was always
something else missing that I could only detect by runtime errors. I
expect any code which explicitly Class methods, or java reflection
would have runtime errors.
Byte optimizations are a little better, but seem buggy. I could not
get code using the byte optimizations to run because methods were
rewritten to expect a int return instead of a void return causing
runtime stack errors, even with Sun's JRE.
The only part of proguard's optimization I could get to work without
runtime errors was obfuscation.
More information about the Java