Skip to content

Commit 8fdbe16

Browse files
committed
Update
1 parent a53aaea commit 8fdbe16

File tree

1 file changed

+1
-35
lines changed

1 file changed

+1
-35
lines changed

benchmark/cajita/Cajita_ParticleDynamicPartitionerPerformance.cpp

Lines changed: 1 addition & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -142,41 +142,7 @@ void performanceTest( std::ostream& stream, MPI_Comm comm,
142142
positions[p], Kokkos::pair<int, int>( 0, par_num ),
143143
Kokkos::pair<int, int>( 0, 3 ) );
144144

145-
// try for num_run times
146-
for ( int t = 0; t < num_run; ++t )
147-
{
148-
// ensure every optimization process starts from the same status
149-
partitioner.initializePartitionByAverage( comm,
150-
global_num_cell );
151-
152-
// compute local workload
153-
local_workload_timer.start( p );
154-
auto pws =
155-
Cajita::createParticleDynamicPartitionerWorkloadMeasurer<
156-
partitioner.cell_num_per_tile_dim,
157-
partitioner.num_space_dim, Device>(
158-
pos_view, par_num, global_low_corner,
159-
1.0f / num_cells_per_dim[c], comm );
160-
partitioner.setLocalWorkload( &pws );
161-
local_workload_timer.stop( p );
162-
163-
// compute prefix sum matrix
164-
prefix_sum_timer.start( p );
165-
partitioner.computeFullPrefixSum( comm );
166-
prefix_sum_timer.stop( p );
167-
168-
// optimization
169-
bool is_changed = false;
170-
// full timer
171-
total_optimize_timer.start( p );
172-
for ( int i = 0; i < max_optimize_iteration; ++i )
173-
{
174-
partitioner.updatePartition( std::rand() % 3, is_changed );
175-
if ( !is_changed )
176-
break;
177-
}
178-
total_optimize_timer.stop( p );
179-
}
145+
180146
}
181147
// Output results
182148
outputResults( stream, "insert_tile_num", problem_sizes,

0 commit comments

Comments
 (0)