开发者

Is Array.Sort() Multithreaded in VB.NET

开发者 https://www.devze.com 2023-03-20 14:55 出处:网络
I know that Array.Sort() in VB.NET uses the quicksort algorithm.But my question is, does it take advantage of multithreading?开发者_如何转开发

I know that Array.Sort() in VB.NET uses the quicksort algorithm. But my question is, does it take advantage of multithreading?开发者_如何转开发

I'm sorting a list of hundreds of thousands of records, and need to ensure the fastest sort times.

Thanks.


I'm not sure how multi-threading would make your sorting faster.
Array.Sort does sorting in a single thread.

If by multi-threading you actually mean taking advantage of several processors when they are available, check out this answer that uses Parallel Extensions (available in .NET 4.0 and partly available for .NET 3.5).

0

精彩评论

暂无评论...
验证码 换一张
取 消