Browse Source

Check whether we have enough RAM to run the 2^28 and 2^30 experiments

Ian Goldberg 3 months ago
parent
commit
da677c6167
3 changed files with 31 additions and 2 deletions
  1. 11 0
      prac/repro
  2. 10 1
      prac/repro-bs.sh
  3. 10 1
      prac/repro-reads.sh

+ 11 - 0
prac/repro

@@ -19,6 +19,17 @@ if [ "$FLORAM_NUMA_P1" == "" -a "$PRAC_NUMA_P1" != "" ]; then
     export FLORAM_NUMA_P1="$PRAC_NUMA_P1"
 fi
 
+# If the PRAC memory usage is set, use it for Floram.
+if [ "$PRAC_P0_MAXGB" != "" ]; then
+    export FLORAM_MAXGB=$((2*PRAC_P0_MAXGB))
+elif [ "$PRAC_P02_MAXGB" != "" ]; then
+    export FLORAM_MAXGB=$((2*PRAC_P02_MAXGB))
+elif [ "$PRAC_MAXGB" != "" ]; then
+    export FLORAM_MAXGB=$PRAC_MAXGB
+else
+    export FLORAM_MAXGB=16
+fi
+
 # Allow running only subsets of the experiment suite.  Valid values are
 # "test", "all", "none".  ("none" is useful if you just want to re-parse
 # the output of existing logs.)  You can also say "single" followed by

+ 10 - 1
prac/repro-bs.sh

@@ -7,10 +7,19 @@ if [ "$1" != "" ]; then
     nitrs="$1"
 fi
 
+# Check whether we have enough RAM to do the two largest experiments
+if [ "$FLORAM_MAXGB" -gt 96 ]; then
+    large_exps="28 30"
+elif [ "$FLORAM_MAXGB" -gt 24 ]; then
+    large_exps="28"
+else
+    large_exps=""
+fi
+
 cd ..
 mkdir -p prac/data
 for itr in $(seq 1 $nitrs); do
-    for size in 16 18 20 22 24 26 28 30; do
+    for size in 16 18 20 22 24 26 ${large_exps}; do
         now=`date`; echo "$now: Running 1 search on DB of size 2^${size} ..."
         ./run-experiment bs ${size} 1 >> prac/data/log_${size}_1_bs.out
     done

+ 10 - 1
prac/repro-reads.sh

@@ -7,10 +7,19 @@ if [ "$1" != "" ]; then
     nitrs="$1"
 fi
 
+# Check whether we have enough RAM to do the two largest experiments
+if [ "$FLORAM_MAXGB" -gt 128 ]; then
+    large_exps="28 30"
+elif [ "$FLORAM_MAXGB" -gt 32 ]; then
+    large_exps="28"
+else
+    large_exps=""
+fi
+
 cd ..
 mkdir -p prac/data
 for itr in $(seq 1 $nitrs); do
-    for size in 16 18 20 22 24 26 28 30; do
+    for size in 16 18 20 22 24 26 ${large_exps}; do
         now=`date`; echo "$now: Running 10 reads on DB of size 2^${size} ..."
         ./run-experiment read ${size} 10 >> prac/data/log_${size}_10_reads.out
     done