This project has moved and is read-only. For the latest updates, please go here.

CPU usage and performance

Jan 18, 2012 at 6:10 AM

Hi All,

I am profiling my ASP.NET MVC app and when I hit my local version on IIS and I have noticed that deserializing an object of about 77kb takes around 100ms, is this expected?

Also the CPU seems to max out while im profiling, is the task of deserializing very intense, or should I be looking elsewhere?



Jan 19, 2012 at 12:37 AM

As an FYI I have cross posted this topic to SO for more visibility.

Jan 19, 2012 at 2:35 AM
Edited Jan 19, 2012 at 2:38 AM

100ms is longer than I would have expected.

In the past week I've checked in various performance improvements. Try getting the latest source code here and use that dll (remember to build using the release configuration). If that doesn't offer any improvement then create a bug on CodePlex with the JSON and the class you're deserializing to and I'll take a look.

Jan 24, 2012 at 9:53 AM

I wrote a little sample app that gets a string into memory (~70kb) then deserializes it over and over with a stopwatch object timing each one.

It seems that the very first hit is an order of mangitude slower than every single remaining deserialization calls, the first one is around 150ms, then each other is around the 15 - 20ms, which is what I would have expected in the first place. Is there some static initialization calls that occur?

I have not yet checked out the latest build to test it, I will though...

Jan 24, 2012 at 11:28 AM