From: pablosantosluac <pab...@te...> - 2008-01-13 15:03:43
|
Hi Carlos, I've just run our test again using Firebird backend. The table below = shows the profiler results for a test with a server (embedded) working = with 20 simultaneous clients, so there's a lot of concurrency. Routine Name Module Name % Time % with Children Time Time with = Children Shared Time Hit Count=20 FesStatement::Fetch FirebirdSql.Data.Firebird.dll 18,57% 3,55% = 2679,05 7806,72 34,32 1240193=20 FesStatement::Free FirebirdSql.Data.Firebird.dll 8,40% 0,56% = 1211,19 1225,23 98,85 660413=20 XsqldaMarshaler::MarshalManagedToNative = FirebirdSql.Data.Firebird.dll 6,66% 0,80% 960,1 1749,81 54,87 1617581=20 XsqldaMarshaler::MarshalNativeToManaged = FirebirdSql.Data.Firebird.dll 6,51% 1,39% 939 3059,23 30,69 1563064=20 GlobalizationHelper::CultureAwareCompare = FirebirdSql.Data.Firebird.dll 3,74% 0,25% 539,87 539,87 100 30454745=20 XsqldaMarshaler::GetString FirebirdSql.Data.Firebird.dll 3,16% = 0,31% 455,28 684,84 66,48 33472568=20 XsqldaMarshaler::CleanUpNativeData FirebirdSql.Data.Firebird.dll = 3,11% 0,24% 448,06 528,05 84,85 2883890=20 FesStatement::GetSqlInfo FirebirdSql.Data.Firebird.dll 2,34% 0,16% = 337,8 343,18 98,43 280302=20 DbField::GetDbDataType FirebirdSql.Data.Firebird.dll 2,22% 0,22% = 319,82 490,04 65,26 39600463=20 FesStatement::Execute FirebirdSql.Data.Firebird.dll 1,92% 0,16% = 277,65 351,86 78,91 660413=20 FesTransaction::Commit FirebirdSql.Data.Firebird.dll 1,89% 0,12% = 272,31 273,31 99,64 13028=20 XsqldaMarshaler::ComputeLength FirebirdSql.Data.Firebird.dll 1,88% = 0,12% 271,28 271,28 100 35290780=20 Descriptor::get_Item FirebirdSql.Data.Firebird.dll 1,88% 0,12% = 270,46 270,46 100 221582569=20 FbDataReader::GetOrdinal FirebirdSql.Data.Firebird.dll 1,83% 0,42% = 263,55 919,09 28,67 6088214=20 FesStatement::Prepare FirebirdSql.Data.Firebird.dll 1,58% 0,59% = 228,24 1291,67 17,67 197368=20 XsqldaMarshaler::MarshalManagedToNative = FirebirdSql.Data.Firebird.dll 1,50% 0,13% 217,06 295,26 73,52 1617581=20 Ok, the first two methods (Fetch & Free) eat about 26% of the test time = and they're basically spending their times at FbClient.isc_dsql_fetch = and FbClient.isc_dsql_free_statement. It looks like Marshaling and Unmarshaling data is taken a long time, I'd = say even longer than the "internal" calls themselves. On the other hand, in my test, the embedded server is slower than the = "external" one: 444s to complete the embedded vs 291 the "external". = Just to give some data to compare: using SQL Server the same test = (exactly the same code base) requires 198 seconds. The interesting thing = is that the test with only one client (instead of 20) is faster with the = Fb backend than the SQL Server one. Maybe it is not an issue with the = provider but firebird itself, although the time taken to marshal and = unmarshal looks like a possible "culprit". But, running exactly the same test against an external server I get the = following: Routine Name Module Name % Time % with Children Time Time with = Children Shared Time Hit Count=20 XdrStream::Read FirebirdSql.Data.Firebird.dll 37,98% 2,28% 3573,73 = 3690,01 96,85 31677462=20 FbDataReader::GetOrdinal FirebirdSql.Data.Firebird.dll 3,38% 0,41% = 318,18 655,04 48,57 6072788=20 XdrStream::Write FirebirdSql.Data.Firebird.dll 2,27% 0,23% 213,13 = 375,04 56,83 12712555=20 DbField::GetDbDataType FirebirdSql.Data.Firebird.dll 2,05% 0,18% = 192,56 290,64 66,25 15044218=20 XdrStream::Flush FirebirdSql.Data.Firebird.dll 1,98% 0,12% 186,07 = 190,78 97,53 2740818=20 GlobalizationHelper::CultureAwareCompare = FirebirdSql.Data.Firebird.dll 1,94% 0,11% 182,78 182,78 100 30456311=20 I don't know whether there is any possible optimization at the = provider's level. Thanks, pablo ----- Original Message -----=20 From: Carlos=20 To: For users and developers of the Firebird .NET providers=20 Sent: Friday, December 28, 2007 11:16 AM Subject: Re: [Firebird-net-provider] Firebird scalability under heavy = load Hello: Ok, so, you mean I should try with the new 2.0+ provider? I mean, we = are having the same problems with the "server" (not the=20 embedded one). Well no, it maybe a problem on it, but we may try to check where is = the problem ( the 2.0+ has performance changes on other areas as well, = but anyway, we should check first where is the real problem )=20 =20 --=20 Carlos Guzm=C3=A1n =C3=81lvarez Vigo-Spain=20 -------------------------------------------------------------------------= ----- = -------------------------------------------------------------------------= This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ -------------------------------------------------------------------------= ----- _______________________________________________ Firebird-net-provider mailing list Fir...@li... https://lists.sourceforge.net/lists/listinfo/firebird-net-provider |