Skip to content

Allow to cache PointLocator in vtkMergeCells

Nicolas Vuaille requested to merge nicolas.vuaille/vtk:MergeCellsPerf into master

TestPUnstructuredGridGhostCellsGenerator outputs the following timing :

Before the changes

709: -- Ghost Level: 1 UseGlobalPointIds: 1 Elapsed Time: min=0.234753, avg=0.234798, max=0.234886
709: -- Ghost Level: 1 UseGlobalPointIds: 0 Elapsed Time: min=0.3649, avg=0.364941, max=0.365001
709: -- Ghost Level: 2 UseGlobalPointIds: 1 Elapsed Time: min=0.889999, avg=0.890727, max=0.891354
709: -- Ghost Level: 2 UseGlobalPointIds: 0 Elapsed Time: min=1.12291, avg=1.12304, max=1.12325

After

709: -- Ghost Level: 1 UseGlobalPointIds: 1 Elapsed Time: min=0.233851, avg=0.233921, max=0.234015
709: -- Ghost Level: 1 UseGlobalPointIds: 0 Elapsed Time: min=0.250582, avg=0.250607, max=0.250659
709: -- Ghost Level: 2 UseGlobalPointIds: 1 Elapsed Time: min=0.889529, avg=0.890644, max=0.891637
709: -- Ghost Level: 2 UseGlobalPointIds: 0 Elapsed Time: min=0.888282, avg=0.888403, max=0.88852

The locator is used only when not using global point ids.

  • For the ghost level 1, speed up is (0.364941 - 0.250607) / 0.364941 = 31%
  • For the ghost level 2, speed up is (1.12304 - 0.888403) / 1.12304 = 21%
Edited by Mathieu Westphal (Kitware)

Merge request reports

Loading