Github user zuyu commented on a diff in the pull request:
https://github.com/apache/incubator-quickstep/pull/22#discussion_r66701558
--- Diff: build/profile_build.sh ---
@@ -0,0 +1,65 @@
+#!/bin/bash
+# This script may be useful for developers to profile the build process
itself.
+#
+# This shell script runs CMake and make, dumping all output into a log
file.
+# It also logs the CPU usage and memory information during the build.
+# All log messages are timestamped to enable profiling.
+#
+# Dependencies:
+# - ts
+# sudo apt-get install -y libtime-duration-perl moreutils
+# - vmstat and mpstat
+# sudo apt-get install -y sysstat
+#
+# Usage: ./profile_build.sh [num_parallel_jobs]
+# The number of parallel make jobs can be passed as argument to this
script.
+# By default, it is the number of (virtual) CPUs on the machine (nproc).
+# Set the CMake flags you want to use below.
+#
+# If CMakeCache.txt is detected, the script skips cmake and runs make only.
+#
+
+NUM_JOBS=`nproc`
+if [[ "$1" != "" ]]; then
+ NUM_JOBS=$1
+fi
+
+echo "Starting build in " `pwd` >> build.log
+echo
+
+# Continuously dump memory usage and cpu load info to files for later
analysis
+rm -f stats_*.txt
+vmstat -SM 3 | ts "%.s (%H:%M:%S)" > stats_mem.txt 3>&1 &
+PID_vmstat=$!
+mpstat 3 | ts "%.s (%H:%M:%S)" > stats_cpu.txt 2>&1 &
+PID_mpstat=$!
+
+START_TIME=`date +"%s"`
+if [[ ! -f CMakeCache.txt ]]; then
+ CMAKE_COMMAND="cmake -D BUILD_SHARED_LIBS=On -D USE_TCMALLOC=0 \
+ -D CMAKE_BUILD_TYPE=Debug \
+ -D CMAKE_C_COMPILER=/usr/bin/clang -D
CMAKE_CXX_COMPILER=/usr/bin/clang++ .. "
--- End diff --
So I suggest to remove this compiler settings.
In a default case, we may not assume that users have `clang`, particularly
nowadays when `llvm.org/apt` is switched off.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---