XPO - A simple benchmark against EF 6 and EF Core (UPDATE)

XPO Team Blog
17 July 2018

We have received many comments and questions on our previous blog post. Thank you all for that!

In this post, I will describe our updated benchmark based on your feedback: 
    https://github.com/DevExpress/XpoNetCoreDemos/tree/master/ORMBenchmark

Let me remind that we have tested the performance of the following Object-Relational Mapping (ORM) libraries for .NET Framework 4.6.1 and higher:


What's New in the benchmark?

  1. EF benchmarks now use the AsNoTracking method in the Fetch, LinqQuery, InstantiationNative and other test cases. It has slightly, but not significantly decreased data reading time.
  2. Since XPO has no option such as the EF's AsNoTracking, we created the additional ProjectionLinq benchmark that demonstrates how much time each ORM library takes to load objects without tracking changes.
  3. For XPO benchmarks, we set the IdentityMapBehavior option to Strong. This allows us to reduce time to place loaded objects in Identity Map.
  4. Our short-time benchmarks (for example, InstantiationLinq and LinqTakeRecords* on small data set) are now more accurate because of improved the benchmark configuration. 

We also tried to use the Find method instead of First in the Fetch benchmark based on Neal's comment. In certain cases it showed lower performance, in others it did not affect the result much. As a result, we left the benchmark unchanged.

Run the updated benchmark tests or review our results here. Example: 



All benchmarks were executed using .NET 4.6.1, AnyCPU release builds (include warm-up), Windows 10 Enterprise x64, local Microsoft SQL Server 2016 Developer Edition, i7-7700 CPU @3.6GHz / 16GB RAM / SSD. Please note that DevExpress.Xpo and other referenced libraries will automatically be restored from Nuget. Edit the connection string in the App.config file, update the ORM library and target framework versions, if necessary. 

Your feedback is needed!

What do you think about this update? Did you try to extend this benchmark with your own scenarios? Let us know in comments. We'd love to hear your feedback and results.

See Also

Love XPO and want to help us promote it? Add the package through Nuget.org instead of DevExpress Nuget!

 

  Yekaterina K.
  Technical writer
  XPO team

Free DevExpress Products - Get Your Copy Today

The following free DevExpress product offers remain available. Should you have any questions about the free offers below, please submit a ticket via the DevExpress Support Center at your convenience. We'll be happy to follow-up.
No Comments

Please login or register to post comments.