Index: tools/tools/build_option_survey/mkhtml.sh
===================================================================
--- tools/tools/build_option_survey/mkhtml.sh
+++ tools/tools/build_option_survey/mkhtml.sh
@@ -74,16 +74,11 @@
' >> $H
-echo '
-The table is explained at the bottom
-
-' >> $H
-
echo '' >> $H
echo "" >> $H
echo "src.conf | " >> $H
-echo "MK_FOO | " >> $H
+echo "BW Time | " >> $H
echo " | " >> $H
echo "BuildWorld | " >> $H
echo " | " >> $H
@@ -110,7 +105,7 @@
elif [ -f $3/$1/_.success ] ; then
table_td $2 $1 $3 $4 >> $H
else
- echo "failed | " >> $H
+ echo "failed SC BW IW | " >> $H
fi
)
@@ -117,8 +112,9 @@
for o in $OPLIST
do
- md=`echo "${o}=foo" | md5`
- m=${RDIR}/$md
+echo "=== Processing $o"
+ md=$o
+ m=${RDIR}/$o
if [ ! -d $m ] ; then
continue
fi
@@ -128,14 +124,12 @@
echo "=== mkhtml ${d}_${o}"
echo "
" >> $H
- echo "" >> $H
- cat $m/src.conf >> $H
- echo " | " >> $H
- echo "" >> $H
- if [ -f $m/bw/_.sc ] ; then
- comm -13 ${RDIR}/Ref/_.sc $m/bw/_.sc >> $H
- fi
- echo " | " >> $H
+ echo "" >> $H
+ echo "$o" >> $H
+ echo " | " >> $H
+ echo "" >> $H
+ tail -1 ${RDIR}/$o/bw/_.bw | cut -f2 | cut -d ' ' -f1 >> $H
+ echo " | " >> $H
majcol bw r $m $md
majcol iw r $m $md
@@ -144,7 +138,6 @@
done
echo "
" >> $H
echo '
-
How to read this table
The table has five major columns.
@@ -159,8 +152,8 @@
-MK_FOO
-Internal build flags affected by this option
+BW Time
+The time buildworld completed in
Buildworld
@@ -208,17 +201,5 @@
Size change in kilobytes relative to the option not be given
-
-
' >> $H
-echo '
-
-
-
-
' >> $H
echo "" >> $H
-
-echo "rsync phk"
-rsync -r $HDIR/. phk@phk:www/misc/build_options
Index: tools/tools/build_option_survey/option_survey.sh
===================================================================
--- tools/tools/build_option_survey/option_survey.sh
+++ tools/tools/build_option_survey/option_survey.sh
@@ -27,7 +27,7 @@
if [ $a -ne 0 ] ; then
exit 1
fi
- make ${MAKE_JOBS} buildworld \
+ \time -h make ${MAKE_JOBS} buildworld \
SRCCONF=${ODIR}/src.conf __MAKE_CONF=/dev/null \
> ${FDIR}/_.bw 2>&1
a=$?
@@ -35,7 +35,7 @@
if [ $a -ne 0 ] ; then
exit 1
fi
- make ${MAKE_JOBS} buildkernel \
+ \time -h make ${MAKE_JOBS} buildkernel \
KERNCONF=GENERIC \
SRCCONF=${ODIR}/src.conf __MAKE_CONF=/dev/null \
> ${FDIR}/_.bk 2>&1
@@ -54,7 +54,7 @@
mount /dev/md${MDUNIT} ${MNT}
cd ../../..
- make ${MAKE_JOBS} installworld \
+ \time -h make ${MAKE_JOBS} installworld \
SRCCONF=${ODIR}/src.conf __MAKE_CONF=/dev/null \
DESTDIR=${MNT} \
> ${FDIR}/_.iw 2>&1
@@ -64,7 +64,7 @@
exit 1
fi
cd etc
- make distribution \
+ \time -h make distribution \
SRCCONF=${ODIR}/src.conf __MAKE_CONF=/dev/null \
DESTDIR=${MNT} \
> ${FDIR}/_.etc 2>&1
@@ -74,7 +74,7 @@
exit 1
fi
cd ..
- make ${MAKE_JOBS} installkernel \
+ \time -h make ${MAKE_JOBS} installkernel \
KERNCONF=GENERIC \
DESTDIR=${MNT} \
SRCCONF=${ODIR}/src.conf __MAKE_CONF=/dev/null \
@@ -99,19 +99,33 @@
echo "iw done"
)
-
# Clean and recreate the ODIR
-if true ; then
- echo "=== Clean and recreate ${ODIR}"
- if rm -rf ${ODIR} ; then
+#if true ; then
+# echo "=== Clean and recreate ${ODIR}"
+# if rm -rf ${ODIR} ; then
+# true
+# else
+# chflags -R noschg ${ODIR}
+# rm -rf ${ODIR}
+# fi
+# mkdir -p ${ODIR} ${FDIR} ${MNT}
+#
+#fi
+
+# Not cleaning for now to preserve reference build
+[ -d ${ODIR} ] || mkdir -p ${ODIR} ${FDIR} ${MNT}
+
+# Delete the non-reference builds, preserving the reference one
+if [ -d ${RDIR}/Ref ] ; then
+ mv ${RDIR}/Ref ${ODIR}
+ if rm -rf ${RDIR}/* ; then
true
else
- chflags -R noschg ${ODIR}
- rm -rf ${ODIR}
+ chflags -R noschg ${RDIR}
+ rm -rf ${RDIR}/*
fi
- mkdir -p ${ODIR} ${FDIR} ${MNT}
-
+ mv ${ODIR}/Ref ${RDIR}
fi
trap "umount ${MNT} || true; mdconfig -d -u $MDUNIT" 1 2 15 EXIT
@@ -118,7 +132,7 @@
umount $MNT || true
mdconfig -d -u $MDUNIT || true
-dd if=/dev/zero of=${ODIR}/imgfile bs=1m count=250
+dd if=/dev/zero of=${ODIR}/imgfile bs=1m count=4096
mdconfig -a -t vnode -f ${ODIR}/imgfile -u $MDUNIT
# Build & install the reference world
@@ -142,9 +156,8 @@
for o in $OPLIST
do
echo "${o}=foo" > ${FDIR}/_src.conf
- m=`md5 < ${FDIR}/_src.conf`
- mkdir -p ${RDIR}/$m
- mv ${FDIR}/_src.conf ${RDIR}/$m/src.conf
+ mkdir -p ${RDIR}/$o
+ mv ${FDIR}/_src.conf ${RDIR}/$o/src.conf
done
fi
@@ -151,7 +164,7 @@
# Run through each testtarget in turn
if true ; then
- for d in ${RDIR}/[0-9a-z]*
+ for d in ${RDIR}/WITH*
do
if [ ! -d $d ] ; then
continue;
Index: tools/tools/build_option_survey/reduce.sh
===================================================================
--- tools/tools/build_option_survey/reduce.sh
+++ tools/tools/build_option_survey/reduce.sh
@@ -36,8 +36,8 @@
for o in $OPLIST
do
- md=`echo "${o}=foo" | md5`
- m=${RDIR}/$md
+ md=$o
+ m=${RDIR}/$o
if [ ! -d $m ] ; then
continue
fi
@@ -44,12 +44,9 @@
if [ ! -d $m/iw -a ! -d $m/bw -a ! -d $m/w ] ; then
continue
fi
- echo "=== reduce ${o}"
- echo
echo -------------------------------------------------------------
echo $md
- cat $m/src.conf
echo -------------------------------------------------------------
if [ ! -f $m/iw/done ] ; then
echo "IW pending"