Re: [Firebird-net-provider] DNET-532
Fresh PR for this issue: https://github.com/cincuranet/FirebirdSql.Data.FirebirdClient/pull/35 On 27 August 2015 at 07:58, Jiří Činčura j...@cincura.net wrote: One more question about string.Equals. Comparison type used in IndexOf calls is StringComparison.CurrentCultureIgnoreCase. My question why this used instead of OrdinalIgnoreCase? My current optimization, including StringComparison change decreased timings to 22 (names) vs 6 (indexes) seconds. Because of national characters. Somebody might use these in parameter name. Although it's pretty weird, I had similar issue in DDEX. -- Mgr. Jiří Činčura Independent IT Specialist -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
Re: [Firebird-net-provider] DNET-532
About Equals call I'm not sure it can be optimized somehow. But decreasing cost of NormalizeParameterName should significantly reduce overall case execution time. On 26 August 2015 at 20:27, Геннадий Забула zabulu...@gmail.com wrote: I've profiled case and found out next hot paths: get_Item: 54,56% 1. 30.30% return this.parameters.FindIndex((PredicateFbParameter) (x = x.InternalParameterName.Equals(normalizedParameterName, StringComparison.CurrentCultureIgnoreCase))); Equals call 2. 21,51% internal static string NormalizeParameterName(string parameterName) { if (string.IsNullOrEmpty(parameterName) || parameterName.StartsWith(@)) return parameterName; return string.Format(@{0}, (object) parameterName); } This method also can be optmized. StartsWith - parameterName[0] == '@' string.Format - string.Concat(@, parameterName) On 26 August 2015 at 16:45, Jiří Činčura j...@cincura.net wrote: Can you share profiler report? There's a test app attached to the ticket. It clearly shows the hot spot. I can share only times (from my machine). -- Mgr. Jiří Činčura Independent IT Specialist -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
[Firebird-net-provider] DNET-532
Hi *, May I bring to your attention the http://tracker.firebirdsql.org/browse/DNET-532 ? I'd like to know others' view as well. -- Mgr. Jiří Činčura Independent IT Specialist -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
Re: [Firebird-net-provider] DNET-532
Before doing any optimizations, there should be done some profiling to find hot paths in particular cases. I think need to start with sample that demonstrates the issue. After that start running it in a loop under profiler. On 26 August 2015 at 15:39, Jiří Činčura j...@cincura.net wrote: Hi *, May I bring to your attention the http://tracker.firebirdsql.org/browse/DNET-532 ? I'd like to know others' view as well. -- Mgr. Jiří Činčura Independent IT Specialist -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
Re: [Firebird-net-provider] DNET-532
Can you share profiler report? There's a test app attached to the ticket. It clearly shows the hot spot. I can share only times (from my machine). -- Mgr. Jiří Činčura Independent IT Specialist -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
Re: [Firebird-net-provider] DNET-532
Can you share profiler report? On 26 August 2015 at 16:05, Jiří Činčura j...@cincura.net wrote: Before doing any optimizations, there should be done some profiling to find hot paths in particular cases. I think need to start with sample that demonstrates the issue. After that start running it in a loop under profiler. Done that already. -- Mgr. Jiří Činčura Independent IT Specialist -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
Re: [Firebird-net-provider] DNET-532
Before doing any optimizations, there should be done some profiling to find hot paths in particular cases. I think need to start with sample that demonstrates the issue. After that start running it in a loop under profiler. Done that already. -- Mgr. Jiří Činčura Independent IT Specialist -- ___ Firebird-net-provider mailing list Firebird-net-provider@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-net-provider