mongodb/mongo-csharp-driver — pull request #159 by DmitryNaumov (2013-06-05 09:46:05+00:00)
Title: CSHARP-750: Fixed array of value type serialization performance issue

When serializing array of value types there is no need to lookup for serializer for every item, because it is homogeneous. This saves us some cpu cycles but most benefit may be achieved when multiple threads are doing serialization, like in my multi-threaded insert benchmark. The suggested fix allows to avoid extra-contention on ReaderWriterLockSlim inside BsonSerializer.