Skip to content

Commit 3da258b

Browse files
committed
call graph partitioner properly
1 parent 1891c70 commit 3da258b

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

test/partitioner/external_tools/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ project(ExtPartitioners)
44

55
set(CMAKE_INSTALL_PREFIX ${PROJECT_SOURCE_DIR}/install)
66

7-
# Set default build type to Debug if not specified
7+
# Set default build type to Release if not specified
88
if(NOT CMAKE_BUILD_TYPE)
9-
set(CMAKE_BUILD_TYPE Debug CACHE STRING "Build type" FORCE)
9+
set(CMAKE_BUILD_TYPE Release CACHE STRING "Build type" FORCE)
1010
endif()
1111

1212
set(CMAKE_CXX_STANDARD 17)

test/partitioner/external_tools/main.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -115,17 +115,17 @@ int main(int argc, char* argv[])
115115

116116
std::cout << "Partitioning " << json_file_name << " into " << parts << " parts using " << partition_method << std::endl;
117117

118-
std::vector<std::chrono::duration<double>> durations;
119-
120118
std::vector<std::string> methods;
121119
if (partition_method.empty()) {
122120
methods = {"SBG", "Metis", "Scotch", "Kahip"};
123121
} else {
124122
methods = {partition_method};
125123
}
126124

125+
GraphPartitioner partitioner(json_file_name, parts);
127126
for (const auto& m : methods) {
128-
GraphPartitioner partitioner(json_file_name, parts);
127+
std::vector<std::chrono::duration<double>> durations;
128+
129129
for (size_t i = 0; i < number_of_executions; i++) {
130130
std::cout << "running " << i << " of " << number_of_executions << std::endl;
131131
auto [partition, duration] = partitioner.createPartition(m, parts, i == number_of_executions - 1);

0 commit comments

Comments
 (0)