Feb 13, 2012 at 12:07 AM
Edited Feb 13, 2012 at 12:43 AM
I've been using MSFT Ajax Minifier 4.0 at: http://aspnet.codeplex.com/releases/view/40584.
When I upgraded from 4.0 to 4.46 it got a *lot* slower. One of our pages went from taking 79ms to 850ms to compress (using the default settings).
Do you happen to know what new features might cause it to be so much slower, and if there is a way to disable them?
I tried all of the following, and it helped a bit, but it was still 5.x slower.
codeSettings.AllowEmbeddedAspNetBlocks = false;
codeSettings.CollapseToLiteral = false;
codeSettings.CombineDuplicateLiterals = false;
codeSettings.EvalLiteralExpressions = false;
codeSettings.IgnoreConditionalCompilation = true;
codeSettings.InlineSafeStrings = false;
codeSettings.LocalRenaming = Microsoft.Ajax.Utilities.LocalRenaming.KeepAll;
codeSettings.MacSafariQuirks = false;
codeSettings.ManualRenamesProperties = false;
codeSettings.PreserveFunctionNames = false;
codeSettings.PreserveImportantComments = false;
codeSettings.RemoveFunctionExpressionNames = false;
codeSettings.RemoveUnneededCode = false;
codeSettings.ReorderScopeDeclarations = false;
codeSettings.StrictMode = false;
codeSettings.StripDebugStatements = false;
Feb 14, 2012 at 3:36 PM
Well, there has been a LOT of code added since 4.0 -- 46 versions worth. That it's slower doesn't surprise me, but THAT much slower definitely does. With all those items turned off, though, why not just use the
-minify:0 option? That would probably squeeze a little more speed out of it for you.
Sounds like I need to start seriously thinking about putting in the effort to flesh out the C++ parser I wrote. That one is a
lot faster than the C# version.