Allow identifying parts of code that are performance-critical, and don't apply performance-affecting obfuscation there
See original GitHub issueFirst things first, thank you for your work on this project, JavaScript Obfuscator, especially when combined with other minification solutions, can produce a brutally undecipherable code; our reverse engineering-protection tests are nearing that of true machine code compilation, so this is indeed getting somewhere.
Please, count on my support if this project turns out to be useful to us.
Problems with micro-optimization
Now, our use case involves a code-base that has lots of tight loops, mercilessly micro-optimized for great runtime performance (it’s an audio production suite with considerable amounts of signal processing and audio visualization of often several GB of data, and the latter must run at steady 60 FPS).
JavaScript Obfuscator, by definition, mangles these parts to make them harder to read. This, however, especially with the controlFlowFlattening
option enabled, undoes the optimization badly, producing a very bad runtime performance degradation.
We actually found that virtually every single option of JavaScript Obfuscator enabled adds a clearly visible runtime performance penalty.
“Standard” and “performance-critical” parts
The mentioned performance issue is only applicable to a very limited part of our codebase, merely a few thousand lines of tight loops total.
It would be great if certain areas of code (e.g. a function, block, annotated region, or method) could be added to an ignore list, so that it does not get transformed in any way that affects performance considerably (e.g. variable names can still be mangled flat in place, but not much more).
While it is theoretically possible to obfuscate files separately, with the selfDefending
option enabled, it becomes impractical (if not impossible) to pack files after obfuscation.
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (2 by maintainers)
Top GitHub Comments
Yes (if i understood you correctly)
Ah, I’ll be damned, I’ve been looking through the docs a lot, but somehow missed that part. Thank you for your quick response.