Currently at the line mentioned below it can be seen that the DynamicCompiler returns a Func that makes a call to EngineUtil.ConvertVariableNamesToLowerCase. When calling Calculate on the CalculationEngine it has already converted all variable names to lowercase. Ideally, this would be a feature one could opt-out of altogether since users interested in maximizing performance might be enforcing lowercase variable names already.
If my performance metrics from a project using your nuget package are correct, ~33% of the time executing a calculation (through the CalculationEngine.Build method, so we are already avoiding the repeated call to EngineUtil.ConvertVariableNamesToLowerCase in the CalculationEngine.Calculate method) for us is taken up by ensuring that the variables are all lowercased.
Currently at the line mentioned below it can be seen that the
DynamicCompiler
returns aFunc
that makes a call toEngineUtil.ConvertVariableNamesToLowerCase
. When callingCalculate
on theCalculationEngine
it has already converted all variable names to lowercase. Ideally, this would be a feature one could opt-out of altogether since users interested in maximizing performance might be enforcing lowercase variable names already.https://github.com/pieterderycke/Jace/blob/f97eac1f13e5582ae8da64d55b63a19360200556/Jace/Execution/DynamicCompiler.cs#L42
If my performance metrics from a project using your nuget package are correct, ~33% of the time executing a calculation (through the
CalculationEngine.Build
method, so we are already avoiding the repeated call toEngineUtil.ConvertVariableNamesToLowerCase
in theCalculationEngine.Calculate
method) for us is taken up by ensuring that the variables are all lowercased.