[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
   Reporting
  [Collapse]Data Grid
   [Expand]Getting Started
   [Expand]Implementation Details
   [Expand]Views
   [Expand]Grid View Data Layout
   [Expand]Binding to Data
   [Expand]Master-Detail Data Representation
   [Expand]Data Editing and Validation
   [Expand]Grouping
   [Expand]Selection
   [Expand]Filtering and Searching
   [Expand]Sorting
   [Expand]Data Summaries
   [Expand]Paging and Scrolling
   [Expand]Focus and Navigation
   [Expand]Conditional Formatting
   [Expand]Drag-and-Drop
   [Expand]Appearance Customization
   [Expand]MVVM Enhancements
   [Expand]Printing and Exporting
   [Expand]End-User Interaction
   [Expand]Miscellaneous
   [Collapse]Performance Improvement
     Optimized Mode
     Processing Large Volumes of Data
     Parallelizing Data-Intensive Operations
     Real-Time Data Management
     Improving the Scrolling Experience
     Frequent Update Performance Enhancement
   [Expand]Design-Time Features
   [Expand]Visual Elements
   [Expand]End-User Capabilities
   [Expand]Examples
  [Expand]Ribbon, Bars and Menu
  [Expand]Charts Suite
  [Expand]Pivot Grid
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Expand]Layout Management
  [Expand]Windows Modern UI
  [Expand]Printing-Exporting
  [Expand]Data Editors
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Diagram Control
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
  [Expand]Scheduler (legacy)
 [Expand]Scaffolding Wizard
 [Expand]Localization
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Frequent Update Performance Enhancement

Expanded Optimized Summary Calculation Mode

Starting with v15.2, the GridControl featured a special mode allowing you to update data summaries without recalculating them for all records. Instead, the grid calculates delta values for changed records and updates summaries according to these values. As a result, the time spent on updating summary values does not depend on the number of records.

To enable this mode, set the grid's GridControl.OptimizeSummaryCalculation property to true. The grid should be bound to an ObservableCollection whose items implement the INotifyPropertyChanged and INotifyPropertyChanging interfaces. Calculation of custom summaries and summaries for unbound columns cannot be optimized.

Expanded ChunkList Overview

Starting with v15.2, the DevExpress WPF Suite featured a new collection type ChunkList<T>, which is designed to improve performance when handling updates of large collections.

Note

Using the ChunkList<T> provides significant performance improvements in applications that handle a large and frequently updated data source. However, operations that iterate over the elements of the data source (e.g., sorting, filtering, summary calculation) are executed slowly in comparison. Using the ChunkList<T> in common scenarios is not recommended.

Items within the ChunkList<T> collection are broken up in relatively small sublists of a fixed size - chunks. Thus, each element can be accessed by its chunk index and index within a chunk. This structure provides much better performance when executing the IndexOf, Insert and Remove data operations compared to a regular list.

The IndexOf operation is called each time the PropertyChanged event fires for an object in a collection to determine the object's position on the list. In a standard collection, it is necessary to iterate through the entire list to find the object index. In ChunkList<T>, the object's chunk index is already known, and you are only required to find the object's index within a chunk.

When the Insert or Remove operations are performed in a standard collection, the collection has to shift all the items following the inserted/removed item. In ChunkList<T>, items will only be shifted in a chunk where the item was inserted or removed, while other chunks stay intact.

The table below illustrates the difference in performance between BindingList and ChunkList<T>.

Scenario (1,000,000 items)

BindingList

Standalone

ChunkList

Standalone

BindingList

Bound to GridControl

ChunkList

Bound to GridControl

Creation time 1016 1171 1422 2016
Insert 10000 items 6422 250 7765 469
Remove 10000 items 9700 219 8400 438
Update 10000 items 58700 156 59328 250
Full iteration 47 328
Memory used (MB) 59 90
Sort string property 7485 8187
Sort int property 2465 3313

Expanded Implementing ChunkList

When creating a ChunkList<T>, you need to specify the approximate size of the collection using the capacity parameter of the ChunkList<T>.ChunkList<T> constructor. The chunk size is calculated as the square root of the capacity value. You can also use the constructor's chunkSize parameter instead to explicitly set the chunk size.

There are two ways to enable the ChunkList<T> to determine the data object's chunk index.

  • Implement the IChunkListObject.ChunkObject property of the IChunkListObject interface in your data objects, so the chunk index is stored in a field at the object level.

    Pros: data source is generated faster and consumes less memory.

    Cons: this method requires data object modification.

    See the example below.

  • Set the useChunksCache parameter of the ChunkList<T>.ChunkList<T> constructor to true to create a hash table that stores chunk indexes for collection items.

    Pros: this method does not require data object modification.

    Cons: the hash table requires additional memory.

    See the example below.

    You can also enable each chunk to listen to PropertyChanged events separately by setting the supportPropertyChanged parameter to true. In this case, there is no need to determine the chunk index to find the item position in the list, so you can disable creating a hash table by setting the useChunksCache parameter to false. However, the IndexOf operation called in runtime will not be optimized.

    See the example below.

Is this topic helpful?​​​​​​​