From da04320e040af4865abf4f8485e90715ea37a760 Mon Sep 17 00:00:00 2001 From: Sam Date: Fri, 1 Jul 2022 12:16:32 +1000 Subject: [PATCH 1/4] Rename index-stats to emit-statistics --- src/ast/analysis/JoinSize.cpp | 2 +- src/main.cpp | 8 ++++---- tests/scheduler/CMakeLists.txt | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/ast/analysis/JoinSize.cpp b/src/ast/analysis/JoinSize.cpp index e84c144e997..d550ffbbef8 100644 --- a/src/ast/analysis/JoinSize.cpp +++ b/src/ast/analysis/JoinSize.cpp @@ -134,7 +134,7 @@ std::vector JoinSizeAnalysis::computeJoinSiz joinSizeStatements.resize(sccOrdering.size()); auto& config = Global::config(); - if (!config.has("index-stats")) { + if (!config.has("emit-statistics")) { return joinSizeStatements; } diff --git a/src/main.cpp b/src/main.cpp index 2aa44b64216..1ed0fdc6696 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -435,7 +435,7 @@ int main(int argc, char** argv) { {"dl-program", 'o', "FILE", "", false, "Generate C++ source code, written to , and compile this to a " "binary executable (without executing it)."}, - {"index-stats", '\x9', "", "", false, "Enable collection of index statistics"}, + {"emit-statistics", '\x9', "", "", false, "Enable collection of index statistics"}, {"live-profile", '\1', "", "", false, "Enable live profiling."}, {"profile", 'p', "FILE", "", false, "Enable profiling, and write profile data to ."}, {"profile-frequency", '\2', "", "", false, "Enable the frequency counter in the profiler."}, @@ -562,10 +562,10 @@ int main(int argc, char** argv) { Global::config().set("profile"); } - /* if index-stats is set then check that the profiler is also set */ - if (Global::config().has("index-stats")) { + /* if emit-statistics is set then check that the profiler is also set */ + if (Global::config().has("emit-statistics")) { if (!Global::config().has("profile")) - throw std::runtime_error("must be profiling to collect index-stats"); + throw std::runtime_error("must be profiling to collect emit-statistics"); } } catch (std::exception& e) { diff --git a/tests/scheduler/CMakeLists.txt b/tests/scheduler/CMakeLists.txt index 100437e2d0f..a8cb8342721 100644 --- a/tests/scheduler/CMakeLists.txt +++ b/tests/scheduler/CMakeLists.txt @@ -24,7 +24,7 @@ function(SOUFFLE_ADD_SCHEDULER_TEST TEST_NAME) set(QUALIFIED_TEST_NAME scheduler/${TEST_NAME}_stats_collection) # Run stats collection - set(SOUFFLE_PARAMS "-p" "${OUTPUT_DIR}/${TEST_NAME}.prof" "--index-stats") + set(SOUFFLE_PARAMS "-p" "${OUTPUT_DIR}/${TEST_NAME}.prof" "--emit-statistics") add_test(NAME ${QUALIFIED_TEST_NAME} COMMAND ${Python3_EXECUTABLE} ${PROJECT_SOURCE_DIR}/cmake/redirect.py From 39ceacc40fe882b6980048a26c573b080522b065 Mon Sep 17 00:00:00 2001 From: Sam Date: Fri, 1 Jul 2022 12:18:10 +1000 Subject: [PATCH 2/4] Fix typo --- src/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.cpp b/src/main.cpp index 1ed0fdc6696..816f9c9f5c6 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -565,7 +565,7 @@ int main(int argc, char** argv) { /* if emit-statistics is set then check that the profiler is also set */ if (Global::config().has("emit-statistics")) { if (!Global::config().has("profile")) - throw std::runtime_error("must be profiling to collect emit-statistics"); + throw std::runtime_error("must be profiling to use emit-statistics"); } } catch (std::exception& e) { From 6adfee18122b74064d2ef9b96ce1c2d141cb70b8 Mon Sep 17 00:00:00 2001 From: Sam Date: Fri, 1 Jul 2022 12:19:29 +1000 Subject: [PATCH 3/4] Fix another typo --- src/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.cpp b/src/main.cpp index 816f9c9f5c6..1a65a988f09 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -435,7 +435,7 @@ int main(int argc, char** argv) { {"dl-program", 'o', "FILE", "", false, "Generate C++ source code, written to , and compile this to a " "binary executable (without executing it)."}, - {"emit-statistics", '\x9', "", "", false, "Enable collection of index statistics"}, + {"emit-statistics", '\x9', "", "", false, "Enable collection of statistics for auto-scheduling"}, {"live-profile", '\1', "", "", false, "Enable live profiling."}, {"profile", 'p', "FILE", "", false, "Enable profiling, and write profile data to ."}, {"profile-frequency", '\2', "", "", false, "Enable the frequency counter in the profiler."}, From 89c831cc7296e60119eacbf3b533060b69d5aeb1 Mon Sep 17 00:00:00 2001 From: Sam Date: Fri, 1 Jul 2022 12:42:41 +1000 Subject: [PATCH 4/4] Clang-format main.cpp --- src/main.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main.cpp b/src/main.cpp index 1a65a988f09..59594219801 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -435,7 +435,8 @@ int main(int argc, char** argv) { {"dl-program", 'o', "FILE", "", false, "Generate C++ source code, written to , and compile this to a " "binary executable (without executing it)."}, - {"emit-statistics", '\x9', "", "", false, "Enable collection of statistics for auto-scheduling"}, + {"emit-statistics", '\x9', "", "", false, + "Enable collection of statistics for auto-scheduling"}, {"live-profile", '\1', "", "", false, "Enable live profiling."}, {"profile", 'p', "FILE", "", false, "Enable profiling, and write profile data to ."}, {"profile-frequency", '\2', "", "", false, "Enable the frequency counter in the profiler."},